feat(runtime): resolve Codex and Claude Code CLIs through the dependency manager - #1138
Draft
sheepbox8646 wants to merge 4 commits into
Draft
feat(runtime): resolve Codex and Claude Code CLIs through the dependency manager#1138sheepbox8646 wants to merge 4 commits into
sheepbox8646 wants to merge 4 commits into
Conversation
sheepbox8646
force-pushed
the
workspace-deps/03-runtime
branch
from
September 3, 2026 08:00
a4d9751 to
9f7dc4a
Compare
sheepbox8646
force-pushed
the
workspace-deps/03-runtime
branch
2 times, most recently
from
September 3, 2026 09:44
a503e79 to
c574342
Compare
sheepbox8646
force-pushed
the
workspace-deps/03-runtime
branch
from
September 3, 2026 12:19
c574342 to
b6d61cc
Compare
Adds the neutral port between direct runtimes and the workspace dependency manager: drivers declare the catalog dependency and pinned version that provides their CLI, and resolve the executable through LauncherResolver at launch time. Also adds the two stable feedback codes for a missing dependency and a version mismatch. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_017sihinqYWYNmZ9K842WqDJ
…ager Codex and Claude Code drivers declare their workspace dependency and pinned CLI version, resolve the executable through the LauncherResolver before launching (managed at pin → toolkit at pin → any managed → any toolkit → PATH) and surface a one-time runtime_notice per thread when the running copy differs from the pin. A missing copy returns the stable agent_dependency_missing feedback and starts a background install through the new background.SpawnManaged task kind. Bot agents API responses now carry the runtime's dependency requirement, direct agents can be created disabled, and the toolkit launcher wrappers lose their PATH fallback. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_017sihinqYWYNmZ9K842WqDJ
…rivers Injects the workspace dependency service into the Codex and Claude Code drivers, validates at startup that every driver's declared dependency exists in the catalog at the declared pin with the expected launcher command, projects runtime_notice metadata into UI message args so the web client can render alignment actions, and makes the panel's alignment verdict follow the same launcher candidate order the resolver and preflight use. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_017sihinqYWYNmZ9K842WqDJ
… shim dir to PATH
With the pins gone the runtime ports carry no version: DependencyRequirer
names only the dependency, Launcher no longer reports a mismatch and the
resolver ranks discovered copies by source (managed → toolkit → PATH)
regardless of version, so selectLauncherCandidate moves from the service
into resolver.go where the ports live. The version-mismatch feedback,
runtime notice and start-up pin validation are dropped; the drivers still
report the handshake version to the copy they launched. The bridge
prepends the dependency shim directory to PATH for every exec and the
Codex, Claude Code and ACP launchers do the same, so a managed overlay wins
over the image copy in terminals and runtimes alike. Bot agent dependencies
shrink to {dependency_id}; Swagger and the SDK are regenerated.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017sihinqYWYNmZ9K842WqDJ
sheepbox8646
force-pushed
the
workspace-deps/03-runtime
branch
from
September 3, 2026 14:18
b6d61cc to
6f3557d
Compare
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.
变更内容
栈
workspace-deps第 3 层:direct runtime 通过依赖管理器解析 CLI,不再硬编码/opt/memoh/toolkit/bin/{codex,claude}。internal/agent/runtime/external):DependencyRequirer(driver 声明依赖 id)、LauncherResolver/Launcher(按 managed → toolkit → PATH 的来源优先级解析可执行文件,不做版本判断)、VersionObserver(握手版本回写缓存)、DependencyMissingError;反馈码agent_dependency_missing(409,argsdep_id/install_task_id)。internal/workspacedeps):Service实现上述端口;无副本时通过background.SpawnManaged投递后台安装并返回 task id。/data/.memoh/deps/bin(存在时),direct runtime 与通用 ACP 的containerPath同步——这是覆盖层对 agent 命令生效的前提。dependency {dependency_id},CreateRequest.enabled可选;ListModels透传 feedback 错误;runtime_notice的 metadata 投影为 UI messageargs。验证
go test ./...全绿;golangci-lint0 issues;FX 图校验通过。agent_dependency_missing并触发后台安装。🤖 Generated with Claude Code
https://claude.ai/code/session_017sihinqYWYNmZ9K842WqDJ