-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
clear LSP clients #2
Comments
If an auto-session session is restored in the post-open hook, then an error may be throw related to that no LSP client is available. This is because the LSP clients takes a while to start. Related to #2
@rmagatti Do you have any thoughts on this. Could it be a potential bug in auto-session? Or am I missing a simple fix. I don't understand all the technical details of how sessions work. |
This is more because the autocmd for Also I thought lsp clients wouldn't keep running in the background if there is no buffer for them to attach to, but idk if that's accurate. |
That makes sense. |
I might be interested in clearing LSP clients, so that old LSP clients does not keep on running in the background after opening a new directory.
I have implemented the simplest fix on branch
clear-lsp-clients
, but it seems to give session-related problems (see b58b760)More specifically regarding auto-session if I stop all LSP clients and then restores a session that was saved while an LSP client was active I get an error.
I have the following setup of opener.nvim, which means that LSP clients are stopped and they immediatly after
RestoreSession
is called.This is of course due to no LSP client being active at the time of restoring, but is that really necessary to restore a session?
The text was updated successfully, but these errors were encountered: