Import python package from local directory into interpreter

前端 未结 9 1857
野的像风
野的像风 2020-11-29 02:54

I\'m developing/testing a package in my local directory. I want to import it in the interpreter (v2.5), but sys.path does not include the current directory. Right now I type

9条回答
  •  暗喜
    暗喜 (楼主)
    2020-11-29 04:00

    Inside a package if there is setup.py, then better to install it

    pip install -e .
    

提交回复
热议问题