As a Wikidata editor I want to see the suggestions on the sex or gender property in the order in which the community defined them, in order to see the most common values first.
Problem:
P21 currently has more than 50 suggested values in its one-of constraint, which means that WikibaseQualityConstraints’ suggestions module (modules/suggestions/EntitySelectorHookHandlerFactory.js) has to make more than one API request to get all the labels and descriptions for the values. Currently, it makes those requests in parallel, then appends the results to the suggestions in whichever order the API requests resolve; since the second request has fewer items in it, it often resolves first and those last few items are therefore shown at the top of the suggestion list. We should fix this to make sure the list is in the right order, either by making sure the parallelized results are concatenated order, or by not parallelizing the requests at all (which would also be more in line with the API etiquette).
Example/Screenshots/mockups:
BDD
GIVEN I am on an item page
WHEN I add a new “sex or gender” statement
THEN the suggestions are in the right order
Acceptance criteria:
- WikibaseQualityConstraints doesn’t reorder the results.