jenkins-bot has submitted this change. ( https://gerrit.wikimedia.org/r/c/pywikibot/core/+/612173 )
Change subject: [bugfix] Do lookups with stripped fragments ......................................................................
[bugfix] Do lookups with stripped fragments
Accidentally dropped in I802948afb.
Change-Id: Iee1e9d819830a54e4cef3d691b35d9c255b9ee84 --- M pywikibot/cosmetic_changes.py 1 file changed, 1 insertion(+), 1 deletion(-)
Approvals: Xqt: Looks good to me, approved jenkins-bot: Verified
diff --git a/pywikibot/cosmetic_changes.py b/pywikibot/cosmetic_changes.py index ff45c5f..740d5a1 100755 --- a/pywikibot/cosmetic_changes.py +++ b/pywikibot/cosmetic_changes.py @@ -472,7 +472,7 @@ # push ']]' out and re-add below split[-1] = split[-1][:-2] return '{}|{}]]'.format( - split[0], '|'.join(cache.get(x, x) for x in split[1:])) + split[0], '|'.join(cache.get(x.strip(), x) for x in split[1:]))
cache = {} exceptions = ['nowiki', 'comment', 'pre', 'source']
pywikibot-commits@lists.wikimedia.org