jenkins-bot has submitted this change. ( https://gerrit.wikimedia.org/r/c/pywikibot/core/+/611841 )
Change subject: Fix KeyError when extension has no name ......................................................................
Fix KeyError when extension has no name
Change-Id: I620ed38d5a8ee2cae5b46cb26a5f133699885423 --- M pywikibot/site/__init__.py 1 file changed, 1 insertion(+), 1 deletion(-)
Approvals: JJMC89: Looks good to me, approved jenkins-bot: Verified
diff --git a/pywikibot/site/__init__.py b/pywikibot/site/__init__.py index bef6a1f..a96ce98 100644 --- a/pywikibot/site/__init__.py +++ b/pywikibot/site/__init__.py @@ -2670,7 +2670,7 @@ """ extensions = self.siteinfo['extensions'] for ext in extensions: - if ext['name'] == name: + if 'name' in ext and ext['name'] == name: return True return False