r/opencode • • Jul 25 '26

Opencode big pickle just wiped my database

thankfully its just a mock system for my university project, but still this is infuriating. No any data wipe reconfirmation or whatsover too, smh. I asked to rename a table to another one. It wipes all table in the db and recreate them all back LMAO. Im stupid enough to believe in AI for such simple task

7 Upvotes

50 comments sorted by

5

u/BigBigga Jul 25 '26

Your 2 users won't mind

2

u/Jolly_Hall_9037 Jul 26 '26

theres no users, its university project lmaooo

4

u/rusl1 Jul 25 '26

Tell me you are a vibecoder without telling me you are a vibecoder

-1

u/Jolly_Hall_9037 Jul 26 '26

who actually code these days, most dev i know only code like 30% while vibe code the rest. Unless theyre an extreme programmer, which is rare these days.

2

u/JivesMcRedditor Jul 27 '26

The difference between a vibe coder and a developer who uses AI is that the developer also uses their brain. Learn from mistakes and think through your systems. The LLM’s output is as good as the input it gets.

1

u/Lanky_Tomatillo9857 Jul 27 '26

You’d be surprised how wrong you are. Vibe coders who say things like you did scratch the surface and think they understand coding because their code runs. The rabbit hole goes much deeper than you think.

And oh, the database lost is on you. You think in prompts, not in systems.

4

u/kitsunekyo Jul 25 '26

posts like this give me so much peace of mind when it comes to job security.

-1

u/Jolly_Hall_9037 Jul 26 '26

I dont plan to work as software dev lmao, maybe just computer guy in government office till i reach 30 and dissapear from the face of the publics

1

u/kitsunekyo Jul 26 '26

i‘m sure the government will happily hire someone with your distinguished skillset.

1

u/Lanky_Tomatillo9857 Jul 27 '26

The government and the people deserve better...

35

u/Potential-Leg-639 Jul 25 '26

No backups?
This should be your 1st learning now.

3

u/lopydark Jul 27 '26

thats why hes a uni lol

27

u/MauricioRobayo Jul 25 '26

There are two kinds of people: the ones that do backups and the ones that will.

10

u/Fahrain Jul 25 '26

There is also a third group: those who check that their backups can be restored correctly.

1

u/bytejuggler Jul 26 '26

So true. You nearly owed me a new keyboard. 😂

23

u/EC36339 Jul 25 '26

Opencode didn't.

You did, using Opencode.

3

u/Volcano_Jones Jul 25 '26

If the task is so simple, why are you using AI for it? It probably took you longer to write the prompt than to just write the SQL statement.

3

u/ClupTheGreat Jul 26 '26

probably doesn't know how to

-2

u/Jolly_Hall_9037 Jul 26 '26

Im using it to lessen my workload by letting it do anything while i scroll my reels duhh

6

u/BrizzyMC_ Jul 25 '26

where are your backups

6

u/retardedGeek Jul 25 '26

Dev database is supposed to be deletable

5

u/Affectionate_Film537 Jul 25 '26

Did you just Directly prompt to do it with out creating a clear and consise plan before implementation

2

u/Horror_Description87 Jul 25 '26

I bet the first, SDD would prevent most of such upsies

2

u/Mskadu Jul 25 '26

I am not surprised - and you will not be the last to experience this (sadly).

I really wouldn't give an experimental AI access to database that held anything of value.

BUT given it was a test/ uni project, use this experience to figure out how you'd avoid this happening in the future. There are several ways around this.

2

u/pine4t Jul 25 '26

At this point we should be running coding agents on servers. Easy to drop and recreate. Don’t wouldn’t need a lid-open laptop 😃

Also I’ve noticed some models trying to run tool calls that seem unnecessary - like reading certain directories that seem obviously unnecessary. I’ve rejected permissions for those requests. And sometimes it’s just tool calls for the wrong paths because the path was constructed wrong.

2

u/Horror_Description87 Jul 25 '26 edited Jul 25 '26

Giving model the access to your system mean it can do what you can do. If you don't want it, you need safeguards and containment. There are multiple possiblities to achieve it. Best is to always pretend you gave a toddler your system. Remember Murphy's law, everything that can happen will happen, so be prepared.

For me auch situations have only happened when I showed him earlier in the session such thinga. For me a model/agent has never done something out of the blue, it mostly had some context pre story or reasoning to at least logically sound right before doing nasty things.

You can f.e. give only a read only access to a database. Or create a dump before,...

If you ask him to rename a table without telling him that the data in the table is of value for you, he did just what you said. It is the nature of the model to find a way maybe a rename/alter was not possible cause of some reason, so it went the drop + create path.

Anyway task completed table now has the desired name :)

2

u/rsajdok Jul 25 '26

Do not be rude, big pickle created for me almost the whole application

2

u/Accomplished-Bird829 Jul 26 '26

Do you know how to use the dny list ?

2

u/LeHonouredOne Jul 26 '26

Well, people can argue that you did it, using opencode.

2

u/Additional-Screen311 Jul 26 '26

Sounds like quite the pickle.

3

u/Quadgie Jul 25 '26

Why are you using a coding assistance, emphasis on assistance, tool to directly edit database schema?

PEBKAC

1

u/zer0evolution Jul 25 '26

what happen ? you didnt set any rule?

1

u/hurdurdur7 Jul 26 '26

Why did it have write access to your db in the first place ...

1

u/TechHealthCuba Jul 27 '26

La BD debe tener un script sql para su creación o en su defecto el mismo sistema debe crearla. Para la data le puedes pedir a la IA que te genere un script con data lo más realista posible y correctamente relacionada. También en tu proyecto en el AGENTS.md incluye una regla para el trabajo, que le indique al modelo que en operaciones no reversibles debe pedirte autorización expresa, y si quieres le incluyes escenarios concretos.

1

u/Difficult_Plantain89 Jul 27 '26

GLM likes to do that. Opencode's big pickle should still be GLM 4.6. I have had issue before where it kept destroying the same file repeatedly as I restored the backup. It was kinda sad and funny at that point. I told it like dude you overwrote the file again, don't do that. It would say sorry and it wouldn't do it again. I restore the file and it immediately did the same thing and sometimes while using different commands. I am honestly impressed that GLM 5.2 is so good because their old models were so bad.

1

u/fschwiet Jul 27 '26

sorry people giving you crap when you're just sharing a story as you're trying to learn.

1

u/Ergo7z Jul 27 '26

I don’t understand why anyone would use a free model to run important file systems anyways. Especially when the opencode go plan starts at 5 euros.

1

u/Relative_Stick_6266 Jul 27 '26

"Don’t try to walk before you can run."

1

u/173827 Jul 31 '26

I backup my stuff but I would still be mad if a model just deleted my stuff. Worst case my backup is one day ago and that can really suck. Apart from that, it's just a trust/reliability issue if models just do things like that. Smug redditors

4

u/[deleted] Jul 25 '26

[removed] — view removed comment

1

u/dota2nub Jul 27 '26

You must've been held back. Don't ever trust anyone, not even a senior.