xskill icon indicating copy to clipboard operation
xskill copied to clipboard

test(server): 修复 kernel-host 合入后的 scheduler 契约回归

Open tiammomo opened this issue 3 months ago • 0 comments

Problem

main@bac932c(#364)新增了常驻 kernel-host scheduler,但 tests/test_server_no_llm_fallback.py 仍断言旧的 scheduler 集合。结果是 main CI 以及所有基于当前 main 的 PR merge-ref 在 Python 3.9–3.12、Linux/macOS/Windows 上一致失败:

  • test_standalone_worker_commands_share_resolved_ecosystem_home 缺少 kernel-host
  • test_team_server_schedules_only_server_watcher 缺少 kernel-host

这不是 #399 或 #400 的分支回归;两条 PR 都继承了当前 main 的相同失败。

Proposed solution

  • 更新两条 scheduler 契约测试,将 kernel-host 纳入预期集合;
  • standalone 模式确认 kernel-host 不携带 --server,team-server 模式确认携带 --server;
  • 确认两种模式下 kernel-host 都是 persistent scheduler,并在应用 shutdown 时停止;
  • 保留 home_root 仅用于本机生态扫描 worker 的现有边界,不给 kernel-host 添加不存在的 --home 契约;
  • 在当前 main 上运行聚焦测试和 CI 等价 UT/IT,确认没有掩盖真实启动差异。

Acceptance criteria

  • [x] 两条失败测试覆盖并接受预期的 kernel-host scheduler。
  • [x] 测试区分 standalone 与 team-server 的 --server 命令契约。
  • [x] 测试验证 kernel-host 是 persistent 且可随应用停止。
  • [x] python -m pytest tests/test_server_no_llm_fallback.py -q 通过。
  • [x] PR 的 UT/IT 矩阵恢复通过。

Regression from #364. Blocks #399 and #400.

tiammomo avatar Sep 01 '26 07:09 tiammomo