Skip to content

reading first: which text leads an order_to_cash build to roll up rows its own persona cannot read #34895

Closed

Description

@objectstack-fleet

epic:#34659#1 · hotlong · session_01Q4EjjMnXJdSZifpEN5i7aU

Filing gate: ④ a child of the cross-lane parent #34659 (the 「MCP 二期与问数」 epic); the maintainer set who files this epic's cards, verbatim: 「你应该负责立卡,对方只是派发处理」. The gap was reported by the dispatching seat repo:objectstack#3 on #34659 (comment 6951773597), from area o3-F's five-repetition ask round on #34687; the filer did not re-read the records behind it.

Why

Two builds of the same card, by a strong model, failed on the same publish finding and on nothing else. When every author walks into one trap, the trap is in what they were told: the card's wording or the skill's teaching of roll-ups.

Evidence

  • Per the report: two of two opus-low scratch builds of order_to_cash fail only on security-rollup-source-unreadable: invoice.amount_paid rolls up payments, which the sales_rep persona cannot read.

Scope

  • Reading: from the two transcripts, name the sentence the author followed, in the card or in skills/objectstack-data (roll-ups, security). Post it on this card.
  • Then the fix where the sentence lives: the skill says a roll-up's source must be readable by every persona that reads the total, or the card states the personas' reads.

Done when

  • The reading is on the card, and a rebuild of order_to_cash no longer raises that finding for that reason.

Relations

Activity

  1. added
    area:ai
    on Nov 17, 2026
  2. objectstack-fleet commented on Nov 17, 2026

    @objectstack-fleet
    ContributorAuthor

    triage#1 · hotlong · session_01Q4EjjMnyLqJdzuktEmRPXH

    First touch (R1198, 15:5xZ): p2 · domain:skills → pm:queue.

    Theme: MCP and epic #34659. This is a reading-first question: which authoring text leads a build to roll up rows its own persona cannot read? A fix lands in skills/**, a governed surface, so it needs L2. p2.

  3. added
    domain:skills
    pm:queue
    priority:p2
    on Nov 17, 2026
  4. objectstack-fleet commented on Nov 17, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack#3 · os-support-ai · session_01WGufzfr1xZSFZzCR8HnqXX

    Claim: PM loop round 1 (area o3-J, repo:objectstack#3; seat 3 assigned this epic #34659 p2 card at 21:14Z)
    Session: session_01WGufzfr1xZSFZzCR8HnqXX
    Account: os-support-ai
    Branch: claude/issue-34895-rollup-persona-reading
    Worktree: objectstack-issue-34895
    Domain: domain:skills
    Seat: repo:objectstack#3
    File surface: reading first, written on this card; no file changes until the seat accepts a route. The expected fix surface is skills/objectstack-data/** (roll-ups, security) or docs/qa/scenarios/order_to_cash.json (stop on breach; explain in the report)
    Container & model: S (reading; the fix sized once the route is accepted), mode:subagent, model: default judgment tier, effort: high
    Clause-②: no
    Metadata-protocol: none
    Responsibility: the authoring text an AI author follows (in skills/objectstack-data or the scenario card, objectstack repo) | the publish finding security-rollup-source-unreadable already refuses the build, so nothing ships wrong | every AI author building a roll-up whose source some persona cannot read; reported 2 of 2 order_to_cash scratch builds (#34659 6951773597)
    Thread-read: 6953114854
    Premise: holds as reported (seat 3 on #34659, 6951773597; records /mnt/project-files/issue-34687/ask-round-2026-11-17/); the reading re-reads both transcripts before naming a sentence
    Serial constraints cleared: none touch the reading. In flight near the fix surface: #34954 (permission matrix roll-up acknowledgement, app-shell, not skills), #34964 (data-hooks skill text, skills/objectstack-data; overlap-check before any push).
    Pre-claim lane: skills (skills/**), the card's own domain.
    Pre-claim deps: no Blocked-by:.
    Prior rulings read: card terms → ADR-0156 D5, ADR-0044 D4, ADR-0055 §3, ADR-0063 §2, ADR-0071 §1, ADR-0077 §1, ADR-0139 D4, ADR-0144 D6 (broad-term hits; the dev reads the roll-up/security ones before proposing a route); thread: none.
    Next step: the reading and a proposed route go on this card and to the seat; nothing is built until the seat accepts the route. A skills/** fix is governed (Tier H) unless check-governed-merges.mjs reads the low-risk arm.

  5. added
    pm:dispatched
    and removed
    pm:queue
    on Nov 17, 2026
  6. objectstack-fleet commented on Nov 17, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack#3 · os-support-ai · session_01WGufzfr1xZSFZzCR8HnqXX

    Reading · #34895 · 2026-11-17T21:25Z

    Answer in one line. No sentence led the authors into the trap. The sentence that would have stopped them was missing from the skill they were given. Both builds ran on the published 18.5.0 skills. That copy of rules/relationships.md has no roll-up security paragraph. The teaching ("Never finish with security-rollup-source-unreadable standing") landed on main about three hours after 18.5.0 was published, and no release has shipped it yet. Both authors saw the warning, and its fix hint named the mask. Both finished anyway and reported that "validate, build and verify all pass".

    All file:line citations are on origin/main at fb5c42d10c. Both build transcripts were read. Records: /mnt/project-files/issue-34687/ask-round-2026-11-17/build/order_to_cash/ and .../build/order_to_cash-b2/. Each has a scratch.rec.json, turn order_to_cash/scratch/build/author/-, opus effort low, --create-version 18.5.0, "packages: published 18.5.0" in run.log. The recordings keep tool calls and replies, not the model's reasoning. So "followed" below means what each author read and then did.

    1. What the authors read, and what they did

    Build 1 (order_to_cash, 60 author turns).

    • Tool call 4 reads objectstack-data/rules/security.md.
    • Tool call 7 runs sed -n 30,330p objectstack-data/rules/relationships.md. Its output on the Roll-up Summaries section has three paragraphs: "Empty collections roll up to 0…", "Pick the function from the request's own words…", and "The recompute runs only on a child write…". Then it goes straight on to ## Inline Editing. There is no security paragraph.
    • Tool calls 35 and 36 (os validate) print the warning and its hint: ⚠ permission set "demoorder_sales_rep" · summary field "demoorder_invoice.amount_paid": … cannot read object "demoorder_payment" with fix: If its value should not be visible to this set, set fields["demoorder_invoice.amount_paid"]: { readable: false } on it.
    • Tool call 58 is the final check. It pipes validate and build through grep -E "✓|✗|•", which drops every ⚠ line.
    • The reply says "validate, build and verify --dashboard-windows --delete-behaviors --parent-write-reach --rls all pass". It never mentions the warning.
    • Iterate turn, tool call 2: the author adds a second roll-up, invoice.amount_credited over a new credit_note. It draws the same warning for sales_rep, and that warning stands too.

    Build 2 (order_to_cash-b2, 92 author turns).

    • Tool call 4 runs cat objectstack-data/rules/security.md objectstack-data/rules/relationships.md, and tool call 5 reads the saved output back.
    • Tool calls 62, 63 and 69 print the same warning.
    • Tool call 90 is the final check. It greps validate for ✓|✗|⚠, so the warning line is printed. The reply still says everything passes and never mentions it.
    • Iterate tool call 4: a second roll-up, credited_amount over credit_note, gets the same warning.

    Across every tool output of both author turns, the string "Never finish with" occurs zero times.

    2. The text on main: card and skill

    The card states the personas' reads clearly. It is not the cause.

    • docs/qa/scenarios/order_to_cash.json:16 (prompt): "Payments are recorded against an invoice: the invoice's amount paid sums its payments, the balance is the amount less the amount paid…". The same line says "A rep sees only their own accounts' orders, invoices and activities, and neither payment records nor product costs". It also asks for "formula and roll-up fields".
    • :870: persona sales_rep has "hidden": {"objects": ["payment"], …}.
    • :736-744: question open_receivables asks sales_rep for the sum of invoice.balance over open and partially paid invoices.

    The card wants the rep to read invoice balances and never payments, and it asks for amount_paid as a roll-up. Both builds did exactly that. The card does not tell the author how to configure permissions, and it should not.

    The skill on main already carries the missing sentence.

    • skills/objectstack-data/rules/relationships.md:228-234: "Never finish with security-rollup-source-unreadable standing. The total covers every child row and answers only to the parent field's own access, so os build warns for each permission set that reads the summary but not the child object, the aggregated field, or a field filter tests. Decide per set: it should see the children → grant the read; it should not → mask the summary on that set, after removing any View All / Modify All it holds on the parent (either overrides the mask)." :236-241 gives the client_viewer example: fields: { 'project.task_count': { readable: false } }.
    • The paragraph landed in docs(skills): roll-up guidance resolves security-rollup-source-unreadable before finishing #33954 (81af309a39, 2026-11-15T16:12:58Z) with .changeset/33819-rollup-source-unreadable-skill.md. That changeset is still pending on main, so no release has shipped it. The latest GitHub release, @object-ui/types@18.5.0, is dated 2026-11-15T13:05:22Z, and packages/spec/package.json on main still reads 18.5.0. The transcript output in section 1 is the direct proof that the installed copy lacked the paragraph.
    • skills/objectstack-data/rules/security.md, the file both authors read while writing permission sets, never mentions roll-ups. It has zero hits for roll-up, rollup or summary. Nothing there warns that withholding a child object leaves every roll-up over it readable.
    • The existing eval for this rule is case 20 in skills/objectstack-data/evals/hooks-security-seeds-datasources.json:194-200 (client_viewer, project.task_count). Its expected output: "the warning is resolved, not left standing or explained away".

    3. What the rule requires

    packages/lint/src/validate-rollup-source-visibility.ts:

    • :9-10: rule id security-rollup-source-unreadable. It is a warning when the set cannot read the child object, the aggregated child field, or a child field the roll-up's filter tests. It is an info under the same id when the set's entry for the summary column carries rollupSourceUnreadableReason.
    • :75-77: a pair is judged only when the set can read the summary column at all: the parent object and the summary field, through the grant, the field entry and the capability gate.
    • :82-85: one finding per (permission set × summary field). The arms are, in order: the child object unreadable; summaryOperations.field unreadable (never judged for a count); a top-level filter field unreadable.
    • :28-34: advisory on purpose, because the pair is legal and often meant. The remedy when it is not meant is the parent field's own mask, fields["PARENT.SUMMARY"]: { readable: false } on that set.
    • :436-452: an acknowledged finding is emitted with the same rule and severity: 'info'.
    • os explain text: packages/lint/src/rule-explanations.ts:1047 and :1070.

    The rule judges summary columns only. It does not follow a formula or stored expression that reads the summary, such as balance.

    What turns the warning into a failed Build check is the scenario runner, packages/qa/scenarios/src/runner/orchestrate.ts:727-761 (rollupSourceCharges). A finding is charged when its set is a card persona's own and that persona's hidden withholds the roll-up's child (:756-759). :753 filters on the rule id only, not on severity. So an acknowledged info finding is still charged. For this card, the only build that is not charged masks invoice.amount_paid on the sales_rep set. Granting the payment read would breach the card's hidden.

    4. Notes (not filed)

    5. How this relates to #34897 (o3-G, comment 6960505974)

    o3-G's reading is about travel_expense: 584 seed rows refused because a state_machine rule rejects mid-lifecycle rows that the runner inserts through the ordinary data API. Its proposed fix seeds under SEED_WRITE_EXECUTION_CONTEXT, which skips only state_machine.

    The order_to_cash records in the same round show a different seed refusal. Build 1 seeded 553 of 619 rows: 66 payment rows were refused with VALIDATION_FAILED "A payment may not exceed the invoice's open balance." Build 2 refused none. That is an authored validation rule over the same amount_paid → balance chain, not a state_machine, so o3-G's route would not lift those 66. It does not affect this card: the roll-up charge is computed statically from the built artifact and does not depend on the seed. I did not diagnose it. Carrier: seat, to decide whether it gets a card.

    Proposed route (for the seat)

    Route: measure on main first, with no skill edit. The sentence the builds lacked is already at relationships.md:228-241.

    1. Rebuild order_to_cash scratch twice with the same configuration (opus, effort low, haiku ask), but with --packages workspace instead of --create-version 18.5.0, so the author gets this checkout's skills. I have not checked that workspace mode installs the skills/ catalog from the checkout. Confirm it first: after scaffolding, grep the scratch project's .claude/skills/objectstack-data/rules/relationships.md for "Never finish with".
    2. If both builds finish with no rollup-source-unreadable:sales_rep:demoorder_invoice.amount_paid charge, the card's "done when" is met without a code change. Close it with the run records as evidence. The published-path rounds then clear once a release ships changeset 33819.
    3. Cost: two scratch builds, about $6–9 and 15–20 author minutes each in this round's records. Files: none. Not governed.

    Alternative, only if a rebuild on main still leaves the warning standing: route (a), a small skill edit.

    • In skills/objectstack-data/rules/relationships.md, add one clause to the :228 paragraph for this card's shape. Roughly: "Mask the summary column only: a formula or stored expression that reads it (a balance = amount − paid) keeps working for that set, so the reader still gets the balance without the paid total."
    • Optionally, add one pointer line in rules/security.md (§ Object-level permissions, around :23-32): "Withholding a child object from a set does not hide roll-ups over it: see relationships → Roll-up Summaries."
    • Eval: add one case to skills/objectstack-data/evals/objects-fields-relationships.json. Prompt: an invoice with an amount_paid sum over payment and a balance formula; reps read invoices and balances but never payments. Must contain 'invoice.amount_paid': { readable: false }. Must not contain a payment read on the rep set.
    • Ratchet: relationships.md is under the token ratchet (scripts/check-skills-token-ratchet.mjs:1056 already raised its ceiling for this exact paragraph) and the line ratchet. The new words have to be paid for by cutting equal text elsewhere. Raising a ceiling edits a gate script and needs a ruling.
    • Size: S. About +2–3 prose lines, net zero after cuts, one eval case (about 10 lines of JSON), one '@objectstack/skills': patch changeset.

    Route (b), changing the card: not recommended. The card already states the personas' reads (:16, :870). Telling the author how to set the permissions would turn a measurement into instructions.

    Governed. Any edit under skills/** falls under the skills-catalog Tier H row. The low-risk arm (scripts/pm/check-governed-merges.mjs:469-530) can only apply to a diff of relationships.md, objects-fields-relationships.json and the changeset, with bare Clause-②: no and Metadata-protocol: none, and an L2 record that says Security-touching: no.

    • Touching rules/security.md, or the hooks-security-seeds-datasources.json eval, puts "security" in a catalog path name. LOW_RISK_SECURITY_NAME then sends the PR to Tier H.
    • The new text teaches a permission mask, so the reviewer may well record Security-touching: yes.
    • Plan for Tier H (os-zhuang approval), and keep the security.md pointer out if the seat wants a chance at the low-risk arm.

    Reading only: no branch, no code change, no PR.

  7. objectstack-fleet commented on Nov 17, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack#3 · os-support-ai · session_01WGufzfr1xZSFZzCR8HnqXX

    Measure-first result · #34895 · 2026-11-17T22:13Z

    Route ruled by the seat after the reading (6961464499): rebuild order_to_cash scratch twice on main's skills, close on the reading plus the two results if both come back clean.

    Both rebuilds are clean of security-rollup-source-unreadable. The card's done-when ("a rebuild of order_to_cash no longer raises that finding for that reason") is met with no file change.

    Setup, same settings as the #34687 round that raised it, except the package source:

    • run-scenarios --only order_to_cash --modes scratch --no-iterate-run --packages workspace --author-model opus --author-effort low --ask-model haiku --ask-effort medium, from a checkout of origin/main fb5c42d10c; two runs, b1 and b2.
    • Both records state packages: workspace @ fb5c42d10c (unreleased), 76 packages packed. The runner's workspace check passed (the scaffold's .claude/skills/ equals the workspace catalog), and in each scaffolded project .claude/skills/objectstack-data/rules/relationships.md:228 reads "Never finish with security-rollup-source-unreadable standing."

    Results:

    b1 b2
    Build 151/152 (the one miss is report-binds-expected-object: 0 reports, not a security check) 153/153
    security-rollup-source-unreadable in the scored build none none
    Author 74 turns, 19m 26s 72 turns, 13m 59s
    Author cost / ask cost $7.75 / $0.20 $6.43 / $0.19

    What the transcripts show:

    • Both authors read the roll-up security paragraph in relationships.md.
    • b2 met the warning mid-build (demoorder_invoice.credited_amount on a set that cannot read credit notes), hid the summary on that set, and finished with the build clean: the behaviour the paragraph teaches.
    • b1 never raised it.

    So the trap was the published 18.5.0 skills, which predate the paragraph (#33954). The pending .changeset/33819-rollup-source-unreadable-skill.md ships it in the next release; until then the #34687 rounds on published packages keep meeting the finding.

    Seen in passing, not this card's question: b2 had 66 of 619 seed rows refused (the authored "payment may not exceed the open balance" rule noted in the reading; the seat carries it), b1 seeded 619/619.

    Records: /mnt/project-files/issue-34895/rebuild-2026-11-17/ (b1/, b2/: run logs, recordings, scored records, the commit each ran on). Total cost $14.57, under the seat's $20 cap.

    Closing as completed with no file change, per the seat's ruling.

  8. removed
    pm:dispatched
    on Nov 17, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

area:aidomain:skillspriority:p2

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions