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

Disable linting #37

Closed
mlucool opened this issue Jun 2, 2021 · 4 comments
Closed

Disable linting #37

mlucool opened this issue Jun 2, 2021 · 4 comments

Comments

@mlucool
Copy link

mlucool commented Jun 2, 2021

Hi,

Is it possible to use this language server and opt out of all linting?

Thanks!

@krassowski
Copy link
Contributor

krassowski commented Jun 2, 2021

You can disable specific plugins:

  • pylsp.plugins.pycodestyle.enabled
  • pylsp.plugins.pydocstyle.enabled
  • pylsp.plugins.pyflakes.enabled
  • pylsp.plugins.pylint.enabled
  • pylsp.plugins.mccabe.enabled

@mlucool
Copy link
Author

mlucool commented Jun 2, 2021

Maybe I'm doing it wrong?

User settings:

{
    pylsp: {
      serverSettings: {
        "pylsp.plugins.pycodestyle.enabled": false,
        "pylsp.plugins.pydocstyle.enabled": false,
        "pylsp.plugins.pyflakes.enabled": false,
        "pylsp.plugins.pylint.enabled": false,
        "pyls.plugins.mccabe.enabled": false,
      }
    }
}

image

@krassowski
Copy link
Contributor

Yes, you are missing "language_servers" top level key. It should be:

{
    "language_servers": {
        "pylsp": {
            "serverSettings": {
                "pylsp.plugins.pycodestyle.enabled": false,
                "pylsp.plugins.pydocstyle.enabled": false,
                "pylsp.plugins.pyflakes.enabled": false,
                "pylsp.plugins.pylint.enabled": false,
                "pylsp.plugins.mccabe.enabled": false,
            }
        }
    }
}

It seems human brains just don't parse the example on the left correctly, see https://github.com/krassowski/jupyterlab-lsp/pull/418 - please leave a comment there on how to improve it after reading the discussion.

Also, for jupyterlab-lsp specifically you could use https://github.com/krassowski/jupyterlab-lsp/issues/585#issuecomment-830661871

@mlucool
Copy link
Author

mlucool commented Jun 2, 2021

These both work - thanks!

I commented on krassowski/jupyterlab-lsp#418.

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

2 participants