Skip to content
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

When a program accepts input, the arrow keys can move the cursor and program receives invalid input #556

Closed
Jimmio92 opened this issue May 29, 2016 · 4 comments

Comments

@Jimmio92
Copy link

Hello all,

I've noticed a very annoying problem with mintty in msys2. When a program requests input and you try to press the up arrow to select previously entered text/commands, the cursor moves instead. If you then move the cursor back into its previous location and hit enter, you can get trapped in a loop waiting for valid input as it never will be thanks to the cursor moving.

I'm not sure what's going on underneath to cause this, but it's really frustrating when I accidentally hit the up arrow to try and select last entered (which is a habit of mine during development of software), and I have to close the program and/or the terminal and relaunch. I do believe I have experienced the whole terminal being unable to be used because of this issue, but I do not recall how to cause it to happen.

I'm sorry in advance if this bug has been discussed before, or if I am not following best reporting practices. I am new to open source development, and therefore, the community involvement process(es).

@mintty
Copy link
Owner

mintty commented May 29, 2016

It might be useful to know which program you are running when the problem occurs. Likely being a native Windows program, this is a duplicate of a number of previous reports, and basically of #56.

@Jimmio92
Copy link
Author

My apologies for yet another duplicate. I should have went through all issues to see if they were similar, not just the issue titles.

I have figured out how to avoid this problem in my own programs, however I cannot fix some (no source). Basically, the problem lied in the fact that I did not check for error on input, and never cleared the fail bit(s).

@mintty
Copy link
Owner

mintty commented May 29, 2016

You may look for a cygwin/MinGW alternative package of your software, that should work then.
Otherwise you could try the conin tool mentioned in issue 56.

@mintty
Copy link
Owner

mintty commented Dec 16, 2019

Cygwin 3.1.0 has been released with ConPTY support.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants