.tar.xz files are served with text/plain content-type by launchpadlibrarian

Bug #645924 reported by Janne Snabb
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Launchpad itself
Triaged
Low
Unassigned

Bug Description

$ wget -O /dev/null http://launchpadlibrarian.net/56261240/downtimed-0.2.tar.xz
--2010-09-23 17:27:17-- http://launchpadlibrarian.net/56261240/downtimed-0.2.tar.xz
Resolving launchpadlibrarian.net... 91.189.89.229, 91.189.89.228
Connecting to launchpadlibrarian.net|91.189.89.229|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 73608 (72K) [text/plain]
Saving to: `/dev/null'
[..]

xz seems to be the hot newcomer of the tarball compression utilities. Projects are switching from bzip2 to xz because it saves space and decompresses faster.

However, as seen above, launchpadlibrarian sets text/plain mime type for these files. This means that if users try to download .tar.xz files with their browser, instead of getting a file save dialog, they get binary garbage on their display. I suppose the content-type should be application/x-tar, application/x-xz or application/octet-stream depending on ones preferences.

Gary Poster (gary)
Changed in launchpad-foundations:
status: New → Triaged
importance: Undecided → Medium
Revision history for this message
Martin Pool (mbp) wrote :

This is distinct from bug 703807 because the file really is thought to be text/plain in the db (rather than it being served up with something other than what launchpad thinks it should have).

Looking at all libraryfilealias ending in .tar.xz, the vast majority are application/octet-stream, but there are some text-plain. In particluar, the oldest ones (prior to 2011-03) tend to be text/plain. I don't know if it gets set by the upload client or by Launchpad, or what changed around then. The most recent is PyGL3Display on 2011-05-26.

Curtis Hovey (sinzui)
Changed in launchpad:
importance: Medium → Low
Revision history for this message
David F. (malteworld) wrote :

The same goes for other file types, for instance .tar.lzma (https://launchpadlibrarian.net/183118867/prebuilt-native-tools.tar.lzma).

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.