Visitar URL original
Ctrl+Z and Ctrl+C don't exit GPython on Windows 10 · Issue #80 · go-python/gpython · GitHub
The Wayback Machine - https://web.archive.org/web/20200910210632/https://github.com/go-python/gpython/issues/80
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

Ctrl+Z and Ctrl+C don't exit GPython on Windows 10 #80

Open
tim-st opened this issue Sep 15, 2019 · 3 comments
Open

Ctrl+Z and Ctrl+C don't exit GPython on Windows 10 #80

tim-st opened this issue Sep 15, 2019 · 3 comments
Labels

Comments

@tim-st
Copy link
Contributor

@tim-st tim-st commented Sep 15, 2019

Currently it's hard to close the REPL on Windows using standard terminal.
On WSL Ubuntu it works with Ctrl+Z, in Windows nothing happens.

@ncw
Copy link
Collaborator

@ncw ncw commented Sep 15, 2019

Does CTRL-D exit the REPL under Windows?

I think this might be a bug in https://github.com/peterh/liner/ which gpython uses.

@ncw ncw added the bug label Sep 15, 2019
@tim-st
Copy link
Contributor Author

@tim-st tim-st commented Sep 15, 2019 •

That's interesting. Ctrl+D does work perfect. Then this can get closed for now, I think.

@tim-st tim-st changed the title Ctrl+Z doesn't exit GPython on Windows 10 Ctrl+Z and Ctrl+C don't exit GPython on Windows 10 Sep 15, 2019
@ncw
Copy link
Collaborator

@ncw ncw commented Sep 15, 2019

That's interesting. Ctrl+D does work perfect. Then this can get closed for now, I think.

In windows the exit sequence is CTRL-Z RETURN. It may be possible to emulate that as well in gpython.

What happens is this

This appears when you press CTRL-Z

>>> ^Z

And only when you press RETURN after that does the interpreter exit.

So we could emulate this just by looking for a string with CTRL-Z in it maybe.. Not sure exactly how liner would deal with that though.

I'll leave this open as an enhancement if someone wants to have a go at it.

@ncw ncw added enhancement and removed bug labels Sep 15, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants
You can’t perform that action at this time.