binbot created this task.
binbot added a project: Pywikibot.
Restricted Application added subscribers: pywikibot-bugs-list, Aklapper.
TASK DESCRIPTION
**Steps to replicate the issue** (ineeds admin rights, try on a wiki where
you are admin):
import pywikibot
site = pywikibot.Site('wikipedia:hu')
page = pywikibot.Page(site, '2023')
print(type(page.getDeletedRevision('2023-01-30T19:11:36Z', content=True)))
print(page.getDeletedRevision('2023-01-30T19:11:36Z', content=True).keys())
**What happens?**:
<class 'dict'>
dict_keys(['revid', 'user', 'timestamp', 'slots', 'comment'])
**What should have happened instead?**:
https://doc.wikimedia.org/pywikibot/master/_modules/pywikibot/page/_basepage.html#BasePage.getDeletedRevision
says:
return: a list of [date, editor, comment, text, restoration
marker]. text will be None, unless content is True (or has
been retrieved earlier).
This is a dictionary, no text (although available from slots), no marker,
instead slots. Documentation and working code should be in accordance.
**Software version** (skip for WMF-hosted wikis like Wikipedia): 8.0.0
TASK DETAIL
https://phabricator.wikimedia.org/T331422
EMAIL PREFERENCES
https://phabricator.wikimedia.org/settings/panel/emailpreferences/
To: binbot
Cc: Aklapper, pywikibot-bugs-list, binbot, PotsdamLamb, Jyoo1011, JohnsonLee01,
SHEKH, Dijkstra, Khutuck, Zkhalido, Viztor, Wenyi, Tbscho, MayS, Framawiki,
Mdupont, JJMC89, Dvorapa, Altostratus, Avicennasis, mys_721tx, Xqt, jayvdb,
Masti, Alchimista
_______________________________________________
pywikibot-bugs mailing list -- [email protected]
To unsubscribe send an email to [email protected]