Support for Wayland
Author: k4j8Created Nov 27, 2016Updated Jan 7, 2026
A series of errors occurred while trying to import the pyautogui module, but only while using Wayland.
>>> import pyautogui
Traceback (most recent call last):
File "/home/k4j8/Python/env/lib/python3.5/site-packages/Xlib/xauth.py", line 43, in __init__
raw = open(filename, 'rb').read()
FileNotFoundError: [Errno 2] No such file or directory: '/home/k4j8/.Xauthority'Can Wayland be supported? Or is Wayland so vastly different from X11 that a whole new module is needed? If it's the latter, I'd like to modify the README to include X11 in the dependencies and then close this issue.
Thanks for creating this awesome module! (And pyperclip too!)
Source: asweigart/pyautogui