jenkins-bot has submitted this change and it was merged.
Change subject: config command line option 'modified' fails
......................................................................
config command line option 'modified' fails
- move global name 'base_dir' before the population of _glv
- delete variable 'ov' which is used only in a procedural block
that is executed in the global scope
Bug 66950
Change-Id: I482ce11abd1a0a6b078ef489ee1256fde2320758
---
M pywikibot/config2.py
1 file changed, 3 insertions(+), 4 deletions(-)
Approvals:
Merlijn van Deen: Looks good to me, approved
jenkins-bot: Verified
diff --git a/pywikibot/config2.py b/pywikibot/config2.py
index 6cca983..4b30df4 100644
--- a/pywikibot/config2.py
+++ b/pywikibot/config2.py
@@ -160,6 +160,8 @@
return base_dir
_base_dir = _get_base_dir()
+# Save base_dir for use by other modules
+base_dir = _base_dir
family_files = {}
@@ -716,7 +718,7 @@
print("WARNING: Type of '%(_key)s' changed" % locals())
print(" %(was)s: %(old)s" % {'was': "Was", 'old': ot})
print(" %(now)s: %(new)s" % {'now': "Now", 'new': nt})
- del nt, ot
+ del nt, ot, ov
else:
print(("WARNING: "
"Configuration variable %(_key)r is defined but unknown.\n"
@@ -741,9 +743,6 @@
transliteration_target = None
elif transliteration_target in ('None', 'none'):
transliteration_target = None
-
-# Save base_dir for use by other modules
-base_dir = _base_dir
#
--
To view, visit https://gerrit.wikimedia.org/r/141288
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: I482ce11abd1a0a6b078ef489ee1256fde2320758
Gerrit-PatchSet: 1
Gerrit-Project: pywikibot/core
Gerrit-Branch: master
Gerrit-Owner: John Vandenberg <[email protected]>
Gerrit-Reviewer: Ladsgroup <[email protected]>
Gerrit-Reviewer: Merlijn van Deen <[email protected]>
Gerrit-Reviewer: jenkins-bot <>
_______________________________________________
Pywikibot-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/pywikibot-commits