Repository navigation
Description
立卡门类别:③ 维护者直派(专题 #39077 的子卡)。Source: topic #39077
thread · os-support-ai · session_01WGufzirjTJ1sVFGR5sBPSL
Blocked-by: #39080, #39081
Parent: #39077 · M2 读取口 · card S3 of the epic's milestone table
定级:area:data · Feature · priority:p1 set by the maintainer (see the Ruling-ref comment) · reach: n/a (new capability, maintainer direct) · evidence: read (isolated analysis on #39077, Served-tier: CONTRACT_REVIEW_TIER, tier verified)
维护者速读
- 新增一个读取口:给出列表当前的筛选,返回这些记录上的评论串(按看的人的权限),给列表页评论栏用。
业务理由:维护者原话「设计列表页本身整个对象的评论入口」「用fable 分析,并立专题卡, p1」「按推荐」——在列表页上直接看当前视图里各条记录的评论串、回复和解决,不用一条条点进记录。已定的九条规则和七条待定的结论在 #39077 正文与其评论里,本卡不复述。
动手的读者:席位为本专题开的专区(维护者「这个专题直接派发吧,并发5」「开一个专区派发」),os-dev 按本卡施工。
Dedupe: 评论 列表 in:title, comments panel list view, view comments feed, list page comments, comments across records, Attio comments (objectstack, incl. closed) → no open card covers this; related #36062 (closed, origin topic), #35947 (open, paused sibling topic).
Scope and acceptance
§N below points at the English analysis inside #39077.
- Layer: spec + backend (plugin-audit) + SDK ·
area:data· Feature · size L · p1 - Scope:
- Spec-first: request and response schemas for
POST /api/v1/comments/threads/queryinpackages/spec/src/api/
(strict body; limits as constants), regenerated artifacts committed. - The door in plugin-audit's comment registrar, steps 1–6 of §5; a ledger row; an SDK method so the row is
sdk, not a newgap; advertised wherever the comment doors are advertised and nowhere it is not mounted. - Reference docs for the route (the API page that documents the comment doors).
- Spec-first: request and response schemas for
- Acceptance (all via HTTP against a booted showcase, as two members with different row scope):
- With a filter selecting 3 of an object's records, the answer holds only top-level comments on those 3, newest
first, each with the record's id and name, its reply count and at most three latest repliers. - The same request by a member who cannot read one of the 3 records omits that record's threads; by a member
with no read on the object it is the object read's own refusal. showResolvedabsent ⇒ no resolved thread;true⇒ they appear.onlyMine: true⇒ only threads the caller
started, replied in or is mentioned in.limit+cursorwalk every thread once with no repeat while a new comment is posted between pages.- An unknown body key, any query parameter,
limitout of range ⇒VALIDATION_ERROR/ 400 and the engine was
never called; a filter on an unreadable field ⇒PERMISSION_DENIED; an object with feeds off ⇒ 403; anonymous
⇒ 401. - On a view larger than the id cap the answer is still complete on SQLite and PostgreSQL (seed > 1000 matching
records), and the threads statement is one statement (query log). - No new error code;
ERROR_CODE_LEDGERdiff is empty.
- With a filter selecting 3 of an object's records, the answer holds only top-level comments on those 3, newest
- Order: see the
Blocked-by:line at the top of this card. - Clause-②: yes (widening) — a new public route, schema and SDK method.
- Metadata-protocol: none
- Likely files: a new
packages/spec/src/api/*.zod.tsbesiderecord-page.zod.ts,
packages/plugins/plugin-audit/src/comment-routes.ts(registerCommentDoorsRoutes),
comment-route-ledger.ts,audit-plugin.ts,packages/client/src/,content/docs/api/data-api.mdx.
Generated by Claude Code
Activity
os-support-ai commentedon Dec 2, 2026
Ruling-ref: priority:p1 — maintainer, project thread, 2026-12-02: 「用fable 分析,并立专题卡, p1」 (07:13Z) and 「按推荐」 (07:36Z); recorded on #39077.
thread · os-support-ai · session_01WGufzirjTJ1sVFGR5sBPSL
Generated by Claude Code
os-support-ai commentedon Dec 2, 2026
Card thread: yes — per pm-dispatch
dispatch-runbook.md卡线程 (big card = L/XL or contract change): size L, Clause-②: yes, and non-testpackages/spec/src/**paths (new route schemas). Not a zonemode:subagentcard.thread · os-support-ai · session_01WGufzirjTJ1sVFGR5sBPSL
Generated by Claude Code
objectstack-fleet commentedon Dec 2, 2026
repo:objectstack@os-support-ai · os-support-ai · session_01WGufzhPdWmTd47Fi2bKYZS
Carried from S1 (#39080, PR #39100, landing record 7341500134) · 2026-12-02T09:48Z · for whoever builds this card:
PlanReadScopeOptionsandReadScopeComparandexported frompackages/objectql/src/index.ts. Setup navigation has ten new group anchors; a contribution to a retired group id still lands in the right group (#39050) #39053's PR feat(setup): ten Setup group anchors; a nav group's renamedFrom keeps retired ids working (#39053) #39092 holds that file now. Add the exports after feat(setup): ten Setup group anchors; a nav group's renamedFrom keeps retired ids working (#39053) #39092 merges, and name the file on this card's claim.OS_TEST_POSTGRES_URLis not provisioned for plugin-security. If this card's threads read joins the same leaf, either give the Postgres cell a CI carrier here or record it as not measured in CI, with the local Postgres 16 run named.objectstack-fleet commentedon Dec 2, 2026
repo:objectstack@os-support-ai · os-support-ai · session_01WGufzhPdWmTd47Fi2bKYZS
Carried from #39080's ADR-0139 note PR (#39124) · 2026-12-02T10:47Z: a planned leaf from
ObjectQL.planReadScopecarries the scope of the context it was planned under. This card's read must plan and place it per request and never cache it across requests or users. Pin that with a two-user test.objectstack-fleet commentedon Dec 2, 2026
repo:objectstack@os-support-ai · os-support-ai · session_01WGufzhPdWmTd47Fi2bKYZS
Claim: card thread of seat repo:objectstack@os-support-ai, epic #39077 (list-page comments, the maintainer's 「这个专题直接派发吧,并发5」), M2 card S3
Session:
session_01WGufzhPdWmTd47Fi2bKYZSThread session:
session_01WGufzfHCzQWh6PeQnvToFzAccount:
os-support-aiBranch:
claude/project-thread-nfg4vp(restarted frommainafter #39110 merged)Domain:
domain:serverSeat:
repo:objectstack@os-support-aiFile surface:
packages/spec/src/api/comment-threads.zod.ts(new) andcomment-threads.test.ts(new),packages/spec/src/api/index.ts; regeneratedpackages/spec/authorable-surface/api.json,packages/spec/declaration-map/api.jsonandcontent/docs/references/api/comment-threads.md(regenerated, never hand-edited);packages/plugins/plugin-audit/src/comment-threads-query.ts(new) with its unit and integration tests,comment-routes.ts,comment-routes.test.ts,comment-route-ledger.ts,comment-route-ledger.conformance.test.ts,audit-plugin.ts,index.ts;packages/objectql/src/index.ts(exportsPlanReadScopeOptionsandReadScopeComparand, N3 of 7341533575);packages/client/src/index.tsand a client test (the SDK method);packages/runtime/src/domains/comments.ts(reason: only if the comment doors are advertised there);packages/qa/dogfood/test/comment-threads-query.dogfood.test.ts(new);content/docs/api/data-api.mdx; a changeset. Stop on breach; explain in the report.Container & model:
L,mode:card-thread,model: TIER_DEFAULT (dispatch-gates --tier prints no MANDATORY line),effort: high; contract-tier L2 at CONTRACT_REVIEW_TIER, in-house.Clause-②: yes (widening)
Metadata-protocol: none
Responsibility:
n/a — feature cardPremise: S1 (#39100,
ObjectQL.planReadScope) and S2 (#39110,sys_comment.participants) are merged onmain81112d2. Per epic ruling 7338398195: a dedicated read returns the comment threads on the records the current view selects, where the current view is the saved filter plus the viewer's temporary filters, and the search box does not count (item 3). It covers only threads the viewer may read, and the SQL datasource only; MongoDB and OData refuse under the engine's existing rules. The planned leaf is planned and placed per request and never cached, pinned by a two-user test (7343013270). The Postgres cell runs locally on Postgres 16 and is named in the PR, recorded as not measured in CI (N5).Serial constraints cleared:
check-handover.mjs --inflightmeets #38894 (seatrepo:objectstack@os-justin, claim 7336726260) at the directorypackages/qa/dogfood/test/only. This card adds one new file there with a name of its own and edits nothing else in that directory. #39092, the last claim onpackages/objectql/src/index.ts, is merged.objectstack-fleet commentedon Dec 2, 2026
repo:objectstack@os-support-ai · os-support-ai · session_01WGufzhPdWmTd47Fi2bKYZS
Claim amendment · 2026-12-02T12:59Z · claim 7343360143.
File surface (added), for two gates this change turns red (+4/−2 in all):
packages/spec/llms.txt: schema count 234→235, api domain 37→38, and "Comment Threads" in the api row (check:llms-txt).scripts/cross-package-test-inputs.mjsandturbo.json: declare plugin-audit'scomment-route-ledger.tsas an input of the client test, because the client URL-conformance sweep importsCOMMENT_ROUTE_LEDGER(check:cross-package-test-inputs).Generator outputs that follow from the new schema (api-surface, export-origins and json-schema manifests, the spec reference READMEs and
api/comment-threads.md,content/docs/references/index.mdx, the unknown-key strictness ledger'sapi.md) are written by the generators, never by hand.Scope ruling: the threads read is served where the self-hosted comment registrar mounts it, and advertised only there. Serving it on the hosted dispatcher needs files this claim does not hold, one of them under Print: the PDF a print attaches carries no print-origin marker, so an app that reacts to a print must key on the file name, which #36801 changed #38894, so it goes to a follow-up card under 专题:列表页右上角的评论入口——看当前视图里各条记录的评论串,可回复、可解决,不能写新评论 #39077.
objectstack-fleet commentedon Dec 2, 2026
repo:objectstack@os-support-ai · os-support-ai · session_01WGufzfHCzQWh6PeQnvToFz
os-dev-report
{ "issue": 39084, "status": "done", "branch": "claude/project-thread-nfg4vp", "pr": "https://github.com/objectstack-ai/objectstack/pull/39135", "session": "session_01WGufzfHCzQWh6PeQnvToFz", "premise_still_valid": true, "summary": "POST /api/v1/comments/threads/query built on head cb3695e7 (10 commits on 81112d2d, 31 files). Spec: strict CommentThreadsQueryRequestSchema / CommentThreadsQueryResponseSchema + limit constants (comment-threads.zod.ts). plugin-audit comment-threads-query.ts mounted from registerCommentDoorsRoutes: every read as the caller; filter via parseFilterAST; ObjectQL#planReadScope planned per request (never cached, two-user pin); ONE threads find (top-level, open unless showResolved, participants $contains when onlyMine, keyset (created_at,id) desc, limit+1); page replies (keyset-paged, caller) for reply count at any depth + latest 3 repliers; one read of the object for display names. Ledger row sdk comments.queryThreads; client.comments.queryThreads; objectql exports PlanReadScopeOptions and ReadScopeComparand; data-api.mdx section; changeset patch x4. Claim amendment 7346184382 commit: llms.txt counts, cross-package-test-inputs.mjs + turbo.json declare comment-route-ledger.ts as a client test input. Deviations: self-hosted mount only (seat ruling; hosted follow-up #39134); inline dogfood stack, not showcase (needs a no-read persona); reply counts from the page's replies, not a grouped count by parent_id (depth needs roots); reference page at the generator's path packages/spec/docs/references/api/comment-threads.md; index on (object_name, created_at) NOT MEASURED. Postgres: local PG 16.15 run of the dogfood file at c4d42665, 17/17 incl. 4 live-postgres; not measured in CI (N5).", "tests": "plugin-audit 118 files / 1944 passed; client 60 / 841; objectql 646 / 14685; spec 922 / 29119 (1 todo); dogfood comment-threads-query 17/17 with OS_TEST_POSTGRES_URL. New: comment-threads-query.test.ts 19, comment-threads-query.integration.test.ts 7, comment-threads.test.ts 9, ledger conformance +1, client URL conformance +2. Ablation: planned scope cached in a module-level ??= -> 'two users through one door' red, restored.", "gates": "dispatch-gates --ran at c4d42665: 127 derived, 127 run, 0 NOT-MEASURED, 0 UNRUN. check:llms-txt and check:cross-package-test-inputs exit 1 until the amendment commit, exit 0 on this head. Four first exit 3 (prerequisites) cleared and rerun exit 0: plugin-teardown self-test, skill-examples, i18n, dual-build-cjs-loads. Typecheck spec/plugin-audit/client/objectql/dogfood exit 0; eslint changed sources exit 0; ERROR_CODE_LEDGER diff empty. PR check-runs: pending at report time.", "mcp_calls": "0", "api_writes": "3 — relay issue_create #39134 (hosted follow-up, seat-ordered), relay pr_create #39135, this report comment", "classifier_refusals": [], "open_questions": [], "security_findings": "none", "out_of_scope_findings": [ "carrier: PR · noted, not filed: sys_comment index leading with (object_name, created_at) for this read not measured (no plan read; object file outside the claim)" ] }docs(changeset): #39084 declares Metadata-protocol added and grades s…
chore(ui): the spec-symbol guard allows the collaboration CommentThre…
objectstack-fleet commentedon Dec 2, 2026
repo:objectstack@os-support-ai · os-support-ai · session_01WGufzhPdWmTd47Fi2bKYZS
Claim amendment · 2026-12-02T13:33Z · claim 7343360143, extends amendment 7346184382.
ui/scripts/check-spec-symbol-derivation.mjs, one ALLOW entry with its reason (commit 750a1ea). The new spec exportCommentThread(a schema type) shares its name with@object-ui/collaboration's published React componentCommentThread. The two live in different layers, and the guard already allows that, as it does forEmptyState. The seat rules ALLOW over a rename: renaming either symbol would change a published name for no behaviour gain. Contract review r4 PASS 7347045361 agrees.Metadata-protocol: none. The new api schemas enter spec's authorable surface, so the declaration isMetadata-protocol: added, with@objectstack/specgraded minor, as PR feat(plugin-audit,spec,client): one read returns the comment threads on the records a list filter selects, as the caller #39135 now states (commit fb20c06). The PR's line governs.