sbt <shibt...@gmail.com> added the comment:

BufferedReader.readinto() should also raise BlockingIOError according to the 
docs.  Updated unittest checks for that also.

BTW, The documentation for BufferedIOBase.read() says that BlockingIOError 
should be raised if nothing can be read in non-blocking mode.  BufferedReader 
inherits from BufferedIOBase and overrides the read() method.  This is the 
documentation for BufferedReader.read():

    read([n])
        Read and return n bytes, or if n is not given or negative, 
        until EOF or if the read call would block in non-blocking mode.

This sentence is complete gobbledygook, and it makes no mention of what should 
happen if nothing can be read in non-blocking mode.   So I presume behaviour 
for BufferedReader.read() should match the documented behaviour for 
BufferedIOBase.read().

----------
Added file: http://bugs.python.org/file23598/blockingioerror.py

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

Reply via email to