Open blasco opened 5 years ago
Try setting the python path in ~/projects/my_project/.vim/coc-settings.json
, also confirm you aren't overriding it globally in ~/.config/nvim/coc-settings.json
or ~/.vim/coc-settings.json
"python.pythonPath": "~/projects/my_project/test_venv/bin/python"
Now it appears when doing :CocCommand python.setInterpreter
, but gives the following error when choosing it:
I've tried all manner of tweaks (both general, and hacky project-specific) in vimrc and coc-settings. No amount of pointing at venv (pipenv) specific paths seems to help - I still see pylint errors about packages that can't be found.
I've tried all manner of tweaks (both general, and hacky project-specific) in vimrc and coc-settings. No amount of pointing at venv (pipenv) specific paths seems to help - I still see pylint errors about packages that can't be found.
In particular, these coc-settings.json
keys helped me fix my linting issues:
"python.pythonPath": "/path/to/my/virtualenv/bin/python"
"python.globalModuleInstallation": true
You should mess around more, because these settings actually do fix the issues for users.
I've created a venv in ~/projects/my_project/test_venv with:
cd ~/projects/my_project python -m venv test_venv
I've tried setting:
python.venvFolders: ["/home/username/projects/my_project/test_venv"], python.venvPath: ["/home/username/projects/my_project/test_venv"],
in my cocconfig. But when I run the coccommand python.setIntepreter, the venv doesn't appear in the list. How is this supposed to work? Thank you in advance for the advice