1.“PyAutoGUI was unable to import pyscreeze. (This is likely because you’re running a version of Python that Pillow (which pyscreeze depends on) doesn’t support currently.) Please install this module to enable the function you tried to call.”
pyautogui.PyAutoGUIException: PyAutoGUI was unable to import pyscreeze. (This is likely because you’re running a version of Python that Pillow (which pyscreeze depends on) doesn’t support currently.) Please install this module to enable the function you tried to call.
解決方案:
pip install pyscreeze
下載依賴包,解決.
2.由於我使用的是idea的python插件,在第一次創建python項目時沒有選擇自己的python安裝路徑,於是idea自動在F盤給我創建了一個python的運行環境,然而我在命令行使用的python命令和下載的包都在D盤..... 最后通過更改運行環境解決了問題:
File➡project Structure➡SDKs
選擇自己的python目錄下的python.exe
然后重啟重新加載運行環境即可