Page MenuHomePhabricator

Descriptions and aliases appear in languages that they should not
Closed, ResolvedPublic

Description

When I am in a language and add a description and switch the language, the description is still displayed. Only on a purge I see the actual data.


Version: unspecified
Severity: major

Details

Reference
bz38181

Event Timeline

bzimport raised the priority of this task from to Unbreak Now!.Nov 22 2014, 12:56 AM
bzimport set Reference to bz38181.
bzimport added a subscriber: Unknown Object (MLST).

During testing of the API for "setitem", this was what I found and it seems to reproduce.

http://localhost/repo/api.php?action=wbsetitem&data={%22labels%22:{%22en%22:%22foo%22,%22nn%22:%22bar%22},%22descriptions%22:{%22en%22:%22This%20is%20foo%22,%20%22nn%22:%22Dette%20er%20bar%22}}&format=jsonfm

Note the "id" and do something like this (I used "9" in this case)

http://localhost/repo/api.php?action=wbgetitems&ids=9&format=jsonfm

Description and labels are now correctly set for "en" and "nn". Open up the browser for the page "Data:Q9" by accessing it with the "uselang=nn" parameter.

http://localhost/repo/index.php?title=Data:Q9&uselang=nn

The label is correct for "nn", while the description comes from "en". Reloading with "action=purge" it will be correct as Danny said

localhost/repo/index.php?title=Data:Q10&uselang=nn&action=purge

For now this is solved by turning of the caching.

See also https://gerrit.wikimedia.org/r/#/c/15625/

Could need a better solution sometimes in the future.

Verified in Wikidata demo time for sprint 9