“ssl module in Python is not available” when installing package with pip3

后端 未结 28 1741
别跟我提以往
别跟我提以往 2020-11-22 08:51

I\'ve install Python 3.4 and Python 3.6 on my local machine successfully, but am unable to install packages with pip3.

When I execute pip3 install

28条回答
  •  滥情空心
    2020-11-22 09:19

    Agree with the answer by mastaBlasta. Worked for me. I encountered the same problem as the topic description.

    Environment: MacOS Sierra. And I use Homebrew.

    My solution:

    1. Reinstall openssl by brew uninstall openssl; brew install openssl
    2. According to the hints given by Homebrew, do the following:

      echo 'export PATH="/usr/local/opt/openssl/bin:$PATH"' >> ~/.bash_profile
      export LDFLAGS="-L/usr/local/opt/openssl/lib"
      export CPPFLAGS="-I/usr/local/opt/openssl/include"
      

提交回复
热议问题