[issue24711] Document getpass.getpass behavior on ^C

2022-01-21 Thread Terry J. Reedy
Terry J. Reedy added the comment: In IDLE Shell, with either ^C or ^D, >> try: ... input('??') ... except: ... 'done' ... ... ?? 'done' 'getpass.getpass('??') does same after printing warning from line 100 that fallback_getpass is being used. The newline may be supplied by

[issue24711] Document getpass.getpass behavior on ^C

2022-01-17 Thread David Lord
David Lord added the comment: Meant to say that "done" shows up on the same line, not the shell prompt. An earlier version of my example was in the REPL, where its prompt *does* show up on the same line. -- ___ Python tracker

[issue24711] Document getpass.getpass behavior on ^C

2022-01-17 Thread Irit Katriel
Change by Irit Katriel : -- resolution: works for me -> versions: +Python 3.10, Python 3.9 -Python 2.7, Python 3.2, Python 3.3, Python 3.4, Python 3.5, Python 3.6 ___ Python tracker

[issue24711] Document getpass.getpass behavior on ^C

2022-01-17 Thread Irit Katriel
Change by Irit Katriel : -- status: closed -> open ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue24711] Document getpass.getpass behavior on ^C

2022-01-17 Thread David Lord
David Lord added the comment: I can reproduce this on Python 3.10. Actually, `input` and `getpass` both seem to have this behavior now. Please reopen it. ```python import getpass try: getpass.getpass("in: ") except: pass print("done") ``` ``` $ python example.py getpass: ^D done

[issue24711] Document getpass.getpass behavior on ^C

2021-01-11 Thread Irit Katriel
Irit Katriel added the comment: Works for me on both linux and windows. -- stage: -> resolved status: pending -> closed ___ Python tracker ___

[issue24711] Document getpass.getpass behavior on ^C

2020-12-04 Thread Irit Katriel
Irit Katriel added the comment: I don't see a difference between getpass and input in this respect: import getpass try: getpass.getpass('getpass: ') except: pass print('goodbye getpass') try: input('input: ') except: pass print('goodbye input')

[issue24711] Document getpass.getpass behavior on ^C

2015-07-24 Thread Markus Unterwaditzer
New submission from Markus Unterwaditzer: getpass.getpass doesn't enter a newline when the user aborts input with ^C, while input/raw_input does. This behavior is surprising and can lead to mis-formatting of subsequent output. However, since this behavior exists since 2.7 and applications may