Repository navigation
Commit 0967cbe
fix(pm): first-touch sweep and H13 read area:* instead of domain:*; the sweep's daily backstop reads the issue type (#35373)
<!-- claude-projects-attribution: {"github_login":"os-bill"} -->
_Requested by **Warren, Bill** · [project
thread](https://claude.ai/code/project/chan_016iMXWSZDzqWRWvWzdNo8wg?thread=cmsg_016iMXWSZDzqWRWvWzdNo8wgXFRsfSS1tQB1kBxAZ86579)_
Part of #35234
Clause-②: no
Metadata-protocol: none
## 维护者速读
- 用户能看到什么变化:用户无感;分诊每天查「新卡有没有分流」时,改看卡的业务区和卡的类型,不再看旧的技术分组标签。
-
为什么做:分诊现在给新卡标的是业务区,巡检还在看旧标签,会把已分好的卡当成没分、把只剩旧标签的卡当成分好了;这是技能评审改进顺序里「车道改成席位加专题」的脚本部分。
- 出错会怎样:只影响巡检报告,不改任何卡;上线后头一轮会多报几张没标业务区或类型的卡,整体撤回即复原。
- 要你做什么:无(旧技术分组标签何时退役,等剩下几处读取迁走后再请你定)。
## What changes
### Reviewer quick look (moved from the brief)
- 先看:`scripts/pm/first-touch-sweep.mjs` 的 `classify()` 与新
`lacksType()`;`scripts/pm/check-half-states.mjs` 的
`h13AreaWithoutPmState()`;`triage-duties.md` 三行规则措辞。
- 两分钟验证:`node scripts/pm/first-touch-sweep.mjs --self-test`,预期「63 cases
pass across 6 batteries」。
Closes only the sweep and H13 half of the card: six `domain:*`
card-label readings outside this card's surface (listed below) still
have to move before the card's Done-when holds, so this PR is a part,
and the card stays open for them.
- `scripts/pm/first-touch-sweep.mjs`: the four label disjunctions read
`area:*` (the label triage's first touch writes) where they read
`domain:*`. A card carrying only a `domain:*` is now as unrouted as a
bare one: disjunct ① lists it, and ② lists a `pm:queue` card whose only
lane reading is a `domain:*`. The daily backstop (outside the verdict
and the exit code, as before) gains a second row: open cards whose issue
type (`type.name` on the REST row) is empty, with the sweep's exclusions
only: no label excuses a type (`security` is exempt on the area row
alone, as before). `--json` gains `no_type`.
- `scripts/pm/check-half-states.mjs` H13: `h13DomainWithoutPmState`
becomes `h13AreaWithoutPmState`, and `DOMAIN_HALF_STATE_STALE_HOURS`
becomes `AREA_HALF_STATE_STALE_HOURS` (same 2h value). The finding text
names `area:*`. No other module imports either name (repo-wide `git
grep`: zero hits).
- `.claude/skills/pm-dispatch/references/triage-duties.md`: the sweep
rule lines ①–④ and the daily backstop line, which now scans for a
missing `area:*` or type and still ends in 补齐 (same line count, every
line within the 120-byte budget; the sweep's self-test pins these
phrases verbatim). Per the claim's surface amendment.
### For the maintainer: retiring the `domain:*` labels (NOT done in this
PR)
The card's last step, retiring the `domain:*` labels, is yours to
confirm after this lands and the sweep runs clean on the live board.
Before you do, these scripts outside this card's surface still read a
card's `domain:*` label to judge it. Retiring the labels before they
move would silence them, without any error. They belong to the
lane-to-seat change, not to this card:
| Script · reading | What it judges from `domain:*` |
|---|---|
| `check-half-states.mjs` H71 (`h71UnclaimedOnDutyLane`) | a `pm:queue`
card on a lane whose seat is on duty but has not claimed it |
| `check-half-states.mjs` H32 lane inventory (in `sweepInto`) |
unclaimed and in-flight counts per lane seat |
| `check-half-states.mjs` H73 (`h73RuledCardStillInBox`) | which lane
seat owes the exit from the decision box |
| `check-half-states.mjs` H74 (`h74InheritsFromParent`) | a sub-issue
inherits its parent's `domain:*` or grade, so it owes no first-touch
audit comment |
| `check-owed-reviews.mjs` (the PR's lane seat) | which lane seat takes
an owed review |
| `fleet-roster.mjs` (seat row vs card) | whether a `domain:` seat row
owns a card |
The other `domain:` hits under `scripts/pm/` are not readings of a
card's label: seat names and signatures (`domain:skills#2`), the
seat-post title parser, the retired-lane alias rewrites on writes
(`issue-create`, `label-write`, `fleet-write/dispatch`), label creation
(`ensure-pm-labels.sh`), self-test fixtures and comments.
## Tests
<details><summary>Self-tests (head 7804d1c)</summary>
- `node scripts/pm/first-touch-sweep.mjs --self-test` exit 0: `✓
first-touch-sweep self-test: 63 cases pass across 6 batteries — offline,
no network.` The classifier battery pin goes 16 → 18 and the backstop
battery 9 → 14 (its registered count). The H13 fixture builder is named
`labelledCard`.
- `node scripts/pm/check-half-states.mjs --self-test` exit 0: `✓
check-half-states self-test: 5323 cases pass.` H13 adds four cases: a
`domain:*` alone is out of scope, the same card with an `area:*` is the
finding, and the row names `area:*` and never `domain`.
</details>
<details><summary>Ablations: each new reading goes red when it is
reverted (scripts/ablation-replace.mjs, restored to the HEAD blob each
time)</summary>
- `classify()` reads `domain:` again: first-touch self-test exit 1, `11
of 65 case(s) failed` (on d6f79bb). Restored, blob `e6892e6b1219`
matches HEAD, `git diff HEAD` empty.
- H13 reads `domain:` again: check-half-states self-test exit 1, `12 of
5323 case(s) failed`. Restored, blob `9358b8d0d630` matches HEAD.
- `lacksType()` always answers false: first-touch self-test exit 1, `3
of 65 case(s) failed` (on d6f79bb: the type row, the walk's
`no_type`, the rendered line). Restored, blob matches HEAD.
- On 7804d1c, `lacksType()` exempts `security` again: first-touch
self-test exit 1, `2 of 63 case(s) failed` (the walk's `no_type` and the
rendered type row). Restored, blob `ba8debf3e4af` matches HEAD.
</details>
<details><summary>Live read of the board (report-only, writes
nothing)</summary>
`node scripts/pm/first-touch-sweep.mjs --since=2026-11-18T06:00:00Z`
exit 0 against objectstack-ai/objectstack at 2026-11-19T07:14Z (head
7804d1c): 424 open issues enumerated over 5 pages, and the platform
also counts 424. ① 1 · ② 0 · ③ 1 · ④ 0 · ⑤ 62. Area backstop 1 card,
issue-type backstop 51 cards. The REST row carries `type`: had the field
been absent, all 424 cards would have been listed.
</details>
## Acceptance notes
- `scripts/pm/ensure-pm-labels.sh` still has a comment describing
disjunct ③ and H13 as reading `domain:*` (around the `status:parked`
label). It is outside this card's file surface and left as is.
- `.claude/skills/pm-dispatch/SKILL.md` still says `domain:*` 仍定文件归属 in
the lane table. That is the lane-to-seat text step, not this card.
- `pnpm check:platform-checklist` exits 1 on d6f79bb and equally on
its base: `platform-core.seed-mode-matrix: VARIANTS STALE — SeedMode ...
now has 0 members`. `SeedMode` became
`enumWithRetiredValues(SEED_MODE_VALUES, ...)`, which the extractor
cannot read. None of this PR's paths are involved, and per
`checklist-status.yml` the gate is not in per-PR CI.
- Known textual overlap: an idle PR touching all three files conflicts
with this branch, and the card-thread branch
`claude/project-thread-rothb5` (no PR yet) conflicts on
`check-half-states.mjs` and `triage-duties.md`. Whichever lands second
merges main and resolves the conflict. Nothing is pre-resolved here.
## Verification
<details><summary>Gates (local; CI runs the full set)</summary>
- `node scripts/pm/dispatch-gates.mjs --commands --repo
objectstack-ai/objectstack` derived 76 families on d6f79bb. All 76
ran locally there; the fix round to 7804d1c (same three files) re-ran
both self-tests, `check-skill-line-ratchet.mjs`,
`check:pm-skill-ratchet`, `check:pm-skill-id-lint` and
`check:nul-bytes`, all exit 0. `--ran` reconciliation exit 0: `76
derived famil(ies) accounted for — 74 run, 2 NOT-MEASURED (2 DERIVED
from a recorded exit 3)`.
- 73 exited 0, including `pnpm check:pm-half-states`, `pnpm
check:pm-skill-id-lint`, `pnpm check:pm-skill-ratchet`, `pnpm
check:pm-dispatch-gates`, `pnpm check:nul-bytes` and `pnpm
check:doc-authoring`.
- NOT MEASURED (exit 3, prerequisite): `check:doc-formula-expressions`
(needs `@objectstack/formula` built) and `check:i18n-coverage` (needs
the CLI built). This diff changes no package, so CI's verdict stands for
these two.
- Red, not caused by this diff: `pnpm check:platform-checklist` exit 1
(see Acceptance notes).
- `node scripts/pm/check-skill-line-ratchet.mjs` exit 0:
`triage-duties.md is 108 lines (ceiling 108; headroom 0)`.
- `node scripts/check-platform-checklist.mjs --changed-from origin/main`
exit 0: no anchored file in the change set.
- `node scripts/pm/overlap-check.mjs --branch=HEAD` exit 1: origin/main
merges cleanly, the platform-readings PR merges cleanly, and the idle PR
noted above conflicts.
- No changeset: `scripts/pm/**` and `.claude/**` publish nothing
(`skip-changeset`).
</details>
Governed surface (`.claude/**`): this PR stays a draft until its tier's
review record exists.
---
_Generated by [Claude
Code](https://claude.ai/code/session_01Utp6CaAqjP52wVTzs99H5G)_
<!-- signed: repo:objectstack#5 · os-bill ·
session_01Utp6CaAqjP52wVTzs99H5G -->
---------
Co-authored-by: Claude <noreply@anthropic.com>1 parent 7ece020 commit 0967cbe
3 files changed
Lines changed: 170 additions & 123 deletions
File tree
- .claude/skills/pm-dispatch/references
- scripts/pm
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
16 | | - | |
17 | | - | |
| 16 | + | |
| 17 | + | |
18 | 18 | | |
19 | 19 | | |
20 | 20 | | |
| |||
64 | 64 | | |
65 | 65 | | |
66 | 66 | | |
67 | | - | |
| 67 | + | |
68 | 68 | | |
69 | 69 | | |
70 | 70 | | |
| |||
0 commit comments