Xqt has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/273584

Change subject: [bugfix] Don't break redirect.py for InterwikiRedirectPage 
exception
......................................................................

[bugfix] Don't break redirect.py for InterwikiRedirectPage exception

Bug: T128283
Change-Id: Ib69f9fc8add170dfcc606b5cfed25ad097332505
---
M scripts/redirect.py
1 file changed, 2 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/pywikibot/core 
refs/changes/84/273584/1

diff --git a/scripts/redirect.py b/scripts/redirect.py
index edfa28d..5c8952f 100755
--- a/scripts/redirect.py
+++ b/scripts/redirect.py
@@ -421,6 +421,8 @@
             pywikibot.output(u'%s doesn\'t exist.' % redir_page.title())
         except pywikibot.InvalidTitle:
             pywikibot.exception()
+        except pywikibot.InterwikiRedirectPage:
+            pywikibot.output('%s is on another site.' % redir_page.title())
         else:
             try:
                 targetPage.get()

-- 
To view, visit https://gerrit.wikimedia.org/r/273584
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ib69f9fc8add170dfcc606b5cfed25ad097332505
Gerrit-PatchSet: 1
Gerrit-Project: pywikibot/core
Gerrit-Branch: master
Gerrit-Owner: Xqt <[email protected]>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to