Skip to content

improve: show edit mismatch candidate lines#97269

Closed
qingminglong wants to merge 13 commits into
openclaw:mainfrom
qingminglong:codex/edit-mismatch-candidates
Closed

improve: show edit mismatch candidate lines#97269
qingminglong wants to merge 13 commits into
openclaw:mainfrom
qingminglong:codex/edit-mismatch-candidates

Conversation

@qingminglong

@qingminglong qingminglong commented Jun 27, 2026

Copy link
Copy Markdown
Contributor

Closes #97032

What Problem This Solves

Resolves a problem where edit tool oldText mismatch failures only showed the generic exact-match error plus current file contents, leaving users to guess whether indentation, escaping, or nearby text drift caused the miss.

Why This Change Was Made

The edit mismatch path now appends bounded nearest-candidate diagnostics with line numbers, escaped line diffs, and indentation hints when the failing edit can be identified. Matching behavior is unchanged: the tool still requires the same exact/fuzzy edit semantics, and validation-phase no-op mismatch errors avoid candidate guesses when the indexed edit source is ambiguous.

User Impact

Users and agents get actionable feedback after a failed edit call: the error can point at nearby candidate lines and show the visible difference, while still preserving the existing current-file-content hint.

Evidence

  • Real behavior proof: ran node --import tsx against createEditTool() on a temp file and intentionally submitted an oldText indentation mismatch. Result: the thrown edit-tool error included Nearest candidate lines:, Candidate 1 (line 2):, indentation: expected 6 spaces, candidate 2 spaces, and escaped diff lines (- " return value;" / + " return value;") after the redacted Current file contents: block.
  • node scripts/run-vitest.mjs src/agents/sessions/tools/edit.test.ts - passed, 30 tests.
  • node scripts/run-vitest.mjs src/agents/agent-tools.create-openclaw-coding-tools.test.ts - passed, 66 tests.
  • node scripts/run-vitest.mjs src/cron/isolated-agent/run-fallback-policy.test.ts src/docs/clawhub-plugin-docs.test.ts src/config/talk-defaults.test.ts src/docs/environment-docs.test.ts src/agents/minimax-docs.test.ts - passed, covering the five CI red-log test families from run 28729651276 on the current PR head.
  • git diff --check - passed.
  • python .agents\skills\autoreview\scripts\autoreview --mode local - clean, no accepted/actionable findings reported.
  • Local lint note: $env:OPENCLAW_OXLINT_SKIP_PREPARE='1'; node scripts/run-oxlint.mjs --tsconfig config/tsconfig/oxlint.core.json src/agents/sessions/tools/edit.ts src/agents/sessions/tools/edit.test.ts was blocked before linting by missing optional Windows platform package @oxlint-tsgolint/win32-x64/tsgolint.exe; pnpm install --frozen-lockfile was retried once and timed out after 120s, and the commit hook also showed missing optional @oxfmt/binding-win32-x64-msvc.

Follow-up after ClawSweeper waiting-on-author review (commit 3fd09be):

# ClawSweeper asked for candidate/target text to be bounded before scoring, storage, and escaped diff formatting.
# Added per-line diagnostic truncation before candidate scoring and formatting.
# Added a long single-line mismatch regression proving diagnostics stay bounded and do not leak long-line tails.

node scripts/run-vitest.mjs src/agents/sessions/tools/edit.test.ts
# passed: 25 tests

node scripts/run-vitest.mjs src/agents/agent-tools.create-openclaw-coding-tools.test.ts
# passed: 65 tests

$env:OPENCLAW_OXLINT_SKIP_PREPARE='1'; node scripts/run-oxlint.mjs --tsconfig config/tsconfig/oxlint.core.json src/agents/sessions/tools/edit.ts src/agents/sessions/tools/edit.test.ts
# passed

git diff --check
# passed

Follow-up after July 5 review blocker (commit 4ced22d):

# ClawSweeper found that PR head 0efc50000b still split the whole current file before applying EDIT_MISMATCH_SCAN_LINE_LIMIT.
# Replaced the full-file split with bounded line collection that stops at EDIT_MISMATCH_SCAN_LINE_LIMIT and truncates each stored line before cheap scoring, expensive scoring, storage, and diff formatting.
# Added a many-line regression proving line 1001 is not collected or surfaced in mismatch diagnostics.

node scripts/run-vitest.mjs src/agents/sessions/tools/edit.test.ts
# passed: 30 tests

node scripts/run-vitest.mjs src/agents/agent-tools.create-openclaw-coding-tools.test.ts
# passed: 66 tests

node scripts/run-vitest.mjs src/cron/isolated-agent/run-fallback-policy.test.ts src/docs/clawhub-plugin-docs.test.ts src/config/talk-defaults.test.ts src/docs/environment-docs.test.ts src/agents/minimax-docs.test.ts
# passed: 5 targeted files, including the five CI red-log test families from run 28729651276

git diff --check
# passed

python .agents\skills\autoreview\scripts\autoreview --mode local
# clean: no accepted/actionable findings reported

Follow-up after CI red-log docs failures (commit b5124f7):

# Merged the latest upstream/main into the PR branch with a normal merge commit, resolving the edit.ts import conflict by keeping upstream's @openclaw/normalization-core utf16-slice import and this PR's bounded candidate diagnostics imports.
# The PR diff is again limited to src/agents/sessions/tools/edit.ts and src/agents/sessions/tools/edit.test.ts.

node scripts/run-vitest.mjs src/cron/isolated-agent/run-fallback-policy.test.ts src/config/talk-defaults.test.ts src/docs/environment-docs.test.ts src/docs/clawhub-plugin-docs.test.ts
# passed: 4 targeted files

node scripts/run-vitest.mjs src/agents/sessions/tools/edit.test.ts src/agents/agent-tools.create-openclaw-coding-tools.test.ts
# passed: 96 tests

git diff --check
# passed

Follow-up after removing unrelated QA timeout hunk (commit 475a968):

# ClawSweeper found that the native-command-session-target QA timeout relaxation was unrelated to the edit mismatch diagnostics fix.
# Removed that YAML hunk so the PR diff is back to the edit mismatch implementation/test surface.
# No runtime behavior was changed beyond dropping the unrelated QA scenario timeout edit.

git diff --check
# passed

git diff upstream/main -- qa/scenarios/channels/native-command-session-target.yaml
# no output: QA scenario timeout now matches upstream/main

Follow-up after current-head bounded collector repair (commit b5ed9e2, head b5ed9e2):

# ClawSweeper found that collectBoundedDiagnosticLines still normalized the full current file before enforcing EDIT_MISMATCH_SCAN_LINE_LIMIT.
# Replaced that path with incremental CRLF/LF line collection that stops at the scan limit and truncates each stored line before candidate scoring or formatting.
# Updated the scan-limit regression to use CRLF input so the bounded path covers CRLF-heavy files.

node scripts/run-vitest.mjs src/agents/sessions/tools/edit.test.ts
# passed: 30 tests

git diff --check
# passed

@openclaw-barnacle openclaw-barnacle Bot added agents Agent runtime and tooling size: M labels Jun 27, 2026
@clawsweeper

clawsweeper Bot commented Jun 27, 2026

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge. Reviewed July 6, 2026, 8:29 AM ET / 12:29 UTC.

Summary
The PR adds bounded nearest-candidate line diagnostics to edit-tool oldText mismatch errors and regression coverage for whitespace, multiline, truncation, scan-limit, and no-op validation cases.

PR surface: Source +268, Tests +164. Total +432 across 2 files.

Reproducibility: yes. Current main source only appends the generic exact-match error plus capped current file contents, while PR proof and tests exercise production createEditTool mismatch output with candidate diagnostics.

Review metrics: 1 noteworthy metric.

  • Diagnostic bounds: 1000 lines scanned, 240 chars per line, 24 prefiltered, 3 rendered. These source-level caps are the maintainer-relevant proof that the previous failed-edit availability concern is now bounded before candidate scoring.

Stored data model
Persistent data-model change detected: serialized state: src/agents/sessions/tools/edit.test.ts, serialized state: src/agents/sessions/tools/edit.ts, unknown-data-model-change: src/agents/sessions/tools/edit.test.ts, unknown-data-model-change: src/agents/sessions/tools/edit.ts. Confirm migration or upgrade compatibility proof before merge.

Root-cause cluster
Relationship: fixed_by_candidate
Canonical: #97032
Summary: The linked issue is the canonical edit mismatch diagnostics request; this PR and several sibling PRs are competing implementation candidates for the same user-facing output problem.

Members:

Proposal only: this assessment does not dispatch repair, suppress jobs, mutate sibling items, close, or merge anything.

Merge readiness
Overall: 🐚 platinum hermit
Proof: 🐚 platinum hermit
Patch quality: 🐚 platinum hermit
Result: ready for maintainer review.

Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch.

Rank-up moves:

  • [P2] Get a clean required-check run or maintainer rerun for the current QA Smoke CI failure, which is outside the edit-tool scenario in the log.

Risk before merge

  • [P1] Multiple open sibling PRs target the same edit mismatch diagnostics issue, so maintainers still need to choose one canonical output contract and branch.
  • [P1] The current head has a failing QA Smoke CI job in scenarios outside runtime-tool-edit; the exact head still needs a clean required-check run or maintainer triage before merge.

Maintainer options:

  1. Decide the mitigation before merge
    Land one bounded edit-tool diagnostic implementation with the maintainer-approved wording, then close or rebase the sibling PRs against that canonical choice.
  2. Pause or close
    Do not merge this PR until maintainers decide whether the risk is worth taking.

Next step before merge

  • No automated repair is currently identified; maintainer review should choose the canonical sibling implementation and require clean checks before merge.

Maintainer decision needed

  • Question: Should this PR's candidate-line wording and bounded diagnostic shape become the canonical implementation for the edit mismatch diagnostics request?
  • Rationale: Several open PRs implement the same user-facing edit mismatch output contract, and automation should not choose the final maintainer-facing wording and canonical branch alone.
  • Likely owner: steipete — steipete carried the major agent runtime refactor and is the strongest history-backed owner for the current edit-tool output contract choice.
  • Options:
    • Use this PR as canonical (recommended): After required checks are clean, land this bounded implementation and close or rebase the sibling attempts against it.
    • Prefer a sibling PR: Pause this PR and choose another open implementation if its output contract is closer to the desired product behavior.
    • Request a combined branch: Ask for one final narrow PR that preserves this branch's bounded scanner while adopting any preferred wording from the sibling attempts.

Security
Cleared: No concrete security or supply-chain concern was found; the diff stays inside the existing edit-tool read/error path and reuses an existing dependency.

Review details

Best possible solution:

Land one bounded edit-tool diagnostic implementation with the maintainer-approved wording, then close or rebase the sibling PRs against that canonical choice.

Do we have a high-confidence way to reproduce the issue?

Yes. Current main source only appends the generic exact-match error plus capped current file contents, while PR proof and tests exercise production createEditTool mismatch output with candidate diagnostics.

Is this the best way to solve the issue?

Yes for the code path, with one maintainer caveat. The edit-tool mismatch wrapper is the right owner boundary and the current implementation is bounded, but maintainers still need to pick the canonical output contract among sibling PRs.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning high; reviewed against 3c530c79a05b.

Label changes

Label changes:

  • add rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🐚 platinum hermit and patch quality is 🐚 platinum hermit.
  • add status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Sufficient (terminal): The PR body includes after-fix terminal output from production createEditTool showing candidate diagnostics after an intentional oldText mismatch, with private paths redacted.
  • remove rating: 🦐 gold shrimp: Current PR rating is rating: 🐚 platinum hermit, so this older rating label is no longer current.
  • remove merge-risk: 🚨 availability: Current PR review selected no merge-risk labels.
  • remove status: ⏳ waiting on author: Current PR status label is status: 👀 ready for maintainer look.

Label justifications:

  • P3: This is a low-priority edit-tool diagnostics improvement with limited blast radius, not an urgent runtime or channel regression.
  • rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🐚 platinum hermit and patch quality is 🐚 platinum hermit.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Sufficient (terminal): The PR body includes after-fix terminal output from production createEditTool showing candidate diagnostics after an intentional oldText mismatch, with private paths redacted.
  • proof: sufficient: Contributor real behavior proof is sufficient. The PR body includes after-fix terminal output from production createEditTool showing candidate diagnostics after an intentional oldText mismatch, with private paths redacted.
Evidence reviewed

PR surface:

Source +268, Tests +164. Total +432 across 2 files.

View PR surface stats
Area Files Added Removed Net
Source 1 272 4 +268
Tests 1 165 1 +164
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 2 437 5 +432

What I checked:

  • Repository policy read: Root AGENTS.md and src/agents/AGENTS.md were read fully; their deep-review, scoped-agent, bounded-runtime, and PR routing guidance affected this review. (AGENTS.md:1, 65131633a132)
  • Current main baseline: Current main only appends a capped Current file contents block on edit mismatch; nearest-candidate diagnostics are absent from the baseline edit tool. (src/agents/sessions/tools/edit.ts:187, 65131633a132)
  • PR head implementation: PR head adds incremental bounded line collection, candidate scoring/formatting, and mismatch-error decoration after the apply phase, so the previous full-file normalization finding is no longer present. (src/agents/sessions/tools/edit.ts:216, b5ed9e2d4bf1)
  • Focused PR tests: PR head covers whitespace candidates, multiline windows, three-candidate limiting, long-line truncation, CRLF scan limiting, and no-op validation suppression. (src/agents/sessions/tools/edit.test.ts:73, b5ed9e2d4bf1)
  • Dependency surface check: The PR uses the existing diff package that is already a root dependency and already imported by edit-diff.ts, so it does not add a new supply-chain source. (package.json:1999, 65131633a132)
  • CI signal: The current QA Smoke CI failure is in reasoning/empty-response scenarios while the runtime-tool-edit scenario passed, so it is a merge blocker for checks but not a supported edit-tool code finding from this diff. (b5ed9e2d4bf1)

Likely related people:

What the crustacean ranks mean
  • 🦀 challenger crab: rare, exceptional readiness with strong proof, clean implementation, and convincing validation.
  • 🦞 diamond lobster: very strong readiness with only minor maintainer review expected.
  • 🐚 platinum hermit: good normal PR, likely mergeable with ordinary maintainer review.
  • 🦐 gold shrimp: useful signal, but proof or patch confidence is still limited.
  • 🦪 silver shellfish: thin signal; proof, validation, or implementation needs work.
  • 🧂 unranked krab: not merge-ready because proof is missing/unusable or there are serious correctness or safety concerns.
  • 🌊 off-meta tidepool: rating does not apply to this item.

Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics.

How this review workflow works
  • ClawSweeper keeps one durable marker-backed review comment per issue or PR.
  • Re-runs edit this comment so the latest verdict, findings, and automation markers stay together instead of adding duplicate bot comments.
  • A fresh review can be triggered by eligible @clawsweeper re-review comments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.
  • PR/issue authors and users with repository write access can comment @clawsweeper re-review or @clawsweeper re-run on an open PR or issue to request a fresh review only.
  • Maintainers can also comment @clawsweeper review to request a fresh review only.
  • Fresh-review commands do not start repair, autofix, rebase, CI repair, or automerge.
  • Maintainer-only repair and merge flows require explicit commands such as @clawsweeper autofix, @clawsweeper automerge, @clawsweeper fix ci, or @clawsweeper address review.
  • Maintainers can comment @clawsweeper explain to ask for more context, or @clawsweeper stop to stop active automation.
Review history (13 earlier review cycles; latest 8 shown)
  • reviewed 2026-07-05T05:42:18.008Z sha 1f00c59 :: needs changes before merge. :: [P2] Restore the docs snippets to the canonical package JSON
  • reviewed 2026-07-05T05:48:38.254Z sha 1f00c59 :: needs changes before merge. :: [P2] Bound scanning before normalizing the file
  • reviewed 2026-07-05T05:57:31.034Z sha 54be730 :: needs changes before merge. :: [P2] Bound collection before normalizing the file
  • reviewed 2026-07-05T06:14:39.779Z sha b5124f7 :: needs changes before merge. :: [P2] Bound collection before normalizing the file
  • reviewed 2026-07-05T06:36:56.301Z sha 1670f1e :: needs changes before merge. :: [P2] Bound collection before normalizing the file | [P2] Keep QA timeout changes out of this PR
  • reviewed 2026-07-05T06:45:14.830Z sha 1670f1e :: needs changes before merge. :: [P2] Drop the unrelated QA timeout change
  • reviewed 2026-07-05T06:50:45.962Z sha 1670f1e :: needs changes before merge. :: [P2] Drop the unrelated QA timeout change
  • reviewed 2026-07-06T10:49:40.341Z sha 475a968 :: needs changes before merge. :: [P2] Bound collection before normalizing the file

@clawsweeper clawsweeper Bot added rating: 🧂 unranked krab Not merge-ready due to missing proof or serious correctness/safety concerns. status: 📣 needs proof The PR needs real behavior proof before ClawSweeper can clear the contributor ask. P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. merge-risk: 🚨 other 🚨 Merging this PR has meaningful risk outside the owned taxonomy. labels Jun 27, 2026
@qingminglong

Copy link
Copy Markdown
Contributor Author

@clawsweeper re-review

Updated this branch to address the previous lint/review blockers and refreshed the Evidence section with real edit-tool mismatch output plus focused validation.

@clawsweeper

clawsweeper Bot commented Jun 27, 2026

Copy link
Copy Markdown
Contributor

🦞🧹
ClawSweeper re-review requested.

I asked ClawSweeper to review this item again.
Action: item re-review queued (workflow sweep.yml, event repository_dispatch).
Result: the existing ClawSweeper review comment will be edited in place when the review finishes.

@clawsweeper clawsweeper Bot added proof: sufficient ClawSweeper judged the real behavior proof convincing. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. merge-risk: 🚨 availability 🚨 May cause crashes, hangs, restart loops, stalls, or process outages. rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. and removed rating: 🧂 unranked krab Not merge-ready due to missing proof or serious correctness/safety concerns. status: 📣 needs proof The PR needs real behavior proof before ClawSweeper can clear the contributor ask. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. labels Jun 27, 2026
@clawsweeper clawsweeper Bot added rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. and removed rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. labels Jun 27, 2026
@qingminglong

Copy link
Copy Markdown
Contributor Author

Have a nice day, please help merge!

@qingminglong

Copy link
Copy Markdown
Contributor Author

@clawsweeper re-review

Addressed the waiting-on-author boundedness finding in 3fd09be and updated the PR body Evidence section with focused edit-tool regression proof.

@clawsweeper

clawsweeper Bot commented Jul 1, 2026

Copy link
Copy Markdown
Contributor

🦞🧹
ClawSweeper re-review requested.

I asked ClawSweeper to review this item again.
Action: item re-review queued (workflow sweep.yml, event repository_dispatch).
Result: the existing ClawSweeper review comment will be edited in place when the review finishes.

@clawsweeper clawsweeper Bot added rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. and removed rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. labels Jul 1, 2026
@clawsweeper clawsweeper Bot added rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. merge-risk: 🚨 automation 🚨 May affect CI, automerge, proof capture, label sync, or maintainer automation. and removed rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. labels Jul 5, 2026
@qingminglong

Copy link
Copy Markdown
Contributor Author

@clawsweeper re-review

Current head 1670f1e8dd079a3dffaf99cdb5dfe34e4ad1657e addresses the latest PR log failures:

  • merged latest upstream/main with a normal merge commit, resolving the edit-tool import conflict;
  • fixed the QA Smoke CI red log by relaxing only the native-command-session-target recovery wait after the artifact showed /stop already returned Agent was aborted and the recovery reply arrived just past the prior 60000ms boundary;
  • refreshed the PR body Evidence for this head.

Current-head checks are green: QA Smoke CI, Real behavior proof, and the focused edit-tool/QA catalog proof listed in the Evidence section all pass.

@clawsweeper

clawsweeper Bot commented Jul 5, 2026

Copy link
Copy Markdown
Contributor

🦞🧹
ClawSweeper re-review requested.

I asked ClawSweeper to review this item again.
Action: item re-review queued (workflow sweep.yml, event repository_dispatch).
Result: the existing ClawSweeper review comment will be edited in place when the review finishes.

@clawsweeper clawsweeper Bot added rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. and removed rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. merge-risk: 🚨 availability 🚨 May cause crashes, hangs, restart loops, stalls, or process outages. labels Jul 5, 2026
@qingminglong

Copy link
Copy Markdown
Contributor Author

@clawsweeper re-review

Current head 475a968b223662ff96097d752a0c00ccbc6f0f08 removes the unrelated QA timeout hunk called out in the latest review. The PR body Evidence was refreshed to replace the old 1670f1e8dd timeout note with the current-head cleanup proof:

git diff --check
# passed

git diff upstream/main -- qa/scenarios/channels/native-command-session-target.yaml
# no output: QA scenario timeout now matches upstream/main

@clawsweeper

clawsweeper Bot commented Jul 6, 2026

Copy link
Copy Markdown
Contributor

🦞🧹
ClawSweeper re-review requested.

I asked ClawSweeper to review this item again.
Action: item re-review queued (workflow sweep.yml, event repository_dispatch).
Result: the existing ClawSweeper review comment will be edited in place when the review finishes.

@clawsweeper clawsweeper Bot added merge-risk: 🚨 availability 🚨 May cause crashes, hangs, restart loops, stalls, or process outages. and removed merge-risk: 🚨 automation 🚨 May affect CI, automerge, proof capture, label sync, or maintainer automation. labels Jul 6, 2026
@qingminglong

Copy link
Copy Markdown
Contributor Author

@clawsweeper re-review

@clawsweeper

clawsweeper Bot commented Jul 6, 2026

Copy link
Copy Markdown
Contributor

🦞🧹
ClawSweeper re-review requested.

I asked ClawSweeper to review this item again.
Action: item re-review queued (workflow sweep.yml, event repository_dispatch).
Result: the existing ClawSweeper review comment will be edited in place when the review finishes.

@qingminglong

Copy link
Copy Markdown
Contributor Author

@clawsweeper re-review

@clawsweeper clawsweeper Bot added rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. and removed rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. merge-risk: 🚨 availability 🚨 May cause crashes, hangs, restart loops, stalls, or process outages. labels Jul 6, 2026
@vincentkoc

Copy link
Copy Markdown
Member

Thanks @qingminglong. The canonical fix for #97032 landed through #97038 as 4204a948457cafc601c1f27a1965fcfb011c2131.

We selected #97038 because it keeps the diagnostic in the shared edit-diff owner path, bounds both scan cost and output, and covers typo, indentation, escaping, cap, and surrogate-safe truncation behavior with focused tests. This PR targets the same behavior, so I’m closing it as superseded. Your parallel implementation helped validate the need and solution space.

@vincentkoc vincentkoc closed this Jul 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agents Agent runtime and tooling P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. proof: sufficient ClawSweeper judged the real behavior proof convincing. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. size: M status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

edit tool: show candidate lines with diff on oldText match failure

2 participants