Page MenuHomePhabricator

Uses P629 (edition of) to add Wikipedia link in the other projects sidebar of Wikisource
Closed, ResolvedPublic

Description

Wikisources pages are connected using sitelinks to the edition items of Wikidata and Wikipedia articles to the work items. The edition item is connected with P629 to the work item. It would be nice to use this relation to fill automatically the other projects sidebar of Wikisource.

It could be implemented using the OtherProjectsSidebarHook inside of the "Wikisource" extension that is not yet deployed or inside of the WikimediaBadges extension (just like what is done for Commons categories).

Event Timeline

I'm fine with doing this and I believe it should be done in the same way as Commons so we have consistency.

I'm fine with doing this and I believe it should be done in the same way as Commons so we have consistency.

Yes, it should be implemented the same way. About the location, are you more in favor of doing it in the WikimediaBadges extension and not in a "Wikisource" extension even if it is Wikisource specific? We should also take into account T180304 which aims at doing the same thing but for language-links. The implementation for these two tasks should probably be in the same place.

I don't have an opinion on that personally.

Change 408365 had a related patch set uploaded (by Tpt; owner: Tpt):
[mediawiki/extensions/Wikisource@master] Uses the sitelinks from the work item in the other projects sidebar

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

I have made a change for the Wikisource extension (the CI is currently broken because the dependency on Wikibase is not setup yet). Having this feature there has two advantages:

  1. Do not require a configuration parameter to enable/disable this feature. We probably want it only on Wikisource.
  2. I am not sure that we want T180304 in WikimediaBadges and implementation of both feature are sharing some concerns (retrieving edition/work items...).

If the Wikidata team prefers to have both T180303 and T180304 in WikimediaBadges it's fine for me and I would be happy to implement the changes there.

@Tpt After looking at both tickets, I think it's fine to do it in the Wikisource extension… in the end I guess one could argue for any of the solutions, but having this in a truly Wikisource only extension definitely makes sense.

Change 408365 had a related patch set uploaded (by Tpt; owner: Tpt):
[mediawiki/extensions/Wikisource@master] Uses the sitelinks from the work item in the other projects sidebar

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

Change 472769 had a related patch set uploaded (by Tpt; owner: Tpt):
[mediawiki/extensions/Wikibase@master] WikibaseClientOtherProjectsSidebar hook: pass the site to output array to the handler

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

Change 408365 had a related patch set uploaded (by Tpt; owner: Tpt):
[mediawiki/extensions/Wikisource@master] Uses the sitelinks from the work item in the other projects sidebar

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

Change 472769 had a related patch set uploaded (by Tpt; owner: Tpt):
[mediawiki/extensions/Wikibase@master] WikibaseClientOtherProjectsSidebar hook: pass the site to output array to the handler

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

Addshore triaged this task as Medium priority.Nov 20 2018, 8:00 AM

Change 472769 merged by jenkins-bot:
[mediawiki/extensions/Wikibase@master] WikibaseClientOtherProjectsSidebar hook: pass the site to output array to the handler

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

For this task to be done, the extension should be deployed on Wikisource: T210174

Change 478631 had a related patch set uploaded (by Tpt; owner: Tpt):
[mediawiki/extensions/Wikibase@master] Pass an UpdateAccumulator to WikibaseClientOtherProjectsSidebar hook

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

Is there anything left to do for the Wikidata team atm here?

@Lydia_Pintscher Maybe review https://gerrit.wikimedia.org/r/c/mediawiki/extensions/Wikisource/ /408365 and try to push the security review of the Wikisource extension to get it deployed on beta then production cluster.

Change 478631 merged by jenkins-bot:
[mediawiki/extensions/Wikibase@master] Pass an UpdateAccumulator to WikibaseClientOtherProjectsSidebar hook

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

Change 408365 merged by jenkins-bot:
[mediawiki/extensions/Wikisource@master] Uses the sitelinks from the work item in the other projects sidebar

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

Change 485486 had a related patch set uploaded (by Tpt; owner: Tpt):
[mediawiki/extensions/Wikisource@master] Tracks entity usage when filling the other project sidebar

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

Change 490929 had a related patch set uploaded (by Tpt; owner: Tpt):
[mediawiki/extensions/Wikibase@master] OtherProjectSidebar Disables hook call in unit tests

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

Change 490929 merged by jenkins-bot:
[mediawiki/extensions/Wikibase@master] OtherProjectSidebar Disables hook call in unit tests

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

Change 485486 merged by jenkins-bot:
[mediawiki/extensions/Wikisource@master] Tracks entity usage when filling the other project sidebar

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

Tpt claimed this task.

Deployed on all Wikisources \o/.

Example in enwikisource: https://en.wikisource.org/wiki/The_Wind_in_the_Willows_(1913)