jenkins-bot has submitted this change. (
https://gerrit.wikimedia.org/r/c/pywikibot/core/+/1306108?usp=email )
Change subject: interwiki: fix pattern for getting dump files
......................................................................
interwiki: fix pattern for getting dump files
Some site codes contains hyphens but they aren't recognized by
the pattern for getting dump files. Modify this pattern accordingly.
Bug: T430451
Change-Id: Id5cc674252f27ece8c1ab19cd800fe6ec1a69a1d
---
M scripts/interwiki.py
1 file changed, 1 insertion(+), 1 deletion(-)
Approvals:
jenkins-bot: Verified
Xqt: Looks good to me, approved
diff --git a/scripts/interwiki.py b/scripts/interwiki.py
index 1ae839d..bbd5bfe 100755
--- a/scripts/interwiki.py
+++ b/scripts/interwiki.py
@@ -2264,7 +2264,7 @@
def get_files(self):
"""Get dump files from directory."""
- pattern = r'(?P<file>(?P<fam>[a-z]+)-(?P<code>[a-z]+)\.txt)'
+ pattern = r'(?P<file>(?P<fam>[a-z]+)-(?P<code>[a-z-]+)\.txt)'
for filename in os.listdir(self.path):
found = re.fullmatch(pattern, filename)
if found:
--
To view, visit
https://gerrit.wikimedia.org/r/c/pywikibot/core/+/1306108?usp=email
To unsubscribe, or for help writing mail filters, visit
https://gerrit.wikimedia.org/r/settings?usp=email
Gerrit-MessageType: merged
Gerrit-Project: pywikibot/core
Gerrit-Branch: master
Gerrit-Change-Id: Id5cc674252f27ece8c1ab19cd800fe6ec1a69a1d
Gerrit-Change-Number: 1306108
Gerrit-PatchSet: 2
Gerrit-Owner: Xqt <[email protected]>
Gerrit-Reviewer: Xqt <[email protected]>
Gerrit-Reviewer: jenkins-bot
_______________________________________________
Pywikibot-commits mailing list -- [email protected]
To unsubscribe send an email to [email protected]