Nox native startup failure diagnostics, 2026-11-09

The generated native consumer now writes native-startup-failure.json before terminal cleanup when port-file discovery or WebSocket startup fails. The snapshot records monotonic elapsed time since spawn, the unchanged 100 polls at 100 ms (10,000 ms polling bound), completed polls, child PID/exit code/signal, an observational kill(pid, 0) result, port-file existence and original read observations, and an 8 KiB tail of existing Chrome stderr. The port text in the snapshot is capped at 1,024 characters. These are observations at failure, not an atomic process/filesystem snapshot or a second readiness source.

tools/nox-current-driver.cjs composes this into the actual retained 20261108-nox-native-equipment/browser-run.cjs, which remains unchanged. The original exception is rethrown, preserving its stack, code, cause and the existing first terminal failure handler. Diagnostic-write errors are contained. No retry, extra poll, stderr endpoint admission, timeout extension, ownership/identity/input change, or deadline change was added.

The 1900 run's actual generated consumer has SHA-256 b348e09df4f7f7ac42bfe9d44f13cc09299fdb93c843e296cdb9de7a727a5bb0. Its manifest, generated bytes and source recovery patch were checked. Its composer recovers exactly from Git f68f79a28a888f47800d1de5276249421b7d494f, matching the manifest's ce2cbb0e5b188225a37f3e714e2bc6aa88f003ef04e08a64d09e071e60b7edd8. The retained startup line polls 100 times at 100 ms and then reads DevToolsActivePort. That read failed with ENOENT at 19:02:56.284 UTC.

This proves missing port-file readiness at the end of polling, before Nox selection. It does not establish the cause of the delay. Retained stderr contains DBus errors and a DevTools listening line, but the listening line has no timestamp and final stderr is not a failure-time snapshot. It cannot prove an available endpoint at admission or that DBus caused the failure. The recorded Chrome exit was SIGKILL at 19:03:10.923; the native parent returned 1 with stdout/stderr EOF, and kernel custody completed with 128 reaps and no remaining/unreaped tasks. These describe cleanup, not the startup root cause. The new diagnostic supplies the missing failure-time observations for a separately authorized future attempt.

Offline validation executes the actual freshly generated consumer with real Node child processes and the existing offline CDP peer. Missing-port and early-death cases retain the full polling bound; early death records exit 17 and absent PID, while missing-port records a live child and a listening stderr line without admitting it. Malformed port text preserves the original URL TypeError and terminates without CDP dispatch. Successful readiness completes the existing ordinary native-key preflight and closes the peer; no failure diagnostic is emitted. Failure cases compare the diagnostic's original stack with the unchanged first-failure record, require no replay, no capture/readiness, cleanup of the profile, and actual child wait with separate stdout/stderr EOF. Existing tamper, blind-repin, identity, drag and first-error controls remain in the same generated-consumer suite.

All 13 generated-consumer checks passed, as did the three production tests from node --test ops/browser-native-input.test.cjs and flock /tmp/wine-build.lock bash tools/build.sh (joined exit 0).

Evidence: scratch/runs/20261109-nox-native-startup-diagnostics-1915/. Source recovery uses exact Git SHA plus relevant small patches; no source tree or media archive was made. Before provider edits, RF1910's selection script and predecessor closure were checked; its subsequent final 698-file pins also exclude both edited Nox files. Q31905's owned provider was not edited. No browser, box, nested worker, or runtime attempt was used. This task's box ID/state is NOT_CREATED; expiry and stop receipt are not applicable. The historical 1900 box bx_4bzv5zxa was already archived by unforced stop_218e6c0d31c478ef, with archiveAfter: null; this task did not touch it.

Next: review a future bounded native failure snapshot before assigning a causal repair or another staff attempt. No native startup success or game progress is claimed by these offline regressions.