Repository navigation
Fail refused ACP models and recover failed initialization - #436
Merged
Merged
Conversation
Two new thread backends drive the OpenCode CLI and Xiaomi's MiMo Code fork through their Agent Client Protocol server (`opencode acp --pure`, `mimo acp --pure`), the way Codex runs through `codex app-server`: one shared server per backend, a session per thread as the resume handle, `session/request_permission` answered through Modex's approval cards, rules and policies, and Stop as `session/cancel`. Modex's modes are agents injected inline through the CLI's config variable: Chat denies edits, Agent allows them, Full access asks nothing, Plan pins the built-in plan agent. A refused mode fails the turn. Settings gets cards, verified executable overrides and default models for both; health reads `auth list`'s credential count and the model list is `<cli> models`. Not wired: confined Code Review turns (refused), Modex's knowledge, Space and image tools, question cards, efforts in the model list. Accepted live on OpenCode 1.19.5 and MiMo Code 0.1.16 (docs/opencode.md, docs/reviews/2026-10-28-opencode-*.json, -mimo-acp.json). AGENTS.md's CLI-only rule now names all four CLIs. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
A stubbed or older backends:health result has no opencode/mimo entries; the executable-path rows now read them optionally instead of throwing and taking the Coding CLIs section down. The stale-account e2e counts all four cards. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Code coverage overviewLanguages: TypeScript TypeScript / code-coverage-agent
View coverage of the 1 most impacted file.
ℹ️ Calculations represent line coverage. Results may change as calculations are updated. Updated |
BunsDev
marked this pull request as ready for review
October 29, 2026 22:41
This was referenced Oct 29, 2026
This branch was successfully deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
An ACP server can refuse the explicitly selected model or fail initialization. Model refusal now fails the turn before submitting a prompt, preserving the selected model and RPC diagnostics. Initialization failure clears the failed connection and cached sessions, terminates that child, and allows the next turn to start a fresh server. Child identity guards keep late events from the old process from disconnecting its replacement.
Regression tests exercise both OpenCode and MiMo families, verify zero prompt requests after model refusal, and verify child termination and successful fresh-server retry after initialization failure. Independent review found no blocking findings in these two repairs. At signed head
8db57f5c42af3c101dd7637a06ba254287a39c34, freshpnpm build && pnpm testpassed with exit code 0. This merges landed mainafd50efwhile preserving the previously reviewed and tested repair tree exactly. These are scripted-process tests; they do not prove live provider inference or runtime permission enforcement. A change of head requires refreshed validation.This follow-up does not resolve the separate permission-policy findings involving inherited agents, delegated sessions, MCP/custom tools and approval delivery. Provider expansion approval remains pending. BunsDev closed #408 after #432 merged, recording the delivered backend support. That closure does not resolve the separate review findings described here; this repair does not claim complete runtime permission qualification.
Refs #408 and #432.
Hosted CI on
8db57f5: Run 40764795777 attempt 1 ended cancelled when the macOS job reached its 45-minute limit. Before cancellation, the cold transcript performance test failed: five samples were 2046.5, 2019.2, 1506.6, 2485.7 and 1583.5 ms, with a 2019.2 ms median against the unchanged 500 ms gate. The desktop suite did not finish and the site suite did not run. The iPhone job passed 43 tests. The cancelled run log and artifact 12853390008 were archived, and ZIP integrity passed. No retry has been requested; this performance failure still needs diagnosis.An exact-candidate local diagnostic rebuilt
8db57f5and collected a renderer CPU profile and Chromium timeline without changing tracked source or the acceptance gate. Its single cold open measured 234.2 ms, with a 187 ms maximum renderer task and all 1,400 items rendered; the long thread was not selected at launch. The local timeline recorded 36.1 ms of layout and sampled scroll-follow code, but it did not reproduce the hosted slowdown. This single profiled launch includes instrumentation overhead and is not the five-launch acceptance test. Renderer source and the measurement fixture are unchanged from baseafd50ef; the repair changes ACP backend code, its unit tests and documentation. The failing hosted run has long-task receipts but no CPU/layout trace or host-load measurements sufficient to establish the cause. The original failure remains unresolved, and no hosted retry has been requested. Raw profiles and the diagnostic source manifest are retained undermodex-land-and-prune/acp-exact-profile*.Signed integration head
78b337db9f9d04e9b0e19f6297f1d71cdf7bcd11merges current mainf03a012. The only merge conflict was indocs/status.md; the reviewed ACP implementation, regression tests and OpenCode documentation remain unchanged. Fresh build/unit validation passed with 2,244 passes, 26 skips and zero failures or cancellations. Full root E2E passed with 474 desktop tests, seven skips and seven site tests, exit 0; the five-launch transcript median was 132.8 ms on Apple M5 Max, 18 cores. This integration includes newly landed Code Review, Markdown, local-model and acceptance changes and requires fresh hosted validation. It is not a fix or explanation for the original hosted performance failure, which remains recorded above. The PR remains draft pending current-head hosted and protected delivery checks.Hosted integration run 40792841673 completed successfully on
78b337db9f9d04e9b0e19f6297f1d71cdf7bcd11: 477 desktop E2E passes, four skips and seven site passes. Its cold-open samples were 515.4, 512.5, 376.4, 433.6 and 448.8 ms; the 448.8 ms median passed the unchanged 500 ms median gate on Apple M1 (Virtual), three cores. The iPhone and coverage jobs also passed. This result does not explain the original hosted slowdown. After preserving the completed run log, signed head2f8e62d95a5f6e6f3f2605bb226973bc712d11a4integrates main33a7820to resolve the documentation conflict introduced by #439. Onlydocs/status.mddiffers from the tested head; fresh build/unit validation passed again with 2,244 passes, 26 skips and zero failures or cancellations. The prior full local E2E covers the identical application/test/build tree; it was not repeated for this documentation-only integration. Fresh hosted checks on the new head and protected queue validation remain required.Current-head hosted validation passed at
2f8e62d95a5f6e6f3f2605bb226973bc712d11a4: CI 40797054898 completed successfully with 477 desktop tests passed, four skipped, seven site tests passed and 43 iPhone tests passed. The unchanged transcript budget passed with median 401.3 ms against 500 ms on Apple M1 Virtual (three cores); samples were 425.1, 401.3, 464.9, 351.1 and 375.7 ms. Native Windows/Linux run 40797054782 also passed. This validates the current candidate; the earlier performance failure remains recorded above and its cause remains unproven.