Xpra: Ticket #1430: X11 crash during connection setup

I've seen this a few times - usually when there is already an active connection and we take over:

setting keymap: rules=evdev, model=pc105, layout=gb,us,gb
[xcb] Unknown request in queue while dequeuing
[xcb] Most likely this is a multi-threaded client and XInitThreads has not been called
[xcb] Aborting, sorry about that.
python: xcb_io.c:165: dequeue_pending_request: Assertion `!xcb_xlib_unknown_req_in_deq' failed.

It looks like we're either accessing the X11 code from the wrong thread or we're just not flushing something (xsync / xswallow).

It could be the cleanup code for the old connection doing an X11 call?

r14996 (backport in r14997) try to make the keyboard code safer using xsync. Maybe this will be enough?

Thu, 16 Feb 2017 07:38:36 GMT - Antoine Martin: status changed; resolution set

Haven't seen it since.

Thu, 02 Mar 2017 04:27:24 GMT - Antoine Martin:

Re-opened with more details here: ticket:1456#comment:5.

Fri, 03 Mar 2017 15:14:37 GMT - Antoine Martin: status changed; resolution deleted

Found the problem: we're querying the server x11 info from the wrong thread, fix incoming.

Fri, 03 Mar 2017 15:51:03 GMT - Antoine Martin:

Fixed in r15220, backport in r15221.

I still want to verify the connection cleanup codepath as this may get triggered from the IO threads in some cases?

Sat, 04 Mar 2017 05:51:45 GMT - Antoine Martin: status changed; resolution set

Verified the cleanup paths:

Sat, 23 Jan 2021 05:24:06 GMT - migration script:

this ticket has been moved to: https://github.com/Xpra-org/xpra/issues/1430