Skip to content

fix(spec)!: composition refuses one job name enabled in two packages - #37392

Merged
os-zhuang merged 9 commits into
mainfrom
claude/project-thread-vmbk98
Nov 26, 2026
Merged

os-zhuang merged 9 commits into
mainfrom
claude/project-thread-vmbk98

Conversation

@objectstack-fleet

@objectstack-fleet objectstack-fleet Bot commented Nov 26, 2026 •

Copy link
Copy Markdown
Contributor

Requested by Irene · project thread
Fixes #36431

repo:objectstack#2 · huangyiirene · session_01J8VVAkQeShvvgjVb5MsbLn

Clause-②: no (narrowing)
Metadata-protocol: narrowed
Skills-docs: none — no skill teaches declaring one job name in two packages of a composition; the refusal names every enabled job of the name and prescribes the fix

维护者速读

  • 用户能看到什么变化:把多个包组合成一个应用时,如果两个包(或包外的顶层部分)都启用了同名的定时任务,现在在组合、校验和构建时就直接报错并点名两处,不再等到启动后两个任务都悄悄不跑。
  • 为什么做:属于“多包组合与安装”这条线;启动时的任务调度和本地安装早就拒绝同名任务,只有组合这一步放行,三处判断不一致,导致定时任务无声丢失。
  • 出错会怎样:最坏是某个以前能组合成功的多包应用现在被拒,需要作者给其中一个任务改名或把它停用;改动只在组合检查,可整体撤回。
  • 要你做什么:无

What changes

  • Composition reads jobs the way the boot's binder does (packages/spec/src/stack.zod.ts). A new reading, composedJobDeclarations, lists every job a composed artifact declares and its holder, input by input. A package body's jobs belong to that body. The residual's jobs are the top-level jobs beyond the bodies' flattened copies, counted by number and never by content: a top-level job that is a body's job object is matched to it first, then by count. That is the same reading as the binder's jobNameCollisions.
  • New refusal collectComposedJobNameErrors: a job name ENABLED in two or more holders (two package bodies, or a body and the residual) is refused with STACK_CROSS_REFERENCE_INVALID (422). The message names every enabled job of that name and marks a residual job (the top level, outside every package body). Example: Job 'crm_nightly' is declared enabled twice across the packages of one composed artifact: 'com.example.sales' (stack #0) jobs[0] and 'com.example.billing' (stack #1) jobs[0]. The runtime schedules an artifact's jobs by their bare name, whichever package declares them, and the job scheduler refuses a name two enabled jobs share, so none of them runs. Rename one of them, or disable one (enabled: false).
  • One reading for the residual door too: the residual's own duplicate-entry door now takes its jobs from composedJobDeclarations. The old by-NAME claim (residualEntryPredicate) read a residual job that shares a body job's name as that body's copy, and that was the gap. The "Known gap" docblock is replaced.
  • Unchanged: a disabled twin composes, because a disabled job is scheduled by nothing. A body job's own flattened copy is not a second job. Distinct names compose. A flat composition keeps its one-package finding.
  • Binder stays as the backstop (packages/runtime/src/app-artifact-handlers.ts, docblock text only): composition now refuses the same set the binder refuses, so the binder's refusal is for artifacts no composition built (hand-written, or built before this change).
  • ADR-0087 semantic entry compose-stacks-job-name-across-packages-refused, and a changeset (minor on @objectstack/spec, BREAKING, FROM → TO).
  • Tests that built an enabled two-holder pair through composeStacks now hand-build the artifact, which is the backstop case. Every refusal assertion is kept. Files: packages/runtime/src/app-artifact-handlers.job-pull.test.ts (a handBuilt helper, with a pin holding it equal to a real composition where one still composes) and packages/cloud-connection/src/marketplace-install-local-jobs.test.ts. The census CONTROL in stack-compose-duplicate-entry-census.test.ts drops its jobs row, and the two-body CONTROL in stack-residual-extension-jobs.test.ts now gives each body its own job name (both pinned the old behaviour by design). The file surface was extended by claim addendum 7178059000.

Read first (by risk):

  1. packages/spec/src/stack.zod.ts: composedJobDeclarations (the nested-input branch: identity match, then count) and collectComposedJobNameErrors (the two-holder condition).
  2. packages/runtime/src/app-artifact-handlers.job-pull.test.ts: handBuilt and its equality pin.
  3. packages/spec/src/stack-composed-job-name-across-holders.test.ts.

Two-minute check: pnpm --filter @objectstack/spec exec vitest run --maxWorkers=2 src/stack-composed-job-name-across-holders.test.ts should show 20 passed.

Tests

All local readings below were taken at head c3c7bfcb, unless a line says otherwise. The patch round for the contract review's S1/N1 (record 7180533824) moved the head to 545757a9; readings retaken there are marked at 545757a9.

New file packages/spec/src/stack-composed-job-name-across-holders.test.ts (20 tests). Refused, each asserting code + status + the named origins:

  • two bodies;
  • one job object reached through two bodies, through a body and the residual, and twice inside one holder (each counted per place it is reached, as the binder binds each copy; added in the S1 patch round);
  • two bodies of a nested artifact;
  • three holders;
  • body + residual;
  • residual before body;
  • a residual beside a nested artifact under first / last;
  • a residual beside a nested artifact that dropped its copy.

CONTROLs that compose:

  • a body's copy alone;
  • a nested copy composed again;
  • a nested artifact read back through JSON (copies counted by number);
  • disabled twins on each side (body/body, body/residual);
  • distinct names;
  • the flat pair keeps the one-package finding.

details: test and ablation readings

  • spec pnpm --filter @objectstack/spec test at 545757a: Test Files 897 passed (897), Tests 28461 passed, 1 todo (at c3c7bfc: 896 / 28435)
  • runtime pnpm --filter @objectstack/runtime test: Test Files 649 passed (649), Tests 12028 passed, 25 skipped; cloud-connection pnpm --filter @objectstack/cloud-connection test: Test Files 94 passed, Tests 1359 passed
  • typecheck: spec, runtime and cloud-connection exit 0 (runtime test-typecheck OK; it needed @objectstack/driver-turso built first)
  • cli unit, the composeStacks-with-jobs files plus migrate-meta-engine-guidance: 5 files, 34 passed
  • metadata owner-stamp-residual-build-boot 27/27 and objectql manifest-service-residual-namespace-name 33/33 (read at 44f206b)
  • Ablations, each a mutation landed through scripts/ablation-replace.mjs and restored (blob equal to HEAD, git diff HEAD empty):
    • (A) the collectComposedJobNameErrors call removed: 8 failed / 8 passed;
    • (B) the copy-count fallback off: 1 failed, the JSON-reloaded nested case;
    • (C) the enabled-only filter off: the 4 disabled-twin CONTROLs fail.

Acceptance notes

  • H1 (the binder's reading): composition refuses exactly the cross-holder names that the binder (jobNameCollisions) and the install door (collectJobNameCollisions) refuse: enabled only, by name, the residual by count beyond the copies. A pair inside ONE holder stays that holder's own door's finding. That door counts a disabled twin too, which is wider than the binder (existing behaviour, unchanged).
  • H2: spec cannot import runtime, so there is no shared helper. The binder keeps its own copy of the reading as the backstop, and its docblock now says so.
  • Finding for the seat to file. class: a (reproducible defect). reach: read from code plus a composeStacks probe; not driven through a public door. evidence: resolveArtifactCollections (packages/runtime/src/artifact-collections.ts, claimedIdentities keys an item name:X) skips a body's job whose name the artifact's top level already carries. For a hand-built artifact whose top level holds a residual job X but no flattened copy of the body's job X (for example a nested preserve artifact that dropped its copies, then composed under last beside a residual input), the binder binds only the residual's job, refuses nothing, and the body's job is silently never scheduled. composeStacks now refuses that shape when both jobs are enabled, so only artifacts no composition built reach it. Dedupe words: resolveArtifactCollections job name claim, residual job shadows body job, binder silent drop.
  • The ADR-0087 entry stack-residual-extension-registered-and-jobs-judged still records the old known gap in its reason text. The new entry supersedes it, and the old one is left as shipped.

Verification

details: local gates

  • node scripts/pm/dispatch-gates.mjs --commands at c3c7bfc: 97 derived commands, all run. 96 exit 0. pnpm check:dual-build-cjs-loads exit 3 (PREREQUISITE NOT MET: it needs every package's dist, e.g. studio and client-react): NOT MEASURED locally, left to CI. check-plugin-teardown-shape --self-test exit 0 after fetching its pinned commit into the shallow clone.
  • --ran reconciliation: 97 derived, 97 run, 0 NOT-MEASURED, 0 UNRUN (runner-declared).
  • pnpm --filter @objectstack/spec check:generated: all 14 generated artifacts up to date (no public export changed).
  • node scripts/check-commit-card-trailers.mjs --range origin/main..HEAD ✓; node scripts/pm/overlap-check.mjs: VERDICT clean.
  • Full dogfood battery on 545757a: VERDICT command-exit 0; Test Files 487 passed, 3 skipped (490); Tests 4128 passed, 68 skipped (4196); no failures.
  • Full dogfood battery on c3c7bfc: pnpm --filter @objectstack/dogfood test under the lock: VERDICT command-exit 0; Test Files 487 passed, 3 skipped (490); Tests 4128 passed, 68 skipped (4196); no failures.

🤖 Generated with Claude Code

https://claude.ai/code/session_01J8VVAkQeShvvgjVb5MsbLn

composeStacks now reads a composed artifact's jobs the way the boot's job
binder does: enabled jobs only, by name, the residual by count beyond the
package bodies' flattened copies. A job name enabled in two package bodies,
or in a body and the residual, is refused (STACK_CROSS_REFERENCE_INVALID)
naming every enabled job of it; the binder would schedule none of them. A
disabled twin, a body's own copy and distinct names still compose.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01J8VVAkQeShvvgjVb5MsbLn
…cblocks

Adds the ADR-0087 semantic entry and the changeset for composition refusing
one job name enabled in two packages, and says in the binder's docblocks
that composition now refuses that set, leaving the binder as the backstop
for artifacts no composition built.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01J8VVAkQeShvvgjVb5MsbLn
Composition now refuses a job name enabled in two holders, so the runtime
binder and the install-local door tests that built such a pair through
composeStacks now hand-build the artifact (the backstop case: an artifact
no composition built), with every refusal assertion kept. A pin holds the
hand-built layout equal to a real composition where one still composes.
The census CONTROL drops its jobs row, which the new spec test pins.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01J8VVAkQeShvvgjVb5MsbLn
@github-actions github-actions Bot added size/l documentation Improvements or additions to documentation tests tooling Fix lands in tooling, not a product package — enters pm:queue only with Unblocks: or a named surface labels Nov 26, 2026
@github-actions

github-actions Bot commented Nov 26, 2026 •

Copy link
Copy Markdown
Contributor

📓 Docs Drift Check

7 anchor(s) derived from 2 changed package(s); no hand-written page names any of them. ⚠️ 1 changed file(s) yielded no anchor (packages/runtime/src/app-artifact-handlers.ts), so the pages documenting them are NOT COVERED by this run — this is not a clean bill of health for those files.

What this run could not see
  • 1 changed file(s) yielded no anchor (packages/runtime/src/app-artifact-handlers.ts) — pages documenting those are invisible to this run
  • 4 name(s) were too generic to anchor anything (single lowercase words)
  • the SDK route bridge reached 69 of 252 client-bound route-ledger rows — the other 183 have no registrar path: tail to select them, so pages documenting THEIR client methods cannot appear above, on this or any run. Of those 183: 0 are remediable by widening that discovery convention (an in-repo file declares the path; the convention did not scan it); 59 are structural — on a ledger where NOT ONE row is declared in-repo, so no discovery change reaches them at any price; 124 are undecided (no in-repo declaration, on a ledger that has other in-repo registrars — absence and an unreadable spelling are not distinguishable here). The rows themselves: node scripts/docs-audit/affected-docs.mjs --bridge-coverage
  • a page that states a rule by its inputs shares no identifier with the emitter that implements the rule, so an emitter-only diff cannot list it — not on this run and not on any run. Measured on fix(driver-sql): emit varchar(maxLength) for a text field a declared index keys on #11430: content/docs/protocol/objectql/types.mdx documents the text-family column mapping by the ObjectQL type names it maps FROM (text / textarea / html) while the diff changed createColumn; it went unlisted, and it was the page that diff falsified, in four places. No shared token exists to detect this on, so a rule your change carries has to be re-read by hand in the pages that restate it.
  • a key NAME is not a key, so the hand re-read the line above prescribes can land on the wrong schema. The same spelling is authorable on one governed type and a [REMOVED] tombstone on another for each of active, aria, joins, objects, template, tools and version (censused on [finding] tools is a key on BOTH AgentSchema (tombstoned, dead) and SkillSchema (live, cloud-attested), so a name-based search attributes skill examples to the agent key — it produced a false stop-the-line alarm on PR #19059 #19093 over the liveness ledger's governed types, top-level keys); nothing in a search result distinguishes the two, so a grep hit on a LIVE example reads as evidence about the DEAD key. Measured on fix(spec): the agent.tools liveness row says dead — it claimed live on a key the schema tombstoned #19059: content/docs/ai/agents.mdx was reported as contradicting the agent.tools tombstone over its tools: example at :161, which is inside the defineSkill({ block opened at :155 — the page was already correct. Settle ownership by PARSING the value against both schemas, never by the name: that literal PASSES SkillSchema, and as an AgentSchema it FAILS at tools with the tombstone prescription. ⛔ These names are not the whole class — a key retired through a .strict() guidance map leaves no tombstone in the walked shape and none of them here (tool.category, live as AIToolDefinition.category).

Coarse fallback — 181 page(s) merely mention a changed package (the pre-#9192 predicate, kept for the deliberately-wide backstop): node scripts/docs-audit/affected-docs.mjs --json ff6f9768d2969c4f2f42819f461424965238e30f → packageMentionDocs.

Which tree this was computed on

This run read content/docs from f01129cb94621dacb6f2d82183587756bc2d7d38 — the merge of head 545757a91ddd9896072ab57ca537cbeb26ebaedf into base ff6f9768d2969c4f2f42819f461424965238e30f, which is what actions/checkout gives a pull_request run. Not the PR head.

A worktree cut from an older main holds a different content/docs, so re-deriving there can legitimately return a different list — that is a different tree, not a wrong row. To answer on the same tree:

# while this PR is open — GitHub drops the merge commit once it closes
git fetch origin f01129cb94621dacb6f2d82183587756bc2d7d38 && git checkout f01129cb94621dacb6f2d82183587756bc2d7d38
# afterwards, rebuild it from the two parents, which stay fetchable
git fetch origin ff6f9768d2969c4f2f42819f461424965238e30f 545757a91ddd9896072ab57ca537cbeb26ebaedf && git checkout -B drift-repro ff6f9768d2969c4f2f42819f461424965238e30f && git merge --no-ff 545757a91ddd9896072ab57ca537cbeb26ebaedf

node scripts/docs-audit/affected-docs.mjs --json ff6f9768d2969c4f2f42819f461424965238e30f

⚠️ That checkout carried uncommitted changes, so the commit above does not fully identify what was read.

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#2 · huangyiirene · session_01J8VVAkQeShvvgjVb5MsbLn

Final green head · 2026-11-26T02:00Z
Head-sha: c3c7bfcbd8b824f84a18dea317de1e1ef1a5dbef
CI at this head: 58 check runs success, 11 skipped, 0 failed or pending.
Local: dispatch-gates --commands 97 derived / 97 run / 96 exit 0 (check:dual-build-cjs-loads exit 3, needs every package dist, measured by CI); dogfood battery 487 files passed, 3 skipped; os-dev-report 7179805898 on #36431.
Owed before the queue: L1 (L1-a), then a contract-review-tier L2 at this head (Clause-②: no (narrowing), Metadata-protocol: narrowed). Not ready, not requested, nothing armed.

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#2 · huangyiirene · session_01J8VVAkBhKxchpbbRXtA3Mf

席位核对

ACCEPT — PR #37392 at c3c7bfcb (L1-a). The contract-review-tier L2 is owed at this head and follows from L1-a.

Head-sha: c3c7bfcbd8b824f84a18dea317de1e1ef1a5dbef · read 2026-11-26T02:04Z

  1. 形态. l1-face.mjs --pr 37392 at c3c7bfcbd8: 11 items ok, 2 flagged (both read below). It is a draft against main, and mergeable_state is clean. Fixes #36431 stands on its own, with no closing keyword next to another card number. Fixes is right: the card's two shapes, residual and two-body, are both refused at composition. Clause-②: no (narrowing) · Metadata-protocol: narrowed · the adr-0087: registered compose-stacks-job-name-across-packages-refused marker, with its entry file in the diff. check-governed-merges --pr 37392: NOT governed, 600 lines.
  2. changeset flag, read. @objectstack/spec: minor, BREAKING narrowing, with a FROM → TO. l1-face also names @objectstack/runtime and @objectstack/cloud-connection as touched with no entry. Neither ships a changed byte:
    • cloud-connection's one file is a .test.ts, outside files: ["dist", …].
    • runtime's app-artifact-handlers.ts change is docblock text only. It sits on jobDeclaringPackages and on the module-private jobNameCollisions. src/index.ts exports neither, and exports addresses only . and ./compiled-plugin-manifest-file, so neither docblock reaches the entry's .d.ts. The tsup JS build drops non-legal comments, and a .js.map's sourcesContent does not count as published.
      So no entry is owed for either, and @objectstack/spec is the one published package that moves.
  3. 前提实测 + changeset, sentence by sentence.
    • collectComposedJobNameErrors groups ENABLED jobs by name across holders (each package body, or the residual) and refuses a name held by two or more holders with STACK_CROSS_REFERENCE_INVALID.
    • composedJobDeclarations files a body's jobs under the body. It matches the top level's copies first by object identity, then by remaining count per name, and files only the jobs beyond the copies as the residual. A disabled job is skipped, and one holder's own pair stays the one-package finding.
    • The changeset's example message is the test's string byte for byte. "A disabled twin composes", "a body job's own flattened copy is not a second job", "distinct job names compose" and "a flat composition keeps its own finding" are each a test. "Two residual jobs of one name stay the one-package finding" agrees with the one-holder skip.
    • Every refusal case asserts code STACK_CROSS_REFERENCE_INVALID and status 422 through expectOneIssue.
    • The census CONTROL drops jobs with its reason stated. The runtime and cloud-connection fixtures now hand-build the backstop artifact, keep their refusal assertions, and add a handBuilt == composed equality pin.
  4. 门禁 check-runs. At c3c7bfcbd8: 58 success, 11 expected skip, 0 unexpected skip, 0 failed, 0 pending. Lint & Repo Gates and TypeScript Type Check success. Dogfood, owed by the (narrowing) arm and the !: the full battery on c3c7bfcb is recorded in the body (487 files passed · 3 skipped, 4128 tests passed · 68 skipped, VERDICT command-exit 0).
  5. 范围外去向. The class-a finding in the Acceptance notes (resolveArtifactCollections / claimedIdentities) is the seat's to file or to set aside under the maintainer's no-new-cards order. Out-of-surface test files were added per the claim addendum 7178059000 (seat option A). Skills-docs: none, with its reason, and no skills/** path.
  6. 落地条款. L2 is owed at CONTRACT_REVIEW_TIER on two faces: published schema (packages/spec/src/stack.zod.ts) and narrowing. L1-a runs it at this head as an isolated subagent. Tier S after a same-head PASS. Fixes closes jobs: two jobs of one name compose and the boot schedules neither (residual and two-body) #36431 on merge.

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#2 · huangyiirene · session_01J8VVAkBhKxchpbbRXtA3Mf
Contract-review-claim: session_01J8VVAkBhKxchpbbRXtA3Mf · head c3c7bfc · 2026-11-26T02:04Z

L1-a runs the isolated CONTRACT_REVIEW_TIER subagent on this head (published schema + narrowing faces), after its L1 ACCEPT 7180430632.

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#2 · huangyiirene · session_01J8VVAkBhKxchpbbRXtA3Mf

Contract review

Served-tier: CONTRACT_REVIEW_TIER
Head-sha: c3c7bfcbd8b824f84a18dea317de1e1ef1a5dbef
Local-runs: none
Scope: packages/cloud-connection/src/marketplace-install-local-jobs.test.ts, packages/runtime/src/app-artifact-handlers.job-pull.test.ts, packages/runtime/src/app-artifact-handlers.ts, packages/spec/src/migrations/entries/semantic/18.compose-stacks-job-name-across-packages-refused.ts, packages/spec/src/stack-compose-duplicate-entry-census.test.ts, packages/spec/src/stack-composed-job-name-across-holders.test.ts, packages/spec/src/stack-residual-extension-jobs.test.ts, packages/spec/src/stack.zod.ts + none in the diff beyond these; read in the cited code and not reviewed: packages/runtime/src/artifact-collections.ts (mergeCollection, resolveArtifactCollections), packages/runtime/src/app-plugin.ts (collectBundleJobs)
Security-touching: no
Rule-change-verified: none

Faces: published schema (packages/spec/src/stack.zod.ts, the semantic migration entry) and narrowing (Clause-②: no (narrowing) on the PR body and the changeset). Inputs: card #36431 with all five comments, the PR body, file list and four comments, the net diff against main, and the check-runs on this head (58 success, 11 skipped, none failed or pending).

① Derived judgments

  • Accept-set narrowing, cross-holder (right). composeStacks now refuses one job name ENABLED in two holders of a result that carries packages[]: two package bodies, or a body and the residual. The code is STACK_CROSS_REFERENCE_INVALID, 422, through the existing artifact pass. This is the route the claim took under 元判据 ②: the install door and the binder already refuse, so composition refuses. The card's to-do 1 (where the clash is judged) is answered at composition, and the binder stays as the backstop.
  • Reading of the residual (right). composedJobDeclarations files a body's jobs under the body and the residual's by count beyond the bodies' copies, matching by object identity first. That is the count jobNameCollisions makes (boundCount - declaredCount), and it agrees with preservePackageEntries on which input becomes a body (stack.manifest, or the carried packages[]).
  • Enabled only (right). enabled === false is skipped, the same test the binder makes. A disabled twin composes.
  • Accept-set narrowing the changeset does not state (right, see N1). The residual's own door now takes its jobs from the same reading. On main a residual job whose name a body also carried was claimed as that body's copy and never read. Two residual jobs of one name beside a body job of that name therefore composed on main, and are now the one-package finding, which counts a disabled job too. That is ruling A (objectExtensions: two entries for one object in the same package silently drop the earlier entry's fields #35228: one package, every door) applied to entries the by-name claim hid. It is a wider refusal than the binder's for the disabled case, which is the one-package door's existing reading.
  • Unchanged (right). A flat composition has one holder and keeps the one-package finding. A body's flattened copy is not a second job. Distinct names compose.
  • Identity dedupe across holders (wrong, see S1). One job object reached through two holders is counted once, and the binder counts it twice.
  • Public surface. No export added or changed: the three new symbols are module-private, and check:generated is reported up to date. The runtime change is two docblocks on symbols src/index.ts does not export.

② Semver level

@objectstack/spec: minor, marked BREAKING, with a FROM → TO line and the adr-0087: registered compose-stacks-job-name-across-packages-refused marker; the entry file is in the diff. That matches what the diff publishes: an accept-set narrowing of composeStacks and no new export. Check Changeset is success on this head. @objectstack/runtime (comment text only) and @objectstack/cloud-connection (one test file) ship no changed byte, so no entry is owed for either.

Clause-②: no (narrowing) — on the PR body and on the changeset, and correct: the diff takes an accepted input away and adds no capability.

③ Boundary flags

  • open_questions: empty in the os-dev-report. Nothing to answer.
  • Dev flag, check:dual-build-cjs-loads exit 3 locally (prerequisite not met): answered by CI. Build Core, Type Check · consumer gates and Lint & Repo Gates are success on this head.
  • Dev flag, out-of-scope finding (resolveArtifactCollections claims a body's job by name, so a top-level residual job shadows a body job with no copy and the body's job is never scheduled): confirmed by reading mergeCollection and claimedIdentities in packages/runtime/src/artifact-collections.ts. It is outside this diff and reachable only by an artifact no composition built. It goes to the seat to file or set aside; it does not block this PR.
  • Stale reason text in the shipped entry stack-residual-extension-registered-and-jobs-judged: left as shipped, superseded by the new entry. Accepted.
  • SQL push-down: no query, no id materialisation and no in-app join in this diff.

④ Design judgment

S1 (should-fix) — one job OBJECT reached through two holders composes, and the boot schedules neither. Read from code, not driven.

  • composedJobDeclarations keeps one seen set across every input and holder (declare returns early on an object it has already filed). Its docblock says so: "One entry OBJECT reached through two inputs is one declaration, counted once".
  • The binder does not count that way. collectBundleJobs reads resolveArtifactCollections(bundle).jobs; mergeCollection appends every body's jobs the top level does not claim, with no dedupe between bodies; jobNameCollisions counts entries by name. Two bodies holding the same job give the binder two enabled jobs of the name, and it refuses both.
  • The shape is reachable through strict defineStack, because a flat composeStacks concatenates by reference (arrays.flat()): const base = defineStack({ jobs: [J] }), a = composeStacks([base, defineStack({ manifest: sales, … })]), b = composeStacks([base, defineStack({ manifest: billing })]), then composeStacks([a, b], { manifest: 'preserve' }). Both assembled bodies carry J. The second declaration is dropped, the name has one holder, and the artifact composes. It is the "shared base inside two nested compositions" the docblock itself names.
  • The same holds for a body and the residual (composeStacks([a, base], { manifest: 'preserve' })), and inside one holder (composeStacks([m, sub, sub]) with a job in sub, top level [J, J]). The one-holder case composed on main too; the jobs reading is rewritten here and keeps it.
  • Sentences this makes false on this head:
    • the card's acceptance, "Two jobs of one name never compose into a boot that silently schedules neither";
    • app-artifact-handlers.ts, "so an artifact it built never reaches this refusal";
    • the changeset, "Read as the binder reads it";
    • the entry's acceptanceCriteria, that a stack which loads without the finding boots with no NOT SCHEDULED error.
  • Precedent: objectExtensions: two entries for one object in the same package silently drop the earlier entry's fields #35228 review S3 settled the same question for hooks. A hook reached twice is counted twice, because a built artifact binds each copy (stack-object-extension-duplicate-target.test.ts, "a hook reached twice is refused"). Jobs are bound per copy as well.
  • Fix direction: count a job per place it is reached, as hooks are. The copy matching inside a nested input does not depend on seen (it uses bodyJobs and the count). Pin the shared-object pair across two bodies, across a body and the residual, and inside one holder.
  • Not a regression: each of these shapes composed on main. It is graded should-fix because the refusal is right wherever it fires and the shape needs one built stack reached through two inputs.

N1 (nit) — the changeset's "as before" is not exact. "Two residual jobs of one name stay the one-package finding … as before" holds only when no body carries the name. Beside a body job of that name the pair composed on main (the by-name claim) and is refused now, a disabled pair included. The changeset and the entry's surface could say so. Prose only.

Files, each against the code it cites:

  • packages/spec/src/stack.zod.ts: holds, apart from S1.
    • Body or residual per input agrees with preservePackageEntries and with the concat pass (a carried packages[] wins over manifest; an empty carried array yields no body).
    • The nested branch matches by identity, then by count, so an in-memory copy and a JSON-reloaded copy are both read as copies; the JSON case names the later entry as the residual's, which the docblock states.
    • collectComposedJobNameErrors skips a name with fewer than two holders, so each one-holder pair stays its own door's finding and is not reported twice.
    • The replaced "Known gap" docblock and the four cross-references agree with the code.
  • 18.compose-stacks-job-name-across-packages-refused.ts: surface, replacement and reason match the code and the changeset. No D2 conversion is right, since which job to keep is the author's call. acceptanceCriteria is subject to S1.
  • packages/runtime/src/app-artifact-handlers.ts: comment text only. The backstop paragraph is accurate except the one sentence S1 names.
  • stack-composed-job-name-across-holders.test.ts: 17 cases. Every refusal asserts code, status and one issue; the nested cases carry anti-vacuity checks. It has no case for one job object reached through two holders (S1).
  • stack-compose-duplicate-entry-census.test.ts, stack-residual-extension-jobs.test.ts: the two CONTROLs pinned the behaviour this card changes. Dropping the jobs row and giving each body its own job name are right, and the new file pins the refusal.
  • app-artifact-handlers.job-pull.test.ts, marketplace-install-local-jobs.test.ts: the fixtures now hand-build the backstop artifact through stand-in names restored after JSON. Every binder and install-door assertion is kept, and handBuilt is pinned equal to a real composition on two layouts that still compose.

Implemented-by: claude/project-thread-vmbk98
Reviewed-by: session_01J8VVAkBhKxchpbbRXtA3Mf

VERDICT: PASS

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#2 · huangyiirene · session_01J8VVAkBhKxchpbbRXtA3Mf

The brief handed to the isolated CONTRACT_REVIEW_TIER subagent whose record follows the claim 7180444373 (verify-review-tier PASS: 32 assistant turns, every one at CONTRACT_REVIEW_TIER). It got no L1 conclusions.

Brief
## Contract review brief — PR #37392 @ `c3c7bfcbd8b824f84a18dea317de1e1ef1a5dbef` (card #36431)

You review at `CONTRACT_REVIEW_TIER`. Render ONE `## Contract review` record on this head — its shape is
`node scripts/pm/record-recognisers.mjs --template` — with a PASS or FAIL verdict, and post it as ONE comment
on the PR or its card.

Inputs — these and nothing else:
  · card #36431: its body and EVERY comment (rulings and earlier records included)
  · PR #37392: its body, its file list, and the net diff against `main` at `c3c7bfcbd8b824f84a18dea317de1e1ef1a5dbef`
  · the check-runs on `c3c7bfcbd8b824f84a18dea317de1e1ef1a5dbef`: their conclusions ARE the gate verdicts
⛔ Not the dispatch order, ⛔ not the dispatching seat's own conclusions — this brief is adversarial by design.

Scope — the paths `reviewFace` returns as `hits` on this PR's file list: packages/cloud-connection/src/marketplace-install-local-jobs.test.ts, packages/runtime/src/app-artifact-handlers.job-pull.test.ts, packages/runtime/src/app-artifact-handlers.ts, packages/spec/src/migrations/entries/semantic/18.compose-stacks-job-name-across-packages-refused.ts, packages/spec/src/stack-compose-duplicate-entry-census.test.ts, packages/spec/src/stack-composed-job-name-across-holders.test.ts, packages/spec/src/stack-residual-extension-jobs.test.ts, packages/spec/src/stack.zod.ts;
  plus every file IN THIS DIFF that directly implements or enforces them — the gate that enforces a rule, the code
  a jsdoc or schema line describes, the validator a skill teaches — reviewed for agreement with the contract.
  Widen it freely, ⛔ never below `hits`; the record's `Scope:` line names the implementing files apart from `hits`.
  The rest of the diff (tests, unrelated modules, lockfiles, generated output, changesets) is the lane seat's
  ACCEPT at `TIER_DEFAULT`, exactly as a standalone PR of those files.
  ④ judges the `hits` files and those implementing files ONLY:
  lockfiles, generated output, changesets and prose elsewhere in the PR are not reviewed;
  code outside the diff is READ to judge them, never reviewed.

Security — if a `hits` path is under `skills/**` or `ui/skills/**` and the change teaches security, auth or permission
  behaviour the path name doesn't show, the record says so and the seat adopting the record adds the `security` label.
  The record says so on its `Security-touching:` line, and the arm lands on `no` alone: write `no` ONLY when no changed
  hunk teaches permission, sharing, credential, token, authentication or other security behaviour, else `yes`.

Rule change — if a `hits` path is under `.claude/**`: the PR body declares `Rule-change:` and you verify it against the diff.
  Write `Rule-change-verified: none` ONLY when no changed hunk alters what an agent may do without the maintainer
  (merge, bypass a check, change repository settings), what gets done and in what order (grading, dispatch, scope), or
  what must go to him (decisions, maintainer actions); process steps, scripts, wording, slimming and file moves are not rule
  changes. Write `ruled` ONLY when every such hunk copies the ruling the PR body quotes on its `Ruling-ref:` line — check the
  copy against the quoted words, do not re-rule it. Otherwise `yes`: the pull request then waits for the maintainer.

⛔ READ-ONLY. No worktree, no checkout, no build, no test run, no gate re-run, no ablation: the check-runs
   on the head already answered every derived gate family, and a local run costs more than it returns.
   If ONE probe is unavoidable, the record's `Local-runs:` line says `probe — REASON`; otherwise `none`.
   Scratch space is `/tmp/claude-0/-home-claude/ef739d1c-d61d-5ca9-8e36-44b007f9735a/scratchpad/pr-37392/` alone; nothing there you did not write this round is read.

Judge, in the record's own sections:
  ① Derived judgments — every accept-set and public-surface change the diff implies, each named right or wrong.
  ② Semver level — the changeset (or `skip-changeset`) matches what the diff publishes, and the `Clause-②:` line.
  ③ Boundary flags — every dev flag and every `open_questions` entry answered, or escalated.
     On every face, SQL push-down: a new id materialisation or in-app join where SQL could push down is a
     finding unless a reason is given (AGENTS.md, Prime Directive 5: SQL first).
  ④ Design judgment — for EVERY `hits` file: does the change hold against the code it cites and the
     scenario it is accepted against? A skill file against the card's eval prompt and the spec it teaches
     on `main`; a schema file against the ruling or ADR it implements and its first consumer; an ADR
     against its first consumer and its execution plan. For EVERY implementing file in the diff: does the
     code agree with the contract, sentence by sentence? Read the cited code in the live tree, and try to
     break the design.
     Grade each finding must-fix, should-fix or nit — a nit has no effect on correctness or the contract.
     A must-fix is a FAIL; a must-fix or should-fix earns a delta review of its fix; nits alone end the round.
     Spell a must-fix or should-fix with its id and grade, `S1 (should-fix) — …`, and a clean round as
     `No must-fix, no should-fix.`: the queue guard reads a graded finding as OPEN on this head and
     refuses the record; the delta record names those it closes by id alone, `S1: closed`.
     A nit is fixed only on the prose faces, or left as an accepted deviation or a follow-up card: a fix
     anywhere else moves the head, and this record no longer covers it.
     ⛔ Judge the tree, never the PR body's account of it.
Sign `Implemented-by:` with the dev's branch and `Reviewed-by:` with your session id — the value is the FIRST
thing after each colon.

Faces — this PR is owed at `CONTRACT_REVIEW_TIER` on TWO faces: the published-schema face (`packages/spec/src/stack.zod.ts`,
  the semantic migration entry) and the narrowing face (`Clause-②: no (narrowing)` on the PR body and changeset). On the
  narrowing face the Scope floor is every path of the diff outside the prose faces — the list above is that floor; the
  changeset is read under ② only. The ④ design judgment is owed (schema + narrowing).

…r binds it

One job object reached through two inputs (a built stack shared by two
compositions, or passed twice) was counted once, while the binder binds
every copy and refuses the name. It is now counted per place, as hooks
are, so the pair is refused across two bodies, a body and the residual,
and inside one holder.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01J8VVAkQeShvvgjVb5MsbLn
…sidual pair now refused

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01J8VVAkQeShvvgjVb5MsbLn
@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#2 · huangyiirene · session_01J8VVAkQeShvvgjVb5MsbLn

Flake judgment · 2026-11-26T03:05Z · head 545757a91ddd9896072ab57ca537cbeb26ebaedf
Red: Test Core (10/10) (job 139646884033, run 45741099367) and its aggregate Test Core. The one failure is packages/plugins/plugin-security/src/insert-check-post-image.test.ts > "[#16608] insert on driver-sqlite-wasm (:memory:) — the check judges the row that will be stored" > "the scoping field lands IN scope…": Error: Test timed out in 5000ms (file 25 tests, 1 failed).
Why a flake, not this diff: (1) the same test failed with the same 5000ms timeout in merge-queue job 139126248269 (run 45590970668, PR #37256, 2026-11-25T10:20Z), a head that does not contain this change; (2) the test touches neither jobs nor composeStacks (0 matches in the file); (3) it passes locally at this head, 25/25. This diff changes only the composeStacks job judge in @objectstack/spec, its tests, and comment text in runtime.
Action: one re-run of the failed jobs through scripts/pm/rerun-failed.mjs; a second failure is read as real. The timeout itself is a flake finding for the seat to file.

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#2 · huangyiirene · session_01J8VVAkQeShvvgjVb5MsbLn

Final green head · 2026-11-26T03:24Z
Head-sha: 545757a91ddd9896072ab57ca537cbeb26ebaedf
Delta from c3c7bfcb: the contract review's S1 (one job object reached through two holders, now counted per place it is reached, as the binder binds each copy; 3 new pins: two bodies, body + residual, one holder twice; ablating the fix reds exactly those 3) and N1 (changeset and entry surface say a residual pair beside a body job of the name composed on main and is refused now). Main merged (branch was 16 behind). os-dev delta report 7181362176 on #36431. PR body counts refreshed.
CI at this head: 60 check runs success, 13 skipped, 0 failed or pending, after one re-run of Test Core (10/10) for the pre-existing plugin-security sqlite-wasm 5000ms timeout (flake judgment 7181392396).
Dogfood battery at this head: VERDICT command-exit 0, Test Files 487 passed / 3 skipped, Tests 4128 passed / 68 skipped.
Owed: L1-a delta and the contract-review-tier L2 delta at this head. Not ready, not requested, nothing armed.

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#2 · huangyiirene · session_01J8VVAkBhKxchpbbRXtA3Mf
Contract-review-claim: session_01J8VVAkBhKxchpbbRXtA3Mf · head 545757a · 2026-11-26T03:26Z

Delta contract review of record 7180533824 (S1 fix round). L1-a runs the isolated CONTRACT_REVIEW_TIER subagent.

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#2 · huangyiirene · session_01J8VVAkBhKxchpbbRXtA3Mf

Contract review

Served-tier: CONTRACT_REVIEW_TIER
Head-sha: 545757a91ddd9896072ab57ca537cbeb26ebaedf
Local-runs: none
Scope: packages/cloud-connection/src/marketplace-install-local-jobs.test.ts, packages/runtime/src/app-artifact-handlers.job-pull.test.ts, packages/runtime/src/app-artifact-handlers.ts, packages/spec/src/migrations/entries/semantic/18.compose-stacks-job-name-across-packages-refused.ts, packages/spec/src/stack-compose-duplicate-entry-census.test.ts, packages/spec/src/stack-composed-job-name-across-holders.test.ts, packages/spec/src/stack-residual-extension-jobs.test.ts, packages/spec/src/stack.zod.ts + none in the diff beyond these; read in the cited code and not reviewed: packages/runtime/src/artifact-collections.ts (mergeCollection, claimedIdentities), packages/runtime/src/app-plugin.ts (collectBundleJobs)
Security-touching: no
Rule-change-verified: none

Delta round on record 7180533824 (head c3c7bfcbd8b824f84a18dea317de1e1ef1a5dbef, PASS with S1 open and N1). Faces: published schema (packages/spec/src/stack.zod.ts, the semantic migration entry) and narrowing (Clause-②: no (narrowing) on the PR body and the changeset). Inputs: card #36431 with all six comments, the PR body, file list and nine comments, the net diff against main, the diff between the two heads, and the check-runs on this head.

What moved between the heads: a merge of main (673a7b619c1), the S1 fix (eb167c5b3e6) and prose (545757a91dd). On the nine files of this PR the two heads differ in five: stack.zod.ts, the new test file, the semantic entry, app-artifact-handlers.ts (comment text) and the changeset. The merge changed none of the nine, and no commit on main since the earlier record's base touches stack.zod.ts, app-artifact-handlers.ts, artifact-collections.ts, app-plugin.ts or the semantic entries directory, so the code the earlier record read is the code on this head. The net diff against main is still the same nine files.

① Derived judgments

  • One job object reached through two places is two jobs (right; this is the S1 fix). composedJobDeclarations no longer keeps a seen set: declare files every job at every place it is reached. One job object in two package bodies, or in a body and the residual, now has two holders and is refused by collectComposedJobNameErrors (STACK_CROSS_REFERENCE_INVALID, 422). That is the binder's count: a flat composition concatenates by reference (composed[field] = arrays.flat()), so the built artifact's top level carries both copies, and jobNameCollisions counts the bound jobs by entry.
  • One job object twice in one holder is that holder's pair (right). The residual's door takes its jobs from the same reading, and duplicateEntryFindings counts origins with no identity dedupe, so composeStacks([m, sub, sub]) with a job in sub is now the one-package finding. This composed on main and booted with neither job scheduled. It is a further narrowing, and the changeset and the entry's surface now state it ("or passed twice", "one job object reached twice in one holder").
  • A nested input's own copies are still not counted again (right). The copy matching never depended on seen: it uses bodyJobs (identity) and the per-name count. A body's flattened copy, a nested copy composed again and a JSON-reloaded nested artifact still compose, and each is a kept CONTROL in the test file. A nested artifact whose top level lists a body's job object twice now files the second as the residual's, where the old seen set dropped it; the binder counts one more bound job than the bodies declare there, so the refusal is the binder's.
  • Wider than the binder for a disabled pair in one holder (right, declared). The one-package door counts a disabled job, so one disabled job object passed twice into one holder is refused although the binder would schedule nothing and refuse nothing. That is the one-package door's existing reading (ruling A, objectExtensions: two entries for one object in the same package silently drop the earlier entry's fields #35228: one package, every door), and the changeset says the one-package wording "counts a disabled job too".
  • Everything the earlier record held under ① still holds. Cross-holder refusal for enabled jobs only, the residual by count beyond the bodies' copies, a disabled twin composes, a flat pair keeps the one-package finding, distinct names compose.
  • Public surface. Unchanged by the delta: no export added or changed; the runtime change is comment text on symbols src/index.ts does not export.

② Semver level

@objectstack/spec: minor, marked BREAKING, with the adr-0087: registered compose-stacks-job-name-across-packages-refused marker and its entry file in the diff. The delta widens the narrowing (a shared job object, and the residual pair beside a body job) and the changeset now names both, so the level and the text match what the diff publishes. Check Changeset is success on this head. @objectstack/runtime (comment text only) and @objectstack/cloud-connection (one test file) still ship no changed byte.

Clause-②: no (narrowing) — on the PR body and on the changeset, and correct: the delta takes more accepted input away and adds no capability.

③ Boundary flags

  • open_questions: empty in the first os-dev-report (7179805898); the patch-round report (7181362176) carries none.
  • Check-runs on this head: 60 success, 13 skipped, none failed or pending. All ten Test Core shards and the Test Core aggregate read success, as do Lint & Repo Gates, TypeScript Type Check, Build Core, Dogfood Regression Gate, Check Changeset and Governed Surface Queue Guard.
  • Flake, Test Core (10/10) first run red on this head (judgment 7181392396): accepted. The one failure was a 5000ms timeout in packages/plugins/plugin-security/src/insert-check-post-image.test.ts, a file this diff does not touch and whose subject is neither jobs nor composition; the same timeout is cited on a head without this change; and the one re-run on this same head is success. The gate verdict on this head is the re-run's. The timeout stays a finding for the seat to file.
  • Dev flag, PR body numbers (the report left them to the seat): the body now reads 20 tests and 897 files / 28461 at 545757a9. Answered.
  • Dev flag, the out-of-scope finding on resolveArtifactCollections (a top-level residual job shadows a body job with no copy): unchanged by the delta, outside this diff, the seat's to file or set aside.
  • SQL push-down: no query, no id materialisation and no in-app join in this diff.

④ Design judgment

No must-fix, no should-fix.

S1: closed

N1: closed

How S1 was judged closed, against the four sentences the earlier record named and its fix direction:

  • The fix is the direction asked: jobs are counted per place reached, as hooks are. The three shapes are each pinned in stack-composed-job-name-across-holders.test.ts, with code, status and one issue asserted: one object in two bodies (names both bodies), one object in a body and the residual (names the body and the residual), one object twice in one holder (the one-package wording, stack #1 jobs[0] and stack #2 jobs[0]). Test Core is success on this head.
  • The card's acceptance, "Two jobs of one name never compose into a boot that silently schedules neither": each shape S1 named is now refused at composition. I tried the remaining routes by reading: the same nested artifact passed twice (two body holders, refused); a nested artifact beside the flat stack one of its bodies was built from (body plus residual, refused, and the binder counts one bound job beyond the bodies' declarations there); a nested top level listing a body's job twice (residual, refused). None composes into an artifact the binder refuses.
  • app-artifact-handlers.ts: the sentence is now "so a composition does not build an artifact this refuses", with the per-place count spelled out. True on this head.
  • The changeset's "Read as the binder reads it" now states the per-place count. True.
  • The entry's acceptanceCriteria now names both findings and says composition counts each job once per place reached. True.

N1: the changeset's "as before" is now bounded ("as before when no package body carries the name") and a new bullet states the residual pair beside a body job of the name is refused now, a disabled job counted too; the entry's surface says the same.

Files, each against the code it cites, on this head:

  • packages/spec/src/stack.zod.ts: holds. The composedJobDeclarations docblock agrees with the code sentence by sentence (per place reached; only a nested input's flattened copies of its own bodies' jobs are not counted again). The residual-door docblock's new sentence on jobs and the collectComposedJobNameErrors docblock ("counted by name and per place reached") agree with it. The rest is as the earlier record read it.
  • 18.compose-stacks-job-name-across-packages-refused.ts: surface and acceptanceCriteria match the code and the changeset. The entry's name has no twin on main's entries directory.
  • packages/runtime/src/app-artifact-handlers.ts: comment text only; the backstop paragraph is accurate against jobNameCollisions as it stands.
  • stack-composed-job-name-across-holders.test.ts: 20 cases, the 17 earlier ones unchanged and three added for S1.
  • stack-compose-duplicate-entry-census.test.ts, stack-residual-extension-jobs.test.ts, app-artifact-handlers.job-pull.test.ts, marketplace-install-local-jobs.test.ts: unchanged between the two heads; the earlier record's reading stands.

Implemented-by: claude/project-thread-vmbk98
Reviewed-by: session_01J8VVAkBhKxchpbbRXtA3Mf

VERDICT: PASS

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#2 · huangyiirene · session_01J8VVAkBhKxchpbbRXtA3Mf

The brief handed to the isolated CONTRACT_REVIEW_TIER subagent for the delta record on this head (claim 7181724841; verify-review-tier PASS). It got no L1 conclusions.

Brief
## Contract review brief — PR #37392 @ `545757a91ddd9896072ab57ca537cbeb26ebaedf` (card #36431)

You review at `CONTRACT_REVIEW_TIER`. Render ONE `## Contract review` record on this head — its shape is
`node scripts/pm/record-recognisers.mjs --template` — with a PASS or FAIL verdict, and post it as ONE comment
on the PR or its card.

Inputs — these and nothing else:
  · card #36431: its body and EVERY comment (rulings and earlier records included)
  · PR #37392: its body, its file list, and the net diff against `main` at `545757a91ddd9896072ab57ca537cbeb26ebaedf`
  · the check-runs on `545757a91ddd9896072ab57ca537cbeb26ebaedf`: their conclusions ARE the gate verdicts
⛔ Not the dispatch order, ⛔ not the dispatching seat's own conclusions — this brief is adversarial by design.

Scope — the paths `reviewFace` returns as `hits` on this PR's file list: packages/cloud-connection/src/marketplace-install-local-jobs.test.ts, packages/runtime/src/app-artifact-handlers.job-pull.test.ts, packages/runtime/src/app-artifact-handlers.ts, packages/spec/src/migrations/entries/semantic/18.compose-stacks-job-name-across-packages-refused.ts, packages/spec/src/stack-compose-duplicate-entry-census.test.ts, packages/spec/src/stack-composed-job-name-across-holders.test.ts, packages/spec/src/stack-residual-extension-jobs.test.ts, packages/spec/src/stack.zod.ts;
  plus every file IN THIS DIFF that directly implements or enforces them — the gate that enforces a rule, the code
  a jsdoc or schema line describes, the validator a skill teaches — reviewed for agreement with the contract.
  Widen it freely, ⛔ never below `hits`; the record's `Scope:` line names the implementing files apart from `hits`.
  The rest of the diff (tests, unrelated modules, lockfiles, generated output, changesets) is the lane seat's
  ACCEPT at `TIER_DEFAULT`, exactly as a standalone PR of those files.
  ④ judges the `hits` files and those implementing files ONLY:
  lockfiles, generated output, changesets and prose elsewhere in the PR are not reviewed;
  code outside the diff is READ to judge them, never reviewed.

Security — if a `hits` path is under `skills/**` or `ui/skills/**` and the change teaches security, auth or permission
  behaviour the path name doesn't show, the record says so and the seat adopting the record adds the `security` label.
  The record says so on its `Security-touching:` line, and the arm lands on `no` alone: write `no` ONLY when no changed
  hunk teaches permission, sharing, credential, token, authentication or other security behaviour, else `yes`.

Rule change — if a `hits` path is under `.claude/**`: the PR body declares `Rule-change:` and you verify it against the diff.
  Write `Rule-change-verified: none` ONLY when no changed hunk alters what an agent may do without the maintainer
  (merge, bypass a check, change repository settings), what gets done and in what order (grading, dispatch, scope), or
  what must go to him (decisions, maintainer actions); process steps, scripts, wording, slimming and file moves are not rule
  changes. Write `ruled` ONLY when every such hunk copies the ruling the PR body quotes on its `Ruling-ref:` line — check the
  copy against the quoted words, do not re-rule it. Otherwise `yes`: the pull request then waits for the maintainer.

⛔ READ-ONLY. No worktree, no checkout, no build, no test run, no gate re-run, no ablation: the check-runs
   on the head already answered every derived gate family, and a local run costs more than it returns.
   If ONE probe is unavoidable, the record's `Local-runs:` line says `probe — REASON`; otherwise `none`.
   Scratch space is `/tmp/claude-0/-home-claude/ef739d1c-d61d-5ca9-8e36-44b007f9735a/scratchpad/pr-37392/` alone; nothing there you did not write this round is read.

Judge, in the record's own sections:
  ① Derived judgments — every accept-set and public-surface change the diff implies, each named right or wrong.
  ② Semver level — the changeset (or `skip-changeset`) matches what the diff publishes, and the `Clause-②:` line.
  ③ Boundary flags — every dev flag and every `open_questions` entry answered, or escalated.
     On every face, SQL push-down: a new id materialisation or in-app join where SQL could push down is a
     finding unless a reason is given (AGENTS.md, Prime Directive 5: SQL first).
  ④ Design judgment — for EVERY `hits` file: does the change hold against the code it cites and the
     scenario it is accepted against? A skill file against the card's eval prompt and the spec it teaches
     on `main`; a schema file against the ruling or ADR it implements and its first consumer; an ADR
     against its first consumer and its execution plan. For EVERY implementing file in the diff: does the
     code agree with the contract, sentence by sentence? Read the cited code in the live tree, and try to
     break the design.
     Grade each finding must-fix, should-fix or nit — a nit has no effect on correctness or the contract.
     A must-fix is a FAIL; a must-fix or should-fix earns a delta review of its fix; nits alone end the round.
     Spell a must-fix or should-fix with its id and grade, `S1 (should-fix) — …`, and a clean round as
     `No must-fix, no should-fix.`: the queue guard reads a graded finding as OPEN on this head and
     refuses the record; the delta record names those it closes by id alone, `S1: closed`.
     A nit is fixed only on the prose faces, or left as an accepted deviation or a follow-up card: a fix
     anywhere else moves the head, and this record no longer covers it.
     ⛔ Judge the tree, never the PR body's account of it.
Sign `Implemented-by:` with the dev's branch and `Reviewed-by:` with your session id — the value is the FIRST
thing after each colon.

Faces — this PR is owed at `CONTRACT_REVIEW_TIER` on TWO faces: the published-schema face (`packages/spec/src/stack.zod.ts`,
  the semantic migration entry) and the narrowing face (`Clause-②: no (narrowing)` on the PR body and changeset). On the
  narrowing face the Scope floor is every path of the diff outside the prose faces — the list above is that floor; the
  changeset is read under ② only. The ④ design judgment is owed (schema + narrowing).

Delta round — this head moved from `c3c7bfcbd8b824f84a18dea317de1e1ef1a5dbef`, whose full record is PR comment 7180533824
  (PASS with S1 should-fix OPEN and N1 nit). Between them: a merge of `main` (`673a7b619c1`) and two commits
  (`eb167c5b3e6` the S1 fix, `545757a91dd` prose). Judge whether S1 is closed (name it `S1: closed` by id if so),
  whether the fix or main's move broke anything the earlier record held, and the check-runs on this head (one Test Core
  shard was re-run on this head after a flake; the card thread's flake judgment is comment 7181392396 on the card or PR).
  Render a full record of the same shape on THIS head.

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#2 · huangyiirene · session_01J8VVAkBhKxchpbbRXtA3Mf

席位核对

ACCEPT — PR #37392 at 545757a9 (L1-a). Delta of ACCEPT 7180430632 after the S1 fix round.

Head-sha: 545757a91ddd9896072ab57ca537cbeb26ebaedf · read 2026-11-26T03:31Z

  1. 形态. Draft against main, mergeable_state clean. Fixes #36431, Clause-②: no (narrowing) · Metadata-protocol: narrowed and the adr-0087: registered marker are unchanged. Since c3c7bfcb there is a merge of main (673a7b619c1, 16 commits, touching none of the PR's nine files) and two commits: eb167c5b3e6, the S1 fix, and 545757a91dd, prose.
  2. 前提实测 (delta).
    • composedJobDeclarations drops the cross-input seen set, so a job counts once per place it is reached, as the binder binds each copy. Nested-copy matching (identity first, then count) is untouched.
    • Three new pins: one job object in two bodies, in a body and the residual, and twice in one holder.
    • Changeset, sentence by sentence: the binder-reading bullet now says "each job counted once per place it is reached … is two jobs", and the new bullet names the residual's own pair beside a body job of that name, which composed on main and is refused now. Both match the code and the pins.
    • The semantic entry's surface and acceptanceCriteria say the same. The runtime file's delta is docblock text only, on functions the entry does not export.
  3. 门禁 check-runs. At 545757a9: 60 success, 13 expected skip, 0 unexpected skip, 0 failed, 0 pending. check-expected-skips --pr 37392 OK, exit 0. Lint & Repo Gates and TypeScript Type Check success. One Test Core shard (10/10) was re-run on this head after a 5000 ms timeout in a plugin-security test the diff does not touch. The flake judgment is 7181392396, and the re-run is green. Dogfood: the full battery on 545757a9 is recorded in the body (487 files passed · 3 skipped, 4128 tests passed · 68 skipped, exit 0).
  4. 接受的偏差. As at 7180430632. The changeset flag on runtime and cloud-connection is unchanged: a test file, plus docblocks not reachable from the entry, so nothing ships and no entry is owed. The delta widens the narrowing to one job object passed twice into one holder, a disabled one included. That is the one-package door's existing reading, and the changeset and entry declare it.
  5. 范围外去向. Unchanged: the resolveArtifactCollections shadowing finding and the plugin-security timeout are the seat's, to file or set aside under the no-new-cards order.
  6. 落地条款. Delta L2 on this head: 7181769662 (CONTRACT_REVIEW_TIER, PASS, S1: closed, N1: closed, no must-fix, no should-fix). Brief 7181781094, verify-review-tier PASS. NOT governed: a Tier S landing by the seat. Fixes closes jobs: two jobs of one name compose and the boot schedules neither (residual and two-body) #36431 on merge.

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#2 · huangyiirene · session_01J8VVAm8Y73VGNq3PkTe3dc

维护者速读

  • 改了什么:把多个包组合成一个应用时,如果两个包(或一个包加包外的顶层部分)都启用了同名定时任务,组合、校验和构建现在直接拒绝(422 STACK_CROSS_REFERENCE_INVALID),并点名每一处;停用的同名任务仍然放行。
  • 为什么改:jobs: two jobs of one name compose and the boot schedules neither (residual and two-body) #36431 量到,启动时的任务调度和本地安装早就拒绝同名任务,只有组合这一步放行,结果组合成功后两个任务启动时都悄悄不跑。
  • 风险与回滚:以前能组合成功、但带两个启用的同名任务的多包应用,现在会被拒,作者需要改名或停用其一;所以声明为 Clause-②: no (narrowing),changeset 为 @objectstack/spec minor(BREAKING,FROM → TO),并有 ADR-0087 语义迁移条目。revert 一个合并即可。
  • 先看:packages/spec/src/stack.zod.ts 里的 composedJobDeclarations(嵌套输入先按对象身份、再按数量配对)和 collectComposedJobNameErrors(两个持有者的判断)。
  • 两分钟验证:pnpm --filter @objectstack/spec exec vitest run --maxWorkers=2 src/stack-composed-job-name-across-holders.test.ts,应为 20 passed。dogfood 在当前 head 为绿。
  • 需要你做的:在当前 head 545757a91ddd9896072ab57ca537cbeb26ebaedf 上点一次 Approve。本 PR 声明了 narrowing,按 2026-11-19 在 governance: the guard scripts join the governed register, .claude/** lands by declared rule-change, and a narrowed spec change lands only by the maintainer #35321 上的裁决由审批人放行;批准后本席经队列落地。

席位意见:ACCEPT(L1-a 7181797620),请审批人批准。

席位核对

ACCEPT · repo:objectstack#2 · head 545757a91ddd9896072ab57ca537cbeb26ebaedf · card #36431

  1. 形态:9 个文件,+606/−51:packages/spec/src/stack.zod.ts、新测试 stack-composed-job-name-across-holders.test.ts(20 个)、ADR-0087 语义条目 18.compose-stacks-job-name-across-packages-refused.ts、changeset,app-artifact-handlers.ts 仅改文档注释,四个原有测试改为手工构造产物(拒绝断言全部保留);文件面经认领补记 7178059000 扩展;Fixes #36431。
  2. 前提实测:label-write --handoff --dry-run 读出走 narrowing 一路(Tier H),记录齐备;check-governed-merges --pr 37392 只读路径,读出 NOT governed,以队列守卫的 narrowed 一路为准。landing-k --pr 37392 读出 K = 8 < 15。
  3. 门禁 check-runs:当前 head 60 success、13 expected skip、0 failed、0 pending,mergeable_state clean(pr-state --pr 37392);check-expected-skips --pr 37392 OK。一个 Test Core 分片因无关的 plugin-security 超时重跑后通过(判定 7181392396)。
  4. 接受的偏差:契约评审首轮 PASS 7180533824 附一项 S1(同一个任务对象经两个持有者到达时,组合放行而绑定会计两次)和 N1,已在 545757a 关闭(delta PASS 7181769662,Served-tier: CONTRACT_REVIEW_TIER,无 must-fix、无 should-fix)。L1-a 记录里的落地条款写成「NOT governed,席位 Tier S 落地」,与工具读数不符;本记录更正为 Tier H,交审批人。
  5. 范围外去向:两项发现按维护者 2026-11-25T23:10Z「不再接新单」的指示不立卡,记在这里:(a) 手工构造的产物若顶层带一个与某个包同名的残余任务,resolveArtifactCollections 会丢掉包里的那个任务;(b) plugin-security 的 insert-check-post-image.test.ts sqlite-wasm 一路首次启动在 5000 ms 超时(本 PR 和 PR feat(service-knowledge): documents carry their organization, and search hands the adapter the caller's organizations #37256 的队列 head 上都见到)。Skills-docs: none。
  6. 落地条款:走 narrowing 一路,等审批人在当前 head 批准;批准后本席入队落地(维护者 2026-11-24 授权「审批人批准后的 Tier H PR 你可以自主落地」)。head 若移动,本记录与评审作废。

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#2 · huangyiirene · session_01J8VVAm8Y73VGNq3PkTe3dc

Approval requested on head 545757a9: the narrowed leg (Tier H by the 2026-11-19 ruling on #35321). Contract review PASS 7181769662 at this head (Served-tier: CONTRACT_REVIEW_TIER). L1 ACCEPT 7181797620; seat record above. All checks green, K = 8. After an authorized approval on this head, seat 2 lands it through the queue.

@objectstack-fleet objectstack-fleet Bot added the pm:awaiting-merge PR only: landing waits on the maintainer's own review and merge (SKILL.md 复核 ②); never on an issue label Nov 26, 2026
@os-zhuang
os-zhuang marked this pull request as ready for review November 26, 2026 03:35
@os-zhuang
os-zhuang added this pull request to the merge queue Nov 26, 2026
Merged via the queue into main with commit 66c854d Nov 26, 2026
122 of 124 checks passed
@os-zhuang
os-zhuang deleted the claude/project-thread-vmbk98 branch November 26, 2026 04:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation pm:awaiting-merge PR only: landing waits on the maintainer's own review and merge (SKILL.md 复核 ②); never on an issue size/l tests tooling Fix lands in tooling, not a product package — enters pm:queue only with Unblocks: or a named surface

Projects

None yet

Development

Successfully merging this pull request may close these issues.

jobs: two jobs of one name compose and the boot schedules neither (residual and two-body)

3 participants