Page MenuHomePhabricator

MediaWiki:Gadget-Move.js is partly functional
Open, Needs TriagePublic

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald Transcript
matej_suchanek renamed this task from MediaWiki:Gadget-Move.js is partly functional. to MediaWiki:Gadget-Move.js is partly functional.Apr 23 2019, 3:41 PM
matej_suchanek removed Kareyac as the assignee of this task.

Do we know if this is a problem in the gadget or the merge API?

Finally, I captured the sever response (and then even one more time):


In other words, the removed sitelink cannot be added to the other item because (the system thinks) it's still in the first item, although it's already been removed. The server is probably too slow to handle consecutive sitelink removal and addition.

merge API?

Seems to be irrelevant, it isn't used by the gadget...

No change has been made yet, it's likely this will happen again and again.
Not sure what those links justify.

Sorry, last comment not for this thread. Still not working.

Esc3300 triaged this task as Unbreak Now! priority.May 16 2019, 8:18 AM

Having looked at the gadget code and Wikibase API code briefly it might be tempting to see this as an issue with the "add sitelink" API call happening too fast after the removal. How often does this happen? Could we have some more data on failing cases (i.e. responses posted above are very useful, I'd still be a bit interested in the respective requests). I couldn't quickly reproduce the situation myself, I also don't want to make random edits on Wikidata to just debug the issue.

Could you try a bit of artificial "sleep" time after the first API call in the gadget, to rule out that it is or is not the timing issue?

I don't use it that often, but I think it didn't work every time in recent weeks.

https://www.wikidata.org/wiki/Q15397819

This sandbox has sitelinks that could be moved to another sandbox.

https://www.wikidata.org/wiki/Q13406268

I tried it there just now: the first worked, the second didn't.

Maybe it has something to do with the edits done just before.

Could you try a bit of artificial "sleep" time after the first API call in the gadget, to rule out that it is or is not the timing issue?

Did it. The gadget will now wait 1000ms before adding the link: https://www.wikidata.org/w/index.php?title=MediaWiki:Gadget-Move.js&diff=944221212&oldid=747108531.

Thanks to both of you. I tested the workaround on the sandbox item above and it worked.

Esc3300 lowered the priority of this task from Unbreak Now! to Needs Triage.May 18 2019, 1:54 PM