Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Latest xdotool version in Ubuntu 22 repos silently fails on Wayland 😭 apt can't upgrade it, and manual doesn't help #449

Open
willsheppard opened this issue Jan 17, 2024 · 2 comments

Comments

@willsheppard
Copy link

willsheppard commented Jan 17, 2024

I've read the previous issues about Wayland, but I think an issue still remains.

I'm using Ubuntu 22.04.3 LTS and I had never heard of (or forgotten about) Wayland.
When I searched for an automation tool, and installed and ran xdotool, it didn't work at all.
Some time later I realised it only works with X11, and I read the README online, and the previous discussions.

I found two ways to check for Wayland:

$ loginctl show-session 2 -p Type
Type=wayland
$ echo $XDG_SESSION_TYPE
wayland

I then edited /etc/gdm3/custom.conf to uncomment the line WaylandEnable=false, and rebooted.
Now xdotool works perfectly.

The problems remaining are

  1. man xdotool does not mention Wayland at all.
  2. xdotool silently fails on Wayland

I have not tested on XWayland.

Suggested changes:

  1. Copy the parts about Wayland from the README to the manual.
  2. Add a warning if running on Wayland.
  3. Alternatively, maybe some kind of message or pointer to docs with relevant Wayland info should appear when you type xdotool with no arguments, or xdotool help.

Am I correct in thinking there is zero functionality on Wayland?

I don't see the problem if warnings are "noisy" when running xdotool multiple times as someone mentioned. Wouldn't you want it to loudly fail if it doesn't work?

Related issues:

@willsheppard
Copy link
Author

willsheppard commented Jan 17, 2024

Forgot to mention I'm using version 3.20160805.1 which I got from apt install xdotool.

When I did apt upgrade and apt upgrade xdotool, I got:

sudo apt upgrade xdotool
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
xdotool is already the newest version (1:3.20160805.1-4).
...etc.

Can anything be done to get a more recent version into these repos?

@willsheppard willsheppard changed the title Silently fails on Wayland 😭 manual doesn't help Commonly available version of xdotool silently fails on Wayland 😭 apt doesn't upgrade it, and manual doesn't help Jan 17, 2024
@willsheppard
Copy link
Author

willsheppard commented Jan 17, 2024

I've now downloaded the 3.20211022.1 release. I'm glad to see a prominent warning about Wayland at the top of the README, but it's still missing from the man page. Someone wouldn't see the README if they're only running xdotool as an end-user.

Okay, now I've been able to run the latest version, it doesn't fail silently anymore 👍
I get Segmentation fault (core dumped) as output which is much better. However, there is still room for improvement. Instead of this error, it could simply output "Wayland is not supported", with a link to the README which already contains all the relevant info.

Note: xdotool --help still works fine with no error.

@willsheppard willsheppard changed the title Commonly available version of xdotool silently fails on Wayland 😭 apt doesn't upgrade it, and manual doesn't help Latest xdotool version in Ubuntu 22 repos silently fails on Wayland 😭 apt can't upgrade it, and manual doesn't help Jan 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant