Message248907
On windows, when python is started from the command line without a GUI, os.isatty(sys.stdin) raises an error, but os.isatty(sys.stdin.fileno()) returns true.
Within IDLE, os.isatty(sys.stdin.fileno()) also raises an error, but os.isatty(0), os.isatty(1), and os.isatty(2) all return true.
I'm not sure exactly when you want which warning to show, let alone whether the above tests are relevant, but I'm happy to run some tests if you can tell me what you're looking for. |
|
Date |
User |
Action |
Args |
2015-08-20 18:06:55 | Jim.Jewett | set | recipients:
+ Jim.Jewett, terry.reedy, ncoghlan, ezio.melotti, njs, takluyver, martin.panter, serhiy.storchaka, The Compiler, mbussonn |
2015-08-20 18:06:55 | Jim.Jewett | set | messageid: <1440094015.23.0.793488229301.issue24294@psf.upfronthosting.co.za> |
2015-08-20 18:06:55 | Jim.Jewett | link | issue24294 messages |
2015-08-20 18:06:55 | Jim.Jewett | create | |
|