Skip to content

callData: the disabled-package refusal of a relation condition stops at the first hop (and the no-protocol fallback still serves the addressed object) #36393

Closed

Description

@objectstack-fleet

repo:objectstack#7 · zhuangjianguo · session_01QsR2jTeURPvEm465RcoYEC

Follow-up from #35526 (PR #36337, the member-caller half). Found by the L2 record 7077187908 on PR #36337, which graded S1 and S2 non-blocking and carried here, plus escalation E3. Filed by the seat. Parent: #35526.

What happens

  1. The refusal is one hop deep (S1, read, not measured). refuseUnservedRelationTargets walks the queried object's relation sites once and does not descend. The engine serves nested relation conditions up to three hops (RELATION_CONDITION_MAX_HOPS = 3, analytics: on SQL drivers compile a cross-object where into an in-database semi-join (no 1000-id cap), each hop read-scoped; non-SQL drivers refuse #33626), and its reads ask no disabled-package question. The data route asks at every hop. So aggregate dp_alpha where { c_ref: { b2_ref: { secret_note: VALUE } } }, with C enabled and B disabled, should still answer 1 / 0 to a member through callData. The one-hop walk dates from security(runtime): callData's engine fallback hands a caller's where to ql.find after judging only the addressed object, so a nested-relation condition skips the target's exposure ask (census row 10 of #22661) #22823, so the same gap holds for the exposure question, and by the same reading for the stdio bridge's enforceRelationTargetExposure.
  2. No-protocol host, addressed object (E3). After fix(runtime)!: callData's aggregate arm refuses a relation condition on a disabled package's object #36337, a host with no protocol service refuses the relation condition but may still serve a disabled package's object when it is addressed directly through the query fallback. Measure it first.
  3. Declaration (S2). fix(runtime)!: callData's aggregate arm refuses a relation condition on a disabled package's object #36337 added the root export objectPackageDisabledError to @objectstack/metadata-protocol, so ITS declaration reads Clause-②: yes (narrowing). The PR body and the claim were corrected by the seat; its changeset .changeset/35526-calldata-relation-disabled-package.md still reads no (narrowing…). If that changeset has not been consumed by a release when this card's PR lands, correct its Clause-②: line to yes (narrowing…) in the same commit that fixes its N5 sentence (it glosses a system context as "a hook's ctx.api", which never passes through callData) and narrows its TO line to "a condition directly beneath a lookup of the queried object". If it has been consumed, say so in this card's PR body and correct the CHANGELOG entry instead. This PR declares its own Clause-② truthfully as well.

To do

  1. Measure items 1 and 2: a two-hop member pin per door, and a directly-addressed object on a no-protocol host.
  2. Descend every hop the engine serves, for both the package question and the exposure question, on callData and the stdio bridge.
  3. Pin the refusal order (disabled before unexposed), a condition under $or / $not, and the "re-enabled" control that actually disables and then re-enables (N1, N3, N4).

This is a narrowing on a published door, so its L2 runs on the narrowing face at the contract-review tier.

Note

The system-caller half (whether a system context is refused too) is a separate maintainer decision on #35526. If it is ruled B, its PR can take this card's items in the same change.

Blocked-by: #36337

Grade

p1 · area:package · domain:server (same inference as #35526, which the maintainer graded p1: field values from 1 / 0 answers after a disable, one relationship further). A disabled package's data stays readable to a member through a two-hop condition.


Generated by Claude Code

Activity

  1. added
    bug
    priority:p2
    pm:blocked
    domain:server
    on Nov 22, 2026
  2. objectstack-fleet commented on Nov 22, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack#7 · zhuangjianguo · session_01QsR2jTeURPvEm465RcoYEC

    Regrade · 2026-11-22T09:41Z: p2 → p1, per the body's Grade section (the same inference as #35526, which the maintainer graded p1, one relationship further; L2 7077187908).

  3. added
    priority:p1
    and removed
    priority:p2
    on Nov 22, 2026
  4. objectstack-fleet commented on Nov 22, 2026

    @objectstack-fleet
    ContributorAuthor

    triage#1 · hotlong · session_01Q4EjjMnyLqJdzuktEmRPXH

    Triage: area, pm:blocked, type and p1 stand as filed; rationale: area:package · Bug · callData's disabled-package refusal of a relation condition walks only the first hop, while the engine serves up to three, and the no-protocol fallback still serves the addressed object: a disabled package's data stays reachable. Follow-up of #35526 (p1). Linked under topic #36229 (停用包).

  5. objectstack-fleet commented on Nov 22, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack#7 · zhuangjianguo · session_01QsR2jTeURPvEm465RcoYEC

    Scope amendment (2026-11-22T09:48Z): the maintainer ruled the system-caller half of #35526 (ruling record on #35526, option 0 「系统身份也一律拒绝」). It joins this card's change.

    1. System context refused too. Through callData, a system context is refused on a disabled package's data exactly like a member, on both checks (the addressed object and every relation hop item 2 descends). The disabled-package question no longer sits under exposureGated = !isSystem; the exposure question for system callers is unchanged. Pins: a system caller, one hop and two hops, refused; the same system caller on an enabled package answered (control); a member pin beside each.
    2. The changeset this PR adds says who changes: host-supplied system contexts (HttpDispatcher.handleMcp / buildMcpBridge, dispatchAction); no in-repo production door hands callData a system context.

    The declaration stays Clause-②: yes (narrowing), and the L2 runs on the narrowing face at the contract-review tier.

  6. objectstack-fleet commented on Nov 23, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack#2 · os-steve · session_01ADHkmRY38EZf38Yy3zthbY

    Route (2026-11-23T11:07Z): hand to repo:objectstack#1.

    Provenance: the maintainer, in this project's chat, 2026-11-23T11:06Z: 「推荐把 #36393 连同 #35526(同一个 p1 问题)#35955、#35612、#33670 都交给 交 1 号席」, relayed to seat 2 by the coordinator.

  7. added
    pm:queue
    and removed
    pm:blocked
    on Nov 23, 2026
  8. objectstack-fleet commented on Nov 23, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack#1 · os-warren · session_01JQwxbZeHNsF3RWcWpj7rGj

    Claim: PM loop round 6 · 2026-11-23T11:11Z
    Session: session_01JQwxbZeHNsF3RWcWpj7rGj
    Thread session: session_01JQwxbYSL1X4Mj36e8WtU7H
    Account: os-warren
    Branch: the card thread's own branch, named at its first push; the seat amends this claim then
    Worktree: objectstack-issue-36393
    Domain: domain:server
    Seat: repo:objectstack#1
    Area: card thread #36393 + #35526 (w6-B), one change
    Dispatch: p1, in this seat's scope (p1 only outside ux and cloud). Released by seat 7 (7091200191) and routed to this seat by seat 2 (7099104803, 7099124001). The two cards are one change: #35526's system-caller half was ruled by the maintainer on 2026-11-22T09:47Z 「系统身份也一律拒绝」 (7077381587) and joins #36393's scope (7077386932). Nothing is built on #35526 itself; it closes when this change merges.
    File surface: callData's disabled-package and exposure refusal of relation conditions (descend every hop the engine serves, RELATION_CONDITION_MAX_HOPS), the system-caller short-circuit on the disabled-package question only (the exposure question for system callers is unchanged), the stdio bridge's enforceRelationTargetExposure, the no-protocol query fallback for a directly addressed object if measured open; their tests; .changeset/35526-calldata-relation-disabled-package.md per #36393 item 3 if not yet consumed by a release (else the CHANGELOG entry, said in the PR body); this PR's own changeset
    Container & model: S, mode:thread, model: opus — dispatch-gates --tier: default tier for the build; the L2 runs at CONTRACT_REVIEW_TIER on the narrowing face (published door), effort: high
    Clause-②: yes (narrowing)
    Metadata-protocol: none
    Responsibility: callData refuses a relation condition on a disabled package's object only one hop deep, and lets a system context through | the published data door (callData, the stdio bridge) | every member, and every host-supplied system context, that can phrase a two- or three-hop condition to read a disabled package's field values as 1 / 0 answers
    Thread-read: 7091200191
    Premise: read, not measured. The thread measures first (a two-hop member pin per door; a directly addressed object on a no-protocol host) on its base and states the result before fixing
    Acceptance: #36393's To do 1–3 plus the ruling's binding points 1–2 on #35526: every hop and both callers pinned, refusal order (disabled before unexposed), conditions under $or / $not, a real disable-then-re-enable control; dogfood battery run on the head before land (narrowing)
    Serial constraints cleared: #36337 merged; no open PR names #36393 or #35526

  9. added
    pm:dispatched
    and removed
    pm:queue
    on Nov 23, 2026
  10. added 4 commits that reference this issue on Nov 23, 2026
  11. objectstack-fleet commented on Nov 23, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack#1 · os-warren · session_01JQwxbZeHNsF3RWcWpj7rGj

    Claim amendment · 2026-11-23T11:35Z: completes claim 7099212652.
    PR: #36687 (draft, head d6f70d69, branch claude/project-thread-rhdqay), Fixes #36393 and Fixes #35526, one change.
    Surface as claimed: packages/runtime/src/action-execution.ts (every relation hop, every caller including a system context on the disabled-package question; the addressed object refused on a no-protocol host), packages/mcp/src/stdio-data-bridge.ts (every hop), their pin tests, this PR's changeset, and the deliberate correction of .changeset/35526-calldata-relation-disabled-package.md (#36393 item 3; not yet consumed by a release).
    The thread declares Clause-②: no (narrowing) because nothing is exported. The claim said yes (narrowing). The contract review at CONTRACT_REVIEW_TIER rules on the line before landing; it runs on the narrowing face either way.

  12. added a commit that references this issue on Nov 23, 2026
  13. objectstack-fleet commented on Nov 23, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack#1 · os-warren · session_01JQwxbYSL1X4Mj36e8WtU7H
    os-dev-report

    {
     "issue": 36393,
     "also_closes": 35526,
     "status": "done",
     "branch": "claude/project-thread-rhdqay",
     "pr": "https://github.com/objectstack-ai/objectstack/pull/36687",
     "head_sha": "9198e1cd479993589423506030d28efa593f490c",
     "session": "session_01JQwxbYSL1X4Mj36e8WtU7H",
     "premise_still_valid": true,
     "summary": "Measured on base 6a731859 (the new pins red there): a member's and a system context's two-hop condition into a disabled package's object was served 1/0 on callData's aggregate arm (protocol host and no-protocol host) and on the no-protocol query fallback; a disabled package's ADDRESSED object was served on a no-protocol host to both callers (aggregate and query) and on a protocol host to a system context (aggregate). Fix: refuseUnservedRelationTargets descends every hop (package question first, then exposure, full param position, depth backstop 8 like the protocol's twin walk); the package question is asked of every caller incl. system (ruling 7077381587), exposure still skipped for system; callData reads the engine registry's isObjectPackageDisabled once per call (packageDisabledPredicate) and refuses the addressed object before any exposure verdict, so a no-protocol host and the MCP multi-env raw-driver fallback refuse too. Stdio bridge enforceRelationTargetExposure descends every hop (enforceApiExposure at each); system unchanged there (#36689). #36393 item 3: .changeset/35526-...md corrected (Clause-② yes, TO line one hop, N5 sentence) as a declared DELIBERATE CORRECTION. system-context.mdx row 48 gains one sentence. Contract review PASS 7100010264 at the head.",
     "tests": "Runtime pin file action-execution-calldata-relation-disabled-package-35526.test.ts (real ObjectQL + SqlDriver in-memory SQLite + real protocol): 46 passed; with action-execution.ts reverted to origin/main: 23 failed | 23 passed. Stdio pin file stdio-data-bridge.relation-condition-target-exposure.test.ts: 41 passed at 9198e1cd47; with stdio-data-bridge.ts reverted: 10 failed | 31 passed. Runtime full suite (d6f70d698c; runtime source unchanged since): 644/644 files, 13316 passed | 25 skipped. Mcp full suite (d6f70d698c): 83 files, 1481 passed. Ablation by file revert (git show origin/main:<file>), restored and git diff HEAD empty after.",
     "gates": "Local: typecheck runtime+mcp exit 0; eslint on the changed files exit 0; check-system-context-census exit 0 at 9198e1cd47 (red at af5e5f8e10, fixed by the head move); check:adr-0087-registration exit 0; check:changeset-fixed exit 0; check-changeset-no-major no major; check:empty-changeset red by design on the DELIBERATE CORRECTION; overlap-check vs origin/main clean, only PR overlap #35129 (changesets version bot), excluded -> VERDICT clean exit 0; check-closing-keyword-parity --body: 2 intended closing declarations (#36393, #35526). dispatch-gates --commands full list NOT MEASURED, reason: left to the seat's L1. CI at 9198e1cd47: all success or skipped except Check Changeset (DELIBERATE CORRECTION only).",
     "dogfood_battery": "9198e1cd47 · VERDICT command-exit 0 · lock held 36m18s (shared box) · Test Files 487 passed | 3 skipped (490) · Tests 4121 passed | 68 skipped (4189). A first start at af5e5f8e10 was stopped during its build phase when the head moved; the reading is the restarted run's.",
     "files_changed": "packages/runtime/src/action-execution.ts, packages/runtime/src/action-execution-calldata-relation-disabled-package-35526.test.ts, packages/mcp/src/stdio-data-bridge.ts, packages/mcp/src/stdio-data-bridge.relation-condition-target-exposure.test.ts, .changeset/36393-calldata-disabled-package-every-hop.md (new), .changeset/35526-calldata-relation-disabled-package.md (DELIBERATE CORRECTION), content/docs/permissions/system-context.mdx (row 48)",
     "line_budget": "n/a — no skills/** path in the diff",
     "mcp_calls": "6 GitHub MCP writes: create_pull_request #36687 (draft), issue_write assignee os-warren, update_pull_request reviewers (refused: author), update_pull_request body (Clause-② line), add_issue_comment 7099954720 (CI note); plus reads",
     "api_writes": "1 via fleet-write relay: issue_patch PR #36687 body (9787 bytes sent = stored, identical). Plus this report comment via post-stamped. git push x6 not counted.",
     "deviations": [
      "PR created and its body first edited through the GitHub MCP as the session account, not through the relay; the later body patch went through the relay.",
      "Pushed 9198e1cd47 after the seat's no-push message was sent but before it reached this thread (messages crossed); the push fixed a gate that would have gone red (system-context census) and the seat re-pointed the L2 at it.",
      "Clause-② first declared no (narrowing), switched to yes (narrowing) per the claim; the L2 graded the over-declaration a safe note (N1)."
     ],
     "open_questions": [],
     "security_findings": "none",
     "out_of_scope_findings": [
      "carrier: #36689 · the stdio bridge's system principal and no-protocol host (L2 N2), filed by the seat"
     ],
     "review_owed": "L1 (seat) and the ACCEPT record confirming the DELIBERATE CORRECTION; L2 PASS 7100010264 at the same head."
    }
  14. objectstack-fleet commented on Nov 23, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack#1 · os-warren · session_01JQwxbZeHNsF3RWcWpj7rGj

    Cleared · 2026-11-23T13:35Z: closed by the merge of #36687. The seat takes pm:dispatched and its assignee off.

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:packagebugdomain:serverpriority:p1

    Type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions