Navigation Menu

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

Wayland: Focusing a window requires user interaction #157

Closed
bearcatsandor opened this issue Oct 25, 2017 · 9 comments
Closed

Wayland: Focusing a window requires user interaction #157

bearcatsandor opened this issue Oct 25, 2017 · 9 comments

Comments

@bearcatsandor
Copy link

[glfw error 65544]: Wayland: Focusing a window requires user interaction
Traceback (most recent call last):
File "/usr/lib64/python3.6/runpy.py", line 193, in _run_module_as_main
"main", mod_spec)
File "/usr/lib64/python3.6/runpy.py", line 85, in _run_code
exec(code, run_globals)
File "./main.py", line 13, in
main()
File "./kitty/main.py", line 292, in main
run_app(opts, args)
File "./kitty/main.py", line 202, in run_app
initialize_window(window, opts)
File "./kitty/main.py", line 161, in initialize_window
glewInit()
RuntimeError: GLEW init failed: [4] Unknown error
[glfw error 65537]: The GLFW library is not initialized

Am i missing a library here or is this not operable on Wayland yet?

Thanks

@kovidgoyal
Copy link
Owner

You need to compile glew with the EGL backend. By default it is compiled with the GLX backend.

@kovidgoyal
Copy link
Owner

And you will also need to compile glfw from master as the released version of glfw has a bug that causes duplicated key presses under wayland.

@kovidgoyal
Copy link
Owner

For people that might find this bug report, you compile glew with EGL using

make SYSTEM=linux-egl

Since wayland is pretty new it's likely your distro does not have a precompiled version of glew built this way.

For example, in Arch:
https://bugs.archlinux.org/task/56025

@dryya
Copy link

dryya commented May 16, 2018

This error still occurs for me using the glew-wayland package from arch, which does set SYSTEM=linux-egl (see the PKGBUILD). I'm also using glfw-wayland-git to build from master.

I get

GL version string: '4.5 (Core Profile) Mesa 18.0.3' Detected version: 4.5
wl_surface@13: error 3: xdg_surface must not have a buffer at creation
[135 23:29:00.699834] [glfw error 65544]: Wayland: Focusing a window requires user interaction
[135 23:29:00.699870] [glfw error 65544]: Wayland: Window position retrieval not supported

@kovidgoyal
Copy link
Owner

The information in this bug report is obsolete. kitty now has its own bundled glfw and you dont need to compile it separately. To run kitty under wayland you do

KITTY_ENABLE_WAYLAND=1 kitty

also make sure that the WAYLAND_DISPLAY env var is set. As for your actual error, it is likely caused by an obsolete wayland compositor. I can tell you that kitty runs fine under weston 4.0.0

@dryya
Copy link

dryya commented May 16, 2018

That's the command I was running that gave that output. Wayland display is set to "wayland-0". I'm running the latest version of the sway alpha. Will test in weston now.
Update: wayland-enabled kitty works on weston. I'll file a bug report over at sway. Thanks for the help!

@emersion
Copy link

This is not a wlroots bug. From the debug log in this comment, you're creating a xdg_surface with a wl_surface which already has a buffer attached, this is forbidden by the protocol.

@kovidgoyal
Copy link
Owner

@Aenda Feel free to pass it on to the glfw project, there is no wayland specific code in kitty itself.

@ignisf
Copy link

ignisf commented Dec 25, 2018

FYI glfw/glfw#1121

[Wayland: Focusing a window requires user interaction] will never be fixed, a client is not allowed to steal focus from another, this behaviour is extremely bad for most users, and can be catastrophic when e.g. they are typing a password or other sensitive information.

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

5 participants