Undo delete the file completely

Hey, this is a known issue. Undo on files that the agent created or modified can delete the whole file instead of rolling back the changes. The bug is logged, and the team is aware.

The same issue is discussed here: Undo suggestion deletes entire file after accepting a created file + one small suggestion

For now, it’s best not to use Ctrl+Z or Undo All on files the agent just created. If you need to revert changes, use Restore Checkpoint from the agent message menu in chat.