ImportError: Cannot Import Name Md5
Solution 1:
I'm using macOS, fix this by brew unlink openssl && brew reinstall python@2
From comment, python@2
is no longer available. This may work brew unlink openssl && brew reinstall https://raw.githubusercontent.com/Homebrew/homebrew-core/86a44a0a552c673a05f11018459c9f5faae3becc/Formula/python@2.rb
Solution 2:
I personally use and would recommend pyenv to manage Python versions. At first I was not sure how to fix this, and tried to re-install using brew
as suggested here. However, I then recalled that I had used pyenv
to install and so I was able to fix my error with.
pyenv install -f 2.7.15
The -f
option forces the installation of that version even if it already exists on your system. You would need to use 2.7.16
or whatever version you would like it to use.
The python-build
that pyenv
uses will use the openssl
library from brew
if it's available.
Solution 3:
I got this error on Python 2.7.14
. Upgrading to 2.7.17
solved the issue for me.
Solution 4:
I'm using macOS and you can uninstall the python2 using brew uninstall python@2
After this you can install usin
brew install {username}/python2/python@2.7.17
Post a Comment for "ImportError: Cannot Import Name Md5"