Repository navigation
refactor(plugins): return self-hosted auth results directly - #140332
Conversation
Return the existing public auth result directly from the interactive prompt flow. Remove its unused private result layer and returned model ID while preserving all prompts, normalization, metadata, and the shared configuration builder. Validation: the same three ordinary interactive/noninteractive cases pass before and after; all 29 canonical stages and managed P2 review pass. The new characterization lives in a focused sibling test file so existing line limits stay intact.
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review completeClawSweeper finished reviewing this revision. The review result is being finalized. |
|
Codex review: needs maintainer review before merge. Reviewed September 6, 2026, 1:43 PM ET / 17:43 UTC. ClawSweeper reviewWhat this changesThe PR removes an intermediate result wrapper from self-hosted provider setup and adds coverage for the unchanged prompts, credentials, and generated configuration. Merge readiness✅ Ready for maintainer review Keep open: this is a coherent, behavior-preserving cleanup that remains absent from current main. No actionable defect was found, and the maintainer-authored, protected PR is not eligible for automated closure. Priority: P3 Review scores
Verification
How this fits togetherSelf-hosted provider setup collects a server URL, API key, and model name through the onboarding prompts. It returns credentials and configuration to the existing authentication flow, which owns persistence and model selection. flowchart LR
A[Provider setup entry] --> B[URL, key, and model prompts]
B --> C[Normalize inputs]
C --> D[Shared configuration builder]
D --> E[Authentication result]
E --> F[Existing persistence and model selection]
Before mergeNone. Agent review detailsSecurityNone. PR surfaceSource -22, Tests +108. Total +86 across 2 files. View PR surface stats
Review metrics
Technical reviewBest possible solution: Keep one interactive setup implementation that returns the existing authentication contract directly while retaining the shared configuration builder. Do we have a high-confidence way to reproduce the issue? Not applicable: this is a behavior-preserving refactor, not a reported runtime defect; source inspection confirms the redundant layer. Is this the best way to solve the issue? Yes: returning the existing public result directly removes unnecessary private plumbing without changing the SDK signature, configuration values, or persistence owner. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against 861804b1654b. LabelsLabel changes:
Label justifications:
EvidenceWhat I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
|
|
Merged via squash.
|
* origin/main: (25 commits) docs(releases): keep the release-notes nav group to version routes (#140353) fix(ui): hide trust wrappers in imported chat history fix(subagents): subagent list building decodes unrelated saved prompts in large session stores (#139540) test(process): share relay startup fixtures (#140345) refactor(doctor): inline GitHub skill discovery inputs (#140343) refactor(ui): share channel status type definitions (#140331) refactor: simplify queue state and infrastructure dispatch (#140311) fix: require saved agent turns before update verification succeeds (#140274) fix(update): keep the service profile when switching to Git (#140263) fix(ui): prevent image avatars overlapping mobile chat (#140341) fix(test): accept release subpages in docs route shape (#140337) refactor(plugins): share uninstall mutation ownership (#140322) refactor(agents): use canonical tool execution arguments (#140280) perf(cli): keep inference metadata and domain help lazy (#140327) refactor(plugins): simplify self-hosted setup results (#140332) refactor(config): reuse parent lookup for unset operations (#140326) fix(plugins): preserve exact installed-index mutation receipts (#140328) test(agents): simplify MCP and LSP boundary fixtures (#140312) fix(ui): preserve literal source previews and copied whitespace (#140306) fix: OpenCode Go/Zen requests are missing the required x-opencode-session header (#137464) ...
Return the existing public auth result directly from the interactive prompt flow. Remove its unused private result layer and returned model ID while preserving all prompts, normalization, metadata, and the shared configuration builder. Validation: the same three ordinary interactive/noninteractive cases pass before and after; all 29 canonical stages and managed P2 review pass. The new characterization lives in a focused sibling test file so existing line limits stay intact.
What Problem This Solves
Self-hosted provider setup retains an intermediate result layer left behind after its former public consumer was removed.
Why This Change Was Made
Return the existing public auth result directly from the interactive prompt flow. Delete the private result type, forwarding function and unused returned model ID while preserving the three prompts, normalization, model metadata and shared configuration builder.
User Impact
The public setup API, prompts and generated configuration remain unchanged. Production code decreases by 22 lines.
Evidence
The same three selected interactive/noninteractive cases pass before and after using synthetic prompt values. All 29 canonical checks and the managed P2 review pass. The new characterization lives in a focused sibling test file; the original test file is unchanged, and the existing line limit is preserved. No live provider or credential-store operation was exercised.