@feigi/fleet-ctl 3.23.36 → 3.23.37
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/scripts/main-checkout.mjs +1 -1
- package/scripts/member-write-guard.mjs +1 -1
- package/scripts/repo-root.mjs +1 -1
- package/skills/run-team/references/reaping.md +1 -1
- package/scripts/agent-test-dir-prose.test.mjs +0 -59
- package/scripts/agent-test.test.mjs +0 -1640
- package/scripts/ambient-git-vars-mjs-prose.test.mjs +0 -397
- package/scripts/ambient-git-vars-prose.test.mjs +0 -192
- package/scripts/ancestry-check-position-prose.test.mjs +0 -175
- package/scripts/apply-ruleset.test.mjs +0 -421
- package/scripts/arg-header-probes-prose.test.mjs +0 -394
- package/scripts/arg.test.mjs +0 -1354
- package/scripts/board-cli.test.mjs +0 -710
- package/scripts/board-identity.test.mjs +0 -429
- package/scripts/board-liveness-banner.test.mjs +0 -119
- package/scripts/board-prev-shape.test.mjs +0 -228
- package/scripts/board-tryparse-null.test.mjs +0 -119
- package/scripts/board.test.mjs +0 -3121
- package/scripts/brief-after-cut-prose.test.mjs +0 -53
- package/scripts/candidates-exit3-prose.test.mjs +0 -302
- package/scripts/candidates.test.mjs +0 -2312
- package/scripts/caveat-unification-prose.test.mjs +0 -98
- package/scripts/cell-readout.test.mjs +0 -615
- package/scripts/ci-comment-rot-prose.test.mjs +0 -2025
- package/scripts/ci-completes-premise-prose.test.mjs +0 -257
- package/scripts/ci-state-prose.test.mjs +0 -113
- package/scripts/ci-state.test.mjs +0 -1933
- package/scripts/ci-vacuous-green.test.mjs +0 -368
- package/scripts/citation-sweep-prose.test.mjs +0 -1712
- package/scripts/claim-lifecycle.test.mjs +0 -187
- package/scripts/claim-ticket.test.mjs +0 -1122
- package/scripts/closing-keyword-prose.test.mjs +0 -193
- package/scripts/cockpit-launch-idempotent-prose.test.mjs +0 -165
- package/scripts/cockpit-tick-nonblocking.test.mjs +0 -210
- package/scripts/compute-board.test.mjs +0 -1214
- package/scripts/compute-spend.test.mjs +0 -517
- package/scripts/consumer-technology-prose.test.mjs +0 -126
- package/scripts/cross-repo-citation-prose.test.mjs +0 -155
- package/scripts/cwd-isolation-pins.mjs +0 -83
- package/scripts/dedupe-guard-prose.test.mjs +0 -243
- package/scripts/delete-merged-branch.test.mjs +0 -576
- package/scripts/derive-testcmd.test.mjs +0 -595
- package/scripts/diff-stats.test.mjs +0 -404
- package/scripts/dispatch-block-golden-prose.test.mjs +0 -1130
- package/scripts/dispatch-block-pins-prose.test.mjs +0 -615
- package/scripts/dispositions-check.test.mjs +0 -936
- package/scripts/dispositions-gate-prose.test.mjs +0 -129
- package/scripts/drop-merged-label.test.mjs +0 -479
- package/scripts/exec-stub.mjs +0 -93
- package/scripts/exec-stub.test.mjs +0 -69
- package/scripts/expected-jobs-prose.test.mjs +0 -80
- package/scripts/fan-out-authorization-prose.test.mjs +0 -80
- package/scripts/filing-bar-seat-prose.test.mjs +0 -242
- package/scripts/filing-claim-bar-prose.test.mjs +0 -166
- package/scripts/finisher-died-prose.test.mjs +0 -31
- package/scripts/finisher-dispatch-premise-prose.test.mjs +0 -312
- package/scripts/finisher-halt-prose.test.mjs +0 -106
- package/scripts/finisher-name-prose.test.mjs +0 -134
- package/scripts/finisher-own-tree-prose.test.mjs +0 -299
- package/scripts/finisher-pin-race-prose.test.mjs +0 -339
- package/scripts/finisher-test-verdict-prose.test.mjs +0 -102
- package/scripts/fix-applier-correction-rules-prose.test.mjs +0 -202
- package/scripts/fix-applier-result-file-prose.test.mjs +0 -149
- package/scripts/fleet-bootstrap.test.mjs +0 -75
- package/scripts/fleet-heartbeat.test.mjs +0 -450
- package/scripts/fleet-provenance.test.mjs +0 -138
- package/scripts/fleet-run.test.mjs +0 -90
- package/scripts/fleet-state.test.mjs +0 -460
- package/scripts/fleet-tick-prose.test.mjs +0 -300
- package/scripts/fleet-tick.test.mjs +0 -2444
- package/scripts/force-with-lease-reason-prose.test.mjs +0 -184
- package/scripts/frontmatter-check.test.mjs +0 -436
- package/scripts/git-env.test.mjs +0 -149
- package/scripts/git-status-untracked-mode-sweep.test.mjs +0 -216
- package/scripts/gone-walk.test.mjs +0 -213
- package/scripts/gp-sep-invariant-prose.test.mjs +0 -188
- package/scripts/head-moved-after-label-prose.test.mjs +0 -233
- package/scripts/immutable-body-claim-prose.test.mjs +0 -204
- package/scripts/implementer-model-tier.test.mjs +0 -235
- package/scripts/inflight-citation-prose.test.mjs +0 -144
- package/scripts/inflight-exit2-prose.test.mjs +0 -81
- package/scripts/inflight-probe-guard-prose.test.mjs +0 -109
- package/scripts/inflight-scan-scope-prose.test.mjs +0 -57
- package/scripts/inflight.test.mjs +0 -2882
- package/scripts/injection-control-prose.test.mjs +0 -404
- package/scripts/install-root-audit.test.mjs +0 -464
- package/scripts/instrument-check-prose.test.mjs +0 -235
- package/scripts/instruments.test.mjs +0 -787
- package/scripts/is-cli.test.mjs +0 -99
- package/scripts/issue-tracker-prose.test.mjs +0 -71
- package/scripts/json.test.mjs +0 -364
- package/scripts/ledger-dispatch.test.mjs +0 -927
- package/scripts/ledger-grammar.test.mjs +0 -227
- package/scripts/ledger-read-require-file.test.mjs +0 -197
- package/scripts/ledger-rotate.test.mjs +0 -142
- package/scripts/ledger.test.mjs +0 -3436
- package/scripts/line-distance-prose.test.mjs +0 -245
- package/scripts/liveness-rationale-prose.test.mjs +0 -83
- package/scripts/locale-pin-prose.test.mjs +0 -189
- package/scripts/main-checkout.test.mjs +0 -332
- package/scripts/member-outcome-prose.test.mjs +0 -167
- package/scripts/member-outcomes-header.test.mjs +0 -129
- package/scripts/member-outcomes-prose.test.mjs +0 -63
- package/scripts/member-outcomes.test.mjs +0 -638
- package/scripts/member-prompt-prose.test.mjs +0 -165
- package/scripts/member-record.test.mjs +0 -541
- package/scripts/member-write-guard.test.mjs +0 -214
- package/scripts/merge-commit-probe-prose.test.mjs +0 -122
- package/scripts/merge-gate.test.mjs +0 -613
- package/scripts/muted-git-guard-sweep.test.mjs +0 -493
- package/scripts/net-ssh-precedence-prose.test.mjs +0 -91
- package/scripts/net-watchdog-prose.test.mjs +0 -79
- package/scripts/net.test.mjs +0 -211
- package/scripts/no-ci-gate-prose.test.mjs +0 -108
- package/scripts/no-undo-audit.test.mjs +0 -3961
- package/scripts/no-wave.test.mjs +0 -138
- package/scripts/node-floor-sweep.test.mjs +0 -611
- package/scripts/pointer-target-prose.test.mjs +0 -186
- package/scripts/pr-cost.test.mjs +0 -521
- package/scripts/pr-overlap.test.mjs +0 -692
- package/scripts/printf-die-sweep.test.mjs +0 -384
- package/scripts/prompt-renderer.mjs +0 -40
- package/scripts/prompt-renderer.test.mjs +0 -68
- package/scripts/prose-pin.mjs +0 -807
- package/scripts/prose-pin.test.mjs +0 -1034
- package/scripts/prove-merge.test.mjs +0 -995
- package/scripts/pull-table-relabel-prose.test.mjs +0 -60
- package/scripts/quiet-payload-prose.test.mjs +0 -222
- package/scripts/reap-cherry-check-prose.test.mjs +0 -80
- package/scripts/reap.test.mjs +0 -4432
- package/scripts/reaping-prose.test.mjs +0 -239
- package/scripts/reaping-reap-authorizers-prose.test.mjs +0 -112
- package/scripts/reaping-release-authorizers-prose.test.mjs +0 -85
- package/scripts/recipe-derivation-prose.test.mjs +0 -112
- package/scripts/recipe-prove.test.mjs +0 -1042
- package/scripts/refuter-scratch-prose.test.mjs +0 -135
- package/scripts/release-label-required-prose.test.mjs +0 -71
- package/scripts/release-label-split-prose.test.mjs +0 -184
- package/scripts/release-ticket-reap-pairing-prose.test.mjs +0 -63
- package/scripts/release-ticket.test.mjs +0 -5099
- package/scripts/renovate-release-contract.test.mjs +0 -379
- package/scripts/repo-root.test.mjs +0 -873
- package/scripts/reporter-output-rule-prose.test.mjs +0 -208
- package/scripts/review-agent-report-only.test.mjs +0 -49
- package/scripts/review-core-booking.test.mjs +0 -35
- package/scripts/review-core-cwd-isolation.test.mjs +0 -374
- package/scripts/review-core-reads.test.mjs +0 -478
- package/scripts/review-core-refuter-scratch.test.mjs +0 -148
- package/scripts/review-core-scratch-refusal.test.mjs +0 -64
- package/scripts/review-core-shared-test-run.test.mjs +0 -275
- package/scripts/review-core-snapshot-path.test.mjs +0 -830
- package/scripts/review-core-specialist-scratch.test.mjs +0 -191
- package/scripts/review-core-testcmd.test.mjs +0 -335
- package/scripts/review-core-unrun.test.mjs +0 -566
- package/scripts/review-core-unverified-discriminant.test.mjs +0 -208
- package/scripts/review-eval-resolver-path.test.mjs +0 -55
- package/scripts/review-host-fixture.mjs +0 -89
- package/scripts/review-in-run-retry.test.mjs +0 -211
- package/scripts/review-no-vendor-dispatch.test.mjs +0 -45
- package/scripts/review-path-default.test.mjs +0 -796
- package/scripts/review-runner-spawns.test.mjs +0 -95
- package/scripts/review-runner.test.mjs +0 -166
- package/scripts/review-tier-audit.test.mjs +0 -140
- package/scripts/run-artifact-pr-prose.test.mjs +0 -341
- package/scripts/run-merge-bot-prose.test.mjs +0 -1413
- package/scripts/run-team-local-hook.test.mjs +0 -442
- package/scripts/scratch-partition-invariant-prose.test.mjs +0 -74
- package/scripts/scripts-path-citation-sweep.test.mjs +0 -73
- package/scripts/section-between-guard-prose.test.mjs +0 -379
- package/scripts/select-dimensions.test.mjs +0 -674
- package/scripts/shared-refusal.test.mjs +0 -388
- package/scripts/shell-traps-prose.test.mjs +0 -504
- package/scripts/shortlist.test.mjs +0 -380
- package/scripts/slow-transport.mjs +0 -72
- package/scripts/snapshot-repo.test.mjs +0 -1006
- package/scripts/snapshot-runner-audience-prose.test.mjs +0 -130
- package/scripts/spend-view.test.mjs +0 -312
- package/scripts/staleness-qualifier-prose.test.mjs +0 -251
- package/scripts/staleness-verdict-prose.test.mjs +0 -142
- package/scripts/staleness.test.mjs +0 -893
- package/scripts/stalled-member-liveness-prose.test.mjs +0 -219
- package/scripts/stash-prohibition-prose.test.mjs +0 -313
- package/scripts/strip-comments.mjs +0 -44
- package/scripts/temp-dir.mjs +0 -47
- package/scripts/ticket-router.test.mjs +0 -981
- package/scripts/tier-check.test.mjs +0 -828
- package/scripts/tier-outcomes-header.test.mjs +0 -518
- package/scripts/tier-outcomes.test.mjs +0 -572
- package/scripts/tier-roles.test.mjs +0 -535
- package/scripts/tracker-block-copy-prose.test.mjs +0 -288
- package/scripts/triage-labels-gloss-prose.test.mjs +0 -97
- package/scripts/unattended-git-sweep.test.mjs +0 -142
- package/scripts/verify-sha-exit2-prose.test.mjs +0 -269
- package/scripts/verify-sha.test.mjs +0 -692
- package/scripts/watcher-degraded-block.test.mjs +0 -369
- package/scripts/watcher-key-prose.test.mjs +0 -106
- package/scripts/within-run-pair-prose.test.mjs +0 -212
- package/scripts/worktree-audit.test.mjs +0 -1408
- package/scripts/worktree-head-prose.test.mjs +0 -276
- package/scripts/worktree-listing-sweep.test.mjs +0 -217
- package/scripts/worktree-model-prose.test.mjs +0 -216
- package/scripts/worktree-porcelain.mjs +0 -35
- package/scripts/worktree-porcelain.test.mjs +0 -102
|
@@ -1,251 +0,0 @@
|
|
|
1
|
-
// #196. `review-and-fix.md` step 6 and `run-team/SKILL.md`'s finisher-dispatch
|
|
2
|
-
// condition are twins: each tells whoever applies `ready-to-merge` that a
|
|
3
|
-
// `skipped` heavy job does not block the label. The #182 dedup pass dropped
|
|
4
|
-
// `behind-count` from the reviewer-side copy alone, leaving "a `skipped` heavy
|
|
5
|
-
// job is staleness" — which names no cause, so the sentence no longer says
|
|
6
|
-
// WHICH staleness is the benign one. `skipped` off a non-zero behind-count is;
|
|
7
|
-
// a heavy job skipped for any other reason is an unverified suite, and this is
|
|
8
|
-
// the clause standing between that and a label.
|
|
9
|
-
//
|
|
10
|
-
// It happened a second time, the same way round and one document over: PR #881
|
|
11
|
-
// reworded the SKILL.md side to add the `solely` qualifier and the pointer to
|
|
12
|
-
// the five-condition note, and left review-and-fix.md step 6 — the label gate
|
|
13
|
-
// itself — saying neither. CLAUSE pinned only the shared substring, so the
|
|
14
|
-
// suite stayed green through exactly the drift it exists to catch. The anchor
|
|
15
|
-
// now carries the qualifier, which is what makes a one-sided reword red.
|
|
16
|
-
//
|
|
17
|
-
// That same commit — `283d985`, `Closes #182` — took a SECOND residue out of
|
|
18
|
-
// the same step-6 line: the mechanism behind "which a behind PR never reaches",
|
|
19
|
-
// leaving the consequence with nothing to rest on. #196 asked for both back, so
|
|
20
|
-
// both are pinned here. The mechanism is single-document by nature: SKILL.md's
|
|
21
|
-
// own copy of that gate states the consequence alone ("a behind PR never
|
|
22
|
-
// reaches full green, so an exit-0 gate strands it unlabelled"), so there is no
|
|
23
|
-
// twin to compare it against and the second test names one document.
|
|
24
|
-
//
|
|
25
|
-
// The drift was one-sided and silent — `board.mjs` and
|
|
26
|
-
// `references/ci-and-staleness.md` both still named the behind-count, and no
|
|
27
|
-
// assertion in this suite compared the two documents, so only a reader holding
|
|
28
|
-
// both open could see it. That is what this file is for.
|
|
29
|
-
//
|
|
30
|
-
// SLICE SIZE is what anchors these, as in `ci-state-prose.test.mjs`. Both
|
|
31
|
-
// documents talk about `skipped` jobs, behind-counts and staleness in
|
|
32
|
-
// neighbouring prose, and a dedup pass like #182 — the very thing that caused
|
|
33
|
-
// this ticket — is what leaves a second copy of a clause lying around. Matched
|
|
34
|
-
// over the whole file, these assertions are then satisfiable from OUTSIDE the
|
|
35
|
-
// rule they guard: measured, with the live clause gutted in both documents and
|
|
36
|
-
// one stray line carrying the old wording appended to each, an unbounded suite
|
|
37
|
-
// went green — the pass bought entirely by the out-of-clause occurrence. So
|
|
38
|
-
// each document is cut to the one paragraph that carries the rule, and a moved
|
|
39
|
-
// anchor reddens instead of silently widening the slice back to the file.
|
|
40
|
-
//
|
|
41
|
-
// THE CEILING: this pins two clauses and nothing else — not the rest of either
|
|
42
|
-
// sentence, not that the surrounding rule is right. Both documents word the
|
|
43
|
-
// qualifier clause identically today, so one phrase covers both; that is a fact
|
|
44
|
-
// about the current text, not a constraint, and a deliberate reword reddens
|
|
45
|
-
// this. Re-anchor the phrase here when that happens, rather than dropping the
|
|
46
|
-
// qualifier a second time.
|
|
47
|
-
//
|
|
48
|
-
// Reflow-safe by construction, against WHITESPACE reflow: `phrase()` joins
|
|
49
|
-
// the words on `\s+`, so SKILL.md (hard-wrapped ~80 cols) and
|
|
50
|
-
// review-and-fix.md (one long line per numbered step) take the identical
|
|
51
|
-
// regex, and a rewrap of either is a no-op for the clauses — unless a wrap
|
|
52
|
-
// lands a continuation at column 0 in list-marker shape (`3. `), which
|
|
53
|
-
// CommonMark renders as a new list item: a structure change, not a rewrap
|
|
54
|
-
// (see the DIGIT-FREE note under THE FOURTH PIN). The slice anchors go through
|
|
55
|
-
// `phrase()` for that same reason — a literal `indexOf` anchor would break on
|
|
56
|
-
// a rewrap the clause itself survives, turning a reflow into a red — but that
|
|
57
|
-
// protection stops exactly where the pinned clauses' does too: see THE REFLOW
|
|
58
|
-
// CEILING below and the paragraph after it, which together reach an anchor the
|
|
59
|
-
// same way they reach CLAUSE and MECHANISM. Measured: each of the qualifier's
|
|
60
|
-
// six inter-word gaps broken on its own, and all six broken at once, still
|
|
61
|
-
// match, and both
|
|
62
|
-
// containing paragraphs rewrapped across 60-400 cols stay green with Python
|
|
63
|
-
// `textwrap`'s `break_on_hyphens` off — which is how a Markdown wrapper wraps.
|
|
64
|
-
//
|
|
65
|
-
// THE REFLOW CEILING is hyphen-breaking, not any one width. With
|
|
66
|
-
// `break_on_hyphens` at its default `textwrap` splits a hyphenated word at the
|
|
67
|
-
// break — `behind-count` becomes `behind-` / `count` — and `\s+` does not span
|
|
68
|
-
// that, so ANY hyphenated token inside a pinned clause is vulnerable, not one
|
|
69
|
-
// named token: CLAUSE carries `behind-count`, MECHANISM carries `behind-count`
|
|
70
|
-
// and `rebase-check`.
|
|
71
|
-
//
|
|
72
|
-
// The same split reaches the slice ANCHOR, not only the clause it bounds —
|
|
73
|
-
// `anchorAt` resolves an anchor through this same `phrase()`, so a hyphenated
|
|
74
|
-
// anchor carries the identical vulnerability one level up. Both anchors this
|
|
75
|
-
// file uses carry one: STEP_6 is `6. Diff-check green`, and the SKILL.md
|
|
76
|
-
// anchor is `**The fix-applier pushes and exits`. The symptom differs from
|
|
77
|
-
// CLAUSE and MECHANISM's, though: a split anchor does not fail the comparison
|
|
78
|
-
// it bounds, it fails to resolve at all — provided the anchor is unique; a
|
|
79
|
-
// second, unsplit copy elsewhere in the document would mask a split occurrence
|
|
80
|
-
// and bind the slice to that copy instead, which neither anchor here has — so
|
|
81
|
-
// `anchorAt` throws its own `slice anchor "…" moved` refusal before
|
|
82
|
-
// `paragraph()` ever returns a slice to compare against anything. The suite
|
|
83
|
-
// still reds — this is not a silent false green — but the message
|
|
84
|
-
// misattributes the cause: a reader who hits `slice anchor "…" moved` goes
|
|
85
|
-
// looking for an edit that moved the anchor, and there is none to find — the
|
|
86
|
-
// anchor text is unchanged; a rewrap split it across the line break instead.
|
|
87
|
-
//
|
|
88
|
-
// The slice bound does not protect against this — a split lands inside the
|
|
89
|
-
// slice as readily as outside it. Measured, review-and-fix.md rewrapped per
|
|
90
|
-
// source line (Python `textwrap.fill`, `break_on_hyphens=True`,
|
|
91
|
-
// `break_long_words=False`): at width 60 the only split inside step 6's own
|
|
92
|
-
// MECHANISM clause falls on its `behind-count` and that test reds; at width 87
|
|
93
|
-
// the only one there is its `rebase-check`, and it reds again. WHICH occurrence
|
|
94
|
-
// splits is what decides a red, and that is an offset, so it is not monotonic
|
|
95
|
-
// in width.
|
|
96
|
-
//
|
|
97
|
-
// A width quoted without its wrap discipline and its document is not
|
|
98
|
-
// reproducible: per-source-line and per-paragraph rewrapping red at disjoint
|
|
99
|
-
// widths, so a reader re-deriving the map builds a different one and reads this
|
|
100
|
-
// note as false — which has already happened here. This ticket existed to
|
|
101
|
-
// replace a width with a MECHANISM; state the property, and attach the
|
|
102
|
-
// discipline and the document to any width kept. Loosening the token to admit
|
|
103
|
-
// the split would let `behind- count` read as the qualifier.
|
|
104
|
-
//
|
|
105
|
-
// THE FOURTH PIN (#1218) — step 4's OWN instance of the same qualifier. Step 4
|
|
106
|
-
// says "a `rebase-check` red or heavy jobs `skipped` **solely from a non-zero
|
|
107
|
-
// behind-count** never clears by waiting", and until #1218 nothing pinned it:
|
|
108
|
-
// measured, `solely` → `mostly` at step 4 with step 6 and SKILL.md untouched
|
|
109
|
-
// left this suite at tests 3 / pass 3 / fail 0. Same load-bearing word, third
|
|
110
|
-
// site — a `rebase-check` red has several causes and only the behind-count one
|
|
111
|
-
// is benign, so weakening it there turns "this staleness is not a failure" into
|
|
112
|
-
// "staleness is not a failure" and licenses waiting-out, or labelling past, a
|
|
113
|
-
// genuine red.
|
|
114
|
-
//
|
|
115
|
-
// It is NOT sliced by `rule()`, and that is not a style choice. `paragraph()`
|
|
116
|
-
// ends at the next blank line, and this document writes one long line per
|
|
117
|
-
// numbered step with NO blank line between them — so the first blank line after
|
|
118
|
-
// step 4 sits below step SIX. Measured: a blank-line slice anchored at step 4
|
|
119
|
-
// returns 10125 bytes carrying steps 4, 5 and 6, against step 6's own 2158.
|
|
120
|
-
// Step 6 only works with this bound because it is the LAST item before the
|
|
121
|
-
// blank line. The over-slice matters for a LOOSER pin, not for the one this
|
|
122
|
-
// file ships: `a `rebase-check` red or heavy jobs `skipped`` — the QUALIFIER
|
|
123
|
-
// clause's OPENING fragment — occurs TWICE in this document, once opening
|
|
124
|
-
// step 4's clause and once as step 6's MECHANISM, so a bare-keyword or
|
|
125
|
-
// opening-fragment-only pin bounded by the blank line would be answerable by
|
|
126
|
-
// step 6's copy, exactly the "second copy of a clause lying around" the SLICE
|
|
127
|
-
// SIZE note above names as this suite's own history. The full QUALIFIER span
|
|
128
|
-
// pinned below is unique in the document today — a blank-line-bounded pin of
|
|
129
|
-
// the whole span also correctly reds on the `solely` → `mostly` mutation — so
|
|
130
|
-
// `betweenPhrases`'s tighter bound is margin against a future reword that
|
|
131
|
-
// would shorten the pin toward that duplicated opening, not a fix for a
|
|
132
|
-
// present false-green.
|
|
133
|
-
// `finisher-dispatch-premise-prose.test.mjs` reached the same conclusion for a
|
|
134
|
-
// different span of this same step 4; this imports the `betweenPhrases`
|
|
135
|
-
// SLICER it uses, not a shared bound — `prose-pin.mjs` exports no bound
|
|
136
|
-
// constant, so the ordered-list-marker regex (`\n\d+\.\s`, the next list item
|
|
137
|
-
// at column 0) is hand-typed identically at both call sites rather than
|
|
138
|
-
// defined once.
|
|
139
|
-
//
|
|
140
|
-
// Both bounds sit OUTSIDE the pinned clause by construction, as that sibling's
|
|
141
|
-
// do: a mutant that rewrote a bound makes the slice THROW rather than the pin
|
|
142
|
-
// redden, which is the harness losing its footing, not a pin discriminating.
|
|
143
|
-
// Both are single-hit in this document:
|
|
144
|
-
// grep -cF "**Staleness is not a failure:**" → 1
|
|
145
|
-
// grep -cF "below for what it looks like and why" → 1
|
|
146
|
-
//
|
|
147
|
-
// Both are also DIGIT-FREE, and that is load-bearing rather than incidental —
|
|
148
|
-
// it is the one thing measured here that the sibling's note does not already
|
|
149
|
-
// cover. This bound reads `\n\d+\.\s` as "the next ordered-list item", and
|
|
150
|
-
// under CommonMark that reading is exact: a column-0 `N.` inside an open
|
|
151
|
-
// ordered list is a sibling item, whatever the wrap meant it as. So a wrap
|
|
152
|
-
// point landing before any `<digit>.` does not fool the bound, it changes the
|
|
153
|
-
// document — step 4 renders as two items — and a pin whose slice spans that
|
|
154
|
-
// point reds correctly. Step 4's prose is full of such digits — it
|
|
155
|
-
// says "repeat from 3", "go to 6", "straight to 6". Measured, the first anchors
|
|
156
|
-
// tried here were `fix a **genuine** failure and repeat from 3` and `Stop
|
|
157
|
-
// watching and go to 6`: a WHITESPACE-only rewrap at 80 cols (`textwrap.fill`
|
|
158
|
-
// per source line, `break_on_hyphens=False`) pushed `3.` to column 0 between
|
|
159
|
-
// them and split step 4 there. `betweenPhrases` reports that as the end anchor
|
|
160
|
-
// lying past the bound, naming the line the bound first matched — not as
|
|
161
|
-
// `slice end anchor "…" moved`, which would send a reader after an anchor
|
|
162
|
-
// nobody touched. The anchors below span the stretch of step 4 that contains
|
|
163
|
-
// no digit at all, so such a split ELSEWHERE in step 4 never reaches this pin,
|
|
164
|
-
// whose clause it leaves intact, while one INSIDE this slice still reds.
|
|
165
|
-
// Verified green under whitespace-only rewraps at 60/72/80/100/140/200/400 cols.
|
|
166
|
-
//
|
|
167
|
-
// THE REFLOW CEILING above reaches this pin too, through its CLAUSE half only:
|
|
168
|
-
// QUALIFIER carries three hyphenated tokens (`rebase-check`, `non-zero`,
|
|
169
|
-
// `behind-count`), any one of which a hyphen-breaking wrapper splits out of the
|
|
170
|
-
// match. Its two ANCHORS carry none — unlike STEP_6's `6. Diff-check green` and
|
|
171
|
-
// SKILL.md's `**The fix-applier pushes and exits`, both of which do — so the
|
|
172
|
-
// anchor half of that ceiling is closed here by the choice of anchor rather
|
|
173
|
-
// than by luck, and a hyphen-breaking rewrap reds this pin through the clause
|
|
174
|
-
// (a plain comparison failure) instead of through `slice anchor "…" moved`,
|
|
175
|
-
// which is the message that misattributes the cause.
|
|
176
|
-
|
|
177
|
-
import { test } from "node:test";
|
|
178
|
-
import assert from "node:assert/strict";
|
|
179
|
-
import { readFileSync } from "node:fs";
|
|
180
|
-
import { join } from "node:path";
|
|
181
|
-
import { betweenPhrases, paragraph, phrase } from "./prose-pin.mjs";
|
|
182
|
-
|
|
183
|
-
const REPO = join(import.meta.dirname, "..");
|
|
184
|
-
const read = (p) => readFileSync(join(REPO, ...p.split("/")), "utf8");
|
|
185
|
-
|
|
186
|
-
// The paragraph carrying the rule, and no more of the file than that. A missing
|
|
187
|
-
// anchor is a failure rather than a wider slice: silently falling back to the
|
|
188
|
-
// whole document is the false green this bound exists to prevent.
|
|
189
|
-
//
|
|
190
|
-
// The shared bound, not a local copy of it (#1372). What it closes that a local
|
|
191
|
-
// copy could not: a blank line carrying whitespace, which a literal `\n\n`
|
|
192
|
-
// search runs straight past into the next paragraph, and an anchor occurring
|
|
193
|
-
// more than once, which binds the pin to whichever copy of the anchored block
|
|
194
|
-
// comes first. What it does NOT close is a blank line deleted outright — the
|
|
195
|
-
// paragraphs then merge and the slice takes both, a hole that predates this
|
|
196
|
-
// bound and is open still (#1377).
|
|
197
|
-
const rule = (name, anchor) => paragraph(read(name), anchor, name);
|
|
198
|
-
|
|
199
|
-
const CLAUSE =
|
|
200
|
-
"a `skipped` heavy job is behind-count staleness and fine — **solely** off that count, which is a condition to establish rather than infer";
|
|
201
|
-
const MECHANISM = "a `rebase-check` red or heavy jobs `skipped` off the behind-count hold it short of full green";
|
|
202
|
-
|
|
203
|
-
const REVIEW_AND_FIX = "commands/review-and-fix.md";
|
|
204
|
-
const STEP_6 = "6. Diff-check green";
|
|
205
|
-
|
|
206
|
-
const DOCS = [
|
|
207
|
-
[REVIEW_AND_FIX, STEP_6],
|
|
208
|
-
["skills/run-team/SKILL.md", "**The fix-applier pushes and exits"],
|
|
209
|
-
];
|
|
210
|
-
|
|
211
|
-
for (const [name, anchor] of DOCS) {
|
|
212
|
-
test(`${name} qualifies the benign \`skipped\` heavy job as behind-count staleness`, () => {
|
|
213
|
-
assert.match(
|
|
214
|
-
rule(name, anchor),
|
|
215
|
-
phrase(CLAUSE),
|
|
216
|
-
`${name} no longer says "${CLAUSE}". Bare "staleness" names no cause, and its twin document still names one — that one-sided drop is exactly #196. Restore the qualifier; if the clause was reworded on purpose, re-anchor CLAUSE in this file to the new wording in BOTH documents at once.`,
|
|
217
|
-
);
|
|
218
|
-
});
|
|
219
|
-
}
|
|
220
|
-
|
|
221
|
-
test(`${REVIEW_AND_FIX} step 6 keeps the mechanism behind "a behind PR never reaches" exit-0 green`, () => {
|
|
222
|
-
assert.match(
|
|
223
|
-
rule(REVIEW_AND_FIX, STEP_6),
|
|
224
|
-
phrase(MECHANISM),
|
|
225
|
-
`${REVIEW_AND_FIX} step 6 no longer says "${MECHANISM}". Stripped of it the line asserts only the consequence — that a behind PR never reaches exit-0 green — and leaves the reader to reconstruct WHY from separated sentences elsewhere. #182 dropped this clause alongside the behind-count qualifier and #196 restored both. Restore it, or re-anchor MECHANISM in this file to the new wording. Unlike CLAUSE this has no twin: SKILL.md's copy of the same gate carries the consequence only.`,
|
|
226
|
-
);
|
|
227
|
-
});
|
|
228
|
-
|
|
229
|
-
// Step 4's own staleness sentence, bounded inside step 4's list item — see THE
|
|
230
|
-
// FOURTH PIN in the header for why this is not `rule()`.
|
|
231
|
-
const STEP_4_FROM = "**Staleness is not a failure:**";
|
|
232
|
-
const STEP_4_TO = "below for what it looks like and why";
|
|
233
|
-
const STEP_4_WHAT = `${REVIEW_AND_FIX} step 4 staleness qualifier`;
|
|
234
|
-
|
|
235
|
-
const step4Staleness = (text = read(REVIEW_AND_FIX)) =>
|
|
236
|
-
betweenPhrases(text, STEP_4_FROM, STEP_4_TO, STEP_4_WHAT, { bound: /\n\d+\.\s/ });
|
|
237
|
-
|
|
238
|
-
// The qualifier as ONE span, cause through consequence. Never the bare word:
|
|
239
|
-
// `solely` occurs twice in this document, so a keyword pin would be answered by
|
|
240
|
-
// step 6's own `**solely** off that count` — the same out-of-clause pass the
|
|
241
|
-
// slice bound exists to deny, reached through the regex instead.
|
|
242
|
-
const QUALIFIER =
|
|
243
|
-
"a `rebase-check` red or heavy jobs `skipped` **solely from a non-zero behind-count** never clears by waiting";
|
|
244
|
-
|
|
245
|
-
test(`${REVIEW_AND_FIX} step 4 qualifies the never-clearing staleness as solely a non-zero behind-count`, () => {
|
|
246
|
-
assert.match(
|
|
247
|
-
step4Staleness(),
|
|
248
|
-
phrase(QUALIFIER),
|
|
249
|
-
`${STEP_4_WHAT}: step 4 no longer says "${QUALIFIER}". This is the sentence telling a standalone reviewer WHICH red to stop watching rather than fix: only the behind-count cause is benign, so dropping or weakening \`solely\` turns "this staleness is not a failure" into "staleness is not a failure" and licenses stopping the watch on a genuine red. That is #182/#196's drift at a third site (#1218), and step 6 and SKILL.md carrying their copies is exactly what makes a one-sided drop here silent. Restore the qualifier, or re-anchor QUALIFIER in this file to the new wording.`,
|
|
250
|
-
);
|
|
251
|
-
});
|
|
@@ -1,142 +0,0 @@
|
|
|
1
|
-
// #823, deferred from PR #813's review (issue #238). PR #813 added run-team's
|
|
2
|
-
// phase-0 liveness machinery as PROSE — the `staleness.mjs` usage block, the
|
|
3
|
-
// exit-code table, and the instruction to annotate a survivor whose probe came
|
|
4
|
-
// back `could not check` — and shipped it unpinned, in a repo whose convention
|
|
5
|
-
// is to pin exactly this kind of load-bearing instructional clause. Settled on
|
|
6
|
-
// the pushed head before writing this file:
|
|
7
|
-
//
|
|
8
|
-
// git grep -lF 'could not check' origin/main -- 'plugin/scripts/*.test.mjs'
|
|
9
|
-
// → no output, exit 1
|
|
10
|
-
//
|
|
11
|
-
// `staleness-qualifier-prose.test.mjs` is the near neighbour and does NOT cover
|
|
12
|
-
// this: it pins #196's `review-and-fix.md` / SKILL.md finisher-dispatch twins,
|
|
13
|
-
// a different clause about a `skipped` heavy job. `staleness.test.mjs` exercises
|
|
14
|
-
// the script's behaviour and reads no SKILL.md text at all (settled: it contains
|
|
15
|
-
// neither `SKILL.md` nor `readFileSync`). So nothing stood between this block
|
|
16
|
-
// and a silent reword.
|
|
17
|
-
//
|
|
18
|
-
// WHAT IS PINNED, and what is deliberately not. The block states more than the
|
|
19
|
-
// rules pinned here — where the probe sits in phase 0 and why, the `--`
|
|
20
|
-
// end-of-options separator #240 needs, the fold-into-a-neighbour hazard behind
|
|
21
|
-
// the third value, the `origin/main`-only read, the absent-and-never-changed
|
|
22
|
-
// positive control, and the refusal to run a reproduction. This file pins the
|
|
23
|
-
// clauses a reader must obey to use the tool correctly — the flag the script
|
|
24
|
-
// actually accepts, which direction flag means what, that exactly one is
|
|
25
|
-
// given, what each exit code's verdict does to supply, and that a
|
|
26
|
-
// `could not check` survivor is annotated as one. The rest is
|
|
27
|
-
// rationale for those rules; it is left unpinned on purpose, so a rewrite of the
|
|
28
|
-
// reasoning is not a red. The `origin/main`-only paragraph also names
|
|
29
|
-
// `claim-ticket.sh`, and no slice here reaches it.
|
|
30
|
-
//
|
|
31
|
-
// THE SLICE ANCHOR IS WHAT ANCHORS. Matched over the whole document these
|
|
32
|
-
// assertions are satisfiable from OUTSIDE the clauses they guard: this SKILL.md
|
|
33
|
-
// discusses exit codes, verdicts, offering and annotating survivors across many
|
|
34
|
-
// neighbouring paragraphs, and phase 0's own prose quotes the member prompt back
|
|
35
|
-
// at itself. Measured — with every pinned clause gutted in place and one stray
|
|
36
|
-
// line carrying the original wording appended to the end of the file, an
|
|
37
|
-
// unbounded suite went green on all of them, the pass bought entirely by the
|
|
38
|
-
// decoy. `paragraph()` cuts each to the one block carrying its rule, and a moved
|
|
39
|
-
// anchor reddens instead of silently widening back to the file.
|
|
40
|
-
//
|
|
41
|
-
// MUTATION-TESTED BOTH WAYS, because a pin that reds on any edit discriminates
|
|
42
|
-
// nothing. Reds measured on token-PRESERVING semantic flips, never on
|
|
43
|
-
// vocabulary deletion — swapping the two verdict rows' supply actions, swapping
|
|
44
|
-
// the `--gone` and `--present` glosses, moving the annotate instruction onto a
|
|
45
|
-
// different verdict, and renaming the invocation's flag to one the script
|
|
46
|
-
// rejects (`--path` → `--file`) each keep every pinned word and flip only the
|
|
47
|
-
// meaning, and each reds its own assertion and no other. Greens measured on the containing
|
|
48
|
-
// paragraphs rewrapped across 60-400 columns: `phrase()` joins words on `\s+`,
|
|
49
|
-
// so a rewrap is a no-op.
|
|
50
|
-
//
|
|
51
|
-
// THE REFLOW CEILING is hyphen-breaking, as `staleness-qualifier-prose.test.mjs`
|
|
52
|
-
// records for its own pins: a wrapper splitting a hyphenated word at the break
|
|
53
|
-
// puts a hyphen-newline where `\s+` cannot span. It does not bite here — no
|
|
54
|
-
// clause pinned in this file carries a hyphenated token — and that is a fact
|
|
55
|
-
// about the current wording, not a guarantee, so a reword that introduces one
|
|
56
|
-
// inherits the ceiling.
|
|
57
|
-
//
|
|
58
|
-
// THE OTHER CEILING is that these are positive pins: they see a clause deleted
|
|
59
|
-
// or reworded, never a contradiction added beside it. A sentence appended after
|
|
60
|
-
// "Give exactly one" permitting both flags leaves this suite green. Pinning the
|
|
61
|
-
// absence of an unwritten future sentence is not something a positive match can
|
|
62
|
-
// do; the guard against it is review, not this file.
|
|
63
|
-
|
|
64
|
-
import { test } from "node:test";
|
|
65
|
-
import assert from "node:assert/strict";
|
|
66
|
-
import { readFileSync } from "node:fs";
|
|
67
|
-
import { join } from "node:path";
|
|
68
|
-
import { paragraph, phrase } from "./prose-pin.mjs";
|
|
69
|
-
|
|
70
|
-
const SKILL = "skills/run-team/SKILL.md";
|
|
71
|
-
const text = readFileSync(join(import.meta.dirname, "..", ...SKILL.split("/")), "utf8");
|
|
72
|
-
|
|
73
|
-
const USAGE = "**`staleness.mjs` runs that check";
|
|
74
|
-
const TABLE = "| Exit | Verdict |";
|
|
75
|
-
// Phase 0's multi-select, where this annotation used to land, is retired
|
|
76
|
-
// (ADR 0013); the dispatch prompt is where the third value lands now (#1804).
|
|
77
|
-
const SURVIVORS = "**The prompt carries only what varies.**";
|
|
78
|
-
|
|
79
|
-
// The flag itself, not just the glosses around it: `--path` sits inside this
|
|
80
|
-
// same paragraph and was asserted by nothing, so the doc could drift to a flag
|
|
81
|
-
// the script does not accept with no red — measured green on
|
|
82
|
-
// `--path` → `--file`. Pinned to the flag alone rather than the whole
|
|
83
|
-
// invocation, so renaming the `<path>` placeholder stays a no-op.
|
|
84
|
-
const INVOCATION = "staleness.mjs --path";
|
|
85
|
-
|
|
86
|
-
const DIRECTIONS =
|
|
87
|
-
"`--gone` is a defect the fix must remove, the wording the ticket quotes as wrong; `--present` is what the fix must add, the assertion a pin ticket asks for";
|
|
88
|
-
const EXACTLY_ONE =
|
|
89
|
-
"Give exactly one — the direction is not inferable from the string, and the wrong one answers the opposite verdict with full confidence";
|
|
90
|
-
const ANNOTATE =
|
|
91
|
-
"a `staleness.mjs` **could not check** verdict with its reason when the Pull got one";
|
|
92
|
-
|
|
93
|
-
// Each row binds a verdict to what it does at the Pull, which is the whole
|
|
94
|
-
// content of the table — a verdict name alone prescribes nothing. Pinned per
|
|
95
|
-
// row rather than as one blob so a first failure cannot mask the others.
|
|
96
|
-
const VERDICT_ROWS = [
|
|
97
|
-
["0", "| 0 | still reproduces | admit it |"],
|
|
98
|
-
["1", "| 1 | provably fixed | do not admit; close citing the payload's `commit` and `subject` |"],
|
|
99
|
-
["2", "| 2 | could not check | admit it, **and say the probe could not check** |"],
|
|
100
|
-
];
|
|
101
|
-
|
|
102
|
-
test(`${SKILL} keeps the invocation on the flag \`staleness.mjs\` actually accepts`, () => {
|
|
103
|
-
assert.match(
|
|
104
|
-
paragraph(text, USAGE, SKILL),
|
|
105
|
-
phrase(INVOCATION),
|
|
106
|
-
`${SKILL} no longer spells the invocation "${INVOCATION}". A reader who copies a flag the script does not accept gets \`staleness: --path <path> is required\` at exit 2 — a could-not-check indistinguishable from a real one, which the table below then says to admit and annotate. Restore it, or re-anchor INVOCATION in this file to the new wording.`,
|
|
107
|
-
);
|
|
108
|
-
});
|
|
109
|
-
|
|
110
|
-
test(`${SKILL} keeps \`--gone\` and \`--present\` bound to the direction each one means`, () => {
|
|
111
|
-
assert.match(
|
|
112
|
-
paragraph(text, USAGE, SKILL),
|
|
113
|
-
phrase(DIRECTIONS),
|
|
114
|
-
`${SKILL} no longer says "${DIRECTIONS}". The direction is not recoverable from the needle itself, so a reader who loses this gloss picks a flag by guess and the wrong one answers the OPPOSITE verdict with full confidence — a live defect reported fixed, or a fixed one reported live. Restore it, or re-anchor DIRECTIONS in this file to the new wording.`,
|
|
115
|
-
);
|
|
116
|
-
});
|
|
117
|
-
|
|
118
|
-
test(`${SKILL} keeps the probe to exactly one direction per invocation`, () => {
|
|
119
|
-
assert.match(
|
|
120
|
-
paragraph(text, USAGE, SKILL),
|
|
121
|
-
phrase(EXACTLY_ONE),
|
|
122
|
-
`${SKILL} no longer says "${EXACTLY_ONE}". Without it the usage block reads as if both flags may be passed together, which no verdict in the table below describes. Restore it, or re-anchor EXACTLY_ONE in this file to the new wording.`,
|
|
123
|
-
);
|
|
124
|
-
});
|
|
125
|
-
|
|
126
|
-
for (const [code, row] of VERDICT_ROWS) {
|
|
127
|
-
test(`${SKILL} keeps exit ${code}'s verdict bound to what it does at the Pull`, () => {
|
|
128
|
-
assert.match(
|
|
129
|
-
paragraph(text, TABLE, SKILL),
|
|
130
|
-
phrase(row),
|
|
131
|
-
`${SKILL}'s exit-code table no longer carries "${row}". A verdict whose supply action drifts is worse than a missing one: the reader still acts, on the wrong instruction. Restore the row, or re-anchor VERDICT_ROWS in this file to the new wording.`,
|
|
132
|
-
);
|
|
133
|
-
});
|
|
134
|
-
}
|
|
135
|
-
|
|
136
|
-
test(`${SKILL} makes a \`could not check\` ticket reach its member annotated as one`, () => {
|
|
137
|
-
assert.match(
|
|
138
|
-
paragraph(text, SURVIVORS, SKILL),
|
|
139
|
-
phrase(ANNOTATE),
|
|
140
|
-
`${SKILL} no longer says "${ANNOTATE}". The dispatch prompt is where the third value has to land — a probe that could not look answers exactly like one that looked and found nothing, so a ticket dispatched without the verdict reads to its member as one the probe checked and found live, which is the collapse into a neighbour that the third value exists to prevent. Restore it, or re-anchor ANNOTATE in this file to the new wording.`,
|
|
141
|
-
);
|
|
142
|
-
});
|