Page MenuHomePhabricator

Add entity_prefix/repoConceptBaseUri to siteinfo
Closed, ResolvedPublic

Description

In various places (e.g. quantiy claims with units 1) we refer to items via their entity urls such as http://www.wikidata.org/entity/Q712226.

Yet there is no easy way of determining what the stem/prefix (i.e. http://www.wikidata.org/entity/ for wikidata) is for a given wikibase installation. Hence it would be useful if this could be included in the siteinfo api call (cf. articlepath).

Note that just /entity/ isn't enough (unlike for articlepath) here since the protocol is http rather than the site default which is https.

Event Timeline

To clarify what I would like to have exposed through siteinfo is $wgWBClientSettings['repoConceptBaseUri']

Lokal_Profil renamed this task from Add entity_prefix to siteinfo to Add entity_prefix/repoConceptBaseUri to siteinfo.Oct 10 2016, 9:59 AM

Change 315063 had a related patch set uploaded (by Lokal Profil):
Expose repoConceptBaseUri through siteinfo

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

One of the use cases for this is for pywikibot to be able to set units by simply providing the Qid and then use the exposed uri base to construct the entity URI.

Change 315220 had a related patch set uploaded (by Thiemo Mättig (WMDE)):
Add missing test cases for onAPIQuerySiteInfoGeneralInfo hook

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

Change 315063 merged by jenkins-bot:
Expose ConceptBaseUri through siteinfo

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

hoo moved this task from Review to Done on the Wikidata-Sprint-2016-10-12 board.
thiemowmde moved this task from Done to Review on the Wikidata-Sprint-2016-10-12 board.
thiemowmde moved this task from incoming to in progress on the Wikidata board.

Change 315220 merged by jenkins-bot:
Add missing test cases for onAPIQuerySiteInfoGeneralInfo hook

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

thiemowmde moved this task from Review to Done on the Wikidata-Sprint-2016-10-12 board.

Question: Other than checking the API response how can I track when this has been deployed?

Question: Other than checking the API response how can I track when this has been deployed?

You could see in which branch your commit is included and check when that's going to be deployed (see https://wikitech.wikimedia.org/wiki/Deployments).

Question: Other than checking the API response how can I track when this has been deployed?

You could see in which branch your commit is included and check when that's going to be deployed (see https://wikitech.wikimedia.org/wiki/Deployments).

Ah. The patch gets cherry picked to a branch which is then part of the deployment train. Thanks then I know what to keep an eye out for.