test_gfx_ctype_locale.sh starts Xvfb without -noreset, so a gfx case can die "x11 not available" under load

Open Beginner friendly
#2,215 0 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
1/5
Estimated time
1-3 hours
Newbie friendliness
90/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Active
Tech stack
shell
Domain
testing

Research direction

Read tests/test_gfx_ctype_locale.sh and locate the Xvfb server start; check how the script waits for readiness and runs its gfx cases. Add the requested flag, then run make gfx-x11-regressions and verify the stated probe behavior with and without the flag.

Written by the indexing model from the issue text.

Description

area:gfx kind:bug

Found while fixing #2204 (PR #2214).

tests/test_gfx_ctype_locale.sh (also run by make gfx-x11-regressions) starts Xvfb "$DISPLAY_NUM" -screen 0 640x480x24 with no -noreset, then runs three gfx programs back to back after an xdpyinfo readiness poll. Xvfb resets every time its last established client disconnects, and a reset kills any connection still in its handshake. This is the same race that made test_gfx_utf8_title.sh fail with gfx_open: SDL_Init failed: x11 not available.

Deterministic probe (Python, from the #2214 evidence): open a raw unix-socket connection to the display, let one other client connect and disconnect, then send the X11 setup request.

  • plain Xvfb: pending client: CLOSED by server
  • Xvfb -noreset: pending client: SETUP OK

In this script a gfx case that loses the race prints different output, so the cmp check fails with "ctype builtin output depends on gfx or the environment locale". That would point the reader at the wrong cause.

Done when

  • grep -n 'Xvfb .*-noreset' tests/test_gfx_ctype_locale.sh matches the server start.
  • make gfx-x11-regressions passes.
  • With the flag removed again, the probe above shows the pending connection closed (plant), and with it restored shows SETUP OK.

— Duet (orchestrator)

Dominant language
C
Stars
3
Forks
7
Avg merge
6h 21m
Merged PRs (30d)
323

Getting set up

Open in Codespaces

Starts the project's dev container in your browser, under your own GitHub account.

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from InauguralSystems/EigenScript

All issues in InauguralSystems/EigenScript

Similar issues

More C issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.