jenkins-bot has submitted this change and it was merged.
Change subject: Identify which page is no redirect
......................................................................
Identify which page is no redirect
One hypothesis why the site tests tells that images are redirects
although it only queried non-redirects is that between iterating through
it and checking it changes to a redirect page. This prints the checked
page if it is a redirect in an attempt to verify that hypothesis.
Bug: 73120
Change-Id: I970099e8aaa9d558909ae9e1a8091aaf6f092829
---
M tests/site_tests.py
1 file changed, 3 insertions(+), 0 deletions(-)
Approvals:
John Vandenberg: Looks good to me, approved
jenkins-bot: Verified
diff --git a/tests/site_tests.py b/tests/site_tests.py
index df22137..30c2644 100644
--- a/tests/site_tests.py
+++ b/tests/site_tests.py
@@ -696,6 +696,9 @@
imagepage = self.imagepage
for using in mysite.imageusage(imagepage, filterredir=False, total=5):
self.assertIsInstance(using, pywikibot.Page)
+ if using.isRedirectPage():
+ print('{0} is a redirect, although just non-redirects were '
+ 'searched. See also bug 73120'.format(using))
self.assertFalse(using.isRedirectPage())
--
To view, visit https://gerrit.wikimedia.org/r/171814
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: I970099e8aaa9d558909ae9e1a8091aaf6f092829
Gerrit-PatchSet: 3
Gerrit-Project: pywikibot/core
Gerrit-Branch: master
Gerrit-Owner: XZise <[email protected]>
Gerrit-Reviewer: John Vandenberg <[email protected]>
Gerrit-Reviewer: Ladsgroup <[email protected]>
Gerrit-Reviewer: Merlijn van Deen <[email protected]>
Gerrit-Reviewer: jenkins-bot <>
_______________________________________________
Pywikibot-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/pywikibot-commits