Last modified: 2014-06-11 23:50:59 UTC
Right now, if you're logged in and you go to a page in the File namespace, there is an Upload page action button. It's not clear from the context what this button actually does, but given its function on article pages and the fact that it is a "page action", I would expect it to replace the current image on the file page with a newly uploaded image. What it actually does is pretty nuts: 1. It uploads the new image to a new file page. 2. It creates a new main namespace page based on the name of the file page you were uploading from and inserts the new image into it. 3. It lazy-loads the main namespace page even though you are still in file namespace. We could try to fix this, but I'm really not sure exactly what the correct behavior would be. Instead I think we should just disable the upload page action from within file pages (which is a 2 line change in modules/uploads/init.js).
Prioritization and scheduling of this bug is tracked on Trello card https://trello.com/c/tsl4Kj5p
I think the purpose of this was to show an upload button on an empty file page - see bug 58311 The 3rd point seems like an issue. I think the second part is an oversight but the first point is correct behaviour. Expected: Should create file page using existing image.
(We might want to revert the fix to bug 58311 in the meantime)
Change 139009 had a related patch set uploaded by Kaldari: Only show upload page action in File namespace if page doesn't already exist https://gerrit.wikimedia.org/r/139009
Change 139009 merged by jenkins-bot: Only show upload page action in File namespace if page doesn't already exist https://gerrit.wikimedia.org/r/139009