When I ask the agent to make a small change in an existing file, it sometimes deletes unrelated parts of the file instead of applying a minimal edit. This seems to happen mostly in Python files.
For example, I may ask it to add a few lines or update a single function, but the generated diff shows large sections of existing code being removed. This happens even when the requested change is very small.
Expected behavior is that the agent should preserve the existing file content and only modify the relevant part. It should not delete unrelated code unless I explicitly ask for that.
Actual behavior is that the agent sometimes rewrites or removes large blocks of code, especially in Python files, which makes the diff unsafe to accept and risks losing working code.
This issue makes file editing unreliable because even simple changes can result in unexpected deletions