jenkins-bot has submitted this change and it was merged.
Change subject: Page.categories parameter withSortKey ignored
......................................................................
Page.categories parameter withSortKey ignored
The withSortKey parameter of Site.pagecategories has been marked as deprecated
since the method was first introduced. However the method Page.categories
has an equivalent parameter which it passes to Site.pagecategories, only
for it to be ignored.
Raise NotImplementedError if withSortKey is enabled calling Page.categories.
Bug: 73561
Change-Id: I22ce77fb91c1f02b71dc028fe75178b1b40c1cde
---
M pywikibot/page.py
1 file changed, 6 insertions(+), 2 deletions(-)
Approvals:
John Vandenberg: Looks good to me, but someone else must approve
Nullzero: Looks good to me, approved
jenkins-bot: Verified
diff --git a/pywikibot/page.py b/pywikibot/page.py
index bda181f..2d71d8a 100644
--- a/pywikibot/page.py
+++ b/pywikibot/page.py
@@ -1341,8 +1341,12 @@
@return: a generator that yields Category objects.
"""
- return self.site.pagecategories(self, withSortKey=withSortKey,
- step=step, total=total, content=content)
+ # FIXME: bug 73561: withSortKey is ignored by Site.pagecategories
+ if withSortKey:
+ raise NotImplementedError('withSortKey is not implemented')
+
+ return self.site.pagecategories(self, step=step, total=total,
+ content=content)
def extlinks(self, step=None, total=None):
"""Iterate all external URLs (not interwiki links) from this
page.
--
To view, visit
https://gerrit.wikimedia.org/r/174143
To unsubscribe, visit
https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: I22ce77fb91c1f02b71dc028fe75178b1b40c1cde
Gerrit-PatchSet: 1
Gerrit-Project: pywikibot/core
Gerrit-Branch: master
Gerrit-Owner: John Vandenberg <jayvdb(a)gmail.com>
Gerrit-Reviewer: John Vandenberg <jayvdb(a)gmail.com>
Gerrit-Reviewer: Ladsgroup <ladsgroup(a)gmail.com>
Gerrit-Reviewer: Merlijn van Deen <valhallasw(a)arctus.nl>
Gerrit-Reviewer: Nullzero <nullzero.free(a)gmail.com>
Gerrit-Reviewer: jenkins-bot <>