-
-
Notifications
You must be signed in to change notification settings - Fork 890
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
Random regressions due to lsp overriding user settings via lsp-register-custom-settings
#4420
Open
3 tasks done
Labels
Comments
Hi-Angel
added a commit
to Hi-Angel/lsp-mode
that referenced
this issue
Apr 8, 2024
If a user has set a setting inside `lsp-client-settings`, changing its value will result in a silent bug in user configuration, that looks like a regression from `lsp-mode` mode update. Let's avoid that by adding a new function `lsp-register-new-settings` that avoids overwritting whatever was set by user and make use of it treewide. While at it, prohibit `lsp-register-custom-settings` from internal use for all the same reasons. Fixes: emacs-lsp#4420
Should be fixed by #4421 |
Hi-Angel
added a commit
to Hi-Angel/lsp-mode
that referenced
this issue
Apr 8, 2024
If a user has set a setting inside `lsp-client-settings`, changing its value will result in a silent bug in user configuration, that looks like a regression from `lsp-mode` mode update. Let's avoid that by adding a new function `lsp-register-new-settings` that avoids overwritting whatever was set by user and make use of it treewide. While at it, prohibit `lsp-register-custom-settings` from internal use for all the same reasons. Fixes: emacs-lsp#4420
Hi-Angel
added a commit
to Hi-Angel/lsp-mode
that referenced
this issue
Apr 8, 2024
If a user has set a setting inside `lsp-client-settings`, changing its value will result in a silent bug in user configuration that looks like a regression from `lsp-mode` mode update. Let's avoid that by adding a new function `lsp-register-new-settings` that avoids overwritting whatever was set by user and make use of it treewide. While at it, prohibit `lsp-register-custom-settings` from internal use for all the same reasons. Fixes: emacs-lsp#4420
Hi-Angel
added a commit
to Hi-Angel/lsp-mode
that referenced
this issue
Apr 8, 2024
If a user has set a setting inside `lsp-client-settings`, changing its value will result in a silent bug in user configuration that looks like a regression from `lsp-mode` mode update. Let's avoid that by adding a new function `lsp-register-new-settings` that avoids overwritting whatever was set by user and make use of it treewide. While at it, prohibit `lsp-register-custom-settings` from internal use for all the same reasons. Fixes: emacs-lsp#4420
Hi-Angel
added a commit
to Hi-Angel/lsp-mode
that referenced
this issue
Apr 8, 2024
If a user has set a setting inside `lsp-client-settings`, changing its value will result in a silent bug in user configuration that looks like a regression from `lsp-mode` mode update. Let's avoid that by adding a new function `lsp-register-new-settings` that avoids overwritting whatever was set by user and make use of it treewide. While at it, prohibit `lsp-register-custom-settings` from internal use for all the same reasons. Fixes: emacs-lsp#4420
Hi-Angel
added a commit
to Hi-Angel/lsp-mode
that referenced
this issue
Apr 8, 2024
If a user has set a setting inside `lsp-client-settings`, changing its value will result in a silent bug in user configuration that looks like a regression from `lsp-mode` mode update. Let's avoid that by adding a new function `lsp-register-new-settings` that avoids overwritting whatever was set by user and make use of it treewide. While at it, prohibit `lsp-register-custom-settings` from internal use for all the same reasons. Fixes: emacs-lsp#4420
Hi-Angel
added a commit
to Hi-Angel/lsp-mode
that referenced
this issue
Apr 8, 2024
If a user has set a setting inside `lsp-client-settings`, changing its value will result in a silent bug in user configuration that looks like a regression from `lsp-mode` mode update. Let's avoid that by adding a new function `lsp-register-new-settings` that avoids overwritting whatever was set by user and make use of it treewide. While at it, prohibit `lsp-register-custom-settings` from internal use for all the same reasons. Fixes: emacs-lsp#4420
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Thank you for the bug report
lsp-mode
related packages.M-x lsp-start-plain
Bug description
Commit 782e1dc by @LaurenceWarne introduced a regression and broke mypy completely for me. That happened, because I had set the same lsp-server settings that the commit modified.
Further research shown that there's nothing wrong with the commit per se, instead the problem is in how
lsp-mode
handles lsp-server settings. Whatever user sets withlsp-register-custom-settings
is being overwritten bylsp-mode
, leading to random problems like this one.Instead
lsp-register-custom-settings
should not overwrite settings that a user has set.Steps to reproduce
/tmp/.emacs
with the following content:emacs -Q -l /tmp/.emacs test.py
lsp-mode
in thetest.py
buffer by evaluating M-x lsppylsp_mypy
and look at the value ofenabled
just below thepylsp_mypy
lineExpected behavior
It is
true
.Which Language Server did you use?
pylsp
OS
Linux
Error callstack
No response
Anything else?
No response
The text was updated successfully, but these errors were encountered: