microsoft / vscode-pylint

Linting support for python using the pylint library.
https://marketplace.visualstudio.com/items?itemName=ms-python.pylint
MIT License
70 stars 34 forks source link

Autoformatting request is broken #536

Closed Kein closed 5 months ago

Kein commented 5 months ago

This exist but it does absolutely nothing: image image

I've went through all the extension outputs but there isnt even an indication action was dispatched. I've tried using external pylint as well

Pylint extension: 2023.11.13481007 Python interp: 3.9.0 Python extension: 2024.3.10791010

karthiknadig commented 5 months ago

@Kein You need to install Formatting extension, and set it as the default formatter. The command there does not know if such an extension is installed or not, it will just ask VS Code to use run a formatter.

Install black, autopep8, ruff, or which ever formatter extension you want to use. Add the following to your settings:

 "[python]": {
        "editor.defaultFormatter": "ms-python.black-formatter" // Use ruff or autopep8 extension ID here depending on which one you have installed.
    },