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 terry.reedy
Recipients Guilherme.Simões, Todd.Rovito, roger.serwy, serhiy.storchaka, terry.reedy
Date 2013-04-26.22:22:06
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1367014926.12.0.0698089429654.issue17838@psf.upfronthosting.co.za>
In-reply-to
Content
I think PseudoXxxFile should have close methods, but that the methods should not be called when they should not be. Rebinding sys.stdin should not close command line input.

My perhaps naive thought is that initializing sys.__stdin__ to the original sys.stdin, as in the standard interpreter and as specified in the docs, is the proper place for the extra reference to keep PseudoInputFile alive. (I presume we are talking about the object in the user process.) While the sys module doc says that any of sys.std** and sys.__std**__ can be None on Windows pythonw gui apps, that does not make None a good idea ;-).
History
Date User Action Args
2013-04-26 22:22:06terry.reedysetrecipients: + terry.reedy, roger.serwy, Todd.Rovito, serhiy.storchaka, Guilherme.Simões
2013-04-26 22:22:06terry.reedysetmessageid: <1367014926.12.0.0698089429654.issue17838@psf.upfronthosting.co.za>
2013-04-26 22:22:06terry.reedylinkissue17838 messages
2013-04-26 22:22:06terry.reedycreate