Open minghu6 opened 1 year ago
Thanks for the bug report. I tried to quickly press cursor down on a long list with 100 entries, but could not get your described behavior (on Ubuntu 22.04 with gnome terminal). Do you also use the default gnome terminal?
Thanks for the bug report. I tried to quickly press cursor down on a long list with 100 entries, but could not get your described behavior (on Ubuntu 22.04 with gnome terminal). Do you also use the default gnome terminal?
Yes, i use default gnome shell (v42.5), sometimes it's ok, however if i rerun the script the issue occurs (just holding the key).
Thanks for the bug report. I tried to quickly press cursor down on a long list with 100 entries, but could not get your described behavior (on Ubuntu 22.04 with gnome terminal). Do you also use the default gnome terminal?
Oh. I found the detail !, I run the script use an alias which is rlwrap python
, that's if I run python in rlwrap (0.43-1build3 from ubuntu official repo) and then the issue occurs!
Python already has built-in edit support with libreadline. Do you really need rlwrap
here?
Python already has built-in edit support with libreadline. Do you really need
rlwrap
here?
It looks like i could use import readline
to replace rlwrap.
With rlwrap simple-term-menu $(seq 1 100)
I can reproduce the behavior, you described. But I am not really sure if this is an issue with simple-term-menu or with rlwrap.
With
rlwrap simple-term-menu $(seq 1 100)
I can reproduce the behavior, you described. But I am not really sure if this is an issue with simple-term-menu or with rlwrap.
I've tried another terminal menu on a Rust impl with rlwrap, and it's alright. Maybe there are some incompatiable on terminal manipulation or comflict on libreadline?
Env: Ubuntu 22.04, Python 3.10, Gnome Shell
Pressing
down
too quickly causesshow
returnsNone
unexpectly (especially for the long menu).And as a workaround, If I put the
show
method into a infinite loop, it also protects from quit shortcuts. (need a specific exception to indicate aquit
event?)