Skip to content

Plugins: drain queued X11 editor events - #90

Merged
emaspa merged 1 commit into
mainfrom
fix/editor-event-queue
Sep 12, 2026
Merged

Plugins: drain queued X11 editor events#90
emaspa merged 1 commit into
mainfrom
fix/editor-event-queue

Conversation

@emaspa

@emaspa emaspa commented Sep 12, 2026

Copy link
Copy Markdown
Owner

Changes

Fixes the native-editor failure in the post-merge CI run for #89, https://github.com/emaspa/openxlr/actions/runs/34685246897. The failure was pre-existing and unrelated to the startup-options changes.

Xlib can consume socket events while waiting for a reply and retain them in its own queue. A PipeWire source watching socket readability then has nothing to wake on. Drain that queue after opening the editor and after guarded callbacks, with bounded follow-up passes after each event pump.

The test also keeps one X connection open throughout its run. This prevents Xvfb resetting between the editor's close and reopen checks.

Verification

  • Unmodified main failed 3 of 40 normal Xvfb runs and 20 of 20 single-core runs.
  • Fixed version passed 60 normal runs and 50 single-core runs.
  • Clean native build with warnings treated as errors passed.
  • Audio and CLAP tests passed all 16 cases.
  • Editor tests passed all 10 cases, also checked independently with normal scheduling and taskset -c 0.

No version or release changes. Plugin-folder management is separate from this patch.

Xlib round trips can move editor events off the socket and leave them in its private queue, so a socket-only event source no longer wakes. Drain those events after guarded callbacks and opening the editor, with bounded follow-up passes.

Keep one X connection alive throughout the editor test so Xvfb cannot reset between close and reopen checks.
@emaspa
emaspa merged commit f145dd1 into main Sep 12, 2026
4 checks passed
@emaspa
emaspa deleted the fix/editor-event-queue branch September 12, 2026 09:58
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

Successfully merging this pull request may close these issues.

1 participant