This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author roger.serwy
Recipients roger.serwy, terry.reedy
Date 2021-11-14.02:48:00
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1636858081.72.0.88336234035.issue45804@roundup.psfhosted.org>
In-reply-to
Content
The shell provided by IDLE uses synchronous sys.stdout.write() calls between the subprocess and the front-end, leading to very slow writes. The provided patch proposes buffering the stdout/stderr streams in the subprocess and then sending a single update after 50ms. The patch also provides back pressure on the buffer so that it doesn't grow without bound.

When trying the behavior of the patch, disable the squeezer extension, or set its limit to 1000. Then in the shell, run:

    for i in range(500): print(i)

The output will instantly appear in the shell.
History
Date User Action Args
2021-11-14 02:48:01roger.serwysetrecipients: + roger.serwy, terry.reedy
2021-11-14 02:48:01roger.serwysetmessageid: <1636858081.72.0.88336234035.issue45804@roundup.psfhosted.org>
2021-11-14 02:48:01roger.serwylinkissue45804 messages
2021-11-14 02:48:00roger.serwycreate