Control: Control: tag -1 moreinfo

Hi, Joey.

On Sep 04 2017, Joey Hess wrote:
> joey@darkstar:~>youtube-dl  http://debian.org/
> [generic] debian: Requesting header
> [redirect] Following redirect to http://www.debian.org/
> [generic] www.debian: Requesting header
> WARNING: Falling back on generic information extractor.
> [generic] www.debian: Downloading webpage
(...)
> Traceback (most recent call last):
(...)
>   File "/usr/lib/python3.5/urllib/request.py", line 472, in open
>     response = meth(req, response)
>   File "/usr/lib/python3/dist-packages/youtube_dl/utils.py", line 981, in 
> http_response
>     uncompressed = io.BytesIO(gz.read())
>   File "/usr/lib/python3.5/gzip.py", line 274, in read
>     return self._buffer.read(size)
>   File "/usr/lib/python3.5/gzip.py", line 480, in read
>     raise EOFError("Compressed file ended before the "
> EOFError: Compressed file ended before the end-of-stream marker was reached

Just for the record, the above is a problem coming from Python, of course.

> I'm able to reproduce this over an Excede satelite internet connection,
> but not from a VPS.

Right. I am not able to reproduce this with whatever I have at my disposal.

> There's some transparent proxying involved, which is apparently confusing
> the gzip Content-encoding support in youtube-dl. (I have not seen the
> transparent proxying cause any other problems with other programs.)

With other python programs?

> Only http urls cause the problem, since https bypasses the transparent
> proxy.

Sure.

> I edited the code to dump out the gzip compressed content it received
> before it trys to decompress it.
(... snip detailed analysis ...)
> curl seems to follow Postel's law in handling this, so perhaps youtube-dl
> should too?

I believe that you meant to file this as a Python bug and I think that the
severity is, quite frankly, lower than normal...

That being said, I'm only tagging this as moreinfo before reassigning this
to python itself, since I want to understand what kind of goal you would
like to achieve here.

>From my point of view, if anything here needs to deal more gracefully with
errors, then, that would be Python's gzip module...


Thanks,

-- 
Rogério Brito : rbrito@{ime.usp.br,gmail.com} : GPG key 4096R/BCFCAAAA
http://cynic.cc/blog/ : github.com/rbrito : profiles.google.com/rbrito
DebianQA: http://qa.debian.org/developer.php?login=rbrito%40ime.usp.br

Reply via email to