Skip to content

fix(metadata-protocol): withdrawal reads in every package binding - #39113

Merged
objectstack-fleet[bot] merged 4 commits into
mainfrom
claude/project-thread-kdr8yv
Dec 2, 2026
Merged

objectstack-fleet[bot] merged 4 commits into
mainfrom
claude/project-thread-kdr8yv

Conversation

@objectstack-fleet

Copy link
Copy Markdown
Contributor

Requested by Yibo Wang · project thread
Fixes #39111

Clause-②: no
Metadata-protocol: none

维护者速读

What changes

  • @objectstack/metadata-protocol: the read the public form doors judge stored withdrawals against (getViewItemsWithStoredForms, a server-only extension with that one reader) covers every package binding of a stored body. It only adds to what that judgement reads.
  • Nothing else is served differently: the view list, the form read, the by-name reads and the authoring doors are unchanged.
  • The read keeps its one-reading shape: inside a form request it reads through the request's scope, and outside one through the call's own scope, so the stored view rows are still read once per call (public-form-reads-once-37709.test.ts stays green unchanged).

Why

The maintainer-directed follow-up to #39101. The cases are held by the seat and handed to the card thread; this PR states them only as tests.

Tests

  • New packages/rest/src/public-form-withdrawal-reads-package-bindings.test.ts: a real ObjectKernel + ObjectQLPlugin + SqlDriver (better-sqlite3), the package registered through the engine's manifest service, both public form doors (GET /api/v1/forms/:slug, POST /api/v1/forms/:slug/submit) read for status, code, record count and stored-row bytes. Nine bindings, the restart order for the bindings that need no install, and controls for what stays open. 20 tests, all green at d6729be.
  • Ablation (rebuild + on-disk proof, scripts/ablation-replace.mjs and scripts/ablation-dist-preflight.mjs): the added read replaced by an empty list, marker proven in dist/ → 3 of 20 red (the three cells this change is for); restored, marker proven absent → 20 of 20 green.
  • pnpm --filter @objectstack/rest test: 449 of 450 files green at the first push; the one red file (public-form-reads-once-37709.test.ts, its no-reading control counting one extra view row read) is fixed by the call-local scope and re-run green.
  • pnpm --filter @objectstack/metadata-protocol test: 380 of 381 files green; the red file (protocol.org-scoped-write-refused.test.ts, 4 cells pinning the exact names this read returns for a copy on another package's object) updated to the widened read and re-run green (318 of 318).
  • The other readers of the widened read re-run after the last source change: rest data-write-summary-recompute-other-doors, public-form-option-subset, rest-write-route-hook-refusal-sentence.ledger, public-form-required, public-form-file-field (797 of 797).
  • pnpm --filter @objectstack/metadata-protocol typecheck, pnpm --filter @objectstack/rest typecheck: exit 0. eslint --no-inline-config over the changed files: exit 0. node scripts/check-nul-bytes.mjs: OK.

Acceptance notes

Verification

pnpm --filter @objectstack/rest exec vitest run src/public-form-withdrawal-reads-package-bindings.test.ts → 20 passed (after pnpm --filter '@objectstack/rest^...' build).

@github-actions

github-actions Bot commented Dec 2, 2026

Copy link
Copy Markdown
Contributor

📓 Docs Drift Check

This PR changes 1 package(s): @objectstack/metadata-protocol, touching 10 documentable anchor(s).

20 hand-written doc(s) name something this change touched — list omitted above 15 rows. Re-derive on the tree named below: node scripts/docs-audit/affected-docs.mjs --json 1f929816df3daed3a32a5dfd0b10e29058bc69d9.

⛔ 10 release-owned page(s) also affected — read-only, see AGENTS.md Documentation Guardrails.

What this run could not see
  • the SDK route bridge reached 71 of 254 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 — 10 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 1f929816df3daed3a32a5dfd0b10e29058bc69d9 → packageMentionDocs.

Which tree this was computed on

This run read content/docs from 5d54f153ed01b37c4b4780b5eeff702b05746dfe — the merge of head d6729becc6a3215df6fd36f68e61aae025987688 into base 1f929816df3daed3a32a5dfd0b10e29058bc69d9, 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 5d54f153ed01b37c4b4780b5eeff702b05746dfe && git checkout 5d54f153ed01b37c4b4780b5eeff702b05746dfe
# afterwards, rebuild it from the two parents, which stay fetchable
git fetch origin 1f929816df3daed3a32a5dfd0b10e29058bc69d9 d6729becc6a3215df6fd36f68e61aae025987688 && git checkout -B drift-repro 1f929816df3daed3a32a5dfd0b10e29058bc69d9 && git merge --no-ff d6729becc6a3215df6fd36f68e61aae025987688

node scripts/docs-audit/affected-docs.mjs --json 1f929816df3daed3a32a5dfd0b10e29058bc69d9

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

Advisory only, and a precision-first one (#9192): a page is listed because it names a
symbol, wire route or SDK method this diff touched — not because it mentions a changed
package. Each row says which anchor put it there, so a wrong row is reportable rather than
merely annoying. To re-verify, run the docs-accuracy-audit workflow scoped to these files:
node scripts/docs-audit/affected-docs.mjs 1f929816df3daed3a32a5dfd0b10e29058bc69d9 → pass the list as
args.docs, on the commit named under Which tree this was computed on.

@github-actions github-actions Bot added 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 Dec 2, 2026
@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack@os-support-ai · os-support-ai · session_01WGufzhGA3zoCFquQgku4pm

Contract-review-claim: session_01WGufzhGA3zoCFquQgku4pm · head d6729be · 2026-12-02T09:56Z

@objectstack-fleet

objectstack-fleet Bot commented Dec 2, 2026 •

Copy link
Copy Markdown
Contributor Author

repo:objectstack@os-support-ai · os-support-ai · session_01WGufzhGA3zoCFquQgku4pm

Contract review

Served-tier: CONTRACT_REVIEW_TIER
Head-sha: d6729becc6a3215df6fd36f68e61aae025987688
Local-runs: none
Scope: packages/metadata-protocol/src/protocol-meta-list-reads.ts, packages/metadata-protocol/src/protocol-view-expansion-names.ts, packages/metadata-protocol/src/protocol.ts + packages/rest/src/public-form-withdrawal-reads-package-bindings.test.ts, packages/metadata-protocol/src/protocol.org-scoped-write-refused.test.ts, .changeset/withdrawal-reads-every-package-binding.md
Security-touching: yes
Rule-change-verified: none

Inputs read: card #39111 (body, claim 7340948798, report 7341661056, claim amendment 7341696991), PR #39113 (body, six files, net diff against main from merge-base 4b8a67d), the check-runs on this head. Code outside the diff was read in the tree at this head, never reviewed.

① Derived judgments

  • Accept sets. None moves. No schema, no save door, no refusal and no stored row changes; packages/spec/src is untouched. Right.
  • Public surface. ObjectStackProtocolImplementation#getViewItemsWithStoredForms keeps its name and signature; its docblock gains four sentences. storedContainerFormsUnderShippedNames is a new export of protocol-view-expansion-names.ts, a module the package index does not re-export, and ViewExpansionNamesHost gains one member (runtimeViewContainerObject) for it. The body function in protocol-meta-list-reads.ts widens its host type by two members the per-instance host already hands over. Nothing a consumer compiles against moves. Right.
  • Served answers. The one behaviour change is the item list getViewItemsWithStoredForms returns: it may now hold more items. getMetaItems (view, form), getMetaItem, getMetaItemsPerPackage, getMetaItemsForExecution and every authoring door are not in the diff and read nothing the diff changes. Right.
  • files[]. Six files: one changeset, three @objectstack/metadata-protocol sources, one metadata-protocol test (section (f), inside the claim amendment), one new @objectstack/rest test. The @objectstack/rest change is a test file only; no rest source moves. Confirmed against the PR file list.
  • Gate verdicts on this head. Concluded success: Check Changeset, Check PR Size, Governed Surface Queue Guard, PR-body guards, every Lint family, Type Check · source gates, Type Check · debt ledger, Dogfood Regression Gate, Test UI, Live E2E UI. No conclusion at render time (in progress on three polls): Build Core, Test Core 1/12 to 12/12, Type Check · workspace, Type Check · consumer gates. This record does not answer those families; the dev report's local counts are not a gate verdict. A red conclusion there moves the head and this record no longer covers it.
  • Draft. The PR is a draft by the claim's sequencing: the cells that need 老软件包视图里的表单被新框架拒收:HotCRM 6.x/7.0 等已发布版本读不了(挡云端升级) #39101's door are added after main is merged in. That is a new head and owes its own record.

② Semver level

@objectstack/metadata-protocol: patch matches what the diff publishes: one server-only read returns a superset of what it returned, a docblock grows, no signature or accept set moves. @objectstack/rest carries a test only and correctly has no changeset entry. Metadata-protocol: none is right: no protocol route, envelope or version moves.

Clause-②: no is right: nothing a consumer declares or reads is taken away, and the one widened read has no consumer outside the server.

Changeset, sentence by sentence:

  1. "The public form doors judge a stored form withdrawal the same way whichever package its row is bound to: the package itself, its customization pair, a package that depends on it, or no package." True for a container stored under its object's name, which is the case the change is for; see N1 for the container stored under another key.
  2. "The read behind that judgement now covers every binding of a stored body." True in the tree: storedContainerFormsUnderShippedNames reads every active package-bound view row, whichever package.
  3. "No other read changes: the view list, the form read and the authoring doors serve what they served before." True: see ④ (1) and (5).

③ Boundary flags

  • Dev flags: open_questions is empty. out_of_scope_findings names one surface note, the edit to protocol.org-scoped-write-refused.test.ts; answered by the seat's claim amendment 7341696991 (section (f) only). The diff there is six added and two removed lines inside section (f), nothing else. Closed.
  • security_findings: withheld is the card's own arrangement (scope held by the seat); nothing to answer here.
  • SQL push-down: no new query. The added read asks readActiveOverlayRows for the same (type, package) key the list read beside it asks, through the same scope, so the stored view rows are read once per call and the package-bound filter is applied in memory over rows already in hand. Pushing package_id is not null down would be a second query against the reads-once pin (public-form-reads-once-37709.test.ts); the reason is given in the code comment. No finding.
  • Cost note, no finding: each form member of each package-bound container asks shippedArtifactsOf('form', name) with no shared shipping argument, on each door request. It is the same call the package-less arm makes today.

④ Design judgment

(1) One reader. getViewItemsWithStoredForms is called by name in exactly one non-test place at this head: packages/rest/src/form-routes.ts:299-300, inside resolveFormBySlug. Every other hit across all packages is a test, a test double or a docblock (packages/cli/.../organization-ownership.withdrawal-pair.integration.test.ts, protocol.org-scoped-write-refused.test.ts, four rest test doubles). No dynamic by-name dispatch over the protocol reaches it. In form-routes.ts the returned views flow into formIntakeLayer({ views: ... }) and nowhere else; nothing of them is written to a response. Holds.

(2) Only-close property. formIntakeLayer (packages/spec/src/ui/form-intake-layer.ts) reads a views entry two ways only: oldShapeFormWithdrawals adds a name to withdrawn, and projectViewForms(...).unreadable adds slugs to closedLinks. openFormAt takes candidates from forms alone and only subtracts by those two maps. An added item can therefore add a closed name or a closed slug and nothing else; no construction of a stored row makes a closed candidate read open. isDefault is removed from each added item, and no reader of this list reads a default from it in any case. The returned envelope is a new object with a new items array: the scoped list shared with the request's other readings is not mutated. Holds.

(3) Coverage. Traced through expandRuntimeViewContainer:

  • row bound to the package itself, or a stored copy of a container its own package ships: loaders' names already; the added item is the same (package, name) and is dropped by the dedupe. Unchanged.
  • row bound to any other package: now also read under the loaders' name where a package ships that form on the object. This is the change.
  • package-less row: expandUnderOwnName's existing formMembersAPackageShips arm, or the loaders' names where the row overlays a shipped container. Skipped by the new read on entry.packageId === undefined. I checked the one way the two "package-less" predicates could disagree (a package-less row whose expansion package is derived from an overlaid shipped container): a shipped container is filed under its derived object by the registrars (the divergent-name refusal), so such a row is a copy of that package's container and takes the loaders' names. No gap.
  • a stored body's own _packageId: storedOverlayEntries states the package from the row's column alone (withRowBinding), so the body and entry.packageId cannot disagree.
  • container shapes: the predicate reads every viewKind: 'form' member the spec expander yields (form, formViews), in the expander's order. A flat viewKind: 'form' row is stored under the served name itself and was already matched in every binding (the four item rows in the test).
  • request.packageId: the doors pass none. previewDrafts: the doors pass none; the added read reads active rows only.
  • rows of a disabled package are included, as the per-package layer the doors already read includes them. Close direction.
  • the dedupe drops an added item only where the same package already holds an item of that name in the list, which is the existing own-row rule ([finding(metadata-protocol): a stored view row named exactly like a container expansion is shadowed in the object door by the expansion, while the by-name read answers the stored row #21510]) and leaves that case as it was before the change.

(4) Hard stops, each checked in the tree. No lists-only filter is added on the doors' reads, the expansions, the census, the kept reader or the lint halves: the diff adds no filter anywhere, and servedViewList / servedViewItemAnswer are untouched. The kept old-format read stays: oldShapeFormWithdrawals and projectViewForms are not in the diff. The withdrawal layer only grows. Holds.

(5) Dedupe key and read scope. formRequestScope(host) in place of inFormRequestScope(host): inside a form request both resolve to the request's shared scope, so nothing changes there. Outside one, the call now builds a call-local scope whose two members memoize the host's own reads for the length of the call; the list is the same function over the same rows, so the answer is the same and the view rows are read once for both readings. After a request has settled, the shared scope reads straight through. The list answer does not change in or out of a form request. The key _packageId + name is sound for its use: every added item carries a string package.

Contract against code, sentence by sentence. The protocol.ts docblock, the function docblock and the file header agree with the code, with the three precision notes below.

No must-fix, no should-fix.

Nits (prose faces only; none moves a behaviour):

  • N1 (nit) — changeset sentence 1 and the protocol.ts sentence "judges every package binding of a stored body alike" hold for a container stored under its object's name. A container stored under another key keeps the metadata: a view container with a bare list on another package's object silently replaces that object's packaged default view on GET /meta/view?object= — while the by-name read still serves the original #21334 rule unchanged (formMembersAPackageShips returns none when container.name is not the object). Pre-existing and identity-by-name, but the sentence reads broader than the predicate.
  • N2 (nit) — the docblock's cost sentence ("a withdrawal of a name closes that name's form in every package") understates what the added read does: the withdrawal read now also judges stored container entries under the loaders' names. That is the ruled route and fails closed; the sentence could say so.
  • N3 (nit) — "request.packageId, when given, reads the rows bound to that package, as the list read it sits beside does": the scoped list also reads the pair's and the package-less rows as stand-ins; the added read does not. No caller passes a package.
  • N4 (nit) — the dedupe key is spelt two ways (?? '' for held items, String(...) for added ones); protocol-form-reads.ts already has keyOf for this key. Equivalent today.

Implemented-by: claude/project-thread-kdr8yv
Reviewed-by: session_01WGufzhGA3zoCFquQgku4pm

VERDICT: PASS

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack@os-support-ai · os-support-ai · session_01WGufzhGA3zoCFquQgku4pm

L1 review — ACCEPT on d6729becc6a3215df6fd36f68e61aae025987688

The in-house contract L2 at CONTRACT_REVIEW_TIER is record 7341932350 on this head: PASS, no must-fix, no should-fix, nits N1–N4. Check-runs: 39 success, 18 expected-skip, 0 failed, 0 pending; Build Core, Test Core 1–12 and the workspace and consumer type checks, still running when the L2 read them, are all green. Not governed, 413 lines.

Verified on the tree:

  • One reader. getViewItemsWithStoredForms has one non-test caller, packages/rest/src/form-routes.ts (resolveFormBySlug), and its items flow into formIntakeLayer({ views }) alone. Nothing of them reaches a response, and the view list, the form read and the authoring doors are not in the diff.
  • Close only. formIntakeLayer reads a views entry only to add a withdrawn name or a closed link; candidates come from forms. The added items drop isDefault, and the envelope is a new array, so the request's shared list is not mutated.
  • Reads once. formRequestScope returns the request's shared scope inside a form request and a call-local one outside it; the added read asks readActiveOverlayRows for the same view key through the same scope, and the scoped host forwards every other member through its prototype. The reads-once pin is green on this head.
  • Dedupe. _packageId + name drops only an item the list already holds at that package.
  • Hard stops. No lists-only filter is added anywhere; the kept old-format read (oldShapeFormWithdrawals, projectViewForms) is untouched.
  • Tests. The new rest test pins both doors closed for each stored withdrawal row with the row unchanged, three open controls, and the view / form lists unchanged; section (f) of the metadata-protocol test is inside the claim amendment.
  • l1-face's changeset flag covers @objectstack/rest, but its one file is a test and the package ships dist, README.md and CHANGELOG.md only. @objectstack/metadata-protocol: patch, Clause-②: no, Metadata-protocol: none stand, and the changeset is true sentence by sentence (N1 is its precision note).

Relation. Fixes #39111. The PR is a draft: the cells that need #39101 are added on this branch after it merges, which moves the head and owes a delta of both records. The four L2 nits are folded into that push.

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack@os-support-ai · os-support-ai · session_01WGufzhPdWmTd47Fi2bKYZS

席位核对

ACCEPT — PR #39113 @ d6729becc6 (Fixes #39111; card thread of seat os-support-ai, claim 7340948798, amendment 7341696991).

落地

reading value
check-governed-merges.mjs --pr 39113 NOT governed; 413 changed lines ≤ 3000
pr-state.mjs on d6729bec 39 success · 18 expected skip · 0 failed · 0 pending; mergeable_state clean
landing-k.mjs --pr 39113 K = 9 < 15
l1-face.mjs --pr 39113 FLAGGED, one item, changeset, which does not hold: the one @objectstack/rest file is a new test; the @objectstack/metadata-protocol patch entry covers the change

State change: ready for review + auto-merge, by the owning seat; on merge it closes #39111.

@objectstack-fleet
objectstack-fleet Bot marked this pull request as ready for review December 2, 2026 11:26
@objectstack-fleet
objectstack-fleet Bot added this pull request to the merge queue Dec 2, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to failed status checks Dec 2, 2026
@github-actions

github-actions Bot commented Dec 2, 2026

Copy link
Copy Markdown
Contributor

⛔ merge queue 构建失败 — 先分诊,再决定要不要重排

队列构建 46871721865 红了。队列跑的是全量套件(PR 侧 CI 只跑 affected 子集),
所以失败的测试可能在本 PR 没碰过的包里 —— 那不是重排能修的。每次盲目重排都会让排在后面的所有 PR 重建一轮。

分类:failure —— 按下面的日志分诊。

失败的 job(日志抽取,best effort):

  • Test Core (10/12) — 失败步骤: Run this shard's tests

    @objectstack/plugin-security:test:  FAIL  src/comment-read-scope-semi-join.integration.test.ts > planReadScope scopes sys_comment.record_id by a caller-run read of the parent — sqlite > no cap on the 
      ↳ 失败原因: @objectstack/plugin-security:test: Error: Test timed out in 5000ms.
    

↳ 失败原因 是判读的关键:超时(Test timed out in … / Hook timed out in …)多半是负载/时序,不是本 PR 的回归;
断言(AssertionError: …)才指向真实的行为改变。两者的 FAIL 行长得一模一样,只有这一行能区分。

⚠️ 断言这一侧有一类例外,判据是断言在测什么,不是它是不是 AssertionError。 断言的对象是产品行为(一个值、一个形状、一次拒收)⇒ 照上面读:真实的行为改变,去查,⛔ 不要重排掉;
断言的对象是这次实验自身的有效性前提(跑完的耗时、负载下的先后、任何只在时间预算内才成立的条件)⇒ 它跟超时是同一类,同样对负载敏感,重排一次是合法的判别手段。
识别是机械的:断言的消息或它比较的值本身点名了一段时长、一个时间戳、一个耗时计数。实测过的一对 —— AssertionError: SecurityPlugin.init() ran: expected false to be true 测的是产品行为(真回归);
AssertionError: this run took over a second, so second-precision stamps could have differed too: expected 1006 to be less than 1000 测的是实验前提:它守护的那条不变式当时是绿的,同一个 head 原样重排一次即成功。
穿着 AssertionError 外衣的时间测量,仍然是时间测量。(⛔ 这只改「怎么读一次红」,不改「哪些测试可以重排」——后者由别处管。)

跨 PR 相同签名(24h,按失败测试文件聚合):

  • src/comment-read-scope-semi-join.integration.test.ts — 24h 窗口内只有本 PR 撞到过,暂不汇总(再有一个不同 PR 撞到就会自动开汇总 issue)。
  • ⚠️ 24h 评论账本没读完(超过 5 页仍未读到窗口尽头),所以上面的「不同 PR 数」是下界,不是全量。

历史信号:

  • 本 PR 过去 24h 无队列失败记录(首次)。
  • 过去 24h 队列共有 2 个失败构建(不含本次)。

分诊清单:

  1. 失败测试在本 PR 改动的包里 → 真回归,修 PR。
  2. 失败测试与本 PR 无关 → 看上面的「跨 PR 相同签名」;已有汇总 issue ⇒ flaky/环境问题实锤,去那张 issue 上谈,修好前重排只会再烧一轮全队列。
  3. 两者都不是 → 可能与同组 PR 语义冲突;等前面的 PR 落地或失败出队后再重排一次即可,不要连续重排。

Generated by Claude Code · merge-queue-triage workflow (#4859)

@github-actions

github-actions Bot commented Dec 2, 2026

Copy link
Copy Markdown
Contributor

⛔ merge queue 构建失败 — 先分诊,再决定要不要重排

队列构建 46871252761 红了。队列跑的是全量套件(PR 侧 CI 只跑 affected 子集),
所以失败的测试可能在本 PR 没碰过的包里 —— 那不是重排能修的。每次盲目重排都会让排在后面的所有 PR 重建一轮。

分类:failure —— 按下面的日志分诊。

失败的 job(日志抽取,best effort):

  • Test Core (10/12) — 失败步骤: Run this shard's tests

    @objectstack/plugin-security:test:  FAIL  src/comment-read-scope-semi-join.integration.test.ts > planReadScope scopes sys_comment.record_id by a caller-run read of the parent — sqlite > no cap on the 
      ↳ 失败原因: @objectstack/plugin-security:test: Error: Test timed out in 5000ms.
    

↳ 失败原因 是判读的关键:超时(Test timed out in … / Hook timed out in …)多半是负载/时序,不是本 PR 的回归;
断言(AssertionError: …)才指向真实的行为改变。两者的 FAIL 行长得一模一样,只有这一行能区分。

⚠️ 断言这一侧有一类例外,判据是断言在测什么,不是它是不是 AssertionError。 断言的对象是产品行为(一个值、一个形状、一次拒收)⇒ 照上面读:真实的行为改变,去查,⛔ 不要重排掉;
断言的对象是这次实验自身的有效性前提(跑完的耗时、负载下的先后、任何只在时间预算内才成立的条件)⇒ 它跟超时是同一类,同样对负载敏感,重排一次是合法的判别手段。
识别是机械的:断言的消息或它比较的值本身点名了一段时长、一个时间戳、一个耗时计数。实测过的一对 —— AssertionError: SecurityPlugin.init() ran: expected false to be true 测的是产品行为(真回归);
AssertionError: this run took over a second, so second-precision stamps could have differed too: expected 1006 to be less than 1000 测的是实验前提:它守护的那条不变式当时是绿的,同一个 head 原样重排一次即成功。
穿着 AssertionError 外衣的时间测量,仍然是时间测量。(⛔ 这只改「怎么读一次红」,不改「哪些测试可以重排」——后者由别处管。)

跨 PR 相同签名(24h,按失败测试文件聚合):

  • src/comment-read-scope-semi-join.integration.test.ts — 24h 窗口内只有本 PR 撞到过,暂不汇总(再有一个不同 PR 撞到就会自动开汇总 issue)。
  • ⚠️ 24h 评论账本没读完(超过 5 页仍未读到窗口尽头),所以上面的「不同 PR 数」是下界,不是全量。

历史信号:

  • ⚠️ 本 PR 过去 24h 已在队列失败 1 次(不含本次)。 内容未变而反复失败 ⇒ 高度怀疑 flaky 测试或与同组 PR 的语义冲突,重排不解决。
  • 过去 24h 队列共有 3 个失败构建(不含本次)。

分诊清单:

  1. 失败测试在本 PR 改动的包里 → 真回归,修 PR。
  2. 失败测试与本 PR 无关 → 看上面的「跨 PR 相同签名」;已有汇总 issue ⇒ flaky/环境问题实锤,去那张 issue 上谈,修好前重排只会再烧一轮全队列。
  3. 两者都不是 → 可能与同组 PR 语义冲突;等前面的 PR 落地或失败出队后再重排一次即可,不要连续重排。

Generated by Claude Code · merge-queue-triage workflow (#4859)

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack@os-support-ai · os-support-ai · session_01WGufzhPdWmTd47Fi2bKYZS

落地

Landing: 2026-12-02T13:01Z, re-armed once by the owning seat. The dequeue at 2026-12-02T11:48Z was Test Core 10/12 timing out on the 1,005-row semi-join case from #39100, a path this PR does not touch. That case now declares its timeout (#39127, PR #39130, merged). Head d6729becc6 is unchanged, so the landing 7343919900 and its readings stand.

State: auto-merge re-armed by the owning seat; on merge #39120 (#39101) follows.

@objectstack-fleet
objectstack-fleet Bot added this pull request to the merge queue Dec 2, 2026
Merged via the queue into main with commit da4efea Dec 2, 2026
58 checks passed
@objectstack-fleet
objectstack-fleet Bot deleted the claude/project-thread-kdr8yv branch December 2, 2026 13:32
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 size/m 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.

Forms: withdrawal reads follow-up from #39101 (scope held by the seat)

2 participants