1

I am using the CoC extension in Neovim. When I import some python modules I have installed, pylint shows an error, as if they were not installed, even though they are. I know this because the file executes correctly (and I installed them previously). After doing :CocCommand workspace.showOutput Pyright, I get the path of the version of python being used, and of course it is not the one I want. But I don't know how to change it.

gxp2
  • 149
  • 2
  • 11

1 Answers1

1

Two ways:

  1. activate the correct Python used in your project, make sure which python points to the correct path, launch nvim
  2. set the path in coc-settings.json by python.pythonPath, default is python that use from $PATH.
fannheyward
  • 18,599
  • 12
  • 71
  • 109