Author roger.serwy
Recipients Guilherme.Simões, Todd.Rovito, roger.serwy, serhiy.storchaka, terry.reedy
Date 2013-04-26.14:25:03
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1366986303.85.0.70731476773.issue17838@psf.upfronthosting.co.za>
In-reply-to
Content
If we remove .close() then we'll need to then have an alternative way to allow "exit()" and "quit()" to actually close IDLE. The RPC proxy already transfers exceptions between the subprocess and the front-end, so we could catch the SystemExit exception and handle it by calling close(). That's perfectably doable, and likely the right way to do it. If anyone wants to write that patch, I'll gladly offer guidance if necessary.

Here's a dirty hack that also solves the issue. Garbage collection on the PseudoInputFile for sys.stdin calls .close(). As long as we hold an extra reference to it, it won't close. The attached patch holds an extra reference to sys.stdin in Lib/idlelib/run.py.
History
Date User Action Args
2013-04-26 14:25:03roger.serwysetrecipients: + roger.serwy, terry.reedy, Todd.Rovito, serhiy.storchaka, Guilherme.Simões
2013-04-26 14:25:03roger.serwysetmessageid: <1366986303.85.0.70731476773.issue17838@psf.upfronthosting.co.za>
2013-04-26 14:25:03roger.serwylinkissue17838 messages
2013-04-26 14:25:03roger.serwycreate