pyls-mypy icon indicating copy to clipboard operation
pyls-mypy copied to clipboard

Using with emacs

Open oivvio opened this issue 5 years ago • 5 comments

This is not an actual issue. I'm just trying to get this plugin work with lsp-mode for emacs. I have mypy workon fine on the commandline and I have lsp-mode working fine in emacs.

When I add pyls-mypy to my virtualenv I get mypy messages in my buffers but it doesn't seem to be reading my mypy.ini

Any pointers on how to remedy that would be most welcome.

oivvio avatar Jan 03 '20 21:01 oivvio

This is sounds like my exact circumstance. I have tried setting flycheck-python-mypy-ini to point to a mypy config file and this doesn't seem to have any effect.

ksafford avatar Jan 22 '20 23:01 ksafford

(with-eval-after-load 'lsp-mode  ; try this or similar
    (lsp-register-custom-settings '(("pyls.plugins.pyls_mypy.enabled" t t))))

Also check *pyls::stderr* for complaints about a missing "future" package. Perhaps unrelated (maybe a regression of #1), but I had to install it manually before the plugin would load. mypy-list

poppyschmo avatar Feb 05 '20 10:02 poppyschmo

Same with LanguageClient-neovim:

WARNING - pyls.config.config - Failed to load pyls entry point 'pyls_mypy': No module named 'future'

akhilman avatar Mar 01 '20 23:03 akhilman

Just run pip install --user future

Davidbrcz avatar Sep 21 '20 08:09 Davidbrcz

Can confirm, fix by installing future helps. Seems that it was fixed here https://github.com/tomv564/pyls-mypy/pull/38, but it's not been published to pypi yet

karlicoss avatar Dec 05 '20 22:12 karlicoss