Detect .zip file as application/zip instead of application/x-zip-compressed
See original GitHub issueThe feature that auto-detects the Content-Type
header based on the filename extension when using @filename
(the “Body Data From a Filename” feature) detects a .zip
file as application/x-zip-compressed
. I think it should use application/zip
instead. Thanks for considering!
Issue Analytics
- State:
- Created 10 years ago
- Comments:5 (1 by maintainers)
Top Results From Across the Web
rar, .zip files MIME Type - Stack Overflow
I would do a check on the file name too. Here is how you could check if the file is a RAR or...
Read more >application/zip
This descriptor is used only when it was not possible to seek in the output zip file, e.g., when the output zip file...
Read more >application/x-zip-compressed - mimetype.io
Instead please use application/zip. ZIP is one of the most popular file compression formats. It was created in 1989 as the native format...
Read more >Python's zipfile: Manipulate Your ZIP Files Efficiently
ZIP files allow you to aggregate, compress, and encrypt files into a single interoperable and portable container. You can stream ZIP files, ...
Read more >ZIP file MIME type is not recognized - Bugzilla@Mozilla
This is a good guess, but my copy of Windows thinks zip files are application/x-zip-compressed and that works fine. And in fact, we...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@jbyler, what OS and Python version do you use?
The mime type is detected using the Python’s
mimetype
module, which for me (OS X 10.9, Python 2.7.6) correctly returnsapplication/zip
:I will say that it seems like there’s probably a design flaw in here somewhere, given that installing mutt can create problems for httpie. I don’t think the design flaw is with httpie. Perhaps the
mimetypes
module ought to provide a mechanism for an application (mutt) to customizemime.types
in a way that is local to that application, rather than global for all users of themimetypes
module.