[New-bugs-announce] [issue36294] `io.BufferedIOBase` returns `None`
Cyker Way
report at bugs.python.org
Thu Mar 14 12:03:21 EDT 2019
New submission from Cyker Way <cykerway at gmail.com>:
Document of [BufferedIOBase](https://docs.python.org/3/library/io.html#io.BufferedIOBase) says:
> ...unlike their RawIOBase counterparts, they will never return None.
But this example shows the above statement is not true:
import io
import os
import sys
os.set_blocking(sys.stdin.fileno(), False)
print(isinstance(sys.stdin.buffer, io.BufferedIOBase))
print(sys.stdin.buffer.read())
Output:
True
None
----------
components: IO, Library (Lib)
messages: 337941
nosy: cykerway
priority: normal
severity: normal
status: open
title: `io.BufferedIOBase` returns `None`
versions: Python 3.7
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue36294>
_______________________________________
More information about the New-bugs-announce
mailing list