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

Solargraph is correctly diagnosing rubocop errors; however, it is "fixing" them incorrectly (formatting) #406

Closed
thornomad opened this issue Jan 18, 2021 · 6 comments

Comments

@thornomad
Copy link

Hello — I use solargraph with coc-nvim and coc-solargraph. I originally opened the issue at coc-solargraph there but it was suggested the issue may with the solagraph language server itself.

Problem

When applying auto-correct formatting to a file, solargraph is not sourcing my project folder's.rubocop.yml file (it does use my $HOME/.rubocop.yml setting).

This only is an issue with solargraph applying rubocop formatting autocorrect; it does source the correct file when displaying linting errors in vim.

Work around

If I copy the .rubocop.yml file from my project directory into my $HOME directory, this fixes the problem. But my rubocop settings for auto-correct are no longer project based and my projects have different settings. Gack.

Do you think this is an issue with the solargraph Gem itself ? I am not sure how to test the language server without relying on the coc-nvim implementation but would be willing to with instruction. More details and some debug logs are at the original issue

Thanks in advance for any help.

@KevinBerthier
Copy link

Same issue since version 0.40.1 for me on VSCode with vscode-solargraph

@castwide
Copy link
Owner

This is a known issue that will be resolved in 0.41.0. See #403

@castwide
Copy link
Owner

castwide commented Feb 7, 2021

Fix released in v0.40.3.

@casret
Copy link

casret commented Apr 20, 2021

I'm seeing this in v0.40.4

@ThomasF34
Copy link

Same here ! I have the issue while using v0.40.4

@mario-amazing
Copy link

Same in 0.45.0

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

No branches or pull requests

6 participants