XZise created this task.
XZise added a subscriber: XZise.
XZise added projects: pywikibot-core, Pywikibot-tests.
Restricted Application added subscribers: Aklapper, pywikipedia-bugs.
TASK DESCRIPTION
I think when a dry test fails to set up that subsequent test also fail when they create a site instance and you get errors like:
```
======================================================================
ERROR: setUpClass (tests.deletionbot_tests.TestDeletionBotWrite)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/home/xzise/Programms/pywikibot/core/tests/aspects.py", line 578, in setUpClass
super(RequireUserMixin, cls).setUpClass()
File "/home/xzise/Programms/pywikibot/core/tests/aspects.py", line 531, in setUpClass
super(SiteWriteMixin, cls).setUpClass()
File "/home/xzise/Programms/pywikibot/core/tests/aspects.py", line 456, in setUpClass
super(CheckHostnameMixin, cls).setUpClass()
File "/home/xzise/Programms/pywikibot/core/tests/aspects.py", line 830, in setUpClass
interface=interface)
File "/home/xzise/Programms/pywikibot/core/pywikibot/__init__.py", line 604, in Site
_sites[key] = interface(code=code, fam=fam, user=user, sysop=sysop)
File "/home/xzise/Programms/pywikibot/core/tests/aspects.py", line 377, in __init__
% (fam, code))
pywikibot.exceptions.SiteDefinitionError: Loading site test:test during dry test not permitted
```
I need to further study that but when I did one test manually it worked fine but as soon as I did it in the test suite it errored with a similar message as above. Now that I've fixed that one place (`tests.dry_api_tests.DryCachedRequestTests.setUp` to be exact) the tests don't fail anymore.
TASK DETAIL
https://phabricator.wikimedia.org/T93471
REPLY HANDLER ACTIONS
Reply to comment or attach files, or !close, !claim, !unsubscribe or !assign <username>.
EMAIL PREFERENCES
https://phabricator.wikimedia.org/settings/panel/emailpreferences/
To: XZise
Cc: pywikipedia-bugs, Aklapper, XZise, jayvdb
NiharikaKohli added a comment.
We're holding an IRC meeting on March 25, at 1700 UTC <http://www.timeanddate.com/worldclock/fixedtime.html?msg=MediaWiki+GSoC%2FO…> for prospective GSoC and Outreachy participants with Wikimedia, on #wikimedia-office channel. Do join us!
TASK DETAIL
https://phabricator.wikimedia.org/T74065
REPLY HANDLER ACTIONS
Reply to comment or attach files, or !close, !claim, !unsubscribe or !assign <username>.
EMAIL PREFERENCES
https://phabricator.wikimedia.org/settings/panel/emailpreferences/
To: NiharikaKohli
Cc: Nv1620, Sampadmedda, Aklapper, kruti_c, Diptichavan, Liuxinyu970226, akashagarwal, NiharikaKohli, Dumindux, JeanFred, Legoktm, Evanontario, Sitic, Qgil, Ricordisamoa, Halfak, Krinkle, jayvdb, valhallasw, MZMcBride, csteipp, Imaculate, pywikipedia-bugs
XZise added a comment.
One quick work around would be to do `my_site.tokens._tokens.clear()` which removes all cached tokens. It's not pretty but until there is a sensible fix that should work.
TASK DETAIL
https://phabricator.wikimedia.org/T61678
REPLY HANDLER ACTIONS
Reply to comment or attach files, or !close, !claim, !unsubscribe or !assign <username>.
EMAIL PREFERENCES
https://phabricator.wikimedia.org/settings/panel/emailpreferences/
To: XZise
Cc: Twp, NiharikaKohli, XZise, Sitic, Qgil, Daniel_Mietchen, jayvdb, valhallasw, Ricordisamoa, 555, Multichill, Ladsgroup, pywikipedia-bugs
Twp added a subscriber: Twp.
Twp added a comment.
This is also a considerable problem for me. My bot operates with a relatively slow edit rate (once every few hours) and it's hitting the badtoken exception on every edit. I can work around it with a wrapper to check for a badtoken error and retry the edit, but it's silly that the application should have to implement that.
I'm still digging through the pywikibot code to find the best place to fix it, but I'm inclined to agree that if it's too difficult to cache tokens reliably then they shouldn't be cached at all. Better to take an efficiency hit than to compromise functionality.
TASK DETAIL
https://phabricator.wikimedia.org/T61678
REPLY HANDLER ACTIONS
Reply to comment or attach files, or !close, !claim, !unsubscribe or !assign <username>.
EMAIL PREFERENCES
https://phabricator.wikimedia.org/settings/panel/emailpreferences/
To: Twp
Cc: Twp, NiharikaKohli, XZise, Sitic, Qgil, Daniel_Mietchen, jayvdb, valhallasw, Ricordisamoa, 555, Multichill, Ladsgroup, pywikipedia-bugs
Qgil added subscribers: EBernhardson, rmoen.
Qgil added a comment.
In https://phabricator.wikimedia.org/T67119#1133446, @jayvdb wrote:
> I am willing to write this up as a project, if a flow developer can be a co-mentor to
CCing more Flow devs. The deadline for candidate proposals is in a week, so realistically speaking we need a yes/no... today?
TASK DETAIL
https://phabricator.wikimedia.org/T67119
REPLY HANDLER ACTIONS
Reply to comment or attach files, or !close, !claim, !unsubscribe or !assign <username>.
EMAIL PREFERENCES
https://phabricator.wikimedia.org/settings/panel/emailpreferences/
To: Qgil
Cc: rmoen, EBernhardson, NiharikaKohli, Capt_Swing, Qgil, jayvdb, Mattflaschen, Xqt, Ricordisamoa, Multichill, Ladsgroup, matthiasmullie, Gryllida, Spage, Quiddity, pywikipedia-bugs
jayvdb closed blocking task T73788: version.getfileversion does not work on py3, and should be rewritten as "Resolved".
TASK DETAIL
https://phabricator.wikimedia.org/T60053
REPLY HANDLER ACTIONS
Reply to comment or attach files, or !close, !claim, !unsubscribe or !assign <username>.
EMAIL PREFERENCES
https://phabricator.wikimedia.org/settings/panel/emailpreferences/
To: jayvdb
Cc: Xqt, jayvdb, valhallasw, Ricordisamoa, Ladsgroup, XZise, Dalba, pywikipedia-bugs
XZise created this task.
XZise added subscribers: XZise, jayvdb.
XZise added a project: pywikibot-core.
Restricted Application added subscribers: Aklapper, pywikipedia-bugs.
TASK DESCRIPTION
There are the actions [[https://en.wikipedia.org/w/api.php?action=help&modules=query+tokens|`query+…]] and [[https://en.wikipedia.org/w/api.php?action=help&modules=tokens|`tokens`]] but it is impossible to differ between them using the `ParamInfo` class as it automatically chooses the query module (if there exist one).
This makes it hard to implement T85725 using this class as sometimes the query module and sometimes the action module is needed.
```
>>> 'tokens' in pywikibot.Site('en', 'wikipedia')._paraminfo._query_modules
True
>>> 'tokens' in pywikibot.Site('en', 'wikipedia')._paraminfo._action_modules
True
>>> pywikibot.Site('en', 'wikipedia')._paraminfo._query_modules & pywikibot.Site('en', 'wikipedia')._paraminfo._action_modules
frozenset({'tokens'})
```
I think we should do it similar to how the API does it and `the_site._paraminfo['query+tokens']` should be given explicitly, although for backwards compatibility we probably need `the_site._paraminfo['action+tokens']` because we currently return the query module.
TASK DETAIL
https://phabricator.wikimedia.org/T92626
REPLY HANDLER ACTIONS
Reply to comment or attach files, or !close, !claim, !unsubscribe or !assign <username>.
EMAIL PREFERENCES
https://phabricator.wikimedia.org/settings/panel/emailpreferences/
To: XZise
Cc: jayvdb, Aklapper, XZise, pywikipedia-bugs