Attempt to index local 'diff' (a nil value)
fnune opened this issue · comments
Description
E5108: Error executing lua: ...share/nvim/lazy/plenary.nvim/lua/plenary/async/async.lua:18: The coroutine failed with this message: .../share/nvim/lazy/neogit/lua/neogit/buffers/status/ui.lua:224: attempt to index
local 'diff' (a nil value)
stack traceback:
[C]: in function 'error'
...share/nvim/lazy/plenary.nvim/lua/plenary/async/async.lua:18: in function 'callback_or_next'
...share/nvim/lazy/plenary.nvim/lua/plenary/async/async.lua:45: in function 'step'
...share/nvim/lazy/plenary.nvim/lua/plenary/async/async.lua:48: in function 'execute'
...share/nvim/lazy/plenary.nvim/lua/plenary/async/async.lua:118: in function 'on_open'
...e/nvim/lazy/neogit/lua/neogit/buffers/status/actions.lua:443: in function 'cb'
.../.local/share/nvim/lazy/neogit/lua/neogit/lib/buffer.lua:580: in function <.../.local/share/nvim/lazy/neogit/lua/neogit/lib/buffer.lua:579>
Press ENTER or type command to continue
This happens when hitting tab to expand a diff.
Neovim version
~/.home.nix => nvim --version
NVIM v0.10.0
Build type: Release
LuaJIT 2.1.1693350652
Run "nvim -V1 -v" for more info
Operating system and version
~/.home.nix => uname -a Linux feanor 6.8.10 #1-NixOS SMP PREEMPT_DYNAMIC Fri May 17 10:15:12 UTC 2024 x86_64 GNU/Linux
Steps to reproduce
- Open Neogit
- Expand a diff
Expected behavior
No response
Actual behavior
Crashes, diff does not open.
Minimal config
-
That's....not right. And also, not my experience. Could you try to make a minimal reproduction case for me?
Sorry about the noise. It looks like this is no longer happening to me. I'm wondering whether it's because I had just upgraded my operating system and there was a problem with a dependency (git?).
An update: this was, in the end, not related to my system dependencies.
I realized it was only happening in one of my repositories, so I removed the directory and cloned the repository again. That solved the problem. Unfortunately I didn't make a backup but I'm assuming it's something obscure about the state in .git
...
That makes sense - the issue in bisect with a missing OID would mean there was a bisect that didn't get stopped? 🤷🏼