Skip to content

fix(present-yaml): 34 example tests read a path nothing has lived at since APR-MONO - #3250

Closed
noahgift wants to merge 1 commit into
mainfrom
PMAT-1098-present-yaml-example-paths
Closed

noahgift wants to merge 1 commit into
mainfrom
PMAT-1098-present-yaml-example-paths

Conversation

@noahgift

Copy link
Copy Markdown
Contributor
ALD-002 should be valid: "Failed to read ../../examples/ald/data_table_virtualized.yaml:
No such file or directory (os error 2)"

Every row in tests/examples.rs (27) and tests/prs_examples.rs (7) failed, all on one cause.
The examples are in the sibling crate, crates/aprender-present/examples/{ald,apr,charts,dashboards,edge_cases,prs}/.

file what it did
examples.rs Path::new("../../examples/…") — two levels up from crates/aprender-present-yaml/ is the repository root, and CWD is whatever the runner chose. Both wrong.
prs_examples.rs already anchored on CARGO_MANIFEST_DIR, then walked .parent().parent().join("examples").join("prs") — to the same repository root. The CWD-independence was right and the destination was wrong, which is why it reads as deliberate.

CARGO_MANIFEST_DIR + ../aprender-present/examples rather than a corrected ../: it resolves
at compile time against the crate being built, so no working directory can break it and it
survives the next move. One helper per file, 27 + 3 call sites.

Proved: pointing the helper back at ../../examples turns all 27 rows red again; restoring it
turns them green. aprender-present-yaml now 205 lib + 27 + 17 + 7 pass, clippy -D warnings
clean.

How this was found — the more useful half

Nothing in this repo runs integration targets: ci.yml's workspace-test is --workspace --lib
plus one explicit --test list, and make coverage — the only other full run — is also
--lib
. So I ran the whole surface once:

cargo nextest run --workspace --lib --tests --no-fail-fast
  (GPU crates excluded, exactly as the full tier excludes them)

Summary [1141.178s] 98621 tests run: 98584 passed, 37 failed, 329 skipped

19 minutes, and ~16,000 tests across 654 binaries that CI has never linked. The 37 failures
are five binaries, not a swamp:

aprender-present-yaml::examples            27   ← this PR
aprender-present-yaml::prs_examples         7   ← this PR
apr-format::golden_fixtures                 1   ← #3248
aprender-mcp::falsify_mcp_008               1   ← #3238
aprender-cgp::falsify doctor_speed_real     1   ← open

The cadence decision that follows from it is #3249.

Not wired here

ci.yml's --test chain is held by #3245 and #3248 this cycle and only one PR may edit that
line; a third would conflict with both. The wiring for these two targets goes in after they land
— and the wiring must land with a fix, never before it, or main goes red the moment it merges.

Refs #3239

no-close: #3239 stays OPEN — this fixes 34 of its 37 measured failures; the tiering decision it
describes is #3249's.

🤖 Generated with Claude Code

…since APR-MONO

    ALD-002 should be valid: "Failed to read ../../examples/ald/data_table_virtualized.yaml:
    No such file or directory (os error 2)"

Every row in tests/examples.rs (27) and tests/prs_examples.rs (7) failed, all on
one cause. The examples are in the SIBLING crate,
crates/aprender-present/examples/{ald,apr,charts,dashboards,edge_cases,prs}/.

  examples.rs      `Path::new("../../examples/...")` -- two levels up from
                   crates/aprender-present-yaml/ is the repository ROOT, and CWD
                   is whatever the runner chose. Both wrong.
  prs_examples.rs  already anchored on CARGO_MANIFEST_DIR and then walked
                   `.parent().parent().join("examples").join("prs")` -- to the
                   same repository root. The CWD-independence was right and the
                   DESTINATION was wrong, which is why it looks deliberate.

`CARGO_MANIFEST_DIR` + `../aprender-present/examples` rather than a corrected
`../`: it resolves at COMPILE time against the crate being built, so no working
directory can break it and it survives the next move. One helper per file, 27 + 3
call sites.

Proved: pointing the helper back at `../../examples` turns all 27 rows red again;
restoring it turns them green. aprender-present-yaml now 205 lib + 27 + 17 + 7
pass, clippy -D warnings clean.

HOW THIS WAS FOUND, because it is the more useful half. Nothing in this repo runs
integration targets: ci.yml's workspace-test is `--workspace --lib` plus one
explicit `--test` list, and `make coverage` -- the only other full run -- is also
`--lib`. So I ran the whole surface once, on this box:

    cargo nextest run --workspace --lib --tests --no-fail-fast
      (GPU crates excluded, as the full tier excludes them)

    Summary [1141.178s] 98621 tests run: 98584 passed, 37 failed, 329 skipped

19 minutes, and about 18,000 tests that CI has never executed. The 37 failures
are FIVE binaries, not a swamp:

    aprender-present-yaml::examples          27   <- this commit
    aprender-present-yaml::prs_examples       7   <- this commit
    apr-format::golden_fixtures               1   <- #3248
    aprender-mcp::falsify_mcp_008             1   <- #3238
    aprender-cgp::falsify (doctor_speed_real) 1   <- open

That reframes #3239: the dark surface is cheap to run and has three distinct
defects left, two of which are already in flight.

Not wired here. ci.yml's --test chain is held by #3245 and #3248 this cycle and
only one PR may edit that line; a third would conflict with both. The wiring for
these two targets goes in after they land.

Pmat-Ticket: PMAT-1098

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
noahgift added a commit that referenced this pull request Sep 14, 2026
Written before the PR was opened, so it cited the number this document then got.
The three PRs that take the failing set from 37 to 1 are #3248 (golden_v2),
#3250 (present-yaml paths) and #3238 (mcp contract copy).

Pmat-Ticket: PMAT-1098

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@noahgift
noahgift enabled auto-merge September 14, 2026 07:23
@github-actions

Copy link
Copy Markdown

§13.11 rung 1 — quorum shadow verdict

S13-SHADOW pr=3250 head=370d28527a8816619f280f668c2bd240990c8ff2 verdict=REFUSE class=Q1 arm_rc=1

Shadow mode: this records a verdict and merges nothing. A refusal
to arm is not a block (§13 adds zero rows to §7) — the pull request is
exactly as green as it was.

noahgift added a commit that referenced this pull request Sep 14, 2026
… it was right on three counts

All four agy lanes (3 plan + 1 teamwork) refused the draft. Three findings stand
and the spec is revised rather than defended.

1. THE RATCHET HAD NO WRITER. The draft proposed shrink-only, tightening to
   hard-fail. Three lanes refused it independently and the defect is mechanical,
   not stylistic: `--update` writes a file and needs a commit, and a scheduled
   workflow has no PR and no author. Every other ratchet here
   (unwired_guards, pipe_grep_q, shell_lint) is updated by a human inside a PR
   BECAUSE it runs in one. A nightly's baseline would only ever be edited by
   someone who already noticed the job was red -- the exact population the
   ratchet exists to stop relying on. So: land #3250/#3248/#3238, gate
   doctor_speed_real, ship hard-failing on day one. The exit condition was
   already ONE test when the draft was written; there was never an interval in
   which a ratchet carried information. Fallback if the gating stalls: ONE named
   exclusion with its issue number, auditable in a line.

2. THE 39 GB TARGET DIR WAS UNBUDGETED. Unanimous, and the draft did not mention
   it once -- on the same day I spent an hour taking gx10 from 0 bytes free after
   it dequeued a PR from merge-queue position 1 (#3247). New §4bis makes it a
   constraint: not on gx10 (916 GB, the box that hit the wall), a per-run target
   dir reclaimed in-job rather than left to a reaper that already cannot reclaim
   under keep=3, and a preflight free-space assertion that fails ENV: instead of
   letting cargo die half-way and read as 650 new defects.

3. THE REVISIT CONDITION WAS WRONG. I keyed it on queue depth vs
   max_entries_to_build; lane 3 pointed out that is a CAP, not a measure of
   slack -- a queue can sit at depth 3 with idle capacity. Keyed on arrival rate
   vs drain rate instead.

Also sharpened, from a measurement all lanes converged on: T-1 does not "add the
full surface", it must BUILD `ci / deep`. That job has 0 hits in every workflow
including the SHA-pinned upstream sovereign-ci.yml, and its other named parts run
nowhere either -- `cargo test --doc` 0, `cargo run --example` 0, feature matrix 0,
`--no-default-features` 1 hit that is a Windows BUILD flag.

And the fast-pool pin leaves this spec entirely (§8bis). All four lanes rejected
it with a computable break-even rather than a caveat: `runs-on` is a hard label
filter with no fallback, so a pin is non-work-conserving and is a NET LOSS
whenever fast-pool wait exceeds the ~18-22 min runtime delta -- which is the
condition that holds exactly when the latency mattered. The asymmetry is real
(#3251); the actuator is wrong.

Lane 4 was briefed as /teamwork but agy 1.2.2 ran ZERO invoke_subagent calls and
created no teamwork_projects dir (PMAT-126 reproduced). It is one model answering
once and is not counted as a team review anywhere in this document.

Refs #3239, #3251

Pmat-Ticket: PMAT-1098

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@noahgift
noahgift added this pull request to the merge queue Sep 14, 2026
@noahgift noahgift added this to the 0.68.0 milestone Sep 14, 2026
@noahgift
noahgift removed this pull request from the merge queue due to a manual request Sep 14, 2026
@noahgift
noahgift added this pull request to the merge queue Sep 14, 2026
@noahgift
noahgift removed this pull request from the merge queue due to a manual request Sep 14, 2026
@noahgift

Copy link
Copy Markdown
Contributor Author

Superseded by #3295, which carries this change unmodified along with eight other
collision-free CI/guard PRs as a single merge-queue entry.

Not abandoned and not rejected: the commits are merged into
PMAT-3231-batch-1-ci-guards verbatim (clean=9 conflicted=0), and this branch is
retained — reopening is one click if #3295 does not land.

Why: a successful merge_group CI run is median 78 min with max_entries_to_merge = 1,
so nine entries is ~12 h of queue for 623 insertions. As one entry it is 78 minutes.
Root cause and the full five-whys: #3294.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1,424 of 1,469 integration targets run only when a PR touches their own crate — four of tonight's defects trace to this

1 participant