Merlijn van Deen has uploaded a new change for review. https://gerrit.wikimedia.org/r/83808
Change subject: Fix auto-summary in delete.py ...................................................................... Fix auto-summary in delete.py mysite was not defined. pywikibot.handleArgs is guaranteed to return a list (as opposed to a generator) after parsing all global arguments (such as -lang and -family). This means it's safe to call pywikibot.getSite immediately after handleArgs, but before handling local arguments. Change-Id: I0bd76806e460fec200973a712370e459c9189ea7 Fixes-Change-Id: https://gerrit.wikimedia.org/r/#q,I386328c62b1bbeb7022a620f8e95d25a67686371,n,z --- M delete.py 1 file changed, 4 insertions(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/pywikibot/compat refs/changes/08/83808/1 diff --git a/delete.py b/delete.py index d1e2c13..f8ce025 100644 --- a/delete.py +++ b/delete.py @@ -75,7 +75,10 @@ generator = None # read command line parameters - for arg in pywikibot.handleArgs(): + localargs = pywikibot.handleArgs() + mysite = pywikibot.getSite() + + for arg in localargs: if arg == '-always': always = True elif arg.startswith('-summary'): -- To view, visit https://gerrit.wikimedia.org/r/83808 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I0bd76806e460fec200973a712370e459c9189ea7 Gerrit-PatchSet: 1 Gerrit-Project: pywikibot/compat Gerrit-Branch: master Gerrit-Owner: Merlijn van Deen <valhall...@arctus.nl> _______________________________________________ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits