简体   繁体   中英

ModuleNotFoundError: No module named 'cryptography'

these are the Error messages I am geeting on running any of my project modules.

Traceback (most recent call last):
  File "C:\Users\hsnl\BlockchainCodesTutor\Wallet.py", line 3, in <module>
    import Transactions
  File "C:\Users\hsnl\BlockchainCodesTutor\Transactions.py", line 2, in <module>
    import Signatures
  File "C:\Users\hsnl\BlockchainCodesTutor\Signatures.py", line 2, in <module>
    import cryptography
ModuleNotFoundError: No module named 'cryptography'

I have already installed the cryptography module and was working perfectly until today I start getting this message that " No module named 'cryptography'". I have again installed the cryptography as well as pip package but still showing the same error.

There might be loose versions running on your system. Please try the following:

python -m pip uninstall cryptography
python -m pip install cryptography

You can also check out this with python -m to make sure you are not using a loose pip.

You might not have cryptogtaphy installed correctly. I see you are using windows. Open commandline as an administrator and run pip install cryptography again. Enshure that the installation finishes without any errors and consider to restart your python interpreter after installation.

For further help you should post more details like the output of pip and your code leading to the error, so a more detailed answer for your problem can be given.

Try download cryptography whl from here .

Then use pip install cryptography-XXX.whl

For example:

pip install cryptography-3.3.1-cp36-abi3-win_amd64.whl

And now just supports python2.7 and python3.6.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM