MOOR security

Dieser Eintrag ist auf Englisch verfasst.

The test that finished but never ended

Entry 00356 of 768 tests pass

Tests timed out at random after they had already passed. The cause was Wine's background processes keeping an output pipe open, not a bug in my code.

What changed

The first full test run was a mess. The clear sample from entry 002, which rendered correctly, would "time out" at random. I fixed the test runner, ran the full suite of 768 tests, and committed the result as the baseline that every later run is compared against.

The interesting part

The sample had already finished, with correct output, and the runner was still waiting.

The runner read each test's output through a pipe until the pipe closed. But the first Wine process in a session starts Wine's background services: wineserver, services.exe, explorer.exe. Those services inherit its stdout and stderr and keep them open for as long as the Wine session lives. So the pipe never closes, and the runner waits forever for output that never comes.

The fix is simple once you see it. Write test output to a file and wait for the process to exit, not for the stream to close. Under the same parallel load that had hung the runner before, the sample then passed 10 of 10 runs. On a real timeout, the runner now also saves stack traces of the stuck process, so the next hang comes with evidence.

Numbers

SuitePassFailSkip
Clear sample100
vkd3d211654
vkd3d-proton34345198
Total56510202

That is 768 tests. Most of the failures need shaders, pipelines or draw calls, none of which exist yet.

One test is flaky: test_fence_rewind_dependent_wait failed 2 of 10 times. It needs fences that can go backwards (entry 002).

Tests by suite at the end of entry 003: 56 of 768 pass (data as CSV)
  • pass
  • fail
  • skip

suite · share of each row's total

  1. vkd3d-proton34 pass, 345 fail, 198 skip of 577
  2. vkd3d21 pass, 165 fail, 4 skip of 190
  3. samples1 pass, 0 fail, 0 skip of 1