ImportError: No module named Crypto.Cipher

前端 未结 25 1397
后悔当初
后悔当初 2020-11-28 04:08

When I try to run app.py (Python 3.3, PyCrypto 2.6) my virtualenv keeps returning the error listed above. My import statement is just from Crypto.Cipher import AES

25条回答
  •  天涯浪人
    2020-11-28 05:00

    For Windows 7:

    I got through this error "Module error Crypo.Cipher import AES"

    To install Pycrypto in Windows,

    Try this in Command Prompt,

    Set path=C:\Python27\Scripts (i.e path where easy_install is located)

    Then execute the following,

    easy_install pycrypto

    For Ubuntu:

    Try this,

    Download Pycrypto from "https://pypi.python.org/pypi/pycrypto"

    Then change your current path to downloaded path using your terminal:

    Eg: root@xyz-virtual-machine:~/pycrypto-2.6.1#

    Then execute the following using the terminal:

    python setup.py install

    It's worked for me. Hope works for all..

提交回复
热议问题