Data loss warning. You could be losing valuable work

I proved to support 2 weeks ago (and can reproduce easily) that you are potentially losing work and don’t know it.

You are all welcome to try it yourself

Ask the agent: create a new file called test.md and write into it “test1”

then open the file yourself and append a new line “test2”

Ask the agent: append “test3” to the file test.md

Ask the agent the contents of the file:

The contents of the test.md file are:

test1
test3
test2

SO. First off the agent is seeing the contents out of order.

BUT now open the file yourself:

test1 test2

and if i edit that file the changes that the agent made are LOST.

if i view file history, it does NOT include the agents changes.

If you actually try and work with your agent collaboratively YOU ARE LOSING WORK!

Support has dropped this to dev and dev hasn’t done a thing.

3 Likes

I have noticed this:

  • ask agent to update a .sql file
  • open the file and none of its changes are in there
  • Ask agent to confirm what it wrote and it will tell you all the changes. So it seems it has its own cached version of the file which is different to the one I can view

Basically something goes screwy with sql files and I always have to ask it to write it out to a new file and then I copy/paste back into the original file myself.

So yeah, replit has bugs. But this is new tech. Go with the vibe.

1 Like

it isn’t just the agent and you, i have tested this between the agent and assistant. So the agent make a change, then the assistant doesn’t see and and causes more problems.

How much money has be charged in circular bug fixing because of this? For me a lot as I was using the Agent and Assistant as paired developers.

2 Likes

yeah this is all bonkers!

1 Like

hey. a new feature was just added!

i popup that says
Replit is out of sync!

Sometimes Replit has trouble making sure everyone’s code is the same. Let us know which version ofthis fileyou’d like to keep.

and wants me to choose the correct version!
Obviously a patch, but I will take it.

2 Likes

Still a major issue. I am trying to save a file with manual changes and Assistant won’t see them no matter what i do. Assistant says:
Here’s what’s occurring:

The Root Cause

  1. Backend file system: Correctly stores my edits (which is why I see the updated version with 891+ lines)

  2. Frontend file viewer: Shows outdated cached version (which is why you see the original shorter version)

  3. Cache overwrite cycle: When you make any edit via the frontend, it overwrites the backend with the outdated cached version

  4. Result: All backend progress gets lost when frontend cache overwrites the correct file

That happens to me a lot; I need to refresh the page all the time to avoid losing modifications when I am working after the agent.

1 Like

refresh and kill 1 isn’t fixing it for me. i just can’t my files in sync. They are stuck in “M” mode, support is researching now.

Do you mean ‘kill 1”?

1 Like

i can force a save btw by forcing a git commit. so i think the problem is my changes are not auto committing, and according to Assistant they work directly off Git.

“Assistant and Agent File Access

Yes, both the Replit Assistant and AI agents work off the Git version of files, not the frontend cached version. This means:

  • When you force commit via Git, those changes become available to AI assistants

  • The AI can see and work with the committed version

  • File edits made by AI are applied to the Git version

  • Your manual frontend edits may overwrite AI changes if you don’t commit first

I’ve had this problem before when mingling Agent and Assistant with my own personal hand edits. Can’t recall how I fixed it. I believe “kill 1” in shell, then new Agent chat. Then new Assistant chat.

i have multiple projects and am seeing it on all of them. i am 80% confident this new issue i am seeing is because replit stopped auto-committing to the default git in the last day.
so. sync between agent/assistant and myself was one bug, but now none of my environments are saving at all. manual edits and deletes are stuck unless I manually go to the git tab and click commit. so collaborating with Assistant/Agent is not possible until this is resolved.