Last modified: 2014-02-11 19:09:24 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T61925, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 59925 - Add more details to image repository information
Add more details to image repository information
Status: NEW
Product: MediaWiki
Classification: Unclassified
API (Other open bugs)
1.23.0
All All
: Normal normal (vote)
: ---
Assigned To: Tisza Gergő
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2014-01-10 22:08 UTC by Mark Holmquist
Modified: 2014-02-11 19:09 UTC (History)
7 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Mark Holmquist 2014-01-10 22:08:27 UTC
I would really like, for both shared DB repos and API repos:

* The canonical name of the file namespace on that wiki (for constructing URLs)
* The article path on that wiki (for constructing different URLs)

I can't currently think of anything else crucial, but that's life.

I'd also in the future like a small icon that can represent the repository in the media viewer - right now we have a hacked-together icon that screams "not Commons" but still looks like a central repository icon. I'd be really happy to put a Wikipedia logo there if applicable.
Comment 1 Tisza Gergő 2014-01-10 22:25:49 UTC
The siteinfo API returns all this (except for the favicon). So maybe we should return a link to the API endpoint in the repoinfo (assuming there is an API)? That would mean an additional, cross-domain request for the media viewer, but otherwise pretty easy to do and probably covers all the things Mark could not as well :)

As for the small icon, we could just add a link to the favicon to the siteinfo.
Comment 2 Tisza Gergő 2014-01-10 22:26:21 UTC
could not <- could not think of
Comment 3 Mark Holmquist 2014-01-10 23:26:17 UTC
Yeah, but it would mean setting up CORS if you want to use the media viewer, which won't necessarily be possible for e.g. third parties using instantcommons.

I think the articlePath being in the repo information isn't such a terrible thing...
Comment 4 Tisza Gergő 2014-01-10 23:41:00 UTC
Public information is available via JSONP, and the mediaviewer only uses public information (maybe except gender?).

That said, maybe we could include something like '\\example.org\wiki\File:$1' where you just have to plug in the file name? That takes care of both the (possibly localized) namespace name and the article path, and it has enough relation to the file repository that it makes sense to put it in the repoinfo.
Comment 5 db [inactive,noenotif] 2014-01-11 19:48:42 UTC
You can use action=query&meta=filerepoinfo to get some information for file repos.
Comment 6 Gerrit Notification Bot 2014-01-13 11:22:16 UTC
Change 107127 had a related patch set uploaded by Gergő Tisza:
Add $wgFavicon to siteinfo API

https://gerrit.wikimedia.org/r/107127
Comment 7 Tisza Gergő 2014-01-13 11:26:09 UTC
(In reply to comment #4)
> Public information is available via JSONP, and the mediaviewer only uses
> public information (maybe except gender?).

Apparently gender is also public -> https://gerrit.wikimedia.org/r/#/c/107125/
That route could be followed for the siteinfo as well.
Comment 8 Tisza Gergő 2014-01-13 11:30:53 UTC
(In reply to comment #1)
> The siteinfo API returns all this (except for the favicon). So maybe we
> should return a link to the API endpoint in the repoinfo (assuming there 
> is an API)?

Apparently this is returned already (friprop=apiurl).
Comment 9 Gerrit Notification Bot 2014-01-13 14:43:25 UTC
Change 107127 merged by jenkins-bot:
Add $wgFavicon to siteinfo API

https://gerrit.wikimedia.org/r/107127
Comment 10 Mark Holmquist 2014-01-14 00:20:39 UTC
(In reply to comment #5)
> You can use action=query&meta=filerepoinfo to get some information for file
> repos.

I know. I wrote it. :)
Comment 11 Andre Klapper 2014-02-11 13:42:33 UTC
Related patch has been merged; resetting status.
Comment 12 Tisza Gergő 2014-02-11 19:09:24 UTC
Mark, is there anything else we need or can this be closed? We do not have article path / namespace in the API response but we extract that information from descBaseUrl or something like that, IIRC.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links