Today's red-team run seeded bugs in two files. The first was cpm.mjs, the critical path engine behind the XER schedule checker, which reads a Primavera P6 export and runs the DCMA 14-point assessment on it. The second was the engine of the window design pressure calculator, which earlier red-team runs had already worked through twice in the last day.
| File | Seeded | Caught | Gaps closed |
|---|---|---|---|
xer-schedule-check/cpm.mjs | 8 | 6 | 2 |
window-design-pressure-calculator/calc.mjs | 8 | 7 | 1 |
That is 13 of 16 caught (81%) before the fixes and 16 of 16 after.
What got through
- The driving path's starting point.
drivingPathwalks back from the activity that sets the project finish. When several activities tie on that date, it prefers the one with no successors. A mutant changed!last || t.succs.length === 0to&&, so a finishing activity that has a successor was never chosen. That is not a rare shape: in A (10 days) start-to-start to B (1 day), A finishes last and still has a successor. The mutant returned an empty path, and DCMA check 12 (the critical path test) would then have reported "no open activity on the driving path". All 534 existing tests passed with it. A two-activity test now pins the path to["A"]. - A started predecessor's start-to-start lag in the backward pass. P6 lets the remaining work of a started activity start as late as its SS successor does, because the part of the lag that ran is already behind the data date. Flipping that rule to subtract the lag again changed nothing the tests could see: in every test schedule, the predecessor's own duration set its late start first. The new test gives the successor float through a longer parallel path, so only the SS rule can set the late start.
- A least horizontal dimension of 0. In the wind calculator,
> 0became>= 0. Zone widthahas a 3 ft floor, so a building with no plan size quietly got a full schedule of DP ratings instead of an error.
Each new test fails with its mutant applied and passes without it (redteam.py rerun).
Hunting for real bugs
I fed the CPM engine and the CLI hostile files: an empty file, a header alone, an activity with no fields, negative and non-numeric durations, a self-link, a link to a missing activity, an unknown relationship type and huge lags. Each one produced a schedule with warnings or a one-line error. A 9,000,000-hour activity stops the whole run with "addWork: ran past 1,000 years". That message is blunt, but it is an exit, not a wrong answer.
On the wind calculator I checked the constants against ASCE 7-16: Kd, the 16 psf minimum, the exposure table, the topographic K1/γ/μ table, the wall (GCp) end points and the 10% low-slope reduction. All of them match. No real defect turned up in either file, so the record says zero rather than stretching a quirk into one.
The backlog the red team cannot clear
Twelve of the thirteen defects earlier red-team runs left open need a control-plane edit: a CI workflow's paths list, prompts/redteam.py itself, the commit audit. Most already have a pull request. About twenty control-plane PRs, the oldest from 2026-11-03, are waiting for the owner's approval. Opening another one would only make that queue longer, so this run left them alone.