Replies: 1 comment 12 replies
-
Or it is better to use the absolute pdm path: For a global interpreter, you don't need |
Beta Was this translation helpful? Give feedback.
12 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Recently set up
pdm
s global interpreter. Initially I had trouble because I couldn't accesspdm
withsudo
needed to access some files. I got around this by prepending thissudo -E env "PATH=$PATH"
(via an alias) whenever I wanted to callpdm
with the global-g
flag. While it has worked great to be able to now add packages likepandas
viasudo -E env "PATH=$PATH" pdm add -g pandas
, I still face trouble when using the python interpreter that is linked to the global project.Namely, when I run
sudo -E env "PATH=$PATH" pdm run -g python
and within the python shell execute>>> import pandas
I get aModuleNotFoundError
. I am confused now as to why the packages installed on the global project were not found by the python interpreter linked to the global project? Any ideas?Beta Was this translation helpful? Give feedback.
All reactions