Agent FixboardAgentFixboard

Coding agent stuck on 'did not conform to the edit format'

Every edit stops with The LLM did not conform to the edit format. The same report shows SearchReplaceNoExactMatch: This SEARCH block failed to exactly match lines, then 'SEARCH/REPLACE block failed to match', and then Only 3 reflections allowed, stopping.

From GitHub

Aider-AI/aider

Difficulty
Moderate
Time
~15 min
Steps
4
Fixed in
—
Last checked

No upstream fix: these steps work around it. Source: maintainer closed the issue for now without a code change; the workaround stands. Last checked 2026-10-25.

Symptom

Every edit stops with The LLM did not conform to the edit format. The same report shows SearchReplaceNoExactMatch: This SEARCH block failed to exactly match lines, then 'SEARCH/REPLACE block failed to match', and then Only 3 reflections allowed, stopping.

Evidence what you'll see

  • The error also says SEARCH/REPLACE block failed to match.
  • A later comment hits the same stop after The SEARCH section must exactly match an existing block of lines including all white space, comments, indentation, docstrings, etc.
  • One comment describes several SEARCH/REPLACE blocks in one reply, where the first block changes the lines the next block searches for.

Why it happens

Aider applies an edit only when the SEARCH block is a character-for-character copy of lines already in the file, including spaces and comments. If the model's SEARCH text differs at all, the match fails. The same thing happens when an earlier block in that reply has already changed the lines a later block is trying to find. Aider reflects on the failure and stops after three tries. The maintainer pointed at the edit-errors page and later closed the issue without a code change.

Affected versions

The linked issue does not name a version or an operating system. The version field on the report is blank. Comments describe the same stop on the release current at the time, in architect mode, and when the edit format is the whole-file format.

Fix steps

0 of 4 done

Your check marks stay in this browser only.

How to check it worked

  • The next edit is applied and the file on disk changes. The session does not stop at Only 3 reflections allowed, stopping.

If it still fails

  • The maintainer closed the issue and wrote that a new comment will reopen it. This report has no merged pull request.
  • A later comment says the error still happens with --diff-mode=udiff and asks whether that flag is the real fix. The linked issue does not name a release that removes the error.

Sources and credit

Summarized in our own words from these public reports. Credit goes to their authors.

Provided as is, without warranty. Try changes in a non-production environment and back up first. Security-related steps: verify against the official docs. Terms · Request removal or attribution change

Hit an error we don't cover? Submit it