Page MenuHomePhabricator

When a local image and an image redirect on Commons have the same name, the wrong description page is linked
Open, MediumPublic

Description

Steps to reproduce (at least as long as the file isn't deleted):

Go to [[de:Sereina_Trachsel]] and look at the second image ("Zieleinfahrt SM 05 in Cham (2005)"). In the wikitext the file name Datei:Zieleinfahrt_SM05.jpg is used. This exists only on commons and is a redirect to File:Sereina Trachsel.jpg.

But there also is a different local file on de.wikipedia with the title File:Sereina Trachsel.jpg.

Now click on the image to visit the description page.

Instead of the correct description page the description page for the local file is shown, without any hint that you were redirected.

Abstract version:

On Commons:
File:Foo.jpg redirects to File:Bar.jpg
On local wiki:
File:Bar.jpg exists
Using File:Foo.jpg in an article shows Commons-Bar.jpg, but links to Local-Bar.jpg.

(Using File:Bar.jpg both shows and links Local-Bar.jpg, which is correct.)

Since most licenses require the correct description page to be displayed I set the severity to major.

Maybe this bug is related or even a duplicate of T30299, but though I tried to understand this bug I wasn't able to do so, so I couldn't find out if it's saying the same thing.


Version: unspecified
Severity: normal
See Also:
https://bugzilla.wikimedia.org/show_bug.cgi?id=28299

Details

Reference
bz36118

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 22 2014, 12:25 AM
bzimport set Reference to bz36118.
bzimport added a subscriber: Unknown Object (MLST).

(In reply to Michael M. from comment #0)

Go to [[de:Sereina_Trachsel]] and look at the second image ("Zieleinfahrt SM
05 in Cham (2005)"). In the wikitext the file name
Datei:Zieleinfahrt_SM05.jpg is used.

Michael: I don't think so anymore (or I don't understand it)?
Editing [[de:Sereina_Trachsel]] I see
[[Datei:Sereina Trachsel.jpg|miniatur|Zieleinfahrt SM 05 in Cham (2005)]]

Maybe this bug is related or even a duplicate of bug 28299

Yeah, might be a duplicate or dependency of bug 28299.
Developers might know and decide.

(In reply to Andre Klapper from comment #1)

Michael: I don't think so anymore (or I don't understand it)?
Editing [[de:Sereina_Trachsel]] I see
[[Datei:Sereina Trachsel.jpg|miniatur|Zieleinfahrt SM 05 in Cham (2005)]]

The local image on de.wikipedia was deleted some time ago, so the original example is no longer reproducible.

Alright. :( Missing testcase.
Sorry this didn't get tackled when this was reported.

Amire80 edited subscribers, added: gpaumier; removed: wikibugs-l-list.

This causes issue T115807 in ContentTranslation.

Ideally, there shouldn't be images with the same name in local wiki and in Commons. Whatever advantage that the current situation happens to provide, such as overriding an unwanted Commons image in a local wiki, is really a hack and it is outweighed by the disadvantages.

I can imagine a solution that goes like this:

  • Find a list of images with identical titles, for example by running a query or by adding such images to a tracking category.
  • Rename (or delete) all of them.
  • Disallow uploading images with an identical title and renaming images to an identical title.

Disallowing identical image names on local and shared repositories is not possible: You can check and disallow uploads to the local repository with names that exist on the shared one (that's actually possible right now, since there is a user right for it, which currently is granted to sysops), but you cannot check whether a new upload to Commons has the same name as an existing file on any local repository (including uncountably many wikis using InstantCommons).

Three years later, I would like to bring this to your attention again because I just came across this "in the wild": https://en.wikipedia.org/wiki/Peter_Baumann_(computer_scientist)

The article includes "File:PeterBaumann.jpg", which is a local file to the English WP.
Clicking on the thumbnail in the article opens the file description page: https://en.wikipedia.org/wiki/File:PeterBaumann.jpg
But that site displays a very different photo which is stored on Commons under the name File:Peter_Baumann_portrait.jpg, but has a redirect File:PeterBaumann.jpg. That redirect causes the bug.

The most confusing part is that the local description page claims to be displaying the Commons description, but in fact displays the local description (including showing a thumbnail of the local file in the history section). I.e. only the main image at the top and the filename below it are wrong.

I was about to fix the issue by deleting the redirect on Commons, but I left it like this for illustration purposes for this bug.