nwdm - 2023-03-05

Gnome will make this problem more common as they have switched to wayland by default now...

For others experiencing this problem, a workaround:

Set the environment variable GDK_BACKEND=x11

Either:
add this line to the top of your script:
GDK_BACKEND=x11
OR:
anywhere you would run "yad", run instead "GDK_BACKEND=x11 yad"