解決方案是:
第壹步:上網查資料。妳需要安裝python的pycrypto庫。
(1)要查詢安裝庫,需要先安裝pip?
(2) pip安裝聲明:
安裝pip:建議安裝Homebrew,然後brew安裝python。
Get home-brew:命令行執行:/usr/bin/ruby-e " $(curl-fssl/home brew/install/master/install)"
命令行繼續:brew install wget
此時再次檢查pip,它已經成功安裝。
步驟2:用pip安裝庫
(1)用法聲明:pip 3 install git+/rncryptor/rncryptor-python . git # egg = rncryptor
(2)開始升級pip版本,執行pip3 install pymysql。如果還是有錯誤,需要執行:PIP3install-Upgrade PIP。
步驟3:用pip安裝pycrypto庫。
(1)執行安裝語句:pip 3 install git+/rncryptor/rncryptor-python . git # egg = rncryptor。
(2)根據提示日誌,庫已經安裝,命令行執行:pip3 install Crypto,或提示上述錯誤,繼續執行:pip3 install pycrypto或提示上述錯誤。直接執行卸載語句:pip3卸載pycrypto,表示卸載成功,再次執行:pip3安裝pycrypto表示安裝成功,然後重啟pycharm運行項目。