3rd / image.nvim

🖼️ Bringing images to Neovim.
MIT License
1.03k stars 42 forks source link

`nvim: src/unix/core.c:148: uv_close: Assertion '!uv__is_closing(handle)' failed` when closing nvim; doesn't happens with `backend = "ueberzug"` #127

Closed kohane27 closed 7 months ago

kohane27 commented 7 months ago

Hello there! Thank you so much for creating and maintaining this plugin! I couldn't even dream of opening images in neovim instead of binary until now!

Description

When I close neovim, the message nvim: src/unix/core.c:148: uv_close: Assertion '!uv__is_closing(handle)' failed is flashed:

https://github.com/3rd/image.nvim/assets/57322459/7c69ea5d-901f-4839-9b57-b3b95193f4a6

picture:

image-nvim

However, this doesn't happens with backend = "ueberzug"; so I suspect it's kitty's problem

Config

.tmux.conf:

set -gq allow-passthrough on
set -g visual-activity off

image.lua:

return {
  "3rd/image.nvim",
  event = "VeryLazy",
  opts = {
    tmux_show_only_in_active_window = true,
  },
  config = function(_, opts)
    package.path = package.path .. ";" .. vim.fn.expand("$HOME") .. "/.luarocks/share/lua/5.1/?/init.lua;"
    package.path = package.path .. ";" .. vim.fn.expand("$HOME") .. "/.luarocks/share/lua/5.1/?.lua;"
    require("image").setup(opts)
  end,
}

Environment

NVIM v0.9.5 Build type: Release LuaJIT 2.1.1702233742

Linux 6.7.4-arch1-1

Terminal: tmux inside kitty

kitty: 0.31.0 tmux: 3.3a sway: 1.8.1

Thank you!

kohane27 commented 7 months ago

I realized if I open a file and then immediately close it; this error exists. However, if I open a file, wait for 5 seconds then close it; this error doesn't exist.

3rd commented 7 months ago

Hey, can you upgrade to Neovim 0.10?

kohane27 commented 7 months ago

I just updated to NVIM v0.10.0-dev-2315+g32b49448b and the error is gone. Thank you!! Have a good day! <3