Page MenuHomePhabricator

Update Wikidata Query Builder query string to include MUL
Closed, ResolvedPublic

Description

As an Query Builder user I want the results of my queries to include mul in the language fallback in order to be able to read the results for my query easily.

Problem:
Currently, mul labels and aliases are not included in the Query Builder language fallback when showing the results of the query. As more labels and aliases are consolidated into mul labels, the results for queries on Query Builder will appear only by their ID making it difficult to read the results.

Screenshots/mockups:
When querying for Douglas Adams:

image.png (190×912 px, 9 KB)

Acceptance criteria:

  • update the query builder to emit "[AUTO_LANGUAGE],mul,en", matching the WDQS UI suggestions

Event Timeline

I am just realizing that the ticket is about the Query Builder but the original request on-wiki is actually linking to a query in the Query Service UI.
I am fairly sure this needs to be fixed in the Query Service UI instead.

I am just realizing that the ticket is about the Query Builder but the original request on-wiki is actually linking to a query in the Query Service UI.

But it does mention that the query was built by the query builder (and the query looks like that too).

IMHO there are three possible approaches to this task:

  • update the query builder to emit "[AUTO_LANGUAGE],mul,en", matching the WDQS UI suggestions (arguably it’s always been unfortunate or even a bug that the query builder didn’t even include ,en)
  • implement T379135: [AUTO_LANGUAGE] does not use language fallbacks and update the query builder to emit "[AUTO_LANGUAGES]" (assuming my suggestion at T379135#10295680 is taken up)
  • make the label service follow language fallbacks, in which case we can also change the WDQS UI suggestions to just "[AUTO_LANGUAGE]" (I’m not aware of a task for this yet)

The on-wiki comment by Vicarage seems to suggest that the query builder should follow the user’s babel profile, but since the query builder is used anonymously (without logging in via Wikidata), I don’t think that’s currently possible, and IMHO it’s not worth adding OAuth integration just for this feature.

Thank you!

IMHO there are three possible approaches to this task:

  • update the query builder to emit "[AUTO_LANGUAGE],mul,en", matching the WDQS UI suggestions (arguably it’s always been unfortunate or even a bug that the query builder didn’t even include ,en)
  • implement T379135: [AUTO_LANGUAGE] does not use language fallbacks and update the query builder to emit "[AUTO_LANGUAGES]" (assuming my suggestion at T379135#10295680 is taken up)
  • make the label service follow language fallbacks, in which case we can also change the WDQS UI suggestions to just "[AUTO_LANGUAGE]" (I’m not aware of a task for this yet)

The second sounds like it'd be best to me but is also probably more work. So maybe the first for now? Thoughts?

The on-wiki comment by Vicarage seems to suggest that the query builder should follow the user’s babel profile, but since the query builder is used anonymously (without logging in via Wikidata), I don’t think that’s currently possible, and IMHO it’s not worth adding OAuth integration just for this feature.

Agreed.

Arian_Bozorg updated the task description. (Show Details)
Arian_Bozorg updated the task description. (Show Details)
Arian_Bozorg renamed this task from Wikidata Query Builder does not support MUL language code to Wikidata Query Builder does not support MUL language fallback.Dec 4 2024, 9:33 AM
karapayneWMDE renamed this task from Wikidata Query Builder does not support MUL language fallback to Update Wikidata Query Builder query string to include MUL .Dec 10 2024, 9:18 AM
karapayneWMDE updated the task description. (Show Details)

Change #1103329 had a related patch set uploaded (by Hasan Akgün (WMDE); author: Hasan Akgün (WMDE)):

[wikidata/query-builder@master] Update Wikidata Query Builder query string to include MUL

https://gerrit.wikimedia.org/r/1103329

Change #1103329 merged by jenkins-bot:

[wikidata/query-builder@master] Update Wikidata Query Builder query string to include MUL

https://gerrit.wikimedia.org/r/1103329

Midleading claimed this task.

Working.