Google Gemini Erases User’s Code: ‘I Have Let You Down Totally and Disastrously’


According to a GitHub user, Google Gemini’s coding agent seemingly hallucinated during a task and subsequently removed a large portion of code. The user, Anuraag Gupta, who goes by anuraag2601 on GitHub, recounted his experience with Gemini CLI, an open-source coding agent. Gupta, a product lead at Cyware, identifies himself as a “curious PM experimenting with vibe coding” rather than a developer. Mashable authenticated the post through a correlating X profile and received advice from Gupta on preventing similar incidents.

Gupta’s endeavor to evaluate Anthropic’s Claude Code against the capabilities of Gemini CLI culminated in what he referred to as “one of the most unsettling and fascinating AI failures I have ever seen.” Google has yet to respond to the situation.

While seasoned developers may be aware of testing AI coding agents in controlled environments, the increasing use among non-developers is influenced by LLMs’ capability to generate software without any programming expertise. Although Gupta’s code was exploratory, it could have real-world ramifications, as demonstrated when tech investor Jason Lemkin’s engagement with Replit AI resulted in a company database erasure. The Replit CEO expressed regret, labeling it “unacceptable.”

The problem for Gupta initiated with a command to transfer files to a new folder, which was absent. Gemini acknowledged that the files were lost due to a command error and security restrictions preventing a search beyond the project directory. Gupta elaborated on the occurrence in a GitHub post.

Gupta employs Gemini 2.5 Pro for his daily assignments but described Gemini CLI as “bad, slow, and unreliable,” leading to a loss of confidence in it. He continues to utilize Claude Code and recommends that others sandbox AI CLI tools while maintaining precise instructions and milestones. He anticipates a rise in vibe coders experimenting with tools from Google and Cursor, implying that tech companies should brace for comparable issues.