https://bugzilla.wikimedia.org/show_bug.cgi?id=72207
Bug ID: 72207 Summary: detect write api actions Product: Pywikibot Version: core (2.0) Hardware: All OS: All Status: NEW Severity: enhancement Priority: Unprioritized Component: network Assignee: Pywikipedia-bugs@lists.wikimedia.org Reporter: jayvdb@gmail.com Web browser: --- Mobile Platform: ---
(Cloned from bug 55068 comment 10)
pywikbot api.py has a hard-coded list of 'write' actions, which cause it to assert the user is logged in.
This should be converted to a detection algorithm (using API action paraminfo)
https://bugzilla.wikimedia.org/show_bug.cgi?id=72207
Ricordisamoa ricordisamoa@openmailbox.org changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |ricordisamoa@openmailbox.or | |g
--- Comment #1 from Ricordisamoa ricordisamoa@openmailbox.org --- Ideally, a persistent cache should be set up to remember the 'paraminfo' data.
For example, the "writerights" property would enable assertion, while "tokentype" would help guessing the required token type automatically.
E.g.: https://www.mediawiki.org/w/api.php?action=paraminfo&modules=thank
pywikipedia-bugs@lists.wikimedia.org