jenkins-bot has submitted this change. ( https://gerrit.wikimedia.org/r/c/pywikibot/core/+/947329 )
Change subject: [IMPR] Enable -touch in newitem script for confirmed user ......................................................................
[IMPR] Enable -touch in newitem script for confirmed user
Bug: T343877 Change-Id: I1dfa90bf54f0d7a7866a9eba99203f68ed9d8c9c --- M scripts/newitem.py 1 file changed, 13 insertions(+), 2 deletions(-)
Approvals: Xqt: Looks good to me, approved jenkins-bot: Verified
diff --git a/scripts/newitem.py b/scripts/newitem.py index 61cdd06..5671960 100755 --- a/scripts/newitem.py +++ b/scripts/newitem.py @@ -20,7 +20,7 @@
""" # -# (C) Pywikibot team, 2014-2022 +# (C) Pywikibot team, 2014-2023 # # Distributed under the terms of the MIT license. # @@ -212,7 +212,8 @@ if not bot.site.logged_in(): bot.site.login() user = pywikibot.User(bot.site, bot.site.username()) - if bot.opt.touch == 'newly' and 'autoconfirmed' not in user.groups(): + if bot.opt.touch == 'newly' and not ( + 'autoconfirmed' in user.groups() or 'confirmed' in user.groups()): pywikibot.warning(fill( f'You are logged in as {user.username}, an account that is not in ' f'the autoconfirmed group on {bot.site.sitename}. Script will not '
pywikibot-commits@lists.wikimedia.org