jenkins-bot has submitted this change. ( 
https://gerrit.wikimedia.org/r/c/pywikibot/core/+/697400 )

Change subject: [bugfix] Remove outdated opt._option which is already dropped
......................................................................

[bugfix] Remove outdated opt._option which is already dropped

Bug: T284005
Change-Id: I38d9a96f63ea5c08bc5d086a1e8d43f326313780
---
M pywikibot/bot.py
1 file changed, 3 insertions(+), 5 deletions(-)

Approvals:
  JJMC89: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/pywikibot/bot.py b/pywikibot/bot.py
index 118823a..216b39d 100644
--- a/pywikibot/bot.py
+++ b/pywikibot/bot.py
@@ -1136,11 +1136,9 @@

         # self.opt contains all available options including defaults
         self.opt = _OptionDict(self.__class__.__name__, self.available_options)
-        # self.options contains the options overridden from defaults
-        self.opt._options = {opt: options[opt]
-                             for opt in received_options & valid_options}
-        self.opt.update(self.opt._options)
-
+        # update the options overridden from defaults
+        self.opt.update((opt, options[opt])
+                        for opt in received_options & valid_options)
         for opt in received_options - valid_options:
             pywikibot.warning('{} is not a valid option. It was ignored.'
                               .format(opt))

--
To view, visit https://gerrit.wikimedia.org/r/c/pywikibot/core/+/697400
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.wikimedia.org/r/settings

Gerrit-Project: pywikibot/core
Gerrit-Branch: master
Gerrit-Change-Id: I38d9a96f63ea5c08bc5d086a1e8d43f326313780
Gerrit-Change-Number: 697400
Gerrit-PatchSet: 2
Gerrit-Owner: Xqt <[email protected]>
Gerrit-Reviewer: JJMC89 <[email protected]>
Gerrit-Reviewer: jenkins-bot
Gerrit-MessageType: merged
_______________________________________________
Pywikibot-commits mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to