asweigart / pyautogui

A cross-platform GUI automation Python module for human beings. Used to programmatically control the mouse & keyboard.
BSD 3-Clause "New" or "Revised" License
10.22k stars 1.24k forks source link

PyAutoGUI usage with default Gnome Wayland (Not the Gnome with Xorg) #740

Closed VictorGimenez closed 1 year ago

VictorGimenez commented 1 year ago

Hello there,

I am working on a project where is being developed a new Linux distro, nowadays, we are doing functional tests (by hand) and I started to write test scripts (in Python and shell script) two weeks ago to automatize tests from resources included in this distro as interface tests and terminal tests. When I was using PyAutoGUI for the first time I remember that when I was executing a function to click on a certain button with locate functions I was facing an error where it was said that there is a NoneType instead of the coordinates from the image returned, and when I was looking for on StackOverflow a tip to solve it, I remember that there is one member that suggested to activate Gnome with Xorg to the screenshot functions work. Yesterday, I talked with my project manager and he didn't agree to use Gnome with Xorg because it would impact our original test environment. Is there any possibility to execute PyAutoGUI in default Gnome also, or any chance to adapt it to wayland?