2019-07-31 14:00:37
|
<wm-bot>
|
Technical Advice IRC meeting starting in 60 minutes in channel #wikimedia-tech, hosts: @Lucas_WMDE & @cscott - all questions welcome, more infos: https://www.mediawiki.org/wiki/Technical_Advice_IRC_Meeting
|
2019-07-31 14:50:23
|
<wm-bot>
|
Technical Advice IRC meeting starting in 10 minutes in channel #wikimedia-tech, hosts: @Amir1 & @cscott - all questions welcome, more infos: https://www.mediawiki.org/wiki/Technical_Advice_IRC_Meeting
|
2019-07-31 15:08:32
|
<Amir1>
|
o/
|
2019-07-31 15:08:48
|
<Amir1>
|
Hello and welcome to this week's TAIM
|
2019-07-31 15:09:08
|
<Amir1>
|
I'm your host today
|
2019-07-31 15:10:23
|
<AntiComposite>
|
o/
|
2019-07-31 15:10:42
|
<AntiComposite>
|
I'm using pywikibot on PAWS to find globalusage of Commons files. If I don't have a local account on one of the wikis where the file is used, pywikibot throws a NoUsername exception. I'd like to handle the exception by autocreating the account, but I can't figure out how to do that with OAuth.
|
2019-07-31 15:10:48
|
<AntiComposite>
|
https://paws-public.wmflabs.org/paws-public/User:AntiCompositeBot/That%20Should%20Be%20SVG.ipynb is the code
|
2019-07-31 15:13:11
|
<tgr>
|
OAuth should autocreate automatically as soon as you make a request
|
2019-07-31 15:13:54
|
<tgr>
|
although it should be the case without OAuth as well, as long as you do a login
|
2019-07-31 15:14:24
|
<Lucas_WMDE>
|
hm, I also experienced situations where accounts were not automatically created
|
2019-07-31 15:14:27
|
<Amir1>
|
AntiComposite: I used to be a pywikibot dev and had similar issues. Have you tried logging in?
|
2019-07-31 15:14:31
|
<Lucas_WMDE>
|
https://github.com/lucaswerkmeister/tool-quickcategories/blob/b1a75f69dc885d6b1af68c2b2d912e3417e9e3ed/app.py#L420
|
2019-07-31 15:14:41
|
<Amir1>
|
python pwb.py login -lang:fa -family:bar
|
2019-07-31 15:14:57
|
<Amir1>
|
this would create account for you
|
2019-07-31 15:17:12
|
<AntiComposite>
|
Throws the same exception
|
2019-07-31 15:22:33
|
<Amir1>
|
hmm
|
2019-07-31 15:26:34
|
<[1997kB]>
|
AntiComposite: why not use that krinkle's auto create script?
|
2019-07-31 15:26:41
|
<AntiComposite>
|
I tried
|
2019-07-31 15:27:01
|
<AntiComposite>
|
It worked for like 1/3 of the wikis, but then wouldn't create any more accounts
|
2019-07-31 15:27:08
|
<tgr>
|
Lucas_WMDE: autocreation might fail (e.g. your username triggers an abuse filter). There is not much you can do about that, short of complaining to the admins.
|
2019-07-31 15:27:22
|
<[1997kB]>
|
ip block?
|
2019-07-31 15:27:36
|
<tgr>
|
Other than that, it should work completely transparently.
|
2019-07-31 15:27:47
|
<tgr>
|
AntiComposite: sounds like a block or a throttle
|
2019-07-31 15:27:56
|
<Lucas_WMDE>
|
tgr: I don’t have a problem with it failing, just wanted to point out that it doesn’t seem to be quite transparent :)
|
2019-07-31 15:28:09
|
<AntiComposite>
|
When I visit one of the wikis it didn't autocreate on, sometimes it will autocreate and other times I have to log in again
|
2019-07-31 15:28:24
|
<Lucas_WMDE>
|
perhaps autocreation from Toolforge / Cloud VPS IPs is blocked?
|
2019-07-31 15:28:36
|
<tgr>
|
account autocreation goes through the same set of spam etc. checks normal account creation does
|
2019-07-31 15:28:45
|
<tgr>
|
(not exactly the same, but similar)
|
2019-07-31 15:35:37
|
<AntiComposite>
|
Hmmm....It doesn't look like the PAWS Oauth grant includes (createaccount). I wonder if that has something to do with it.
|
2019-07-31 15:36:00
|
<tgr>
|
isn't createaccount part of the basic grant?
|
2019-07-31 15:36:27
|
<AntiComposite>
|
https://meta.wikimedia.org/wiki/Special:ListGrants#basic
|
2019-07-31 15:59:06
|
<AntiComposite>
|
Darn, doesn't appear to be an Oauth grant problem.
|
2019-07-31 16:01:52
|
<tgr>
|
AntiComposite: I think autocreation skips grants checks for obscure reasons
|
2019-07-31 16:02:32
|
<tgr>
|
wouldn't bet on it, and there were permissions refactorings a month ago which could have broken it, but I think we'd have heard sooner if that was the case
|
2019-07-31 16:03:21
|
<AntiComposite>
|
I tried it from my personal computer using my regular account, with a new Oauth consumer. Still throws NoUsername if there is no local account
|
2019-07-31 16:35:59
|
<tgr>
|
I'll add autocreateaccount to the basic grant, I can see no harm in that. Not convinced that's were the problem lies, though.
|
2019-07-31 16:54:32
|
<AntiComposite>
|
If you've got any other ideas, I'd be happy to try them.
|
2019-07-31 18:21:35
|
<AntiComposite>
|
tgr, Seems like this issue has existed for a while https://phabricator.wikimedia.org/T149672
|
2019-07-31 18:57:35
|
<tgr>
|
I'm confused. The OAuth code does read like it would error out when the user doesn't exist locally. Yet I'm pretty sure it's possible, or used to be possible, to OAuth-edit wikis where you have no local account yet.
|
2019-07-31 19:01:19
|
<Platonides>
|
maybe the autocreation somehow kicks in before the oauth?
|
2019-07-31 19:02:04
|
<tgr>
|
no, that error handling is during SessionManager's user identification process
|
2019-07-31 19:02:25
|
<tgr>
|
autocreation happens when the user has been identified successfully but doesn't exist locally
|
2019-07-31 20:46:25
|
<Acamicamacaraca>
|
Hi! Serbian Wikipedia Community wanted to enable GRAMMAR function. I created patch on Gerrit but seems it has some problems or more work. Can someone take a look? Thanks in advance.
|
2019-07-31 20:46:34
|
<Acamicamacaraca>
|
https://gerrit.wikimedia.org/r/#/c/mediawiki/core/+/481103/
|