Skip to content Skip to sidebar Skip to footer

Pyopenssl Version 0.13.1 After Pip Upgrade

I am on Mac El Capitan. My system shows me stuck on PyOpenSSl version 0.13.1. When I upgrade to 16.2.0, the upgrade is successful. However, when I check the version, it's still on

Solution 1:

The core of the problem is that sudo pip install pyopenssl --user --upgrade was installing into a directory where the "non-sudo" pip ... did not look first. There are many reasons why that might happen.

The first aspect to simplify this problem is understanding that pip install --user ... should never need to be run with sudo. The --user option means install into the user packages directory (it should be under /Users/your_username/ somewhere), and advanced privileges are not needed for that.

If you try pip install --user --upgrade pyopenssl without sudo, it should solve the problem.

The old pyopenssl-0.13.1 will still exist in /System/Library/Frameworks/Python.framework/Versions/2.7/... , however the new one should now exist in /Users/your_username/... and should be found first by the Python import machinery.

However, there is a reasonable chance that pip install --user is installing the new version of pyopenssl in a directory where the Python import machinery doesnt look. To fix this, you need to know where pip is installing the package. Try using pip install --user --verbose .. if the default pip output it doesnt tell you were the package is being installed. Then you need to add this path to PYTHONPATH, such as the following with ... replaced with where pip installed the package (it should be under /Users/your_username/ somewhere).

export PYTHONPATH="/Users/your_username/Library/...:$PYTHONPATH"
pip show pyopenssl

If that works, add the above export .. to your bash .profile so that your Python runtime is always loading packages from that directory first.

Post a Comment for "Pyopenssl Version 0.13.1 After Pip Upgrade"