Skip to content

fix(mcp): steer a soft doctor smoke at solidify - #25

Merged
linkerlin merged 1 commit into
masterfrom
cursor/doctor-pending-solidify-steer-8076
Nov 3, 2026
Merged

linkerlin merged 1 commit into
masterfrom
cursor/doctor-pending-solidify-steer-8076

Conversation

@linkerlin

Copy link
Copy Markdown
Owner

Summary

未完成 run 上,readonly_smoke 点名的 swarm_doctor 在软缺口(soft_continue=true)时现在也给出 next_action=swarm_solidify 和 preserve 三元组。只读冒烟之后按 next_action 走的宿主会去固化,而不会因为缺这个键、又看到「循环没被挡住」再去 tick。gate_soft_continue 与 session_not_failed 仍然缺席。本调用不结算这条 run,不写 Parent baseline,不执行 --fix,也不放宽固化门。

On an unfinished run, a soft-continue swarm_doctor report (the other tool named by readonly_smoke) now sets next_action=swarm_solidify and the preserve triad. A host that smokes and then follows next_action solidifies instead of ticking because the action was missing and the loop looked unblocked. gate_soft_continue and session_not_failed stay absent. The call does not settle the run, write a Parent baseline, run --fix, or relax the solidify gate.

What changed

  • 仅当存在未完成 run、soft_continue=true、且没有硬 blockers 时,swarm_doctor 增加 pending_solidify、next_action=swarm_solidify、readonly_smoke(settles_run=false)和 preserve_pending=true / abandon_run=false / action_required=swarm_solidify。hint 先写现在调用 swarm_solidify,不要 tick,固化前不要执行 fixes。
  • 不写 gate_soft_continue。缺席不是 false,避免把严格 false 读成整段会话失败(DEBUG #67)。不写 session_not_failed:那个旗标只属于 tick 重定向,不是 doctor 的健康位。
  • 没有未完成 run 时 doctor 形状不变。硬阻断(例如不是 git 仓库,ok=false)不另给 next_action。
  • 工具描述与返回体同一口径。DEBUG #61 的宿主目录缓存没有做假修复。
  • 不改第一次 tick 重定向(仍是 ok=true、retryable=false、没有 error、没有 loop_fuse、软缺口上 gate_soft_continue 缺席)。不改保险丝(ok=false、loop_fuse=pending_redirect_loop)。

How to test

  1. uv run pytest tests/test_mcp_host_usability_pending_smoke.py tests/test_mcp_server.py tests/test_mcp_protocol.py tests/test_mcp_host_usability_p0.py tests/test_mcp_host_usability_p1.py tests/test_mcp_host_usability_p2.py tests/test_mcp_host_usability_polish.py tests/test_swarm.py -q --tb=line
    • Expected: 153 passed.
    • test_pending_doctor_on_a_soft_gap_names_solidify fails on unmodified master (KeyError: pending_solidify). The hard-blocker case stays ok=false with no next_action.
  2. uv run ruff check src tests && uv run ruff format --check src tests && uv run mypy src
    • Expected: ruff clean, mypy Success: no issues found in 353 source files.

Risk

Low. The soft-continue doctor envelope gains a solidify steer only while a run is unfinished. ok, soft_continue, and loop_ready stay as the open-box report computed them. Hard failures do not gain next_action. Solidify gate, skip_validation, Parent baseline, and val seal are unchanged.

Harness/evaluator governance

Upstream governance surface: MCP swarm_doctor return while a run is unfinished (soft-continue only). Not solidify, selector, mutation, or the frozen gate.
Downstream EvoX impact: N/A -- existing read-only tool return, no bridge or contract change.
Rollout-local scope: host-visible doctor smoke only; boot, status, and the tick redirect envelope are unchanged.
Promotion boundary: N/A -- no proposal/rollout/default promotion.
Evaluator mismatch sets: N/A
Non-regression evidence: tests/test_mcp_host_usability_pending_smoke.py pins the soft-continue steer (next_action=swarm_solidify, preserve triad, gate_soft_continue and session_not_failed absent, no baseline file) and the hard-blocker path (no new action).
Fix-severity review: low
Owner approval: N/A
Security boundary: no new data, tool, host, network, or secret surface. Doctor still calls doctor(fix=False).
Rollback: revert this commit.
Live promotion: no
Autonomous evaluator self-editing: no

Self-check

  • No new runtime dependencies without a clear justification in "What changed".
  • Tests added or updated to cover the new behavior; gates pass locally: uv run pytest (modules listed above), uv run ruff check src tests, uv run ruff format --check src tests, uv run mypy src.
Open in Web Open in Cursor 

A read-only swarm_doctor call while a run is unfinished and the report
is soft-continue now sets next_action to swarm_solidify. gate_soft_continue
and session_not_failed stay absent, and the call still does not settle
the run or write a Parent baseline.

Co-authored-by: Steper Lin <linker.lin@live.com>
Copilot AI balanced review requested due to automatic review settings November 2, 2026 23:36

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota. Try requesting a review at a lower effort level.

@linkerlin
linkerlin merged commit b8bd4da into master Nov 3, 2026
5 checks passed
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.

3 participants