frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

fp.

Open in hackernews

I asked Gemini for a script to move files to Cloudflare R2. It deleted them

https://twitter.com/levelsio/status/1921974501257912563
6•bundie•11mo ago

Comments

qwertox•11mo ago
Rule #1: Always put deletions behind a flag which is disabled for the first couple of test runs.
turtleyacht•11mo ago
It was truncating filenames, so /pics/1003-46.png overwrote /pics/1003-45.png because both were renamed /pics/1003-.png, or something like that.
qwertox•11mo ago
Truncating file names for the target. Then it proceeded to delete the source file. "Successfully deleted local file: ..."

I mean, look at the printout. It shows that it created the remote file with the truncated filename, then deletes the local file with the correct filename.

turtleyacht•11mo ago
Oh, I see. Having a flag to skip deletion during test runs is a good rule then.
rvz•11mo ago
Recently there was a story about an updater causing a $8,000 bill because there was a lack of basic automated tests to catch the issue. [0]

The big lesson here is that you should actually test the code you write and also write automated tests to check any code generated by an LLM that the code is correct in what it does.

It is also useless to ask another AI to check for mistakes created by another LLM. As you can see in the post, both of them failed to catch the issue.

This why I don't take this hype around 'vibe-coding' seriously since not only it isn't software engineering, it promotes low quality and carelessness over basic testing and dismisses in checking that the software / script works as expected.

Turning $70 problems found in development into $700,000+ costs in production.

There are no more excuses in not adding tests.

[0] https://news.ycombinator.com/item?id=43829006

victorbjorklund•11mo ago
Who runs such an AI generated script without checking the code first?
qwertox•11mo ago
To be fair, the code Gemini outputs in AI Studio is so extremely verbose that it is almost impossible to read through it.

It turns 10 lines of code which is perfectly fine to reason about into 100 lines of unreadable code full of comments and exception handling.

weatherlite•11mo ago
Right so lets just always run the code as is ?
qwertox•11mo ago
No. Not at all. I've settled to discussing my code with Gemini. That way it works very well. I explicitly say "Comment on my code and discuss it" or "Let's discuss code for a script doing this and that. Generate me an outline and let's see where this leads. Don't put comments in the code, nor exception handling, we're just discussing it".

Or you create elaborate System Instructions, since it adheres to them pretty well.

But out-of-the-box, Gemini's coding abilities are unusable due to the verbosity.

I've even gone so far to tell it that it must understand that I am just a human and have limited bandwidth in my brain, so it should write code which is easy to reason about, that this is more important than having it handle every possible exception or adding multiline comments.

rsynnott•11mo ago
> To be fair, the code Gemini outputs in AI Studio is so extremely verbose that it is almost impossible to read through it.

In which case, it should simply be considered unusable. Like, the sensible response to "tool is so inadequate that there is no reasonable way to make sure its output is safe" is to _not use that tool_.

rsynnott•11mo ago
In which Roko's Basilisk fires a warning shot.
jethronethro•11mo ago
This is why you test code or a script before running it for real. Live and learn, I guess ...

Sociotechnical Archaeology

https://jensrantil.github.io/posts/sociotechnical-archaeology/
1•JensRantil•49s ago•0 comments

The M×N problem of tool calling and open-source models

https://www.thetypicalset.com/blog/grammar-parser-maintenance-contract
1•remilouf•3m ago•0 comments

Show HN: AI agents are bad at API integrations – we fixed it

https://www.apimatic.io/product/context-plugins/showcase
3•sohaibtariq•4m ago•0 comments

A Server That Forgets: Exploring Stateless Relays

https://blog.torproject.org/exploring-stateless-relays/
1•ahlCVA•4m ago•0 comments

Study: Google's AI Overviews show wrong answers every hour

https://www.popsci.com/technology/ai-overview-inaccuracy-google/
1•Brajeshwar•4m ago•0 comments

'Snoopy', 'Adolf' and 'Password': The Hungarian Government Passwords Exposed

https://www.bellingcat.com/news/2026/04/09/the-hungarian-government-passwords-exposed-online/
1•lschueller•5m ago•0 comments

Pipeline Architecture System Design

https://dvcoolarun.com/2026/04/09/Pipeline-architecture-system-design.html
1•dvcoolarun•5m ago•0 comments

Need Advice. Should I Give Up My CS Degree in the Last Semester?

1•jornbess•5m ago•0 comments

AI Code Security Scanner – static analysis for 14 languages, OWASP Top

https://github.com/astro717/ai-code-security-scanner
1•astro717•5m ago•0 comments

Using AI in Blogging

https://cagrimmett.com/2026/02/16/on-using-ai-in-blogging/
1•speckx•6m ago•0 comments

Real Time Tide Data Novaa

https://tidesandcurrents.noaa.gov/map/
1•prakashqwerty•7m ago•0 comments

A complete GPT language model in ~600 lines of C#, zero dependencies

https://github.com/milanm/AutoGrad-Engine
1•evo_9•7m ago•0 comments

What to Do with Your Extra Tokens

https://www.johnbhiggins.com/writing/extra-tokens
1•jhiggins777•7m ago•1 comments

Adam Back: I'm not Satoshi

https://twitter.com/adam3us/status/2041811857732768148
2•wslh•8m ago•0 comments

Uncharted island will soon appear on nautical charts

https://phys.org/news/2026-04-uncharted-island-nautical.html
1•pseudolus•9m ago•0 comments

Legos vs. 3D Printers

https://koaning.io/posts/legos-vs-3d-printers/
1•sebg•10m ago•0 comments

Show HN: MCP Gateway – Zero-Trust Access to MCP Tool Servers

https://github.com/openziti/mcp-gateway
2•michaelquigley•10m ago•0 comments

The Model Says Walk: How Surface Heuristics Override LLM Reasoning Constraints

https://arxiv.org/abs/2603.29025
1•timssopomo•10m ago•0 comments

Family files lawsuit after man dies in care of telehealth ICU doctor

https://www.cnn.com/2026/04/09/health/telehealth-icu-conor-hylton
1•SilverElfin•10m ago•0 comments

Agent Sandboxes Are So Hot Right Now: 19 Providers Compared

https://engine.build/lab/agent-sandboxes
1•alasano•11m ago•1 comments

Cassidy Williams on Technical Blogging

https://writethatblog.substack.com/p/cassidy-williams-on-technical-blogging
1•mooreds•11m ago•0 comments

How to End American Power [video]

https://www.youtube.com/watch?v=0Vo_fVDRnzY
1•mooreds•12m ago•0 comments

How AI Can, and Can't, Cure Cancer

https://curecancer.ai/
1•profchemai•12m ago•1 comments

Repurposed Nvidia RT Cores for LLM routing (218x speedup)

https://github.com/JordiSilvestre/Spectral-AI
1•Jordisilvestre•12m ago•0 comments

MIT16.485 – Visual Navigation for Autonomous Vehicles

https://vnav.mit.edu/
1•sebg•13m ago•0 comments

We orchestrate our internal AI agent (PydanticAI, Gemini, Jinja2 prompts)

https://merylldindin.com/thoughts/reasoning-loop/
1•meryll_dindin•14m ago•0 comments

Mass drowning of chicks puts emperor penguins at risk of extinction

https://www.theguardian.com/environment/2026/apr/09/mass-drowning-of-chicks-puts-emperor-penguins...
1•ljf•15m ago•0 comments

Banksy, Satoshi and the Unmasking Impulse

https://om.co/2026/04/08/banksy-satoshi-the-unmasking-impulse/
1•tomaskafka•15m ago•0 comments

Pentagon Threatened the Pope After He Criticized Trump

https://newrepublic.com/post/208820/pentagon-threatened-pope-criticized-donald-trump
2•sleepyguy•16m ago•0 comments

Retina monitor explorer

https://retinadisplays.com/
2•Amorymeltzer•17m ago•0 comments