Revert "fix(core): guide agent to pivot to read-only tools when plan mode blocks" - #6782
Revert "fix(core): guide agent to pivot to read-only tools when plan mode blocks"#6782wenshao wants to merge 1 commit into
Conversation
…mode blo…" This reverts commit 92b47a4.
|
Thanks for the PR! Template: Revert PR using GitHub default format — no project template headings. Not blocking for a maintainer revert, but a brief "why" in the body would save reviewers time. Problem: This reverts PR #6764 (merged yesterday), which fixed issue #6763 — the plan mode error message misleading the agent into immediately calling Direction: Maintainer revert — deferring to author's judgment. Flagging that without context, this restores the behavior reported as a bug in #6763. Size: 5 production lines across 2 core files ( Approach: Clean, minimal revert — exactly undoes PR #6764. No scope creep, no unrelated changes. Moving on to code review. 🔍 中文说明感谢 PR! 模板:Revert PR 使用了 GitHub 默认格式,没有项目模板标题。对于维护者的 revert 不做阻拦,但在 body 中简要说明"为什么"可以帮助审查者节省时间。 问题:此 PR 回退了昨天合并的 PR #6764,该 PR 修复了 issue #6763——plan mode 错误信息误导 agent 立即调用 方向:维护者 revert——尊重作者的判断。提示一下:在没有上下文的情况下,这会恢复 #6763 中报告的 bug 行为。 规模:2 个核心文件中 5 行生产代码( 方案:干净、最小化的 revert——精确回退 PR #6764。没有范围蔓延,没有无关改动。 进入代码审查 🔍 — Qwen Code · qwen3.7-max |
Code ReviewIndependent proposal: If reverting the pivot-to-read-only guidance from PR #6764, I would: (1) restore the original error messages in Comparison: The PR's diff matches this exactly. Clean inverse of PR #6764, no extra changes, no missed spots. The No critical issues. No AGENTS.md violations. Reuse check: N/A — this is a text revert, no new logic. Test ResultsUnit tests (run on PR branch in worktree): TypeScript compilation: CLI Smoke Test (tmux)Dev build verified working on the PR branch: CLI responds correctly. The plan mode error message changes are internal (only triggered when a non-read-only tool is blocked in plan mode context) and cannot be directly exercised via a simple CLI invocation — covered by the unit tests above. 中文说明代码审查独立方案: 如果要回退 PR #6764 中的 pivot-to-read-only 引导,我会:(1) 恢复 对比: PR 的 diff 与此完全一致。PR #6764 的干净逆向操作,没有多余改动,没有遗漏。 无关键问题。无 AGENTS.md 违规。 测试结果单元测试(在 worktree 的 PR 分支上运行):258 + 58 测试全部通过。 TypeScript 编译: 无错误。 CLI 冒烟测试(tmux): Dev 构建正常工作,CLI 正确响应。Plan mode 错误信息变更是内部行为(仅在 plan mode 下阻止非只读工具时触发),无法通过简单 CLI 调用直接测试——由上述单元测试覆盖。 — Qwen Code · qwen3.7-max |
|
This is a clean, minimal revert by a maintainer — mechanically correct, tests green, no scope issues. The diff is an exact inverse of PR #6764 with nothing extra. The one thing giving me pause: the original PR fixed a documented problem (issue #6763 — the error message misleading the agent into immediately exiting plan mode), was merged yesterday after both bot and maintainer review with local verification, and is now being reverted by the same maintainer who approved it. No explanation in the PR body. That pattern usually means the fix looked good in tests but caused problems at runtime, or the maintainer has reconsidered the approach. Either way, it's a maintainer judgment call. My independent proposal for this revert matches the diff exactly. Every change is necessary and nothing is missing. 258 + 58 unit tests pass, TypeScript compiles clean, CLI smoke test works. Approving — the revert itself is sound. Would appreciate a follow-up comment on the PR explaining what prompted the revert, so that issue #6763 can be revisited with better context if needed. 中文说明这是一个由维护者发起的干净、最小化的 revert——机械上正确,测试全绿,没有范围问题。Diff 是 PR #6764 的精确逆操作,没有多余内容。 唯一让我犹豫的是:原始 PR 修复了一个有记录的问题(issue #6763——错误信息误导 agent 立即退出 plan mode),昨天刚经过 bot 和维护者的审查及本地验证后合并,现在却被同一位批准它的维护者 revert 了。PR body 没有解释原因。这种模式通常意味着修复在测试中看起来没问题但在运行时产生了问题,或者维护者重新考虑了方案。无论如何,这是维护者的判断。 我对这个 revert 的独立方案与 diff 完全一致。每个变更都是必要的,没有遗漏。258 + 58 单元测试通过,TypeScript 编译无误,CLI 冒烟测试正常。 批准——revert 本身没有问题。希望作者能在 PR 中补充一条评论说明 revert 的原因,以便在需要时能更好地重新审视 issue #6763。 — Qwen Code · qwen3.7-max |
qwen-code-ci-bot
left a comment
There was a problem hiding this comment.
LGTM, looks ready to ship. ✅
Code Coverage Summary
CLI Package - Full Text ReportCore Package - Full Text ReportFor detailed HTML reports, please see the 'coverage-reports-22.x-ubuntu-latest' artifact from the main CI run. |
Reverts #6764