Two agents, one limit, one refused.
All guides
Approvals
Updated
2 min read
by Anlyon Team

A GitHub file changed after review

Handle a stale reviewed file update using GitHub's blob SHA precondition, a fresh diff and a new approval.

GitHubconcurrencypreconditions

An approval can remain bound to the same request while the target file changes. These are different problems. Request binding detects a changed operation; a provider precondition protects against overwriting a resource that changed after review.

Anlyon's GitHub file-update adapter sends the blob SHA shown during review. If the file changes before the write, GitHub can reject the stale conditional update. The effect grades failed with the stale version recorded as evidence. This protection comes from GitHub's conditional write, not from the approval digest detecting a remote edit.

Reproduce the conflict safely

Use a disposable repository or fixture directory on a designated nondefault branch. Choose one existing UTF-8 text file within the adapter's configured path prefix and size limit. Create a preview of a small change and note the reviewed state.

Before dispatch, modify the file through a separate authorized path. Then attempt the reviewed update. Inspect the provider result and effect record. Confirm the intervening change remains intact. This is a test procedure; it is not a claim that a live provider run was performed for this article.

Recover with a new diff

Read the latest file and determine whether the proposed change still makes sense. Resolve the content conflict in your application or review workflow. Create a new preview showing the updated before-and-after text and obtain the required decision again.

Do not automatically replace the reviewed SHA with the latest SHA and resend the old content. That can erase the intervening change while presenting the operation as the previously approved edit.

Understand the boundary

The adapter updates one existing text file. It is not an atomic multi-file change or a general Git workflow. Its normal configuration avoids the default branch unless explicitly permitted. A successful commit establishes the recorded file change, not successful deployment or application tests.

For an unknown response, matching file content alone does not prove this action made the change. Reconciliation looks for provider evidence tied to the effect.

Follow adapter setup, the GitHub workflow guide and unknown-outcome reconciliation.

Continue with a related task

Free tier, no credit card. One command if you use Claude or Cursor.

$ claude mcp add anlyon -- npx -y @anlyonhq/mcp-server