Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #92802
| References | <59756062-6632-46b4-a92c-aa3a260718a7@googlegroups.com> <mailman.575.1434587009.13271.python-list@python.org> <0dd32144-8969-4e15-9e78-4c9698fb9d8c@googlegroups.com> <mailman.577.1434591971.13271.python-list@python.org> <db74b4ee-b88f-4e41-8844-2c80671a6bee@googlegroups.com> |
|---|---|
| Date | 2015-06-18 13:56 +1000 |
| Subject | Re: Posting gzip'd image file - server says Malformed Upload? |
| From | Chris Angelico <rosuav@gmail.com> |
| Newsgroups | comp.lang.python |
| Message-ID | <mailman.578.1434599772.13271.python-list@python.org> (permalink) |
On Thu, Jun 18, 2015 at 1:48 PM, Paul Hubert <phbrt25@gmail.com> wrote: >> # Now: >> gz = '/Users/Paul/Desktop/scripts/pic.jpg.gz' >> with open(dafile, 'rb') as f_in, gzip.open(gz, 'wb') as f_out: >> f_out.write(f_in.read()) >> > > Same result - server says malformed upload. :/ Oh well, was worth a shot. Since the file's sitting around still, you should be able to attempt to decompress it with the stand-alone gzip command; does that give the right result? Also, you should be able to manually send that .gz file up to the server, which would be worth confirming. Are you certain that the content should be gzipped as a file? It's not meant to be done as a transfer-level encoding? ChrisA
Back to comp.lang.python | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Posting gzip'd image file - server says Malformed Upload? Paul Hubert <phbrt25@gmail.com> - 2015-06-17 14:55 -0700
Re: Posting gzip'd image file - server says Malformed Upload? Chris Angelico <rosuav@gmail.com> - 2015-06-18 10:23 +1000
Re: Posting gzip'd image file - server says Malformed Upload? Paul Hubert <phbrt25@gmail.com> - 2015-06-17 17:45 -0700
Re: Posting gzip'd image file - server says Malformed Upload? Michael Torrie <torriem@gmail.com> - 2015-06-17 19:10 -0600
Re: Posting gzip'd image file - server says Malformed Upload? Chris Angelico <rosuav@gmail.com> - 2015-06-18 11:46 +1000
Re: Posting gzip'd image file - server says Malformed Upload? Paul Hubert <phbrt25@gmail.com> - 2015-06-17 20:48 -0700
Re: Posting gzip'd image file - server says Malformed Upload? Chris Angelico <rosuav@gmail.com> - 2015-06-18 13:56 +1000
Re: Posting gzip'd image file - server says Malformed Upload? Michael Torrie <torriem@gmail.com> - 2015-06-17 21:59 -0600
Re: Posting gzip'd image file - server says Malformed Upload? Laura Creighton <lac@openend.se> - 2015-06-18 23:44 +0200
Re: Posting gzip'd image file - server says Malformed Upload? random832@fastmail.us - 2015-06-18 08:38 -0400
Re: Posting gzip'd image file - server says Malformed Upload? Chris Angelico <rosuav@gmail.com> - 2015-06-18 22:42 +1000
csiph-web