jenkins-bot has submitted this change. ( https://gerrit.wikimedia.org/r/c/pywikibot/core/+/808289 )
Change subject: [IMPR] PEP8 updates ......................................................................
[IMPR] PEP8 updates
Bug: T305859 Change-Id: Iedf5eac852c2db1e3774b8915720568e1b0927d9 --- M scripts/dataextend.py 1 file changed, 6 insertions(+), 0 deletions(-)
Approvals: Xqt: Looks good to me, approved jenkins-bot: Verified
diff --git a/scripts/dataextend.py b/scripts/dataextend.py index a2c42c4..8c8135b 100644 --- a/scripts/dataextend.py +++ b/scripts/dataextend.py @@ -2604,6 +2604,8 @@ result = self.findbyre(r'>{}|([^<>]+)'.format(name), html) if result: return result.replace(' ', '') + else: + return None
def findlanguagenames(self, html): languagenames = set() @@ -2636,11 +2638,15 @@ section = self.findbyre(r'ns1:nationalityOfEntity(.*?)</ns1:nationalityOfEntity>', html) if section: return self.findallbyre(r'ns1:text([^<>]+)</ns1:text>', section, 'country') + else: + return None
def findlanguagesspoken(self, html): section = self.findbyre(r'ns1:languageOfEntity(.*?)</ns1:languageOfEntity>', html) if section: return self.findallbyre(r'ns1:text([^<>]+)</ns1:text>', section, 'language') + else: + return None
def findoccupations(self, html): sections = self.findallbyre(r'ns1:occupation(.*?)</ns1:occupation>', html)
pywikibot-commits@lists.wikimedia.org