Page MenuHomePhabricator

AuthorityControl sometimes removes Commons media statement values since wmf.30
Closed, ResolvedPublic

Description

Since the deployment of the wmf.30 branch to Wikidata (which includes T46727: [Story] Statement should show a thumbnail for image/video/audio properties), with the AuthorityControl gadget enabled values for “Commons media” statements sometimes disappear entirely a short time after loading the entity.

DbLIuyhW4AAZuXF.jpg:large.jpeg (518×912 px, 35 KB)

This happens only some of the time (probably some kind of race condition), but I can reproduce it fairly reliably after some reloads with the AuthorityControl gadget enabled (in different accounts), and not at all with the gadget disabled.

Event Timeline

I fixed something very similar in the commons media gadget: https://www.wikidata.org/w/index.php?diff=667100296&oldid=370730384

Are we sure this is another issue?

FYI I disabled AuthorityControl, but the issue still randomly happens. I could find if it follows a pattern or not, so the bug is difficult to track.

hoo claimed this task.

To keep it short: The gadget always mangles/ re-does the html for all string-value snaks with a formatter URL set on the property (except for external ids that are already handled). As P18 (and others) have a formatter URL set, the gadget tries to re-do their html, which results in the reported problems.

Fixed: https://www.wikidata.org/w/index.php?diff=668951347&oldid=667850658 (please note that this might need some time to propagate due to caching)

Note: If someone were to set a formatter URL on a math-property the same would happen there :/