When you use the click.prompt() method and you specify confirmation_prompt=True, there is no way to allow the user to just hit ENTER (empty str).
passphrase = click.prompt(
"Create Passphrase",
hide_input=True,
confirmation_prompt=True,
default=""
)
Hit ENTER for the first passphrase. Then, when it asks you to confirm, hit ENTER again.
It repeats forever and never lets you exit.
After hitting ENTER the second time, I expect it to save return "" as the user's prompt answer.
Environment:
- Python version: 3.9.7
- Click version: 8.0.3
When you use the
click.prompt()method and you specifyconfirmation_prompt=True, there is no way to allow the user to just hit ENTER (empty str).Hit ENTER for the first passphrase. Then, when it asks you to confirm, hit ENTER again.
It repeats forever and never lets you exit.
After hitting ENTER the second time, I expect it to save return
""as the user's prompt answer.Environment: