[issue16723] io.TextIOWrapper on urllib.request.urlopen terminates prematurely

2013-02-06 Thread Roundup Robot
Roundup Robot added the comment: New changeset 6cc5bbfcf04e by Serhiy Storchaka in branch '3.2': Issue #16723: httplib.HTTPResponse no longer marked closed when the connection http://hg.python.org/cpython/rev/6cc5bbfcf04e New changeset 0461ed77ee4e by Serhiy Storchaka in branch '3.3': Issue

[issue16723] io.TextIOWrapper on urllib.request.urlopen terminates prematurely

2013-02-06 Thread Serhiy Storchaka
Changes by Serhiy Storchaka storch...@gmail.com: -- resolution: - fixed stage: patch review - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue16723

[issue16723] io.TextIOWrapper on urllib.request.urlopen terminates prematurely

2013-02-05 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Senthil, Antoine, anyone, what you think about this patch? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue16723 ___

[issue16723] io.TextIOWrapper on urllib.request.urlopen terminates prematurely

2013-02-05 Thread Antoine Pitrou
Antoine Pitrou added the comment: This looks ok to me. I am slightly surprised that isclosed() isn't documented anywhere (but perhaps it's better). -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue16723

[issue16723] io.TextIOWrapper on urllib.request.urlopen terminates prematurely

2013-01-31 Thread Serhiy Storchaka
Changes by Serhiy Storchaka storch...@gmail.com: -- assignee: - serhiy.storchaka ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue16723 ___ ___

[issue16723] io.TextIOWrapper on urllib.request.urlopen terminates prematurely

2013-01-26 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Here is a patch which fixes HTTPResponse's end. closed property no longer settled automatically, but only after explicit close(). -- components: +IO, Library (Lib) keywords: +patch nosy: +orsenthil stage: - patch review versions: +Python 3.2, Python

[issue16723] io.TextIOWrapper on urllib.request.urlopen terminates prematurely

2013-01-15 Thread David Beazley
David Beazley added the comment: I have run into this bug myself. Agree that a file-like object should never report itself as closed unless .close() has been explicitly called on it. HTTPResponse should not return itself as closed after the end-of-file has been reached. I think there is

[issue16723] io.TextIOWrapper on urllib.request.urlopen terminates prematurely

2012-12-19 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc added the comment: Hum, io objects are not supposed to close themselves when they run out of data. Even if HTTPResponse chooses to close the underlying socket (to clean unused resources?), it should not report itself as a closed io.IOBase. Subsequent calls read() should

[issue16723] io.TextIOWrapper on urllib.request.urlopen terminates prematurely

2012-12-19 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: This looks as a known bug in io.TextIOWrapper which call read() even previous read() returned an empty data. There was a related issue, I can't found it now. -- nosy: +serhiy.storchaka ___ Python tracker

[issue16723] io.TextIOWrapper on urllib.request.urlopen terminates prematurely

2012-12-19 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc added the comment: buffer.read() never returns empty data in this case. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue16723 ___

[issue16723] io.TextIOWrapper on urllib.request.urlopen terminates prematurely

2012-12-19 Thread Wibowo Arindrarto
Changes by Wibowo Arindrarto b...@bow.web.id: -- nosy: +bow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue16723 ___ ___ Python-bugs-list mailing

[issue16723] io.TextIOWrapper on urllib.request.urlopen terminates prematurely

2012-12-19 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Indeed. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue16723 ___ ___ Python-bugs-list mailing list

[issue16723] io.TextIOWrapper on urllib.request.urlopen terminates prematurely

2012-12-18 Thread Michiel de Hoon
New submission from Michiel de Hoon: I am trying to use io.TextIOWrapper to wrap a handle returned by urllib.request.urlopen. Reading line-by-line from the wrapped handle terminates prematurely. As an example, consider this script: import urllib.request import io url =