[X] I have searched the existing issues of edgy.nvim
[X] I have searched the existing issues of plugins related to this issue
Neovim version (nvim -v)
NVIM v0.9.2
Operating system/version
Linux 5.15.0-84-generic #93-Ubuntu SMP Tue Sep 5 17:16:10 UTC 2023 GNU/Linux
Describe the bug
Neovim exhibits unusual behavior when an invalid configuration is used. Specifically, instead of encountering an exception during the execution of require"edgy".setup {}, Neovim starts to consume 100% of a CPU's core after certain window manipulations. Additionally, it may freeze on the :q command.
SPOILER
Extensive examination revealed the root of the issue. The utility `edgy.util.with_retry` fails to increment the `retries` variable. This results in Neovim entering a perpetual loop of `try -> vim.schedule(try) -> vim.schedule(try) ->...`, effectively rendering it stuck and not displaying an error message to the user.
Steps To Reproduce
Implement a basic configuration:
local plugs = vim.fn.stdpath("data") .. "/lazy"
local edgy = plugs .. "/edgy.nvim"
vim.opt.runtimepath:append(edgy)
require("edgy").setup({
// Erroneous configuration
animate = false,
bottom = { { ft = "help" }, },
})
Run a clean instance of Neovim using nvim --clean -u /path/to/cfg.lua.
Issue :h cmd.
Monitor CPU usage using ps -eo %cpu,command | grep nvim.
Optionally, try manipulating more windows (may require configuration adjustment) until Neovim becomes unresponsive to input.
Expected Behavior
Neovim should maintain normal CPU usage and not reach 100% consumption.
Repro
local plugs = vim.fn.stdpath("data") .. "/lazy"
local edgy = plugs .. "/edgy.nvim"
vim.opt.runtimepath:append(edgy)
require("edgy").setup({
-- Erroneous configuration, should be `{ animate = { enabled = false } }`
animate = false,
bottom = { { ft = "help" }, },
})
Did you check docs and existing issues?
Neovim version (nvim -v)
NVIM v0.9.2
Operating system/version
Linux 5.15.0-84-generic #93-Ubuntu SMP Tue Sep 5 17:16:10 UTC 2023 GNU/Linux
Describe the bug
Neovim exhibits unusual behavior when an invalid configuration is used. Specifically, instead of encountering an exception during the execution of
require"edgy".setup {}
, Neovim starts to consume 100% of a CPU's core after certain window manipulations. Additionally, it may freeze on the :q command.SPOILER
Extensive examination revealed the root of the issue. The utility `edgy.util.with_retry` fails to increment the `retries` variable. This results in Neovim entering a perpetual loop of `try -> vim.schedule(try) -> vim.schedule(try) ->...`, effectively rendering it stuck and not displaying an error message to the user.Steps To Reproduce
Expected Behavior
Neovim should maintain normal CPU usage and not reach 100% consumption.
Repro