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 eryksun, matejcik, paul.moore, steve.dower, terry.reedy, tim.golden, zach.ware
Date 2021-08-05.04:12:43
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1628136764.58.0.747148371198.issue44762@roundup.psfhosted.org>
In-reply-to
Content
The rationale for the __stdin__ and stdin check is this:  When python starts, both are usually set an io.TextIOWrapper wrapping a system console. (At least on Windows, both may instead be None instead.)  __stdin__ should never be altered.  Getpass.getpass knows how to turn off echo on a system terminal.  So if stdin is not None and is not __stdin__, stdin is very likely not a system terminal, and if so, getpass does not know to turn off echo, if indeed this is possible.

As far as I know, the tk and hence tkinter text widget do not come with a option to not display key presses that are stored in the widget.  An application would have to intercept keypresses and store them elsewhere.
But this is quite different issue.

This issue is not about echo, but about interactivity.  Testing that with isatty is *NOT* a substitute for testing whether an interactive device is the system terminal or not.  (IDLE's stdio connected to Shell passes isatty.)  Any new test would have to added without deleting the current test.
History
Date User Action Args
2021-08-05 04:12:44terry.reedysetrecipients: + terry.reedy, paul.moore, tim.golden, matejcik, zach.ware, eryksun, steve.dower
2021-08-05 04:12:44terry.reedysetmessageid: <1628136764.58.0.747148371198.issue44762@roundup.psfhosted.org>
2021-08-05 04:12:44terry.reedylinkissue44762 messages
2021-08-05 04:12:43terry.reedycreate