feat(LSP): Override pretty flag for Mypy

As the `--pretty` flat for Mypy provides nicer output, the soft word
wrap it uses makes editors receive part of the message.  Hence the
setting has to be overridden inside editors (the flag is kept on
because invoking Mypy from terminal benefits from the extra output
information).
This commit is contained in:
Dionisio E Alonso 2024-02-25 23:00:39 -03:00
parent 1493b3ceb5
commit 41115cdd19
2 changed files with 2 additions and 2 deletions

View File

@ -20,7 +20,7 @@
:flake8 (:enabled t)
:pylint (:enabled t
:executable "pylint")
:pylsp_mypy (:enabled t)
:pylsp_mypy (:overrides [t "--no-pretty"])
:pycodestyle (:enabled :json-false)
:pyflakes (:enabled :json-false)))))
(when window-system (set-frame-size (selected-frame) 85 60))

View File

@ -4,7 +4,7 @@ local pylsp_settings = {
ruff = { enabled = true }, -- Settings come from $XDG_CONFIG_HOME/ruff/ruff.toml
flake8 = { enabled = true },
pylint = { enabled = true },
pylsp_mypy = { enabled = true },
pylsp_mypy = { overrides = { true, "--no-pretty" } },
pycodestyle = { enabled = false }, -- covered in flake8
pyflakes = { enabled = false }, -- covered in flake8
},