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 ...

Cppreference.com has been under maintenance for a year

https://en.cppreference.com/
1•GalaxySnail•5s ago•0 comments

Veteran artist behind Mass Effect, Halo, & Overwatch 2 weighs in on Nvidia DLSS5

https://www.notebookcheck.net/Veteran-artist-behind-Mass-Effect-Halo-and-Overwatch-2-weighs-in-on...
1•DarrylLinington•1m ago•0 comments

I was copy-pasting to Claude from WhatsApp – so I fixed that

https://github.com/sliamh11/Deus
1•sliamh11•2m ago•1 comments

From bytecode to bytes: automated magic packet generation

https://blog.cloudflare.com/from-bpf-to-packet/
1•syscll•5m ago•0 comments

Show HN: Giving My First Pitch at 1M Cups Using a Custom Mobile App

https://andonalert.net/dev-blog/giving-my-first-pitch-at-1-million-cups
1•SolarpunkRachel•10m ago•0 comments

Neural Computers

https://arxiv.org/abs/2604.06425
1•50kIters•11m ago•0 comments

A hacker has allegedly breached one of China's supercomputers

https://www.cnn.com/2026/04/08/china/china-supercomputer-hackers-hnk-intl
1•tamnd•15m ago•0 comments

Amazon Cuts Kindle Store Access for 2012 and Older Kindle Models Starting May 20

https://www.ghacks.net/2026/04/09/amazon-cuts-kindle-store-access-for-2012-and-older-kindle-model...
1•penguin_booze•16m ago•0 comments

Ask HN: How do you monitor and debug integrations in production?

1•OdinSpecc•18m ago•0 comments

Seedance 2.0 on live–their strongest multimodal AI video model with native audio

https://seedance2video.cloud/
1•bingbing123•20m ago•0 comments

Show HN: I built a free open-source SVG to 3D tool

https://3dsvg.design
2•renatoworks•20m ago•1 comments

Today Is CSS Naked Day

https://css-naked-day.org/?
1•edent•21m ago•0 comments

Rules for Ranking Music on the Hitmagist

https://medium.com/the-hitmagist/rules-for-ranking-music-on-the-hitmagist-1730d5d53355
1•bryanrasmussen•26m ago•0 comments

Show HN: I made an app to live longer (free, open source, no tracking)

https://apps.apple.com/us/app/illll-live-longer/id6760903742
1•bdav24•28m ago•0 comments

Answer me – the bands visit [video]

https://www.youtube.com/watch?v=z5jJCBQKATg
1•marysminefnuf•31m ago•0 comments

What if you had to pay Claude as a human employee?

https://github.com/chucknuris/Claude-Colleague
2•beast2027•31m ago•0 comments

S3 Files

https://aws.amazon.com/s3/features/files/
1•ksajadi•36m ago•0 comments

A practical guide for setting up Zettelkasten method in Obsidian

https://desktopcommander.app/blog/zettelkasten-obsidian/
1•rkrizanovskis•37m ago•1 comments

Rust Terminal Projects in 3 Years

https://blog.orhun.dev/800-rust-projects/
1•swq115•37m ago•0 comments

DesigNet: Learning to Draw Vector Graphics as Designers Do

https://arxiv.org/abs/2604.06494
1•50kIters•38m ago•0 comments

Blackdesk – open-source market research terminal (Go, TUI, local AI)

https://blackdesk.ai/
1•dumitruflorin•39m ago•0 comments

GitHub Availability March 2026

https://github.blog/news-insights/company-news/github-availability-report-march-2026/
4•alexbilbie•41m ago•0 comments

Rendering large code diffs in the browser without freezing the UI

https://github.com/Zhang-JiahangH/react-virtualized-diff
1•jiahangzhang•42m ago•1 comments

Interpretable models with boosting, symbolic regression and e-graphs

https://mchav.github.io/grow-and-mow/
1•mchav•43m ago•0 comments

Show HN: HoldMyBill – Organize Ownership

1•niksmac•48m ago•0 comments

Show HN: UX Agent Mac app running continuously locally using Gemma 4

https://github.com/tommyjepsen/ux-agent-app
1•tommyjepsen•52m ago•0 comments

Tell HN: I know I dislike a developer

3•ishener•53m ago•3 comments

The First Bike Bell Designed to Penetrate Noise-Cancelling Headphones

https://www.youtube.com/watch?v=zDaVPfpQvPI
1•Ahmedb•55m ago•0 comments

Ask HN: What are you building that's not AI related?

6•meander_water•55m ago•2 comments

AI company's breached biometrics, ID document images make deepfake fraud easier

https://www.biometricupdate.com/202604/ai-companys-breached-biometrics-id-document-images-make-de...
1•tagyro•57m ago•0 comments