How to let AREPL detect libraries installed with PDM #419
-
pdm installs libraries into the local project directory How to setup so that AREPL can detect the libraries? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
Oh god there's another python package management tool? 😱 Python really needs to settle on one of them. Anyways, unfortunately AREPL doesn't have a setting to recognize the import sys
import os
sys.path.insert(0,os.path.abspath('__pypackages__\\3.8-32\\lib')) Replace You can test if it works like so: import sys
import os
sys.path.insert(0,os.path.abspath('__pypackages__\\3.8-32\\lib'))
import <yourLibrary>
print(<yourLibrary>.__version__) # the version number should match the one installed in pdm If you want to you can dive into the AREPL code itself (do For example, I added |
Beta Was this translation helpful? Give feedback.
Oh god there's another python package management tool? 😱 Python really needs to settle on one of them.
Anyways, unfortunately AREPL doesn't have a setting to recognize the
__pypackage__
folder automatically. You can manually specify it with the following code:Replace
3.8-32
with your python version. If you're on a mac/linux OS use/
instead of\\
You can test if it works like so:
If you want to you can d…