-
Notifications
You must be signed in to change notification settings - Fork 4.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Console.ReadLine on Ubuntu in WSL disables echo of characters when cancelled with Ctrl-C #64166
Comments
Tagging subscribers to this area: @dotnet/area-system-console Issue DetailsDescriptionAfter exiting a program with ctrl-c, that was waiting for input via Console.ReadLine leaves the command line in bad state. Reproduction Steps
Press ctrl-c as the program asks for. Now you are back on the command line. Try to type anything, you will not see the characters typed. Expected behaviorTerminal behaves normally as if the program was never run. Actual behaviorYou will not see the characters you type. Another thing I recognized that when executing Regression?No response Known WorkaroundsExecute Configuration
And also tested on Ubuntu 20.04 LTS on WSL2 Other informationNo response
|
cc: @tmds |
@danielbisar thank you for the clear reproducer. It looks like a regression from #54136 which causes |
Thank you for the fast fix. |
Description
After exiting a program with ctrl-c, that was waiting for input via Console.ReadLine leaves the command line in bad state.
Reproduction Steps
Press ctrl-c as the program asks for. Now you are back on the command line. Try to type anything, you will not see the characters typed.
Expected behavior
Terminal behaves normally as if the program was never run.
Actual behavior
You will not see the characters you type. Another thing I recognized that when executing
echo x
it does not print a newline anymore but overwrites part of the prompt.Regression?
No response
Known Workarounds
Execute
tput reset
in bash.Configuration
And also tested on Ubuntu 20.04 LTS on WSL2
Other information
No response
The text was updated successfully, but these errors were encountered: