Getting "ReadError: not a gzip file" when trying to pip install TileStache on some machines
See original GitHub issueI hope you help me shed some light on this problem!
I found that when I run pip install TileStache
on an ubuntu machine, it is failing with the error:
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/tarfile.py", line 1676, in open
return func(name, filemode, fileobj, **kwargs)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/tarfile.py", line 1727, in gzopen
raise ReadError("not a gzip file")
ReadError: not a gzip file
I noticed that when I wget http://tilestache.org/download/TileStache-1.46.7.tar.gz
, I end up with the file as tar file (1.0MB), rather than a gzipped tar file (200KB). However when I download in the browser it is the gzipped tar file.
I think it might be something to do with the server response headers? As a comparison, I uploaded the gzipped tar file to CloudApp and ran pip install http://cl.ly/1O3I322n0S3m/TileStache-1.46.7.tar.gz
, which works!
Any help much appreciated. Thanks!
Issue Analytics
- State:
- Created 10 years ago
- Comments:5 (3 by maintainers)
Top Results From Across the Web
ReadError while installing using pip and tar.gz - Stack Overflow
and it's giving me following error. OSError: Not a gzipped file (b'<!') Some tracebacks and then. tarfile.ReadError ...
Read more >Not a gzipped file - Part 1 (2019) - fast.ai Course Forums
I am trying my first learning exercise (image classification). I have images in a tar gzipped file on my google drive and have...
Read more >TileStache - PyPI
TileStache 1.51.14. pip install TileStache. Copy PIP instructions. Latest version. Released: Mar 30, 2019. A stylish alternative for caching your map tiles.
Read more >Installing a Python module from a gzipped tarball (*.tar.gz) for ...
A quick howto on install python packages that come as gzipped tarballs for OSX or Linux.
Read more >Untitled
Maquina para sacar tientos, Tilecache vs tilestache, Ruta meilutyte and tom daley ... Entecavir 1 mg, Jesse pattison todrick, Not identified in config...
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
You closed this issue many months ago, so probably don’t care, but since your page comes up at the top of a google search for “pip not a gzip file”, I will add the following comment for posterity:
I encountered this same symptom with a new version of the pip client (1.5) working against a very old pypi server. The problem was that the pip code would gunzip while downloading the .tar.gz file, but leave the file extension as .tar.gz, and then when it tried to unpack the file, it would assume (based on the file extension) that it needed to gunzip again.
Note that wget works fine, consistent with your symptoms.
Possible fixes:
The file will need to be hosted by the official Pypi server at some point anyway since newer versions of pip will only work with self hosted (by default - which can be overridden, but then why do that).