jenkins-bot has submitted this change and it was merged. ( https://gerrit.wikimedia.org/r/560518 )
Change subject: [IMPR] shorten lang['prefix'] to key ......................................................................
[IMPR] shorten lang['prefix'] to key
detached from I1817868c952685949709f18ee845fc00727c0ca5
Change-Id: Ib5203d144c287d41f82c867b23756eb28668d5ab --- M generate_family_file.py 1 file changed, 4 insertions(+), 3 deletions(-)
Approvals: Dvorapa: Looks good to me, approved jenkins-bot: Verified
diff --git a/generate_family_file.py b/generate_family_file.py index 97eac88..03bfc2d 100755 --- a/generate_family_file.py +++ b/generate_family_file.py @@ -108,10 +108,11 @@ """Load other language pages.""" print('Loading wikis... ') for lang in self.langs: - print(' * %s... ' % (lang['prefix']), end='') - if lang['prefix'] not in self.wikis: + key = lang['prefix'] + print(' * {}... '.format(key), end='') + if key not in self.wikis: try: - self.wikis[lang['prefix']] = self.Wiki(lang['url']) + self.wikis[key] = self.Wiki(lang['url']) print('downloaded') except Exception as e: print(e)
pywikibot-commits@lists.wikimedia.org