-
-
Notifications
You must be signed in to change notification settings - Fork 2.2k
Description
Describe the bug
Instead of using shortcut c
to commit changes I use Shift+;
shortcut for "Custom command" to add additional options to git commit
command and to get external text editor (e.g. nano). Since lazygit-0.44.0 release and in lazygit-0.44.1 after I save commit message changes the lazygit Stop
and "crashes".
Maybe it's related to use of pgp-key to sign the commits too.
The lazygit-0.43.1
isn't affected by this issue
To Reproduce
Steps to reproduce the behavior:
- Change directory in terminal to any git repo
- Make any changes in files under this repo
- Launch the
lazygit
and accept changes in appropriate window - Use
Shift+;
shortcut to open "Custom command" prompt and entergit commit
(or e.g.git commit -s -S
) - In opened text editor enter message, save end exit text editor
- Notice that lazygit crashes with
[1]+ Stopped lazygit
message in terminal afterPress enter to return to lazygit
message.
Expected behavior
Show Press enter to return to lazygit
message after exit from text editor without stop running lazygit.
Screenshots
Version info:
lazygit --version
: commit=, build date=, build source=unknown, version=0.44.1, os=linux, arch=amd64, git version=2.44.2
git --version
: git version 2.44.2
Additional context
gdb output:
$ gdb lazygit
GNU gdb (Gentoo 14.2 vanilla) 14.2
Copyright (C) 2023 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Type "show copying" and "show warranty" for details.
This GDB was configured as "x86_64-pc-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<https://bugs.gentoo.org/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from lazygit...
warning: File "/usr/lib/go/src/runtime/runtime-gdb.py" auto-loading has been declined by your `auto-load safe-path' set to "$debugdir:$datadir/auto-load".
To enable execution of this file add
add-auto-load-safe-path /usr/lib/go/src/runtime/runtime-gdb.py
line to your configuration file "/home/user/.config/gdb/gdbinit".
To completely disable this security protection add
set auto-load safe-path /
line to your configuration file "/home/user/.config/gdb/gdbinit".
For more information about this security protection see the
"Auto-loading safe path" section in the GDB manual. E.g., run from the shell:
info "(gdb)Auto-loading safe path"
(gdb) run
Starting program: /usr/bin/lazygit
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib64/libthread_db.so.1".
[New Thread 0x7fffb13486c0 (LWP 17279)]
[New Thread 0x7fffb0b476c0 (LWP 17280)]
[New Thread 0x7fffabfff6c0 (LWP 17281)]
[New Thread 0x7fffab7fe6c0 (LWP 17282)]
[New Thread 0x7fffaaffd6c0 (LWP 17283)]
[Detaching after vfork from child process 17284]
[Detaching after vfork from child process 17285]
[New Thread 0x7fffaa7fc6c0 (LWP 17287)]
+ /bin/bash -i -c git commit -s -S
[Detaching after vfork from child process 17343]
[dev 1a99e35ca] lazygit
2 files changed, 33 insertions(+)
create mode 100644 dev-vcs/lazygit/lazygit-0.44.1.ebuild
Press enter to return to lazygit
Thread 8 "lazygit" received signal SIGTTIN, Stopped (tty input).
[Switching to Thread 0x7fffa9ffb6c0 (LWP 17288)]
runtime/internal/syscall.Syscall6 () at /usr/lib/go/src/runtime/internal/syscall/asm_linux_amd64.s:36
36 CMPQ AX, $0xfffffffffffff001
(gdb) bt
#0 runtime/internal/syscall.Syscall6 () at /usr/lib/go/src/runtime/internal/syscall/asm_linux_amd64.s:36
#1 0x000055555556350d in syscall.RawSyscall6 (num=18446744073709551104, a1=0, a2=93824992294190, a3=0, a4=824636563728, a5=0, a6=0, r1=<optimized out>, r2=<optimized out>, errno=<optimized out>)
at /usr/lib/go/src/runtime/internal/syscall/syscall_linux.go:38
#2 0x000055555563a746 in syscall.Syscall (trap=0, a1=0, a2=824636563728, a3=1, r1=<optimized out>, r2=<optimized out>, err=<optimized out>) at /usr/lib/go/src/syscall/syscall_linux.go:82
#3 0x00005555556387d8 in syscall.read (fd=<optimized out>, p=..., n=<optimized out>, err=...) at /usr/lib/go/src/syscall/zsyscall_linux_amd64.go:736
#4 0x0000555555656fee in syscall.Read (fd=0, n=<optimized out>, err=..., p=...) at /usr/lib/go/src/syscall/syscall_unix.go:181
#5 internal/poll.ignoringEINTRIO (fd=0, fn=<optimized out>, p=...) at /usr/lib/go/src/internal/poll/fd_unix.go:736
#6 internal/poll.(*FD).Read (fd=0xc000110000, p=..., ~r0=<optimized out>, ~r0=<optimized out>, ~r1=..., ~r1=...) at /usr/lib/go/src/internal/poll/fd_unix.go:160
#7 0x00005555556623b2 in os.(*File).read (f=0xc000072020, b=..., n=<optimized out>, err=...) at /usr/lib/go/src/os/file_posix.go:29
#8 os.(*File).Read (f=0xc000072020, b=..., n=<optimized out>, err=...) at /usr/lib/go/src/os/file.go:118
#9 0x00005555555e24f0 in io.ReadAtLeast (r=..., buf=..., min=1, n=<optimized out>, err=...) at /usr/lib/go/src/io/io.go:335
#10 0x0000555555676bfa in io.ReadFull (r=..., buf=..., n=<optimized out>, err=...) at /usr/lib/go/src/io/io.go:354
#11 fmt.(*readRune).readByte (r=0xc0002b60f0, b=<optimized out>, err=...) at /usr/lib/go/src/fmt/scan.go:321
#12 0x0000555555676cf1 in fmt.(*readRune).ReadRune (r=0xc0002b60f0, rr=<optimized out>, size=<optimized out>, err=...) at /usr/lib/go/src/fmt/scan.go:337
#13 0x00005555556767d3 in fmt.(*ss).ReadRune (s=0xc0001103c0, r=<optimized out>, size=<optimized out>, err=...) at /usr/lib/go/src/fmt/scan.go:189
#14 0x00005555556768b7 in fmt.(*ss).getRune (s=0xfffffffffffffe00, r=<optimized out>) at /usr/lib/go/src/fmt/scan.go:211
#15 0x000055555567733c in fmt.(*ss).SkipSpace (s=0xfffffffffffffe00) at /usr/lib/go/src/fmt/scan.go:422
#16 0x00005555556793ff in fmt.(*ss).convertString (s=0xc0001103c0, verb=118, str=...) at /usr/lib/go/src/fmt/scan.go:828
#17 0x0000555555679f96 in fmt.(*ss).scanOne (s=0xc0001103c0, verb=118, arg=...) at /usr/lib/go/src/fmt/scan.go:1012
#18 0x000055555567aea5 in fmt.(*ss).doScan (s=0xfffffffffffffe00, a=..., numProcessed=<optimized out>, numProcessed=<optimized out>, err=...) at /usr/lib/go/src/fmt/scan.go:1073
#19 0x00005555556764e5 in fmt.Fscanln (r=..., a=..., n=<optimized out>, err=...) at /usr/lib/go/src/fmt/scan.go:132
#20 0x0000555555cd9da5 in fmt.Scanln (a=..., n=<optimized out>, err=...) at /usr/lib/go/src/fmt/scan.go:70
#21 github.com/jesseduffield/lazygit/pkg/gui.(*Gui).runSubprocess (gui=0xc0000c6608, cmdObj=..., ~r0=...) at /var/tmp/portage/dev-vcs/lazygit-0.44.1/work/lazygit-0.44.1/pkg/gui/gui.go:973
#22 0x0000555555cd971e in github.com/jesseduffield/lazygit/pkg/gui.(*Gui).runSubprocessWithSuspense (gui=0xc0000c6608, subprocess=..., ~r0=<optimized out>, ~r0=<optimized out>, ~r1=..., ~r1=...)
at /var/tmp/portage/dev-vcs/lazygit-0.44.1/work/lazygit-0.44.1/pkg/gui/gui.go:939
#23 0x0000555555cd9565 in github.com/jesseduffield/lazygit/pkg/gui.(*Gui).runSubprocessWithSuspenseAndRefresh (gui=0xfffffffffffffe00, subprocess=..., ~r0=...)
at /var/tmp/portage/dev-vcs/lazygit-0.44.1/work/lazygit-0.44.1/pkg/gui/gui.go:915
#24 0x0000555555cdaa45 in github.com/jesseduffield/lazygit/pkg/gui.(*guiCommon).RunSubprocessAndRefresh (self=<optimized out>, cmdObj=..., ~r0=...)
at /var/tmp/portage/dev-vcs/lazygit-0.44.1/work/lazygit-0.44.1/pkg/gui/gui_common.go:37
#25 0x0000555555c92a90 in github.com/jesseduffield/lazygit/pkg/gui/controllers.(*ShellCommandAction).Call.func1 (command=..., ~r0=...)
at /var/tmp/portage/dev-vcs/lazygit-0.44.1/work/lazygit-0.44.1/pkg/gui/controllers/shell_command_action.go:33
#26 0x0000555555c0436d in github.com/jesseduffield/lazygit/pkg/gui/controllers/helpers.(*ConfirmationHelper).setKeyBindings.(*ConfirmationHelper).wrappedPromptConfirmationFunction.func5 (~r0=...)
at /var/tmp/portage/dev-vcs/lazygit-0.44.1/work/lazygit-0.44.1/pkg/gui/controllers/helpers/confirmation_helper.go:45
#27 0x0000555555c0431a in github.com/jesseduffield/lazygit/pkg/gui/controllers/helpers.(*ConfirmationHelper).setKeyBindings.(*ConfirmationHelper).wrappedPromptConfirmationFunction.(*ConfirmationHelper).wrappedConfirmationFunction.func8 (~r0=...) at /var/tmp/portage/dev-vcs/lazygit-0.44.1/work/lazygit-0.44.1/pkg/gui/controllers/helpers/confirmation_helper.go:34
#28 0x0000555555ca283b in github.com/jesseduffield/lazygit/pkg/gui/controllers.(*SuggestionsController).GetKeybindings.func1 (~r0=...)
at /var/tmp/portage/dev-vcs/lazygit-0.44.1/work/lazygit-0.44.1/pkg/gui/controllers/suggestions_controller.go:35
#29 0x0000555555ce0ee4 in github.com/jesseduffield/lazygit/pkg/gui.(*Gui).callKeybindingHandler (gui=0xc0000c6608, binding=<optimized out>, ~r0=...)
at /var/tmp/portage/dev-vcs/lazygit-0.44.1/work/lazygit-0.44.1/pkg/gui/keybindings.go:465
#30 0x0000555555ce0a9b in github.com/jesseduffield/lazygit/pkg/gui.(*Gui).SetKeybinding.func1 (~r0=...) at /var/tmp/portage/dev-vcs/lazygit-0.44.1/work/lazygit-0.44.1/pkg/gui/keybindings.go:412
#31 0x0000555555ce09b3 in github.com/jesseduffield/lazygit/pkg/gui.(*Gui).SetKeybinding.(*Gui).wrappedHandler.func3 (g=<optimized out>, v=0x0, ~r0=...)
at /var/tmp/portage/dev-vcs/lazygit-0.44.1/work/lazygit-0.44.1/pkg/gui/keybindings.go:406
#32 0x000055555590c94a in github.com/jesseduffield/gocui.(*Gui).execKeybinding (g=<optimized out>, v=<optimized out>, kb=<optimized out>, ~r0=...)
at /var/tmp/portage/dev-vcs/lazygit-0.44.1/work/lazygit-0.44.1/vendor/github.com/jesseduffield/gocui/gui.go:1529
#33 0x000055555590c825 in github.com/jesseduffield/gocui.(*Gui).execKeybindings (g=0xc0000a2e00, v=0xc0001d6c00, ev=0xc000cef5a0, ~r0=...)
at /var/tmp/portage/dev-vcs/lazygit-0.44.1/work/lazygit-0.44.1/vendor/github.com/jesseduffield/gocui/gui.go:1497
#34 0x000055555590bc7e in github.com/jesseduffield/gocui.(*Gui).onKey (g=0xfffffffffffffe00, ev=<optimized out>, ~r0=...)
at /var/tmp/portage/dev-vcs/lazygit-0.44.1/work/lazygit-0.44.1/vendor/github.com/jesseduffield/gocui/gui.go:1308
#35 0x0000555555909fd9 in github.com/jesseduffield/gocui.(*Gui).handleEvent (g=<optimized out>, ev=<optimized out>, ~r0=...)
at /var/tmp/portage/dev-vcs/lazygit-0.44.1/work/lazygit-0.44.1/vendor/github.com/jesseduffield/gocui/gui.go:842
#36 0x0000555555909b4f in github.com/jesseduffield/gocui.(*Gui).processEvent (g=0xc0000a2e00, ~r0=..., ~r0=...)
at /var/tmp/portage/dev-vcs/lazygit-0.44.1/work/lazygit-0.44.1/vendor/github.com/jesseduffield/gocui/gui.go:796
#37 0x0000555555909797 in github.com/jesseduffield/gocui.(*Gui).MainLoop (g=0xc0000a2e00, ~r0=...) at /var/tmp/portage/dev-vcs/lazygit-0.44.1/work/lazygit-0.44.1/vendor/github.com/jesseduffield/gocui/gui.go:775
#38 0x0000555555cd8add in github.com/jesseduffield/lazygit/pkg/gui.(*Gui).Run (gui=0xc0000c6608, startArgs=..., ~r0=..., ~r0=...) at /var/tmp/portage/dev-vcs/lazygit-0.44.1/work/lazygit-0.44.1/pkg/gui/gui.go:846