folke / noice.nvim

💥 Highly experimental plugin that completely replaces the UI for messages, cmdline and the popupmenu.
Apache License 2.0
4.36k stars 101 forks source link

Noice is currently broken on Nightly (fixed) #298

Closed folke closed 1 year ago

folke commented 1 year ago

The big tui rework has been merged, which is really cool and will eventually make Noice work even better.

However, at this moment, Noice is unstable on nightly.

Last commit that works with noice is https://github.com/neovim/neovim/commit/99cf111289bfcd14981255e805da43bac5139141

Issues

dbalatero commented 1 year ago

I've been meaning to check out noice but I'm also on nightly. Would you mind updating this issue/thread once everything's stabilized? Thanks!

folke commented 1 year ago

I will. For now it's just waiting till the linked issue is fixed

crivotz commented 1 year ago

I have the same problem as the linked issue by doing =G or gg=G or =% only in normal. I will stay on the stable for now, thanks for the work

kierun commented 1 year ago

Everyone here probably knows this… However, for anyone using bob: bob use 99cf111 will get you the last bleeding-edge version of Neovim before the bug.

folke commented 1 year ago

I just pushed an update after which, Noice should no longer crash Neovim.

The change however is that the router now no longer updates messages during blocking events for ext_messages.

What that means is that in some casesm during blocking events we force redraw the ui to make sure you see the message immediately.

This is now no longer the case.

The only kind where I can think that this leads to issues is with confirm messages and specifically the ones about a swap file.

To work around this, when receiving a confirm message from Neovim, I temporarly disable Noice and enable it again after the confirm has been handled by Neovim.

So now at least you will see the confirm message. However, for swap files for example, Neovim also prints an "attention" messages before showing the confirm dialog. Unfortunately it's impossible to show that message now at the correct time, so you'll only see it after handling the confirm.

If anyone would still experience segfaults, please let me know in a comment.

przepompownia commented 1 year ago

No crash with the initial example from https://github.com/neovim/neovim/issues/21604 (after update by Lazy) and in my regular environment :tada:

surmish commented 1 year ago

Should LazyVim change to make version false for noice?

folke commented 1 year ago

@surmish I just released a new version, so you can just update LazyVim

folke commented 1 year ago

With the recent changes I no longer experience segfaults, but some functionality is severely impaired right now...

Biggest issues right now (that are unfortunately not fixable from within Noice):

It's is highly advisable to use something like dressing.nvim, which at least fixes all the issues related to vim.ui (used by lsp code actions etc)

folke commented 1 year ago

Together with @bfredl, we've been able to come up with a work-around for the Neovim crashes with Noice, so everything should pretty much work the same as it did before the TUI rework. You can ignore my comments above about impaired functionality. Everything should work again with a recent nightly.

If you would still experience crashes, please let me know in the comments.

image

folke commented 1 year ago

Are there any other macos users that still experience segfaults? I'm running Linux and didn't have any segfault anymore since my fix.

See also:

max397574 commented 1 year ago

I didn't experience any

przepompownia commented 1 year ago

I still don't have regular crashes as such from https://github.com/neovim/neovim/issues/21604

folke commented 1 year ago

@przepompownia you do have crashes or you don't? :)

przepompownia commented 1 year ago

Restricting the scope to described in the above Neovim bug I don't (we can stick to this scope here ;)) :)

In last days i got some crash after enter some input but I'm not sure if it was related to Noice or UI separation and I cannot reproduce it.

camin-mccluskey commented 10 months ago

@folke MacOS user here. Started to notice crashes in the last week or so. I assumed I was hitting some weird "quit all" keycombo (I'm fairly new to LazyVim). Dug in a bit today and realised they are SegV of the type mentioned here.