Agent trying to do git diff/git status at the end of each task

Where does the bug appear (feature/product)?

Cursor IDE

Describe the Bug

I am using GPT 5.2 and recently seeing agent want to do git diff/ git status etc and the end of every task, I didn’t see GPT 5.2 in cursor trying to work like this before or see it in codex, so I assume it is cursor prompt change, the thing is it make agent think the manual edit made by me or another agent in the same repo an unintended change and actively trying to revert them, it makes multi agent without a git worktree hard to work with each other even if they are touching completely unrelated pieces in the same repo.

Steps to Reproduce

use gpt 5.2 and it is trying to do git diff/ git status/ git porcelain almost everytime at the end of a task, and trying to revert change that is not done by current agent

Expected Behavior

do not assume the edit outside what the agent has changed is a accident made by the current agent

Operating System

Windows 10/11

Current Cursor Version (Menu → About Cursor → Copy)

2.4.0-pre.12.patch.0

For AI issues: which model did you use?

gpt5.2

Does this stop you from using Cursor

No - Cursor works, but with this issue

Hey, thanks for the report. This is interesting behavior with GPT 5.2, we haven’t seen this before.

We need a bit more info so we can pass it to the team:

  • Request ID: can you copy it from the chat context menu (top right)? We need the one from the session where the agent tries to roll back someone else’s changes.
  • An example prompt or task that triggers this. Does it happen with any task, or is there a pattern?
  • If you can, a screenshot of the moment when the agent tries to run git diff or git status, or suggests rolling back changes.

Also, there’s a similar thread about files building up in the review list: AI Agent file review list accumulates stale files and doesn't sync with git status. It might be related.

This topic was automatically closed 22 days after the last reply. New replies are no longer allowed.