Skip to content
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

Set globalSettings instead of "workspace" settings #19

Merged
merged 2 commits into from
May 2, 2023

Conversation

rchl
Copy link
Member

@rchl rchl commented May 2, 2023

Looks like we should not be setting default options explicitly as then those will override globalSettings. See rust-lsp code here: https://github.com/charliermarsh/ruff-lsp/blob/8474ad1092843ffbf4e6d4d3f030588ab902a060/ruff_lsp/server.py#L724-L730

Fixes issue mentioned in #18

@rchl rchl requested a review from LDAP May 2, 2023 16:33
@rchl rchl mentioned this pull request May 2, 2023
@LDAP
Copy link
Collaborator

LDAP commented May 2, 2023

Should we set global settings instead?

@rchl
Copy link
Member Author

rchl commented May 2, 2023

I've looked at the source and it appears that this should be fine.

Comment on lines +22 to +28
"enum": [
"error",
"warn",
"info",
"debug",
"off"
],
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't know if this option really has any effect but whatever.

Copy link
Collaborator

@LDAP LDAP left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@rchl rchl changed the title Allow globalSettings to override "workspace" settings Set globalSettings instead of "workspace" settings May 2, 2023
@rchl rchl merged commit c964491 into main May 2, 2023
@rchl rchl deleted the fix/default-settings branch May 2, 2023 20:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants