Skip to content

[FIX] patch tool 'other' error bucket still dominant — 70/86 failures (81%) after decomposition fix #1537

Description

@Lexus2016

Problem (observed in real usage)

The patch tool other error bucket remains the dominant failure class after the #1502 decomposition fix landed. While new sub-categories (patch-ambiguous, patch-old-string-empty) now appear in the digest, 81% of patch failures still fall into the unclassified other bucket — the agent cannot determine why the patch was rejected and retries with near-identical content.

Evidence (aggregated, anonymized)

  • Frequency: 70 other-classified patch failures in 7-day window (1124 sessions scanned)
  • Failure rate: patch at 7.65% failure rate (86 total failures / 1124 sessions)
  • Reason breakdown: other=70, file-not-found=8, parse-error=2, patch-ambiguous=3, patch-old-string-empty=3 — 81% of all patch failures are still unclassified
  • Trend: per-session rate dropped from 8.4% (prior baseline, 68/806) to 6.2% (70/1124) — the fix is helping but other remains overwhelmingly dominant
  • Spiral signal: patch appears in repeated-tool-runs (max 6 consecutive in 3 sessions)

Impact on real tasks

When patch returns a generic other error, the agent retries the same edit with minor whitespace variations (up to 6 consecutive attempts) rather than switching to write_file or adjusting the match strategy. This wastes 3-6 tool calls per affected edit and frequently leaves the intended file change un-applied.

Proposed direction

  1. Audit the 70 other failures: sample session data to identify the top 2-3 actual error causes now that the prior sub-categories are extracted
  2. Add new sub-classifications for the dominant remaining causes (e.g., fuzzy-match-failure, indentation-mismatch, context-truncated)
  3. Add a directive after 2 consecutive other-class patch failures on the same file: switch to write_file for the full content

Value

  • Impact: 0.7 (70 failures/week, 81% of patch errors, retry spirals up to 6 deep)
  • Effort: 0.4 (audit + add classification branches + recovery directive)
  • Priority Score: 0.7 × 2 × (1 − 0.4 × 0.4) = 1.00

Metadata

Metadata

Assignees

No one assigned

    Labels

    acceptedAccepted by evolution — sent to a PR / implementedbugSomething isn't workingintrospectionFound by session introspection

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions