lnav icon indicating copy to clipboard operation
lnav copied to clipboard

Esc key doesn't abort

Open xuyangyuio opened this issue 1 year ago • 5 comments

ESC key doesn't abort the search or command, only Ctrl-] does.

xuyangyuio avatar Jul 19 '24 15:07 xuyangyuio

What is your operating system, terminal emulator, and version of lnav?

avi-cenna avatar Jul 19 '24 17:07 avi-cenna

@xuyangyuio can you provide some more details. Things seem to work for me and others, so it's hard to know what the issue might be.

tstack avatar Aug 04 '24 16:08 tstack

EDIT: The behavior below can be reproduced by some configuration in readline. Note that this happens in Zsh as well even though it doesn't use readline. It's a separate issue from this one, so I opened another issue for it #1341

I have a similar issue. It's doing something odd. I press :123456789123456789 nothing appears in the command bar until 23456789, so :1234567891 aren't visible (same thing if I start with ;). I press <escape> and what I see 232 q:123456789123456789. If I press <enter> I get ✘ error: unknown command - 123456789123456789 which is to be expected, but the escape button and command bar don't seem to behave properly.

Linux 6.10.8-arch1-1 #1 SMP PREEMPT_DYNAMIC Wed, 04 Sep 2024 15:16:37 +0000 x86_64 GNU/Linux

lnav --version
lnav 0.12.2

# Tried on 2 terminals
echo $TERM
alacritty
echo "$TERM"        
xterm-kitty

YasserKa avatar Sep 11 '24 15:09 YasserKa

2024-09-11_18:32:25

This behavior can be reproduced. Check comment above.

YasserKa avatar Sep 11 '24 15:09 YasserKa

I am on MacOS Monterey. Tried Iterm2/Kitty, bash/zsh, none of the 4 combinations worked. Nothing happens when <Esc> key is pressed.

xuyangyuio avatar Sep 11 '24 15:09 xuyangyuio

I'll pile on... I notice the same behaviour here, using 0.12.2. For me, it happens when I shell into my Alpine-based Docker container and run lnav from there. Ctrl-] works but Esc does not.

The more irksome behaviour, and possibly related to this issue, is that the : key makes lnav immediately exit, leaving me unable to enter commands into lnav. 0.12.1 did not exhibit this problem.

TERM is set to xterm-256color.

jvinet avatar Nov 02 '24 19:11 jvinet

The top-of-tree has switched from ncurses to notcurses for input handling. Pressing ESC in prompts seems to do the right thing now.

tstack avatar Jan 23 '25 21:01 tstack