Repository navigation
v0.15.0 — collection errors fail closed
Collection errors fail closed
A test module that fails to import (ImportError, syntax error, broken module-scope fixture) is silently dropped from pytest's collected items. Before 0.15 the daemon served the shortened suite as if nothing happened: green summary, n quietly smaller, rc=0 — a silently shortened suite looking green is the worst failure mode a test runner can have (observed in the wild: two files with ImportError ran a «green» suite with zero trace).
Now:
- collect-time failures are captured in the forkserver preload (
CollectReportrecorder) and shipped to the daemon with the workers' one-timereadyframe; - the summary grows a loud
COLLECT ERRORS (N)block (with per-file tracebacks) right underresults :; - every run served by that boot forces
rc=1— single-run, persist-pool and bench paths alike; - the successfully collected tests still run: you get the full remaining suite AND a red, attributed verdict (semantics of
--continue-on-collection-errors, but loud); - daemon-plugin
run_infogains an additivecollect_errorskey (list of(nodeid, longrepr)), and the block contract gains conditionalcollect-errors.
Also: the fuzz-tier noise strategy no longer generates KNOWN outcome strings (hypothesis falsified the categorize-noise property with noise=['failed'] — significance ordering working as designed; the property's domain is genuinely-unknown strings), with the surfaced edge pinned as a deterministic test.
Full matrix green: 3 OS × py3.11–3.14, stress+parity tiers, 125-test dogfood suite.