You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
plugin-security: the per-variant officer cases in org-admin-assignment-boundary.posture.test.ts hit vitest's 5000 ms default on a loaded Test Core shard #35436
Area: data-1 · found on PR #35386 (#35167), measured in 7004581195 and 7004622123
维护者速读
问题: 一组权限测试在 CI 负载高的时候会超时,跟改动无关,却让别的 PR 一直是红的。
要做: 给这组测试定一个实测的时间预算,或把每个测试的工作量拆小。
不做会怎样: 改到写入路径的 PR 会因为这组测试反复变红、没法合入。
你要做的: 无。
What
The 12 "adding and removing a holder" cases (2 postures × 6 callers) in packages/plugins/plugin-security/src/org-admin-assignment-boundary.posture.test.ts (around :1153) take about 0.5 s each locally. On loaded Test Core shards today, the shards that also run scenarios, service-messaging and verify, they took 2 to 5.5 s:
The whole file takes 75 to 179 s on CI. For every variant, each case does a grant insert, a removal by id, a bulk removal and a position holding.
Fix
Fix the time budget, not the assertions. Either declare a measured per-case budget with its class (the AGENTS.md suite-weight rule), or split the per-variant loop so each case does less work. Do not raise the global testTimeout, and do not skip anything.
Done when
The file's cases carry a declared, measured budget (or are split), with the measurement recorded. PR #35386 goes green after this lands and main is merged in.
Claim: PM loop round 9 · area data-1 (the maintainer, verbatim, 2026-11-19T04:35Z project chat: 「再开 area:data」; standing 「暂时都只派 p1 p2 的卡」) · 2026-11-19T09:07Z
Area: data-1
Session: session_01Utp6Ca1jJvsA1dHsPwMiQb
Account: os-bill
Branch: claude/issue-35436-posture-test-budget
Worktree: objectstack-issue-35436 (os-dev worktree in the data-1 container)
Domain: domain:server
Seat: repo:objectstack#5
File surface: packages/plugins/plugin-security/src/org-admin-assignment-boundary.posture.test.ts only (a measured per-case budget with its class per AGENTS.md / ruling record 6181973363, or a split of the per-variant loop); root .changeset/ only if the repo requires one for a test-only change. ⛔ No product source, no global testTimeout, no skip. Stop on breach and report.
Container & model: S, mode:subagent, model: default — no path-derived mandate, effort: medium
Clause-②: no
Metadata-protocol: none
Responsibility: platform test infra — the 12 per-variant officer cases reach vitest's 5000 ms default on a loaded Test Core shard (3.2–5.5 s measured on main and two PRs today) and hold PR #35386 red; every PR whose shard is loaded.
Thread-read: none
Premise: holds — measured in 7004581195 (#35167) and 7004622123 (PR #35386): cases ~0.5 s locally, 2–5.5 s on loaded shards; main's own scheduled run 44484542279 at 3217 ms.
Serial constraints cleared: none — the file is not in any open data-1 claim; PR #35386 adds different plugin-security test files.
Pre-claim lane: domain:server (packages/plugins/plugin-security/** tests)
Pre-claim deps: none. Blocks #35386's green.
Prior rulings read: AGENTS.md suite-weight clause (ruling records 6181973363 measured budget with class, 6120820653 deletion); check-prior-rulings 202 ADR candidates, none on test budgets; thread: none
Triage: lands in domain:server · dispatched; rationale: area:data · Bug · Impeded (a permission posture test times out under CI load and holds unrelated PRs red) · builders, often (every write-path PR) → p2 as set.
{
"issue": 35436,
"status": "done",
"branch": "claude/issue-35436-posture-test-budget",
"pr": "https://github.com/objectstack-ai/objectstack/pull/35452",
"head": "3de047739a",
"session": "session_01Utp6Ca1jJvsA1dHsPwMiQb",
"premise_still_valid": true,
"summary": "Split the three-officer describe in org-admin-assignment-boundary.posture.test.ts: 12 cases (2 postures x 6 callers, each looping 3 auditor variants) become 36 cases (one per posture, caller and variant). Each case does one variant's grant insert, removal by id, bulk removal and position holding, with the same finally cleanup; every expect line is unchanged, only the variant loop moved from inside the it to around it. The file's test-budget header keeps 20 s and its class, REASON updated to 128 cases / thirty-six three-officer cases. No testTimeout raise, no per-case timeout, no skip, no deletion.",
"readings": {
"A1": "holds in shape: before, the 12 cases ran 265-611 ms each locally (shared 4-core box, under os-verify-lock), same order as the card's ~0.5 s; CI readings taken from the card, not re-read.",
"A2": "partly false: the declared shape exists (one header line 'test-budget: SECONDS — CLASS: REASON', read by readTestBudget in scripts/measure-test-shard-timings.mjs, classes in TEST_BUDGET_CLASSES), but it governs the report's 10 s per-FILE wall line, not vitest's per-case 5000 ms timeout, and this file already declares 20 s. It cannot hold a case under 5 s, so route switched to the split per the ruling's intent.",
"A3": "holds: each old case did, per variant and per table, an insert + read-back, a seeded removal by id, two seeded bulk removals; the split keeps all of it per variant."
},
"timings": "before (BASE a9b36efffa): 104 tests passed, tests phase 20.94 s, three-officer cases 12 x 265-611 ms. after (3de047739a): 128 tests passed, tests phase 22.27 s, three-officer cases 36 x 71-223 ms. Slowest case x0.36; applied to the card's worst CI reading 5534 ms => ~2.0 s, 2.5x under the 5 s default. Shared-box seconds; ratios are the claim.",
"tests": "3de047739a: pnpm --filter @objectstack/plugin-security exec vitest run --maxWorkers=2 --reporter=verbose src/org-admin-assignment-boundary.posture.test.ts under os-verify-lock => 'Test Files 1 passed (1) / Tests 128 passed (128)', VERDICT command-exit 0. Before-run on BASE: 'Tests 104 passed (104)', VERDICT command-exit 0. pnpm --filter @objectstack/plugin-security run typecheck (tsc + tsconfig.scripts + check:test-typecheck OK, 0 debt) VERDICT command-exit 0. No ablation: no tested behaviour changed. test:repo not run locally (diff touches no repo-project test), declared to CI.",
"gates": "local, head 3de047739a: dispatch-gates --commands derived 54; 52 exit 0 (check:type-check-debt re-run detached to completion: EXIT=0, 'check-type-check-coverage --re-measure: OK'); 2 exit 3 PREREQUISITE NOT MET (check:i18n, check:dual-build-cjs-loads need a full workspace build) => NOT MEASURED locally, CI runs them. dispatch-gates --ran: '54 derived famil(ies) accounted for — 52 run, 2 NOT-MEASURED', exit 0. overlap-check --branch=HEAD: VERDICT clean exit 0. CI on 3de047739a at report time: Check Changeset success; Lint (ESLint, PM dispatch-gates, repo & tooling, docs & code guards, CI/release/engine, scoped x3), Type Check (workspace, source, consumer, debt ledger), Governed Surface Queue Guard, PR-body guards, Check PR Size: in_progress. Test Core not yet listed.",
"dogfood_battery": "n/a — no ! in the PR title and no (narrowing) arm",
"line_budget": "+19 / -16, 35 changed lines, 1 file",
"files_changed": ["packages/plugins/plugin-security/src/org-admin-assignment-boundary.posture.test.ts"],
"deviations": "PR body 维护者速读 carries the six fixed lines of os-dev.md, not the dispatch's 'at most four', and the technical part is under the os-dev English section order, not '## 席位核对': os-dev.md says it wins on conflict; lines carry no paths or code names. Commit trailer spelled 'Co-authored-by: Claude' per AGENTS.md (dispatch spelled Co-Authored-By); model-free either way.",
"mcp_calls": "0",
"api_writes": "2 relay strokes — (1) pr_create: POST /repos/objectstack-ai/objectstack/pulls (draft), POST /issues/35452/assignees [os-bill], POST /issues/35452/labels [skip-changeset], read-back identical 4068 bytes, labels listed skip-changeset; (2) this os-dev-report comment via post-stamped on #35436. Plus 2 git pushes (not REST).",
"open_questions": [],
"security_findings": "none",
"out_of_scope_findings": [
"carrier: none · noted in PR Acceptance notes, not filed — the card reads the whole file at 75-179 s on loaded CI shards against its declared test-budget of 20 s; not re-measured (no CI timing read), the timings refresh lane's to read.",
"carrier: none · noted in PR Acceptance notes, not filed — three per-posture hidden-column cases in the same file run 0.56-0.64 s locally, the same order as the old three-officer cases; none reported timing out."
]
}
Close-out 2026-11-19T10:47Z: PR #35452 merged and Fixes closed this card. The three-officer cases are split one per auditor variant: 12 cases become 36, with every assertion unchanged. The slowest case went from 611 ms to 223 ms locally (×0.36), and the file's test-budget: header records the measurement. There was no global testTimeout raise and no skip. L1-a ACCEPT 7005808166.
Next, per "Done when": #35383 goes back to the merge queue, and main is merged into #35386 so it can go green. pm:dispatched off.
Activity
objectstack-fleet commentedon Nov 19, 2026
repo:objectstack#5 · os-bill · session_01Utp6Ca1jJvsA1dHsPwMiQb
Claim: PM loop round 9 · area data-1 (the maintainer, verbatim, 2026-11-19T04:35Z project chat: 「再开 area:data」; standing 「暂时都只派 p1 p2 的卡」) · 2026-11-19T09:07Z
Area: data-1
Session:
session_01Utp6Ca1jJvsA1dHsPwMiQbAccount:
os-billBranch:
claude/issue-35436-posture-test-budgetWorktree:
objectstack-issue-35436(os-dev worktree in the data-1 container)Domain:
domain:serverSeat:
repo:objectstack#5File surface:
packages/plugins/plugin-security/src/org-admin-assignment-boundary.posture.test.tsonly (a measured per-case budget with its class per AGENTS.md / ruling record 6181973363, or a split of the per-variant loop); root.changeset/only if the repo requires one for a test-only change. ⛔ No product source, no globaltestTimeout, no skip. Stop on breach and report.Container & model:
S,mode:subagent,model: default — no path-derived mandate,effort: mediumClause-②: no
Metadata-protocol: none
Responsibility: platform test infra — the 12 per-variant officer cases reach vitest's 5000 ms default on a loaded Test Core shard (3.2–5.5 s measured on main and two PRs today) and hold PR #35386 red; every PR whose shard is loaded.
Thread-read: none
Premise: holds — measured in 7004581195 (#35167) and 7004622123 (PR #35386): cases ~0.5 s locally, 2–5.5 s on loaded shards; main's own scheduled run 44484542279 at 3217 ms.
Serial constraints cleared: none — the file is not in any open data-1 claim; PR #35386 adds different plugin-security test files.
Pre-claim lane:
domain:server(packages/plugins/plugin-security/**tests)Pre-claim deps: none. Blocks #35386's green.
Prior rulings read: AGENTS.md suite-weight clause (ruling records 6181973363 measured budget with class, 6120820653 deletion); check-prior-rulings 202 ADR candidates, none on test budgets; thread: none
objectstack-fleet commentedon Nov 19, 2026
triage#1 · hotlong · session_01Q4EjjMnyLqJdzuktEmRPXH
Triage: lands in
domain:server· dispatched; rationale: area:data · Bug · Impeded (a permission posture test times out under CI load and holds unrelated PRs red) · builders, often (every write-path PR) → p2 as set.objectstack-fleet commentedon Nov 19, 2026
repo:objectstack#5 · os-bill · session_01Utp6Ca1jJvsA1dHsPwMiQb
os-dev-report
{ "issue": 35436, "status": "done", "branch": "claude/issue-35436-posture-test-budget", "pr": "https://github.com/objectstack-ai/objectstack/pull/35452", "head": "3de047739a", "session": "session_01Utp6Ca1jJvsA1dHsPwMiQb", "premise_still_valid": true, "summary": "Split the three-officer describe in org-admin-assignment-boundary.posture.test.ts: 12 cases (2 postures x 6 callers, each looping 3 auditor variants) become 36 cases (one per posture, caller and variant). Each case does one variant's grant insert, removal by id, bulk removal and position holding, with the same finally cleanup; every expect line is unchanged, only the variant loop moved from inside the it to around it. The file's test-budget header keeps 20 s and its class, REASON updated to 128 cases / thirty-six three-officer cases. No testTimeout raise, no per-case timeout, no skip, no deletion.", "readings": { "A1": "holds in shape: before, the 12 cases ran 265-611 ms each locally (shared 4-core box, under os-verify-lock), same order as the card's ~0.5 s; CI readings taken from the card, not re-read.", "A2": "partly false: the declared shape exists (one header line 'test-budget: SECONDS — CLASS: REASON', read by readTestBudget in scripts/measure-test-shard-timings.mjs, classes in TEST_BUDGET_CLASSES), but it governs the report's 10 s per-FILE wall line, not vitest's per-case 5000 ms timeout, and this file already declares 20 s. It cannot hold a case under 5 s, so route switched to the split per the ruling's intent.", "A3": "holds: each old case did, per variant and per table, an insert + read-back, a seeded removal by id, two seeded bulk removals; the split keeps all of it per variant." }, "timings": "before (BASE a9b36efffa): 104 tests passed, tests phase 20.94 s, three-officer cases 12 x 265-611 ms. after (3de047739a): 128 tests passed, tests phase 22.27 s, three-officer cases 36 x 71-223 ms. Slowest case x0.36; applied to the card's worst CI reading 5534 ms => ~2.0 s, 2.5x under the 5 s default. Shared-box seconds; ratios are the claim.", "tests": "3de047739a: pnpm --filter @objectstack/plugin-security exec vitest run --maxWorkers=2 --reporter=verbose src/org-admin-assignment-boundary.posture.test.ts under os-verify-lock => 'Test Files 1 passed (1) / Tests 128 passed (128)', VERDICT command-exit 0. Before-run on BASE: 'Tests 104 passed (104)', VERDICT command-exit 0. pnpm --filter @objectstack/plugin-security run typecheck (tsc + tsconfig.scripts + check:test-typecheck OK, 0 debt) VERDICT command-exit 0. No ablation: no tested behaviour changed. test:repo not run locally (diff touches no repo-project test), declared to CI.", "gates": "local, head 3de047739a: dispatch-gates --commands derived 54; 52 exit 0 (check:type-check-debt re-run detached to completion: EXIT=0, 'check-type-check-coverage --re-measure: OK'); 2 exit 3 PREREQUISITE NOT MET (check:i18n, check:dual-build-cjs-loads need a full workspace build) => NOT MEASURED locally, CI runs them. dispatch-gates --ran: '54 derived famil(ies) accounted for — 52 run, 2 NOT-MEASURED', exit 0. overlap-check --branch=HEAD: VERDICT clean exit 0. CI on 3de047739a at report time: Check Changeset success; Lint (ESLint, PM dispatch-gates, repo & tooling, docs & code guards, CI/release/engine, scoped x3), Type Check (workspace, source, consumer, debt ledger), Governed Surface Queue Guard, PR-body guards, Check PR Size: in_progress. Test Core not yet listed.", "dogfood_battery": "n/a — no ! in the PR title and no (narrowing) arm", "line_budget": "+19 / -16, 35 changed lines, 1 file", "files_changed": ["packages/plugins/plugin-security/src/org-admin-assignment-boundary.posture.test.ts"], "deviations": "PR body 维护者速读 carries the six fixed lines of os-dev.md, not the dispatch's 'at most four', and the technical part is under the os-dev English section order, not '## 席位核对': os-dev.md says it wins on conflict; lines carry no paths or code names. Commit trailer spelled 'Co-authored-by: Claude' per AGENTS.md (dispatch spelled Co-Authored-By); model-free either way.", "mcp_calls": "0", "api_writes": "2 relay strokes — (1) pr_create: POST /repos/objectstack-ai/objectstack/pulls (draft), POST /issues/35452/assignees [os-bill], POST /issues/35452/labels [skip-changeset], read-back identical 4068 bytes, labels listed skip-changeset; (2) this os-dev-report comment via post-stamped on #35436. Plus 2 git pushes (not REST).", "open_questions": [], "security_findings": "none", "out_of_scope_findings": [ "carrier: none · noted in PR Acceptance notes, not filed — the card reads the whole file at 75-179 s on loaded CI shards against its declared test-budget of 20 s; not re-measured (no CI timing read), the timings refresh lane's to read.", "carrier: none · noted in PR Acceptance notes, not filed — three per-posture hidden-column cases in the same file run 0.56-0.64 s locally, the same order as the old three-officer cases; none reported timing out." ] }objectstack-fleet commentedon Nov 19, 2026
repo:objectstack#5 · os-bill · session_01Utp6Ca1jJvsA1dHsPwMiQb
Close-out 2026-11-19T10:47Z: PR #35452 merged and
Fixesclosed this card. The three-officer cases are split one per auditor variant: 12 cases become 36, with every assertion unchanged. The slowest case went from 611 ms to 223 ms locally (×0.36), and the file'stest-budget:header records the measurement. There was no globaltestTimeoutraise and no skip. L1-a ACCEPT 7005808166.Next, per "Done when": #35383 goes back to the merge queue, and main is merged into #35386 so it can go green.
pm:dispatchedoff.