Python on MacOS “dyld: Library not loaded” - error

后端 未结 2 2070
-上瘾入骨i
-上瘾入骨i 2021-01-19 07:52

I am trying to run a python script that executes few API calls and Kafka logic but getting following error:
dyld: Library not loaded: @executable_path/../.Python

相关标签:
2条回答
  • 2021-01-19 08:08

    The issue is related to hombrew Python installs/upgrade.

    Anyone who is using pipenv (and you should!) can simply use these two commands — without having the venv activated:

    rm -rf `pipenv --venv` # remove the broken venv
    pipenv install --dev   # reinstall the venv from pipfile 
    
    0 讨论(0)
  • 2021-01-19 08:16

    Hi I got this issue too after brew upgrade, I solved with delete virtualenv

    find myvirtualenv -type l -delete
    

    then recreate virtualenv

    virtualenv myvirtualenv
    

    Reference:

    http://www.jeremycade.com/python/osx/homebrew/2015/03/02/fixing-virtualenv-after-a-python-upgrade/

    0 讨论(0)
提交回复
热议问题