Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/python/286.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Python 属性错误:模块';pyautogui';没有属性';getWindowsWithTitle';_Python_Macos_Pyautogui - Fatal编程技术网

Python 属性错误:模块';pyautogui';没有属性';getWindowsWithTitle';

Python 属性错误:模块';pyautogui';没有属性';getWindowsWithTitle';,python,macos,pyautogui,Python,Macos,Pyautogui,我正在编写一个与浏览器交互的机器人(不要说服我重写Selenium或Keyboard等),它给了我一个错误。附近没有名为pyautogui的文件,我尝试将其命名为main和pythonv3.8、3.9。在任何情况下都会收到此错误。马科斯 /Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/rubicon/objc/ctypes_patch.py:21: UserWarning: rubicon

我正在编写一个与浏览器交互的机器人(不要说服我重写Selenium或Keyboard等),它给了我一个错误。附近没有名为pyautogui的文件,我尝试将其命名为main和pythonv3.8、3.9。在任何情况下都会收到此错误。马科斯

/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/rubicon/objc/ctypes_patch.py:21: UserWarning: rubicon.objc.ctypes_patch has only been tested with Python 3.4 through 3.8. You are using Python 3.9.4. Most likely things will work properly, but you may experience crashes if Python's internals have changed significantly.
  warnings.warn(
Traceback (most recent call last):
  File "/Users/alina/PycharmProjects/ABOBA/main_miner_alienworlds.py", line 183, in <module>
    for i in pyautogui.getWindowsWithTitle('##### #######'):
AttributeError: module 'pyautogui' has no attribute 'getWindowsWithTitle'

pyautogui与pip3一起安装

您使用了错误的模块


包含getWindowsWithTitle的模块是否引发此导入错误:无法从“pygetwindow”导入名称“getWindowsWithTitle”(/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/site packages/pygetwindow/_uinit.py)
import pyautogui

…
for j in pyautogui.getWindowsWithTitle('##### #######'):
    do something