Skip to content

feat(github): authorize agent identities from Settings - #126474

Merged
steipete merged 6 commits into
mainfrom
steipete/github-device-authorization
Aug 20, 2026
Merged

steipete merged 6 commits into
mainfrom
steipete/github-device-authorization

Conversation

@steipete

@steipete steipete commented Aug 19, 2026 •

Copy link
Copy Markdown
Contributor

Closes #125157

AI-assisted implementation. I reviewed the architecture, code, and validation results; no agent transcript is included.

Additional instructions

MUST: Keep Allow edits from maintainers enabled for this PR so maintainers
can help update the branch when needed.

What Problem This Solves

PAT-only setup and ambient GitHub authentication make a dedicated bot or user identity cumbersome and easy to confuse with the Gateway preview credential. Cloud publication also intentionally gives workers no forge credential, so operators need a safe Gateway-owned way to authorize the user identity that local gh commands and publication should use.

Why This Change Was Made

Settings now owns GitHub device authorization through the dedicated OpenClaw GitHub Tools OAuth App. The Gateway owns polling, hidden refresh metadata, restart recovery, stable managed-profile replacement, and publication identity; system and complete per-agent identities remain distinct, native inference remains the unconfigured default, PAT setup remains an explicit one-use fallback, and cloud workers remain credential-free.

The browser receives only the user code, pinned GitHub verification URL, relative expiry presentation, and cancel action. It never receives the device code, access token, or refresh token. Refresh verifies the durable numeric GitHub account ID, preserves the stable managed profile and custom Git author, atomically replaces hosts.yml, retains already-admitted local runs, and drains non-idempotent refresh work during shutdown.

User Impact

An operator can open GitHub from Settings → Agents → Tools, enter the displayed code, and authorize the intended GitHub user. The Gateway refreshes that identity and makes it effective for local gh execution and Gateway-owned publication. Operators can choose a system identity or a complete per-agent override, inspect the effective identity and selected scope separately, cancel authoritatively, remove a managed identity with explicit new-run wording, or use PAT fallback. Cloud workers still receive no forge credential.

Evidence

Exact reviewed head: dbf7f6007de4b08877e2027d057faf9b2fed89a7

  • Focused routed Vitest: 9 files across agent, Gateway, and Control UI shards, 164 tests passed; the dedicated Control UI device-authorization E2E added 1 passing browser test.
  • pnpm protocol:check passed, including registry, Swift/Kotlin generation, additive-method vintage, and committed-output drift checks.
  • swift test --package-path apps/shared/OpenClawKit --filter GatewayProtocolGeneratedModelsTests passed 7 tests, including all 8 device-result outcomes.
  • node scripts/check-changed.mjs passed the complete branch classifier: core/UI/scripts typechecking and lint, architecture/security/schema guards, plus 484 macOS/tooling tests.
  • pnpm build passed all build groups, 61 external plugin distributions, 146 public Plugin SDK subpaths, runtime postbuild checks, and Control UI performance budgets.
  • git diff --check origin/main...HEAD passed.
  • Fresh branch P1 autoreview against origin/main reported no accepted/actionable findings.
  • Exact-head CI run 32316304047 is green at the final head, including Android Play/third-party/Wear tests, builds, and ktlint.
  • Native OPENCLAW_TESTBOX=1 scripts/pr prepare-run 126474 passed at 2026-08-20 00:40 UTC in hosted_exact_or_recent_parent mode, reusing the exact hosted CI result for this head; it verified the remote PR tree equals the prepared tree, required no rebase/changelog/push rewrite, and therefore needed no separate Testbox lease.
  • Initial exact-head CI run 32313254865 correctly found a stale generated native tool-display snapshot for the new status tool. The snapshot was regenerated; 129 focused TypeScript display/catalog/tool tests, the Swift ToolDisplayRegistryTests, tool-display:check, git diff --check, and a fresh P1 autoreview all passed before the repair commit.
  • Follow-up exact-head CI run 32313654801 found the corresponding common-config snapshot and Linux Node 24 startup-byte baseline. The snapshot now records tools.github.kind at both scopes. The startup baseline uses the exact 347,023-byte CI measurement (+1,445 bytes), stays below the unchanged 350 KiB hard cap, and names the Settings status/recovery copy. The 24-test config-quality suite, focused UI build/performance check, git diff --check, and a fresh P1 autoreview passed before the repair commit.
  • Final-head candidate run 32314128175 exposed a Madge cycle caused by importing the account type from the identity runtime back into OAuth storage. GitHubToolAccount is now a five-line leaf contract shared by both owners, with no compatibility alias or behavior change. The complete architecture chain, 78 focused record/identity/lifecycle tests, scoped production/test typechecks and guards, git diff --check, and a fresh P1 autoreview passed before the refactor commit.
  • Exact-head candidate run 32315539622 exposed an unrelated existing scheduler-sensitive tooling assertion: under load, the shared 500 ms gateway startup deadline can expire before a delayed first refusal, so one attempt is valid although the test always required two. The test now asserts the actual invariant—one deadline, at least one attempt, and no more than the single allowed retry—while separate tests retain exact two-attempt restart coverage. No timeout or production code changed; the full 21-test owner suite, formatting, git diff --check, test-audit, and fresh P1 autoreview passed.

Safe public endpoint proof on this head generated no user authorization and printed no code values: HTTP 200; 40-character device-code shape; valid user-code shape; pinned https://github.com/login/device; expiry 899 seconds; interval 5 seconds; no error.

Local Android unit execution remains unavailable because this host has no Android SDK/ANDROID_HOME; Kotlin generation passed locally and exact-head PR CI is required to provide the Android unit/build proof.

Production LOC: +4042/-463; tests/test support: +3168/-90; generated protocol/config/i18n/native-display/performance artifacts: +553/-59; docs: +13/-6. Production growth is the concrete authorization capability: OAuth client and hidden bounded records, lifecycle/CAS recovery, stable-profile refresh, protocol/status surfaces, and the Settings flow. There is no SQLite schema-version bump.

Dependency contracts checked directly:

Review disposition

  • ClawSweeper's status-RPC compatibility finding is skipped with release proof. tools.github.status first landed in feat(agents): configure per-agent GitHub identities #125199 at 6e458d84bfc1970ccd97b0a0b493f1e0f4965c56 on August 17. No stable or beta tag contains that commit: the newest beta tag predates it (August 14), and the newest stable tag is July 13. Repository doctrine gives unreleased main and beta-only surfaces no compatibility obligation, so this final staged feature keeps one canonical status method instead of adding an obsolete legacy RPC before first shipment.
  • The direct-contract rank-up move is complete: current GitHub OAuth App source and the exact Codex environment/process source are cited above.
  • Maintainer decision: accept the Gateway-owned OAuth App boundary and requested scopes for local agent tooling and Gateway publication. The linked maintainer-authored umbrella and staged PR sequence own this final authorization phase; cloud workers remain credential-free. Team production rollout and real-user enrollment remain separate post-merge work.

Visual proof

Before: current-main PAT-only managed identity UI.

Before: PAT-only managed identity

After: connected system identity is effective and refresh-capable.

After: connected system identity

Device authorization: the browser-visible surface contains only the fake user code, pinned verification link, relative expiry, and cancel action.

Device authorization code flow

Scope separation: the selected agent override and effective system identity render as distinct blocks.

System identity shadowed by agent scope

Full sanitized flow recording:

[email protected]

@clawsweeper

clawsweeper Bot commented Aug 19, 2026

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

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

@openclaw-barnacle openclaw-barnacle Bot added docs Improvements or additions to documentation app: android App: android app: web-ui App: web-ui gateway Gateway runtime scripts Repository scripts agents Agent runtime and tooling size: XL maintainer Maintainer-authored PR labels Aug 19, 2026
@steipete
steipete marked this pull request as ready for review August 19, 2026 23:26
@steipete
steipete requested a review from a team as a code owner August 19, 2026 23:26
@clawsweeper clawsweeper Bot added merge-risk: 🚨 auth-provider 🚨 May break OAuth, tokens, provider routing, model choice, or credentials. merge-risk: 🚨 compatibility 🚨 May break existing users, config, migrations, defaults, or upgrade paths. merge-risk: 🚨 security-boundary 🚨 May affect sandboxing, authorization, credentials, or sensitive data. P2 Normal backlog priority with limited blast radius. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. labels Aug 19, 2026
@clawsweeper

clawsweeper Bot commented Aug 19, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: found issues before merge. Reviewed August 19, 2026, 8:17 PM ET / August 20, 2026, 00:17 UTC.

ClawSweeper review

What this changes

Adds Settings-driven GitHub OAuth device authorization for system and per-agent identities, including Gateway refresh lifecycle, managed profiles, protocol models, and Control UI controls.

Merge readiness

⚠️ Ready for maintainer review - 6 items remain

Keep open. The previous P1 remains: this replaces an existing public Gateway status RPC rather than extending it, so prior clients are rejected before the handler runs. The maintainer-owned OAuth/security boundary also needs an explicit decision.

Priority: P2
Reviewed head: dbf7f6007de4b08877e2027d057faf9b2fed89a7
Owner decision: Required. See Decision needed.

Review scores

Measure Result What it means
Overall readiness 🦐 gold shrimp (3/6) The OAuth implementation has useful owner-boundary coverage and a concrete P1 public-protocol regression to resolve.
Proof confidence 🌊 off-meta tidepool Not applicable: The contributor-proof gate does not apply to this member-authored PR; its linked screenshots and recording were not available in the prepared local manifest, which contained only a failed example.test download.
Patch quality 🦐 gold shrimp (3/6) 1 actionable review finding remain.

Verification

Check Result Evidence
Real behavior Not applicable Not applicable: The contributor-proof gate does not apply to this member-authored PR; its linked screenshots and recording were not available in the prepared local manifest, which contained only a failed example.test download.
Evidence reviewed 7 items Previous public status contract: The PR base accepts a closed request containing only agentId and returns the flat GitHub identity result.
Breaking protocol validation: The branch makes selectedScope required in the same closed request schema, so an existing { agentId } request fails validation.
Handler rejects before status resolution: The existing method validates the changed request schema before resolving the agent or computing a status response.
Findings 1 actionable finding [P1] Preserve the public GitHub status RPC
Security None None.

Live Verification

Command: pnpm openclaw --help

Result: PASS (completed)

pnpm openclaw --help
runner@runnervm76f27:/tmp/clawsweeper-live-proof-126474-uMiFY6/target$ pnpm openclaw --help
$ node scripts/run-node.mjs --help
pnpm openclaw --help
[openclaw] Building TypeScript (dist is stale: missing_build_stamp - build stamp missing).
[openclaw] Building bundled plugin assets.
[canvas] build: node scripts/bundle-a2ui.mjs
[log] ‹DIR›/a2ui.bundle.js  chunk │ size: 399.96 kB
[log] ‹DIR›/a2ui-v0.9.bundle.js  chunk │ size: 615.66 kB
[log]
[success] rolldown v1.2.0 Finished in 111.87 ms
[diffs] build: node --import tsx ../../scripts/build-diffs-viewer-runtime.mts curated
[diffs-language-pack] build: node --import tsx ../../scripts/build-diffs-viewer-runtime.mts full
[discord] build: node --import tsx ../../scripts/build-discord-activity-sdk.mts
[tsdown-build] invocation 1/2 finished in 0.7s
node_modules/web-tree-sitter/web-tree-sitter.js (2343:30) [EVAL] Use of direct ˋevalˋ function is strongly discouraged as it poses security risks and may cause
issues with minification.
      ╭─[ node_modules/web-tree-sitter/web-tree-sitter.js:2343:31 ]
      │
 2343 │           ASM_CONSTS[start] = eval(func);
      │                               ──┬─
      │                                 ╰─── Use of direct ˋevalˋ here.
      │
      │ Help: Consider using indirect eval. For more information, check the documentation: https://rolldown.rs/guide/troubleshooting#avoiding-direct-eval
──────╯

node_modules/web-tree-sitter/web-tree-sitter.js (2366:32) [EVAL] Use of direct ˋevalˋ function is strongly discouraged as it poses security risks and may cause
issues with minification.
      ╭─[ node_modules/web-tree-sitter/web-tree-sitter.js:2366:33 ]
      │
 2366 │           moduleExports[name] = eval(func);
      │                                 ──┬─
      │                                   ╰─── Use of direct ˋevalˋ here.
      │
      │ Help: Consider using indirect eval. For more information, check the documentation: https://rolldown.rs/guide/troubleshooting#avoiding-direct-eval
──────╯

node_modules/playwright-core/lib/coreBundle.js (65821:28) [EVAL] Use of direct ˋevalˋ function is strongly discouraged as it poses security risks and may cause
issues with minification.
       ╭─[ node_modules/playwright-core/lib/coreBundle.js:65821:29 ]
       │
 65821 │               const value = eval(ˋ(${expr})ˋ);
       │                             ──┬─
       │                               ╰─── Use of direct ˋevalˋ here.
       │
       │ Help: Consider using indirect eval. For more information, check the documentation: https://rolldown.rs/guide/troubleshooting#avoiding-direct-eval
───────╯

node_modules/playwright-core/lib/coreBundle.js (65828:28) [EVAL] Use of direct ˋevalˋ function is strongly discouraged as it poses security risks and may cause
issues with minification.
       ╭─[ node_modules/playwright-core/lib/coreBundle.js:65828:29 ]
       │
 65828 │               const value = eval(ˋ(${expr})ˋ);
       │                             ──┬─
       │                               ╰─── Use of direct ˋevalˋ here.
       │
       │ Help: Consider using indirect eval. For more information, check the documentation: https://rolldown.rs/guide/troubleshooting#avoiding-direct-eval
───────╯

[tsdown-build] invocation 2/2 finished in 14.3s
[plugin-control-plane-loads] verified 36 built modules with native require and checked doctor closures
runtime-postbuild: 10 phases completed in 4394ms (slowest: built plugin control-plane loads 3651ms)

OpenClaw 2026.8.1 (dbf7f60) — All your chats, one OpenClaw.

Usage: openclaw [options] [command]

Options:
  --container ‹name›   Run the CLI inside a running Podman/Docker container named ‹name› (default: env OPENCLAW_CONTAINER)
  --dev                Dev profile: isolate state under ~/.openclaw-dev, default gateway port 19001, and shift derived ports (browser/canvas)
  -h, --help           Display help for command
  --log-level ‹level›  Global log level override for file + console
… output truncated …

Assertions:

  • PASS expect_output: Usage:

How this fits together

Settings asks the Gateway to authorize and retain a GitHub identity. The Gateway then supplies its managed profile to local agent tools and Gateway-owned publication without sending credentials to browsers or cloud workers.

flowchart LR
  A[Settings operator] --> B[Gateway authorization service]
  B --> C[GitHub device authorization]
  C --> D[Hidden OAuth records]
  D --> E[Managed GitHub profile]
  E --> F[Local agent tools]
  E --> G[Gateway publication]
Loading

Decision needed

Question Recommendation
Should OpenClaw make this Gateway-owned OAuth app and its requested GitHub scopes the permanent core authority for local agent tooling and publication? Approve the core boundary after repair: Retain Gateway ownership and explicit operator authorization, but land only after the additive status-RPC repair and direct dependency-contract verification.

Why: The credential owner, durable refresh behavior, and requested scopes define a product security boundary that code review alone cannot choose.

Before merge

  • Preserve the public GitHub status RPC (P1) - tools.github.status previously accepted only { agentId } and returned the flat identity object. Requiring selectedScope here makes existing clients fail parameter validation before this handler runs, while the new closed result also breaks their decoders. Keep this method compatible and add a separate scoped status method for the selected/effective view.
  • Resolve merge risk (P1) - Existing clients that send the previously advertised status request are rejected, and clients decoding the former flat response cannot consume the replacement shape.
  • Resolve merge risk (P1) - This adds a persistent OAuth authority with repo, workflow, read:org, gist, and offline_access scopes; the permanent core security boundary needs maintainer acceptance.
  • Resolve merge risk (P1) - Direct Codex-runtime and current-main contract inspection was blocked by the unavailable sibling checkout and missing-object fetch failure.
  • Complete next step (P2) - The P1 compatibility repair is clear, but the versioned public-method shape and permanent OAuth security boundary require maintainer direction.

Findings

  • [P1] Preserve the public GitHub status RPC — packages/gateway-protocol/src/schema/agents-models-skills.ts:1020-1023
Agent review details

Security

None.

PR surface

Source +3562, Tests +2987, Docs +7, Generated +2, Other +600. Total +7158 across 77 files.

View PR surface stats
Area Files Added Removed Net
Source 42 4060 498 +3562
Tests 22 3073 86 +2987
Docs 3 13 6 +7
Config 0 0 0 0
Generated 3 5 3 +2
Other 7 625 25 +600
Total 77 7776 618 +7158

Review metrics

Metric Value Why it matters
Production versus test growth production +4042/-463; tests/test support +3168/-90 The stated production growth is substantial but tied to a new authorization capability; it needs the explicit core-boundary decision above.
Gateway protocol surface 3 methods added; 1 existing method reshaped The three authorization methods are additive, but reshaping the existing status method creates the compatibility blocker.
GitHub identity config 1 credential-kind field added at 2 scopes System and per-agent identity config now distinguish OAuth records from PAT-managed profiles.

Stored data model

Persistent data-model change detected: migration/backfill/repair: test/helpers/openclaw-test-instance.test.ts, serialized state: src/agents/github-oauth-client.test.ts, serialized state: src/agents/tools/github-identity-status-tool.test.ts, serialized state: ui/src/pages/agents/github-identity-controller-shared.ts, serialized state: ui/src/pages/agents/github-identity-controller.ts, unknown-data-model-change: packages/gateway-protocol/src/schema/agents-models-skills.ts, and 2 more. Confirm migration or upgrade compatibility proof before merge.

Root-cause cluster

Relationship: fixed_by_candidate
Canonical: #125157
Summary: This PR is the candidate implementation for the linked system and per-agent GitHub identity feature request.

Members:

Proposal only: this assessment does not dispatch repair, suppress jobs, mutate sibling items, close, or merge anything.

Merge-risk options

Maintainer options:

  1. Make scoped status additive (recommended)
    Preserve the current status method's request and flat response, and route the new selected-scope view through a distinct versioned method with focused old-client coverage.
  2. Pause OAuth rollout
    Do not merge this core credential boundary if maintainers do not want to own the requested scopes and refresh lifecycle.

Technical review

Best possible solution:

Keep the existing status RPC and flat result intact, then add a separately named scoped-status method for the selected-versus-effective identity view before landing the OAuth flow.

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

Yes, from source: send the previous closed request shape { agentId } to tools.github.status; the branch requires selectedScope, so validation rejects it before the handler executes.

Is this the best way to solve the issue?

No. The OAuth lifecycle is owner-oriented, but replacing the existing status RPC is not the best path; a new additive scoped-status method preserves clients and supplies the needed view.

Full review comments:

  • [P1] Preserve the public GitHub status RPC — packages/gateway-protocol/src/schema/agents-models-skills.ts:1020-1023
    tools.github.status previously accepted only { agentId } and returned the flat identity object. Requiring selectedScope here makes existing clients fail parameter validation before this handler runs, while the new closed result also breaks their decoders. Keep this method compatible and add a separate scoped status method for the selected/effective view.
    Confidence: 0.99

Overall correctness: patch is incorrect
Overall confidence: 0.96

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning high; reviewed against 02be7fea9725.

Labels

Label justifications:

  • P2: This is a substantial operator-facing identity feature with a concrete compatibility blocker, but no demonstrated emergency outage or active compromise.
  • merge-risk: 🚨 compatibility: The branch changes the required input and response shape of an already advertised Gateway status method.
  • merge-risk: 🚨 auth-provider: It adds OAuth issuance, refresh rotation, credential selection, and publication-time identity refresh.
  • merge-risk: 🚨 security-boundary: It stores rotating GitHub credentials and introduces a privileged operator authorization path with broad GitHub scopes.
  • rating: 🦐 gold shrimp: Overall readiness is 🦐 gold shrimp; proof is 🌊 off-meta tidepool and patch quality is 🦐 gold shrimp.
  • status: ⏳ waiting on author: ClawSweeper has contributor-facing work open and is waiting for author action. Not applicable: The contributor-proof gate does not apply to this member-authored PR; its linked screenshots and recording were not available in the prepared local manifest, which contained only a failed example.test download.

Evidence

What I checked:

Likely related people:

  • steipete: The available shallow history attributes the changed Gateway protocol, handler, and identity resolver to Peter Steinberger; prior-area history could not be recovered from this grafted checkout. (role: feature author; confidence: medium; commits: dbf7f6007de4; files: packages/gateway-protocol/src/schema/agents-models-skills.ts, src/gateway/server-methods/tools-github.ts, src/agents/github-tool-identity.ts)

Rank-up moves

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

  • Preserve the existing status RPC and add the selected-scope view through an additive method with old-client request/response coverage.
  • Obtain the required direct Codex-runtime and GitHub OAuth contract checks before merge.

Rating scale

Score Internal tier Crab rank Meaning
6/6 S 🦀 challenger crab Exceptional readiness
5/6 A 🦞 diamond lobster Very strong readiness
4/6 B 🐚 platinum hermit Good normal PR; ordinary maintainer review
3/6 C 🦐 gold shrimp Useful, but confidence is limited
2/6 D 🦪 silver shellfish Proof or implementation needs work
1/6 F 🧂 unranked krab Not merge-ready
N/A NA 🌊 off-meta tidepool Rating does not apply

Overall follows the weaker of proof and patch quality.
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics.

Workflow

  • ClawSweeper keeps one durable marker-backed review comment per issue or PR.
  • Re-runs edit this comment so the latest verdict, findings, and automation markers stay together instead of adding duplicate bot comments.
  • A fresh review can be triggered by eligible @clawsweeper re-review comments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.
  • PR/issue authors and users with repository write access can comment @clawsweeper re-review or @clawsweeper re-run on an open PR or issue to request a fresh review only.
  • Maintainers can also comment @clawsweeper review to request a fresh review only.
  • Fresh-review commands do not start repair, autofix, rebase, CI repair, or automerge.
  • Maintainer-only repair and merge flows require explicit commands such as @clawsweeper autofix, @clawsweeper automerge, @clawsweeper fix ci, or @clawsweeper address review.
  • Maintainers can comment @clawsweeper explain to ask for more context, or @clawsweeper stop to stop active automation.

History

Review history (3 earlier review cycles)
  • reviewed 2026-08-19T23:37:26.411Z sha 8ae64b6 :: needs maintainer review before merge. :: none
  • reviewed 2026-08-19T23:45:15.703Z sha 09b0198 :: needs maintainer review before merge. :: none
  • reviewed 2026-08-20T00:06:29.150Z sha dc09a39 :: found issues before merge. :: [P1] Preserve the public GitHub status RPC

@clawsweeper clawsweeper Bot added rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. and removed rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. labels Aug 20, 2026
@steipete

Copy link
Copy Markdown
Contributor Author

Land-ready proof for dbf7f6007de4b08877e2027d057faf9b2fed89a7:

  • Exact-head CI run 32316304047 is green, including Android Play/third-party/Wear tests, builds, and ktlint.
  • Native OPENCLAW_TESTBOX=1 scripts/pr prepare-run 126474 passed in hosted_exact_or_recent_parent mode, reused that exact hosted result, and verified the remote PR tree equals the prepared tree. No rebase, changelog, push rewrite, or separate Testbox lease was needed.
  • Local owner proof covers 165 focused OAuth/agent/Gateway/UI tests, protocol generation, 7 Swift generated-model tests with all 8 device outcomes, the full changed classifier with 484 macOS/tooling tests, full build/UI performance, complete architecture checks, safe public device-endpoint shape proof, and fresh P1 autoreviews after every repair.
  • ClawSweeper compatibility finding is skipped with release proof: tools.github.status landed after every stable and beta tag and has never shipped. Direct Codex and GitHub OAuth contract inspection is cited in the PR body. The maintainer accepts the Gateway-owned OAuth boundary and requested scopes; cloud workers remain credential-free.
  • Remaining gap is intentional: Team production rollout and enrollment of a real GitHub user happen after merge. No release or deployment was performed here.

@steipete
steipete merged commit 0a86702 into main Aug 20, 2026
256 checks passed
@steipete
steipete deleted the steipete/github-device-authorization branch August 20, 2026 00:42
@steipete

Copy link
Copy Markdown
Contributor Author

Merged via squash.

github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Aug 20, 2026
* feat(github): add device authorization lifecycle

* fix(github): harden device authorization lifecycle

* fix(github): refresh native tool display snapshot

* fix(github): refresh config and UI baselines

* refactor(github): break OAuth identity import cycle

* test: make gateway retry deadline assertion scheduler-safe
steipete added a commit that referenced this pull request Aug 20, 2026
main is red on the Control UI startup-JS ratchet: unrelated PR #126725 measures 348289 B and this branch measures 348351 B against a 347023 B baseline + 1056 B tolerance. Twenty-six UI commits have landed since the last bump (#126474), none individually large. Baseline moves to the CI-measured 348351 B, well under the 358400 B maintainer-approved ceiling that still guards cumulative creep.
steipete added a commit that referenced this pull request Aug 20, 2026
…126734)

* fix(config): validate config writes against the config being written

writeConfigFileFromContext passed the pre-write snapshot's plugin
metadata into strict validation. During onboarding that snapshot belongs
to an intermediate config written by agent creation, which has no plugin
entries, so its scoped manifest registry is empty. Validating the final
candidate against it made every plugin entry added by the same write look
unknown, and non-interactive onboarding warned that the openai and codex
entries it had just written were stale or uninstalled.

Drop the stale snapshot so validation resolves the manifest registry from
the candidate it is actually validating. Strict semantic validation is
unchanged, and the registry load stays lazy.

* fix(ci): raise the Control UI startup JS baseline to unblock main

main is red on the Control UI startup-JS ratchet: unrelated PR #126725 measures 348289 B and this branch measures 348351 B against a 347023 B baseline + 1056 B tolerance. Twenty-six UI commits have landed since the last bump (#126474), none individually large. Baseline moves to the CI-measured 348351 B, well under the 358400 B maintainer-approved ceiling that still guards cumulative creep.
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Aug 21, 2026
…penclaw#126734)

* fix(config): validate config writes against the config being written

writeConfigFileFromContext passed the pre-write snapshot's plugin
metadata into strict validation. During onboarding that snapshot belongs
to an intermediate config written by agent creation, which has no plugin
entries, so its scoped manifest registry is empty. Validating the final
candidate against it made every plugin entry added by the same write look
unknown, and non-interactive onboarding warned that the openai and codex
entries it had just written were stale or uninstalled.

Drop the stale snapshot so validation resolves the manifest registry from
the candidate it is actually validating. Strict semantic validation is
unchanged, and the registry load stays lazy.

* fix(ci): raise the Control UI startup JS baseline to unblock main

main is red on the Control UI startup-JS ratchet: unrelated PR openclaw#126725 measures 348289 B and this branch measures 348351 B against a 347023 B baseline + 1056 B tolerance. Twenty-six UI commits have landed since the last bump (openclaw#126474), none individually large. Baseline moves to the CI-measured 348351 B, well under the 358400 B maintainer-approved ceiling that still guards cumulative creep.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agents Agent runtime and tooling app: android App: android app: web-ui App: web-ui docs Improvements or additions to documentation gateway Gateway runtime maintainer Maintainer-authored PR merge-risk: 🚨 auth-provider 🚨 May break OAuth, tokens, provider routing, model choice, or credentials. merge-risk: 🚨 compatibility 🚨 May break existing users, config, migrations, defaults, or upgrade paths. merge-risk: 🚨 security-boundary 🚨 May affect sandboxing, authorization, credentials, or sensitive data. P2 Normal backlog priority with limited blast radius. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. scripts Repository scripts size: XL status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Feature]: Add system and per-agent GitHub tool identities

1 participant