Last modified: 2014-10-28 07:23:25 UTC
looking at [[foundation:Special:MediaStatistics]] Mime types like application/vnd.oasis.opendocument.spreadsheet get cut off to application/vnd.oasis.opendocument.spreadshe because img_minor_mime field isn't long enough.
tables.sql says: img_minor_mime varbinary(100) NOT NULL default "unknown", Seems that wmf wikis (or just foundationwiki) missing the sql patch: patch-mime_minor_length.sql
ALTER TABLE /*_*/filearchive MODIFY COLUMN fa_minor_mime varbinary(100) default "unknown"; ALTER TABLE /*_*/image MODIFY COLUMN img_minor_mime varbinary(100) NOT NULL default "unknown"; ALTER TABLE /*_*/oldimage MODIFY COLUMN oi_minor_mime varbinary(100) NOT NULL default "unknown"; All 3 are still 32, on foundationwiki at least...
Checked enwiki and commons too. I guess it's all "older" sites that haven't been updated
I just did foundationwiki... How do we get the minor_mimie fields to update?
They update next time someone purges the image description page. Suppose we could write a mantinance script, although issue is not exactly causing big problems.
Purge does not rewrite these values, a reupload would do it, but than oldimage table contains that broken value. Some one has to run an update: application/vnd.oasis.opendocument.presentat -> application/vnd.oasis.opendocument.presentation application/vnd.oasis.opendocument.spreadshe -> application/vnd.oasis.opendocument.spreadsheet https://wikimediafoundation.org/wiki/Special:MIMESearch/application/vnd.oasis.opendocument.spreadshe contains a file with .odf, which should be 'application/vnd.oasis.opendocument.formula'? When the image table is updated [[foundation:Special:MediaStatistics]] gets updated with in the next 3 days.
(In reply to Umherirrender from comment #6) > Purge does not rewrite these values, a reupload would do it, but than > oldimage table contains that broken value. Purge definitely should (calls LocalFile::upgradeRow, which calls LocalFile::reloadFromFile, which should in fact redetermine what the MIME type is) > Some one has to run an update: > application/vnd.oasis.opendocument.presentat -> > application/vnd.oasis.opendocument.presentation > > application/vnd.oasis.opendocument.spreadshe -> > application/vnd.oasis.opendocument.spreadsheet > > https://wikimediafoundation.org/wiki/Special:MIMESearch/application/vnd. > oasis.opendocument.spreadshe contains a file with .odf, which should be > 'application/vnd.oasis.opendocument.formula'? Probably uploaded before we had good mime checking. So its probably an ods file with wrong extension. (In reply to Sam Reed (reedy) from comment #4) > I just did foundationwiki... How do we get the minor_mimie fields to update? Note, on tool labs, img_minor_mime is still VARBINARY(32) (but oi_minor_mime and fa_minor_mime are VARBINARY(100)). I'm not sure if it just takes a while for changes to reflect in tool labs DESCRIBE.
(In reply to Bawolff (Brian Wolff) from comment #7) > (In reply to Umherirrender from comment #6) > > Purge does not rewrite these values, a reupload would do it, but than > > oldimage table contains that broken value. > > Purge definitely should (calls LocalFile::upgradeRow, which calls > LocalFile::reloadFromFile, which should in fact redetermine what the MIME > type is) > > > Some one has to run an update: > > application/vnd.oasis.opendocument.presentat -> > > application/vnd.oasis.opendocument.presentation > > > > application/vnd.oasis.opendocument.spreadshe -> > > application/vnd.oasis.opendocument.spreadsheet > > > > https://wikimediafoundation.org/wiki/Special:MIMESearch/application/vnd. > > oasis.opendocument.spreadshe contains a file with .odf, which should be > > 'application/vnd.oasis.opendocument.formula'? > > Probably uploaded before we had good mime checking. So its probably an ods > file with wrong extension. > > > > (In reply to Sam Reed (reedy) from comment #4) > > I just did foundationwiki... How do we get the minor_mimie fields to update? > > Note, on tool labs, img_minor_mime is still VARBINARY(32) (but oi_minor_mime > and fa_minor_mime are VARBINARY(100)). I'm not sure if it just takes a while > for changes to reflect in tool labs DESCRIBE. It works on my local wiki (for jpegs), but a anon purge on wikimediafoundation.org does not have the effect for the 10 files. The schema change is not done or there is a problem for slave/master or some other issue? No idea.
(In reply to Bawolff (Brian Wolff) from comment #7) > (In reply to Sam Reed (reedy) from comment #4) > > I just did foundationwiki... How do we get the minor_mimie fields to update? > > Note, on tool labs, img_minor_mime is still VARBINARY(32) (but oi_minor_mime > and fa_minor_mime are VARBINARY(100)). I'm not sure if it just takes a while > for changes to reflect in tool labs DESCRIBE. Strange. I wonder what happened. The other 2 were still there. Just re-did it. I wonder if purge will work correctly now? :) Yup https://wikimediafoundation.org/wiki/File:GARDNER_WIKIMANIA_2012.odp GARDNER_WIKIMANIA_2012.odp (file size: 15.9 MB, MIME type: application/vnd.oasis.opendocument.presentation)
The patch has gone out to s2, s3, s5, s6, and s7 wikis today. Tomorrow will likely see s1 (enwiki) done, but s4 (commonswiki) will be slower because oldimage has no primary key for an online schema change, and is large enough for that to matter on the master. Probably why the patch wasn't previously applied.
(In reply to Bawolff (Brian Wolff) from comment #7) > Note, on tool labs, img_minor_mime is still VARBINARY(32) (but oi_minor_mime > and fa_minor_mime are VARBINARY(100)). I'm not sure if it just takes a while > for changes to reflect in tool labs DESCRIBE. The labsdb VIEWs will need to be refreshed.
S1 done.
So only s4 is missing?
Correct.