sys.stdout在bpython中没有属性flush
我正在使用bpython进行交互式Python会话,由于我更新了我的系统,我遇到了以下问题: 在bpython3中:sys.stdout在bpython中没有属性flush,python,python-3.x,sys,bpython,Python,Python 3.x,Sys,Bpython,我正在使用bpython进行交互式Python会话,由于我更新了我的系统,我遇到了以下问题: 在bpython3中: >>> import sys >>> sys.stdout.flush Traceback (most recent call last): File "<input>", line 1, in <module> AttributeError: 'FakeStream' object has no attribute
>>> import sys
>>> sys.stdout.flush
Traceback (most recent call last):
File "<input>", line 1, in <module>
AttributeError: 'FakeStream' object has no attribute 'flush'
这是一个在版本中修复的错误
使用
pip3安装-U bpython升级应该更新到最新的稳定版本,其中包括修复程序。这是一个在版本中修复的错误
使用pip3安装-U bpython
升级应该更新到最新的稳定版本,其中包括修复程序。是否使用sys.\uuuuu stdout\uuuuu.flush
工作?这确实在bpython3
中有效,@padraiccunningham似乎是一个在0.13版pip3安装-U bpython
中修复的错误,非常感谢。它解决了这个问题。为完整起见,修复此错误的提交:@J.F.Sebastian,当然,done.doessys.\uu stdout\uuuu.flush
有效吗?这确实在bpython3
中有效,@padraickunningham似乎是一个在0.13版pip3安装中修复的错误,谢谢。它解决了这个问题。为了完整性,修复此错误的提交:@J.F.Sebastian,当然,完成。
>>> import sys
>>> sys.stdout.flush
<built-in method flush of _io.TextIOWrapper object at 0x7fab6b7fb708>
$ bpython3 --version
bpython version 0.12 on top of Python 3.4.2
(C) 2008-2012 Bob Farrell, Andreas Stuehrk et al. See AUTHORS for detail.
$ python3 --version
Python 3.4.2