Page MenuHomePhabricator

Rename page namespaces on Wikisource while renaming a file on Wikimedia Commons
Open, Needs TriagePublicFeature

Description

If someone renames a PDF/DjVu file on Wikimedia Commons, the corresponding wikipages in the Index and Page namespaces on Wikisource are not renamed simultaneously. So, even if a file gets a new name, the wikipages in the index and page namespaces on Wikisource retains the old names and thus the linkage between the file and them get disrupted.

Ideally, the rename should happen simultaneously both on Wikimedia and corresponding Wikisource projects.

Event Timeline

Anoop changed the subtype of this task from "Task" to "Feature Request".EditedJun 13 2025, 6:19 AM
Anoop subscribed.

Perhaps maybe feature request for a bot similar to commons delinker bot to move filename that are available/used on other wikis, but generally if page have too many usage such files are not moved unless crosswiki usage of such files are rectified quickly

https://commons.wikimedia.org/wiki/Commons:File_renaming#Which_files_should_not_be_renamed

Additional naming conventions and exceptions from the above list might be discussed for specific projects. For example, moving PDF and DjVu files transcluded at the Wikisources is problematic for those wikis and should be avoided unless the file mover understands the consequences.

Note that this raises thorny issues of cross-project policy, permissions (e.g. filemover on Commons vs. move permissions on Wikisource), and what happens when the same file on Commons is used by multiple Wikisourcen (e.g. a book transcribed on one of the Indic Wikisourcen and translated on enWS). Files being renamed on Commons without the Wikisource community being aware of it (before someone notices the broken transcription) causes quite a few problems already, and if renaming a file on Commons suddenly triggered mass moves on Wikisource that's likely to get even worse.

I think the approach that would probably solve the biggest part of this while introducing the least amount of secondary pain, would be a Gadget on the Wikisource side that both let users mass-move pages and offers to help moving the file on Commons (with all the appropriate safeguards so the move is within Commons policy, checks for filemover rights, shows Commons' file moving policy, etc.). And now that we finally have support for async/await in Gadgets it's even feasible to implement that Gadget.

Even if such a great tool existed and worked properly (which would be somewhat tricky to get right), there is the additional issue of all the pages transcluding Page namespace page content as is commonly done via the <pages /> tag, etc. If the Index and Page pages are renamed it will likely break anything that transcludes them id they are not also updated. Are you further proposing this new process handle such things or are just want to stop at the renaming thus breaking things elsewhere?

There are also the cases where Index pages are not tied to a media file but the Page pages are like for JPEGs, etc. Is this magical renamer supposed to correctly handle renaming the Page pages and then updating both its transclusions and its references like in Index pages, etc.? Index pages also commonly directly transclude the Page pages that refer to the table of contents, etc.

Also any proposal to move pages has to face the idea to leave redirects behind or not. Is this new proposed process supposed to automatically detect if the Commons media move leaves a redirect behind or not and then move pages around all over multiple Wikisource sites either leaving redirects or not based upon the original move on Commons?

This opens a lot of stickiness in the definition of the proposal to begin with. I agree with Anoop and Xover that some interesting powertools like a bot or scripting gadget, etc. could potentially be developed to help assist with some of the process but to have it be entirely automatic could prove to be problematic.