Page MenuHomePhabricator

Page.templates() cache does not respect get_redirect
Closed, DeclinedPublic

Description

Originally from: http://sourceforge.net/p/pywikipediabot/bugs/1257/
Reported by: tgr_
Created on: 2010-10-31 10:39:27
Subject: Page.templates() cache does not respect get_redirect
Original description:
Steps to reproduce:

page = wikipedia.Page\(someSite, someRedirect\)
page.templates\(\) \# returns \[\]
page.templates\(get\_redirect=True\) \# returns \[\] from cache even if the page does have templates

Pywikipedia \[http\] trunk/pywikipedia \(r8690, 2010/10/28, 15:34:19\)
Python 2.6.5 \(r265:79096, Mar 19 2010, 21:48:26\) \[MSC v.1500 32 bit \(Intel\)\]
config-settings:
use\_api = True
use\_api\_login = True
unicode test: ok


Version: compat-(1.0)
Severity: normal
See Also:
https://sourceforge.net/p/pywikipediabot/bugs/1257
T58188: core Page.templates has incompatible API change from compat

Details

Reference
bz55256

Event Timeline

bzimport raised the priority of this task from to High.Nov 22 2014, 2:30 AM
bzimport set Reference to bz55256.
bzimport added a subscriber: Unknown Object (????).
  • Bug 55227 has been marked as a duplicate of this bug. ***

TEST SCRIPT:
import pywikibot
p = pywikibot.Page(pywikibot.getSite("en", "wikipedia"), "Wikipedia:K")
print p.templates()
print p.templates(get_redirect=True)
p = pywikibot.Page(pywikibot.getSite("en", "wikipedia"), "Wikipedia:K")
print p.templates(get_redirect=True)

CONFIRMED on compat:
Pywikibot: [https] r/pywikibot/co (r10375, 80b6c36, 2013/10/25, 20:37:20, ok)

The bug does not exist on core because the API is different (in an incompatible way, see bug 56188

Aklapper lowered the priority of this task from High to Lowest.Jun 5 2015, 1:41 PM
Aklapper subscribed.

Pywikibot has two versions: Compat and Core. This task was filed about the older version, called Pywikibot-compat, which is not under active development anymore. Hence I'm lowering the priority of this task to reflect the reality. Unfortunately, the Pywikibot team does not have the manpower to retest every single bug report / feature request against the (maintained) Pywikibot code base. Furthermore, the code base of Pywikibot-Compat has changed a lot compared to the code base of Pywikibot-Core so there is a chance that the problem described in this task might not exist anymore. Please help: Unfortunately manpower is limited and does not allow testing every single reported task again. If you have time and interest in Pywikibot, please upgrade to Pywikibot-Core and add a comment to this task if the problem in this task still happens in Pywikibot-Core (or directly edit the task by removing the Pywikibot-compat project and adding the Pywikibot project to this task). To learn more about Pywikibot and to get involved in its development, please check out https://www.mediawiki.org/wiki/Manual:Pywikibot/Development Thank you for your understanding.

Xqt subscribed.

compat branch is closed