Ugra Dániel <daniel.u...@gmail.com> added the comment:

This patch has introduced some problems for me with Python 3.2.1 (64-bit Arch 
Linux).

The following code:

with urllib.request.urlopen(url) as page:
    pass

raises "ValueError: I/O operation on closed file." exception when url is 
"http://www.imdb.com/";.

When I removed "h.close()" (added by this patch) from request.py everything 
worked as expected.

Interestingly other URLs work flawlessly with patched code 
("http://www.google.com/"; for example).

I had no time to further investigate the differences between HTTP responses of 
"good" and "bad" sites... and I am by no means an HTTP expert :)

Should I open a new bug report for this one or is it OK to just leave this 
comment here?

----------
nosy: +daniel.ugra

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue12133>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to