Skip to content

feat(client): 增加 Edge 本地进程 executor#37

Merged
DeliciousBuding merged 1 commit into
dev/delicious233from
feat/client-runner-process-adapter-delicious233
May 22, 2026
Merged

feat(client): 增加 Edge 本地进程 executor#37
DeliciousBuding merged 1 commit into
dev/delicious233from
feat/client-runner-process-adapter-delicious233

Conversation

@DeliciousBuding
Copy link
Copy Markdown
Collaborator

目标

  • 为 Edge Run lifecycle 增加可测试的本地进程 executor。
  • 支持将 stdout / stderr 转为 run.output.batch,并映射成功、失败、取消等状态事件。
  • 未配置 --runner-command 时仍使用现有 MockExecutor。

改动

  • 新增 lifecycle.ProcessExecutor,通过 exec.CommandContext 启动可配置命令。
  • agenthub-edge 增加 --runner-command 和可重复 --runner-arg
  • 子进程会收到 AGENTHUB_RUN_ID / AGENTHUB_PROJECT_ID / AGENTHUB_THREAD_ID
  • 补齐缺失 run、nil bus/store、命令缺失、命令启动失败、非零退出、取消、重复启动等测试。
  • 更新总路线图、客户端路线图和本分支路线图。

边界

  • 这是本地进程 executor 边界,不是完整 Claude Code / Codex / OpenCode adapter。
  • 不改变公共 REST API 或 WebSocket event。
  • 不引入第三方依赖。

验证

  • git diff --check
  • python -c "import yaml, pathlib; yaml.safe_load(pathlib.Path('api/openapi.yaml').read_text(encoding='utf-8')); print('yaml ok')"
  • cd edge-server; go test -count=1 ./...
  • cd runner; go test -count=1 ./...

Review

  • 只读交叉 review 发现 1 个 High、1 个 Medium:缺失 run 仍会启动进程、nil bus/store 可导致 panic。
  • 已修复:缺失 run 返回 store.ErrNotFound 且不启动进程;nil bus/store 在构造期返回错误。

Copilot AI review requested due to automatic review settings May 22, 2026 21:40
@DeliciousBuding DeliciousBuding merged commit 19a9273 into dev/delicious233 May 22, 2026
1 of 2 checks passed
@DeliciousBuding DeliciousBuding deleted the feat/client-runner-process-adapter-delicious233 branch May 22, 2026 21:41
@DeliciousBuding DeliciousBuding review requested due to automatic review settings May 22, 2026 22:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant