Skip to content

fix: keep your account's model access in managed worktrees and other workspaces - #207277

Merged
obviyus merged 5 commits into
mainfrom
core/catalog-entitlement-owner
Nov 28, 2026
Merged

obviyus merged 5 commits into
mainfrom
core/catalog-entitlement-owner

Conversation

@obviyus

@obviyus obviyus commented Nov 28, 2026 •

Copy link
Copy Markdown
Collaborator

What Problem This Solves

A chat can require an OpenAI access program that the account offers. When that chat's session is bound to a managed worktree, turns that run in the worktree (for example, a subagent reporting back to its parent) were refused before any model request with "This … program is not advertised for the current account, model, and runtime". The same account in the same chat passed for ordinary messages. Users saw subagent results fail to come back.

User Impact

Turns that run in a workspace other than the agent's main one (managed worktrees, child sessions, cron jobs with a workspace, compaction with a requested workspace) now see the same account facts as the main workspace. The access check is unchanged: a program is still allowed only when the account's current credential advertises it, and no request reaches a model without it.

Why This Change Was Made

The facts an account is offered (providerOutcomes) belong to the agent and its credential, not to a directory. They live in the prepared catalog inventory, and every inventory row is already guarded per provider: a source fingerprint (provider config including the resolved key, the providing plugins' versions and install hashes, auth profiles and order, env) plus the credential identity. But the inventory was stored per catalog owner, and owners are keyed by workspace because a workspace can add plugins. So an owner for a second workspace started empty, and in static mode (turns never rediscover) it had no account facts. Only chat.send avoided this, because it deliberately prepares its catalog from the main workspace.

Now a non-configured owner is offered the configured owner's inventory for the same agent, and the existing retention guards decide which rows hold for its own config and credentials. The seed is used only when the plugin set matches exactly (a workspace plugin could otherwise provide the same provider id with different code). The owner key, plugins and models stay per workspace. The seed applies at retention time, so a rejected seed does not hide the provider's generated models.

Named edges, not coded:

  • If the configured owner has recorded discovery failures, a seeded worktree run owner retries that discovery until its lease ends.
  • Before the configured owner's first discovery, or right after a provider config or sign-in change and before rediscovery completes, a worktree turn can still be refused. A main-workspace turn recovers on rediscovery. This is not a regression.

Evidence

  • New prepared-model-runtime.workspace-inventory.test.ts. Each case prepares the worktree turn with the dispatch's plugin generation, as report turns are prepared. The entitlement is keyed by account and credential identity:
    • gives a worktree run with the same direct key only the account facts of its own credential and … with the same stored account … see the main workspace's outcomes. Both fail on the merge base ([]).
    • … with a different direct key …, … with a second stored account … and … with a signed-out credential … inherit nothing.
    • drops the account facts on the next worktree turn after the credential rotates: after a sign-in change, a turn pinned to the old generation is refused ("superseded"), and the next turn sees no old-account facts.
    • The negative cases pass on the merge base by construction, since it never shares facts. With the retention credential guard disabled, the second-account, signed-out and rotation cases fail. The direct-key case is caught separately by the provider-config fingerprint, which includes the resolved key.
  • Real in-process Gateway fixture (synthetic HTTP only; not committed because it clones the repository): chat.send and then a requester-settle completion into a parent bound to a real managed worktree. Merge base: the ordinary turn passes and the completion is refused (OPENAI_ACCESS_PROGRAM_UNAVAILABLE, not advertised). This branch: both pass. The worktree-bound chat.send turn passes on both.
  • Prepared model runtime, prepared model catalog and access-program suites plus every direct importer of the changed files: 64 files, 475 tests, all pass.
  • findConfiguredOwnerCandidates moved unchanged to prepared-model-runtime.configured-owner.ts so the owner module stays within its line cap.
  • Production (read-only): every refusal of this kind came from a session bound to a managed worktree. Each worktree was created minutes to hours before the first refusal, and none of those sessions ever had a successful report.

… facts

- A non-configured owner for another workspace of the same agent is offered the configured
  owner's catalog inventory; the existing per-provider source and credential guards decide
  which rows hold. The seed applies only for an identical plugin set.
- Worktree turns (subagent reports, children, cron, compaction) now see the same account
  facts as the main workspace, so the access check no longer refuses a program the
  credential advertises. The access check is unchanged.
- findConfiguredOwnerCandidates moves unchanged to a sibling module (owner line cap).
@clawsweeper

clawsweeper Bot commented Nov 28, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

ClawSweeper review complete

ClawSweeper finished reviewing this revision. The review result is being finalized.

View the workflow run.

@openclaw-barnacle openclaw-barnacle Bot added agents Agent runtime and tooling size: S labels Nov 28, 2026
@clawsweeper clawsweeper Bot added P1 High-priority user-facing bug, regression, or broken workflow. impact:auth-provider Auth, provider routing, model choice, or SecretRef resolution may break. clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. labels Nov 28, 2026
- Split the seed off before callbacks capture the catalog-access params, so a workspace
  runtime never pins the configured owner's inventory; retention reads it once.
…tial identity

- A second stored account, a signed-out credential, a different direct key and a rotated
  credential never inherit another credential's advertised outcomes; a turn pinned to the
  pre-rotation generation is refused.
@clawsweeper clawsweeper Bot added rating: 🧂 unranked krab Not merge-ready due to missing proof or serious correctness/safety concerns. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. and removed clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. labels Nov 28, 2026
@clawsweeper

clawsweeper Bot commented Nov 28, 2026

Copy link
Copy Markdown
Contributor

Codex review: passed.

What this changes

This PR seeds workspace-scoped model inventories from the configured agent’s inventory when plugin identity, provider source, and credentials match.

Example: Agent pro uses key-a, and a subagent reports into its parent’s managed worktree with the same credential.

  • Before: The worktree runtime lacks the account’s advertised access programs and refuses the report before inference.
  • After: The worktree runtime retains matching account facts, allowing the existing access check to evaluate them.

Review scores

Measure Result What it means
Overall readiness 🧂 unranked krab (1/6) The patch is focused and source-consistent, but required real-behavior proof is mock-only and failed CI gates remain unattributed.
Proof confidence 🧂 unranked krab (1/6) Real behavior proof is not required for maintainer- or bot-authored pull requests.
Patch quality 🦐 gold shrimp (3/6) No actionable review findings were identified.

Product

Kind: Bug fix · Worth it: Yes · Fix scope: Complete
User problem: Subagent results can fail to return when their parent runs in a managed worktree, despite the same account succeeding in ordinary chat.
Reason: The repair restores consistent account facts across execution workspaces without changing access policy or adding configuration; maintainer authorship establishes direction.

Merge readiness

✅ Ready for maintainer review

Keep open: this PR addresses a source-confirmed loss of account facts in workspace-scoped runtimes that remains on main; no definite introduced production defect was found.

Reviewed head: 7394ab5ab16b332b70391f3ce7fb66b899131569

Before merge

None.

Findings

None.

Agent review details

How this fits together

Prepared model runtimes combine agent configuration, credentials, plugin generations, and discovered catalogs into workspace-scoped snapshots consumed by model selection and inference admission.

flowchart TD
  A[Configured agent inventory] --> C[Retention guards]
  B[Workspace credentials and plugins] --> C
  C --> D[Workspace runtime snapshot]
  D --> E[Existing access program check]
  E --> F[Model request]
Loading

Technical review

Best possible solution:

Keep the seed in the existing runtime publication and retention owners, preserving credential isolation and workspace-specific plugin selection.

Do we have a high-confidence way to reproduce the issue?

Source traces the failure from workspace-keyed ownership through static run preparation to missing provider outcomes consumed by the access check; the author also reports a base-failing Gateway fixture, but this review ran no target code.

Is this the best way to solve the issue?

This is a focused repair at the existing inventory owner: it reuses established identity guards, preserves workspace isolation, and separates the seed from persistent callback captures.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against 5f6a68b9b13c.

Provenance checked

  • Workspace-scoped runtime ownership keeps the original intent (06f5f73: Lifecycle-owned model discovery consolidates catalogs, authentication, and plugin generations; later startup work preserves distinct workspace/plugin facts.)
  • Provider inventory retention keeps the original intent (ec7c8bb: Preserve admitted catalog facts across publication changes while retaining source, credential, and generation boundaries.)
  • Persistent callback lifetime keeps the original intent (5914641: Avoid callbacks retaining publication batches and retired catalogs; the seed is destructured away before persistent callbacks capture parameters.)

Testing

Proof path: in-process harness.

Security

None.

Evidence

What I checked:

  • Current main retains the defective boundary: Main reads inventory only from the current workspace owner, while run acquisition defaults to static catalog preparation; a new workspace owner therefore lacks the configured owner’s discovered account outcomes. (src/agents/prepared-model-runtime.catalog-source.ts:115, 5f6a68b9b13c)
  • Introduced change preserves existing identity guards: The seed requires an identical installed-plugin fingerprint, then passes through the existing provider-source and credential comparisons; workspace owner keys and the access-program check remain unchanged. (src/agents/prepared-model-runtime.catalog-source.ts:119, 7394ab5ab16b)
  • Credential-boundary regression coverage: The added cases exercise matching and different direct keys, matching and different stored accounts, sign-out, and next-turn credential rotation through real runtime acquisition with mocked discovery. (src/agents/prepared-model-runtime.workspace-inventory.test.ts:104, 7394ab5ab16b)
  • Supplied proof scope: The complete body reports base failures for both positive sharing cases and a successful in-process Gateway reproduction using synthetic HTTP; it supplies no real-model execution capture. Both discussion comments are review-status messages. The body was read in full against supplied source revision 76620ca13e68166f8152fd3395a16e65fd124224c38c7a3716fcb31f465ef245. (7394ab5ab16b)
  • Required CI remains unresolved: The reviewed head has failed architecture, changed-lint, and core test-type jobs. Lint annotations identify files outside the introduced diff; architecture and type annotations provide no actionable source diagnostic. Job-log retrieval redirects to a blocked storage host, so these failures cannot be classified confidently as diff-caused or external. (7394ab5ab16b)
  • Prior retention contract: The earlier catalog repair preserves discovered rows only when provider source and credentials remain valid; this PR reuses that contract rather than adding a second entitlement decision. (src/agents/prepared-model-runtime.catalog-source.ts:137, 204ff9770617)

Likely related people:

  • Ayaan Zaidi: Raw commit 204ff97 adds src/agents/prepared-model-runtime.catalog-source.ts:116 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: 204ff9770617; files: src/agents/prepared-model-runtime.catalog-source.ts)
  • Peter Steinberger: Raw commit ec7c8bb adds src/agents/prepared-model-runtime.catalog-source.ts:105 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: ec7c8bb9454b; files: src/agents/prepared-model-runtime.catalog-source.ts)
  • Vincent Koc: Raw commit 5914641 adds src/agents/prepared-model-runtime.owner.ts:469 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: 5914641ef824; files: src/agents/prepared-model-runtime.owner.ts)

PR surface

Source +22, Tests +165. Total +187 across 7 files. Added test files: 1.

View PR surface stats
Area Files Added Removed Net
Source 6 51 29 +22
Tests 1 165 0 +165
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 7 216 29 +187

Preflight source

Source unknown. Source comparison at the observed PR snapshot only. Completion is self-reported; body, policy, tests, execution, and report bytes are not verified.

Review metrics

Metric Value Why it matters
Production versus test delta Production +51/-29 lines; tests +165/-0 lines Production growth is narrow seed plumbing plus relocation of an existing selector; tests protect distinct credential-sharing boundaries.

Labels

Label changes:

  • add rating: 🧂 unranked krab: Overall readiness is 🧂 unranked krab; proof is 🧂 unranked krab and patch quality is 🦐 gold shrimp.
  • add status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR.

Label justifications:

  • rating: 🧂 unranked krab: Overall readiness is 🧂 unranked krab; proof is 🧂 unranked krab and patch quality is 🦐 gold shrimp.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR.

Rank-up moves

Optional improvements that raise the rating; they are not merge blockers.

  • Attach the real-Gateway evidence described in the proof assessment.
  • Classify the failed CI checks and repair any failure attributable to this PR.

Rating scale

6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior.

Workflow

ClawSweeper edits this one comment on every review. Comment @clawsweeper re-review for a fresh review only. Repair and merge execution lanes are retired.

Reviewed November 28, 2026, 2:02 AM ET / 07:02 UTC.

@obviyus
obviyus merged commit 3b899c3 into main Nov 28, 2026
116 checks passed
@obviyus
obviyus deleted the core/catalog-entitlement-owner branch November 28, 2026 08:27
@obviyus

obviyus commented Nov 28, 2026

Copy link
Copy Markdown
Collaborator Author

Landed.

  • Bug: turns that ran in a workspace other than the agent's main one (for example, a subagent reporting back into a chat bound to a managed worktree) started with an empty account record. A required access program was then refused before any model request, even though the account offers it.
  • Fix: such an owner now starts from the agent's main account record. The existing per-provider config and credential checks decide which facts hold, and the record is used only for an identical plugin set. The access check itself is unchanged.
  • Proof: a real in-process Gateway test was refused on main and passes here. New tests show that a second account, a signed-out credential, a different direct key and a rotated credential never inherit another credential's outcomes. With the credential guard disabled, those cases fail. CI is green and the local review is clean.

github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Nov 29, 2026
…workspaces (openclaw#207277)

## What Problem This Solves

A chat can require an OpenAI access program that the account offers. When that chat's session is bound to a managed worktree, turns that run in the worktree (for example, a subagent reporting back to its parent) were refused before any model request with "This … program is not advertised for the current account, model, and runtime". The same account in the same chat passed for ordinary messages. Users saw subagent results fail to come back.

## User Impact

Turns that run in a workspace other than the agent's main one (managed worktrees, child sessions, cron jobs with a workspace, compaction with a requested workspace) now see the same account facts as the main workspace. The access check is unchanged: a program is still allowed only when the account's current credential advertises it, and no request reaches a model without it.

## Why This Change Was Made

The facts an account is offered (`providerOutcomes`) belong to the agent and its credential, not to a directory. They live in the prepared catalog inventory, and every inventory row is already guarded per provider: a source fingerprint (provider config including the resolved key, the providing plugins' versions and install hashes, auth profiles and order, env) plus the credential identity. But the inventory was stored per catalog owner, and owners are keyed by workspace because a workspace can add plugins. So an owner for a second workspace started empty, and in static mode (turns never rediscover) it had no account facts. Only `chat.send` avoided this, because it deliberately prepares its catalog from the main workspace.

Now a non-configured owner is offered the configured owner's inventory for the same agent, and the existing retention guards decide which rows hold for its own config and credentials. The seed is used only when the plugin set matches exactly (a workspace plugin could otherwise provide the same provider id with different code). The owner key, plugins and models stay per workspace. The seed applies at retention time, so a rejected seed does not hide the provider's generated models.

Named edges, not coded:
- If the configured owner has recorded discovery failures, a seeded worktree run owner retries that discovery until its lease ends.
- Before the configured owner's first discovery, or right after a provider config or sign-in change and before rediscovery completes, a worktree turn can still be refused. A main-workspace turn recovers on rediscovery. This is not a regression.

## Evidence

- New `prepared-model-runtime.workspace-inventory.test.ts`. Each case prepares the worktree turn with the dispatch's plugin generation, as report turns are prepared. The entitlement is keyed by account and credential identity:
  - `gives a worktree run with the same direct key only the account facts of its own credential` and `… with the same stored account …` see the main workspace's outcomes. Both fail on the merge base (`[]`).
  - `… with a different direct key …`, `… with a second stored account …` and `… with a signed-out credential …` inherit nothing.
  - `drops the account facts on the next worktree turn after the credential rotates`: after a sign-in change, a turn pinned to the old generation is refused ("superseded"), and the next turn sees no old-account facts.
  - The negative cases pass on the merge base by construction, since it never shares facts. With the retention credential guard disabled, the second-account, signed-out and rotation cases fail. The direct-key case is caught separately by the provider-config fingerprint, which includes the resolved key.
- Real in-process Gateway fixture (synthetic HTTP only; not committed because it clones the repository): `chat.send` and then a requester-settle completion into a parent bound to a real managed worktree. Merge base: the ordinary turn passes and the completion is refused (`OPENAI_ACCESS_PROGRAM_UNAVAILABLE`, not advertised). This branch: both pass. The worktree-bound `chat.send` turn passes on both.
- Prepared model runtime, prepared model catalog and access-program suites plus every direct importer of the changed files: 64 files, all pass, re-run after merging current main.
- `findConfiguredOwnerCandidates` moved unchanged to `prepared-model-runtime.configured-owner.ts` so the owner module stays within its line cap.
- Production (read-only): every refusal of this kind came from a session bound to a managed worktree. Each worktree was created minutes to hours before the first refusal, and none of those sessions ever had a successful report.

Co-authored-by: Ayaan Zaidi <[email protected]>
tideclaw-bot pushed a commit that referenced this pull request Nov 29, 2026
…workspaces (#207277)

## What Problem This Solves

A chat can require an OpenAI access program that the account offers. When that chat's session is bound to a managed worktree, turns that run in the worktree (for example, a subagent reporting back to its parent) were refused before any model request with "This … program is not advertised for the current account, model, and runtime". The same account in the same chat passed for ordinary messages. Users saw subagent results fail to come back.

## User Impact

Turns that run in a workspace other than the agent's main one (managed worktrees, child sessions, cron jobs with a workspace, compaction with a requested workspace) now see the same account facts as the main workspace. The access check is unchanged: a program is still allowed only when the account's current credential advertises it, and no request reaches a model without it.

## Why This Change Was Made

The facts an account is offered (`providerOutcomes`) belong to the agent and its credential, not to a directory. They live in the prepared catalog inventory, and every inventory row is already guarded per provider: a source fingerprint (provider config including the resolved key, the providing plugins' versions and install hashes, auth profiles and order, env) plus the credential identity. But the inventory was stored per catalog owner, and owners are keyed by workspace because a workspace can add plugins. So an owner for a second workspace started empty, and in static mode (turns never rediscover) it had no account facts. Only `chat.send` avoided this, because it deliberately prepares its catalog from the main workspace.

Now a non-configured owner is offered the configured owner's inventory for the same agent, and the existing retention guards decide which rows hold for its own config and credentials. The seed is used only when the plugin set matches exactly (a workspace plugin could otherwise provide the same provider id with different code). The owner key, plugins and models stay per workspace. The seed applies at retention time, so a rejected seed does not hide the provider's generated models.

Named edges, not coded:
- If the configured owner has recorded discovery failures, a seeded worktree run owner retries that discovery until its lease ends.
- Before the configured owner's first discovery, or right after a provider config or sign-in change and before rediscovery completes, a worktree turn can still be refused. A main-workspace turn recovers on rediscovery. This is not a regression.

## Evidence

- New `prepared-model-runtime.workspace-inventory.test.ts`. Each case prepares the worktree turn with the dispatch's plugin generation, as report turns are prepared. The entitlement is keyed by account and credential identity:
  - `gives a worktree run with the same direct key only the account facts of its own credential` and `… with the same stored account …` see the main workspace's outcomes. Both fail on the merge base (`[]`).
  - `… with a different direct key …`, `… with a second stored account …` and `… with a signed-out credential …` inherit nothing.
  - `drops the account facts on the next worktree turn after the credential rotates`: after a sign-in change, a turn pinned to the old generation is refused ("superseded"), and the next turn sees no old-account facts.
  - The negative cases pass on the merge base by construction, since it never shares facts. With the retention credential guard disabled, the second-account, signed-out and rotation cases fail. The direct-key case is caught separately by the provider-config fingerprint, which includes the resolved key.
- Real in-process Gateway fixture (synthetic HTTP only; not committed because it clones the repository): `chat.send` and then a requester-settle completion into a parent bound to a real managed worktree. Merge base: the ordinary turn passes and the completion is refused (`OPENAI_ACCESS_PROGRAM_UNAVAILABLE`, not advertised). This branch: both pass. The worktree-bound `chat.send` turn passes on both.
- Prepared model runtime, prepared model catalog and access-program suites plus every direct importer of the changed files: 64 files, all pass, re-run after merging current main.
- `findConfiguredOwnerCandidates` moved unchanged to `prepared-model-runtime.configured-owner.ts` so the owner module stays within its line cap.
- Production (read-only): every refusal of this kind came from a session bound to a managed worktree. Each worktree was created minutes to hours before the first refusal, and none of those sessions ever had a successful report.

Co-authored-by: Ayaan Zaidi <[email protected]>

(cherry picked from commit 3b899c3)

Co-authored-by: RomneyDa <[email protected]>
tideclaw-bot pushed a commit that referenced this pull request Nov 30, 2026
…workspaces (#207277)

A chat can require an OpenAI access program that the account offers. When that chat's session is bound to a managed worktree, turns that run in the worktree (for example, a subagent reporting back to its parent) were refused before any model request with "This … program is not advertised for the current account, model, and runtime". The same account in the same chat passed for ordinary messages. Users saw subagent results fail to come back.

Turns that run in a workspace other than the agent's main one (managed worktrees, child sessions, cron jobs with a workspace, compaction with a requested workspace) now see the same account facts as the main workspace. The access check is unchanged: a program is still allowed only when the account's current credential advertises it, and no request reaches a model without it.

The facts an account is offered (`providerOutcomes`) belong to the agent and its credential, not to a directory. They live in the prepared catalog inventory, and every inventory row is already guarded per provider: a source fingerprint (provider config including the resolved key, the providing plugins' versions and install hashes, auth profiles and order, env) plus the credential identity. But the inventory was stored per catalog owner, and owners are keyed by workspace because a workspace can add plugins. So an owner for a second workspace started empty, and in static mode (turns never rediscover) it had no account facts. Only `chat.send` avoided this, because it deliberately prepares its catalog from the main workspace.

Now a non-configured owner is offered the configured owner's inventory for the same agent, and the existing retention guards decide which rows hold for its own config and credentials. The seed is used only when the plugin set matches exactly (a workspace plugin could otherwise provide the same provider id with different code). The owner key, plugins and models stay per workspace. The seed applies at retention time, so a rejected seed does not hide the provider's generated models.

Named edges, not coded:
- If the configured owner has recorded discovery failures, a seeded worktree run owner retries that discovery until its lease ends.
- Before the configured owner's first discovery, or right after a provider config or sign-in change and before rediscovery completes, a worktree turn can still be refused. A main-workspace turn recovers on rediscovery. This is not a regression.

- New `prepared-model-runtime.workspace-inventory.test.ts`. Each case prepares the worktree turn with the dispatch's plugin generation, as report turns are prepared. The entitlement is keyed by account and credential identity:
  - `gives a worktree run with the same direct key only the account facts of its own credential` and `… with the same stored account …` see the main workspace's outcomes. Both fail on the merge base (`[]`).
  - `… with a different direct key …`, `… with a second stored account …` and `… with a signed-out credential …` inherit nothing.
  - `drops the account facts on the next worktree turn after the credential rotates`: after a sign-in change, a turn pinned to the old generation is refused ("superseded"), and the next turn sees no old-account facts.
  - The negative cases pass on the merge base by construction, since it never shares facts. With the retention credential guard disabled, the second-account, signed-out and rotation cases fail. The direct-key case is caught separately by the provider-config fingerprint, which includes the resolved key.
- Real in-process Gateway fixture (synthetic HTTP only; not committed because it clones the repository): `chat.send` and then a requester-settle completion into a parent bound to a real managed worktree. Merge base: the ordinary turn passes and the completion is refused (`OPENAI_ACCESS_PROGRAM_UNAVAILABLE`, not advertised). This branch: both pass. The worktree-bound `chat.send` turn passes on both.
- Prepared model runtime, prepared model catalog and access-program suites plus every direct importer of the changed files: 64 files, all pass, re-run after merging current main.
- `findConfiguredOwnerCandidates` moved unchanged to `prepared-model-runtime.configured-owner.ts` so the owner module stays within its line cap.
- Production (read-only): every refusal of this kind came from a session bound to a managed worktree. Each worktree was created minutes to hours before the first refusal, and none of those sessions ever had a successful report.

Co-authored-by: Ayaan Zaidi <[email protected]>
(cherry picked from commit 3b899c3)

Follow-ups: 7b0b2e3 refactor(auth): keep published store lookup passive (#200185) [not selected for this narrow backport]

Release adaptation: Use the shared configured-owner resolver and inventory seed while preserving stable publication imports and account/provider fences.

(cherry picked from commit 740a1a4a0ce093185bdcf1b1f024d3d3dbabc16f)

Companion audit: 7b0b2e3 is broader passive auth-store refactoring, not required; focused inventory and retention gates pass on stable publication owners.

Co-authored-by: RomneyDa <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agents Agent runtime and tooling impact:auth-provider Auth, provider routing, model choice, or SecretRef resolution may break. P1 High-priority user-facing bug, regression, or broken workflow. rating: 🧂 unranked krab Not merge-ready due to missing proof or serious correctness/safety concerns. size: M status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant