0

I have a python repository, I'm using nvim as my ide and jedi-language-server for writing python files. I want to add a path like I can in my .vscode/settings.json -

{
    "python.analysis.extraPaths": [
        "./<path>"
    ]
}⏎

This allows the editor to access my dependencies, how do i set the same in nvim

I used :set path, but I still get where the issue is.

1 Answers1

0

You should probably be using g:jedi#added_sys_path = [...], which is documented here.

However I would also point out that in general with a good setup you should probably look into setting up your Python environments properly. In those cases, jedi-vim should always work properly. For your own libraries, pip install -e . might be interesting (to add them to the system path). For other software make sure you activate the correct virtualenv, which jedi-vim can then pick up.

Dave Halter
  • 15,556
  • 13
  • 76
  • 103
  • i installed jedi-ls using mason. ``` . ./init.lua ./plugin ./plugin/packer_compiled.lua ./lua ./lua/ethsign ./lua/ethsign/init.lua ./lua/ethsign/packer.lua ./lua/ethsign/set.lua ./lua/ethsign/remap.lua ./after ./after/plugin ./after/plugin/colors.lua ./after/plugin/telescope.lua ./after/plugin/lsp.lua ./after/plugin/fugitive.lua ./after/plugin/treesitter.lua ./after/plugin/harpoon.lua ./after/plugin/undotree.lua ``` this is my nvim folder Also, I'm using poetry to set environments, how do i set up the path for this env for jedi? – samarpan.d May 24 '23 at 06:51