https://bugzilla.wikimedia.org/show_bug.cgi?id=4421
--- Comment #64 from Aryeh Gregor <[email protected]> 2010-04-02 17:20:30 UTC --- Okay, so: 1) Problem with the current system: Cannot upload a new version of a file in a different format while preserving history. 2) Problem with the current system (not mentioned for a while): Google apparently doesn't index image pages properly on non-Wikimedia MW installs, because it assumes anything ending in .png/.jpeg/etc. is an image page, not an HTML page. 3) Problem with the proposed system: Files are possible that have no extension, or a completely misleading extension, so it's not clear what general type of file they are (although sometimes this is unclear anyway). There are several possible solutions I can think of. The status quo solves (3) but not (1) or (2). The proposal solves (1) and (2) but not (3). I don't see any reason why we wouldn't want to allow the proposed changes as an option; some wiki admins will surely prefer the option, although others may not. It could be disabled by default. Another possibility is to require extensions as now, but allow upload of a new file to an existing filename of a different type. This would automatically rename the file to the new appropriate extension, and would only work if that's possible. Reverting to an earlier file of a different type would also change the name. This solves (1) and (3) but not (2). It would be a bit messy, but I think strictly better than the status quo. (In reply to comment #52) > Hi Aryeh: the reason I chose to store the file extension in addition to MIME > is > that both img_file_ext='jpg' or 'jpeg' are both valid values when > img_minor_mime is 'jpeg'. While one might be able to infer what the extension > would be based on the preferred extension given the MIME type, it's > potentially > a booby trap for devs and sysadmins down the road, who might unintentionally > corrupt a wiki by changing the preferred file extension from one to the > other. > What may seem like a harmless switch from "jpg" to "jpeg" as the preferred > extension would suddenly cause a lot of existing images, archive images, and > thumbnails to break. By storing this in the DB, changing the preferred > extension in the configuration/code is safe, with only future updates taking > on > the new preferred extension. Why not just hardcode "jpg" as the preferred version, and never change it? That seems a lot simpler and less error-prone than keeping track of it. -- Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug. You are on the CC list for the bug. _______________________________________________ Wikibugs-l mailing list [email protected] https://lists.wikimedia.org/mailman/listinfo/wikibugs-l
