DistutilsOptionError: must supply either home or prefix/exec-prefix — not both

前端 未结 8 2093
旧时难觅i
旧时难觅i 2020-11-28 01:03

I\'ve been usually installed python packages through pip.

For Google App Engine, I need to install packages to another target directory.

I\'ve tried:

8条回答
  •  情话喂你
    2020-11-28 01:37

    I hit errors with the other recommendations around --install-option="--prefix=lib". The only thing I found that worked is using PYTHONUSERBASE as described here.

    export PYTHONUSERBASE=lib
    pip install -I flask-restful --user
    

    this is not exactly the same as --target, but it does the trick for me in any case.

提交回复
热议问题