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•1y ago

Comments

qwertox•1y ago
Rule #1: Always put deletions behind a flag which is disabled for the first couple of test runs.
turtleyacht•1y 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•1y 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•1y ago
Oh, I see. Having a flag to skip deletion during test runs is a good rule then.
rvz•1y 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•1y ago
Who runs such an AI generated script without checking the code first?
qwertox•1y 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•1y ago
Right so lets just always run the code as is ?
qwertox•1y 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•1y 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•1y ago
In which Roko's Basilisk fires a warning shot.
jethronethro•1y ago
This is why you test code or a script before running it for real. Live and learn, I guess ...

Living 35 ft underground: inside a preserved Titan II nuclear missile silo

https://www.youtube.com/watch?v=rSFSnOBYlbM
1•bane•2m ago•0 comments

An Overview of the Mathematical Theory of Communication for Philosophers [pdf]

https://theinformationalturn.net/wp-content/uploads/2012/03/MTC_overview.pdf
1•teleforce•2m ago•0 comments

Baseball is learning to live with shorter attention spans

https://www.ft.com/content/f499089d-a104-44ad-9773-1ef31715afae
2•petethomas•3m ago•0 comments

People who use ChatGPT for writing are accurate detectors of AI text (2025)

https://arxiv.org/abs/2501.15654
1•lexandstuff•6m ago•0 comments

Can AI just replace me already? – A comparative AI-writing ID experiment

https://www.richardhanania.com/p/can-ai-replace-me-already
1•botacode•7m ago•0 comments

OpenBSD/zaurus: pocket-sized BSD

http://miod.online.fr/software/openbsd/stories/zaurus2.html
1•uticus•12m ago•1 comments

US Joint Forces Command Millennium Challenge 2002: Experiment Report [pdf]

https://www.esd.whs.mil/Portals/54/Documents/FOID/Reading%20Room/Joint_Staff/12-F-0344-Millennium...
1•KnuthIsGod•13m ago•0 comments

War Game Exposed U.S. Vulnerability to Low-Tech Warfare

https://nsarchive.gwu.edu/news/2024-11-01/rigged-war-game-exposed-us-vulnerability-low-tech-warfare
2•KnuthIsGod•17m ago•2 comments

Bluesky Radio – Hosted by Opus 4.7

https://bskyrad.io/
2•wilted-iris•21m ago•0 comments

Data centers raise nearby temperatures by up to 4 degrees in Phoenix

https://techxplore.com/news/2026-05-centers-nearby-temperatures-degrees-phoenix.html
3•limitedfrom•25m ago•1 comments

My First Game, Shadow Dungeon (Procedural Roguelike)

https://dynaq.itch.io/shadow-dungeon
3•mik09•30m ago•0 comments

Ball Simulator in Python Made with Claude

https://github.com/simin75simin/ball-sandbox
2•mik09•34m ago•1 comments

Google's Own AI Researchers Jockey for Access to Its Computing

https://www.bloomberg.com/news/articles/2026-05-18/google-s-own-ai-researchers-jockey-for-access-...
2•osnium123•42m ago•0 comments

Have I Been Pwned: Colombian fintech company leaks 34.5M accounts in March 2026

https://haveibeenpwned.com/Breach/ADDI
3•guessmyname•44m ago•0 comments

Do Androids Dream of Your Electric Life?

https://medium.com/@vektormemory/do-androids-dream-of-your-electric-life-4c2c439ab0aa
2•vektormemory•46m ago•0 comments

Language Registries Are Unstable by Default

https://nesbitt.io/2026/05/15/language-registries-are-unstable-by-default.html
2•pabs3•49m ago•0 comments

Retrospective on DDIA

https://www.khola.blog/p/designing-data-intensive-applications
2•bcapchickadee•49m ago•0 comments

The American Rebellion Against AI Is Gaining Steam

https://www.wsj.com/tech/ai/the-american-rebellion-against-ai-is-gaining-steam-94b72529
11•JaakkoP•51m ago•3 comments

New features in GCC 16: Improved error messages and SARIF output

https://developers.redhat.com/articles/2026/04/28/gcc-16-improved-error-messages-sarif-output
2•siteshwar•51m ago•0 comments

A shallow dive into formal verification

https://vitalik.eth.limo/general/2026/05/18/fv.html
3•wslh•53m ago•0 comments

Reverse Lookup and AI-Powered Osint

https://sherlockeye.io/
2•mrzenodd•1h ago•0 comments

The Coming Food Crisis in South Asia

https://thediplomat.com/2026/05/the-coming-food-crisis-in-south-asia/
5•panny•1h ago•0 comments

The last six months in LLMs in five minutes

https://simonwillison.net/2026/May/19/5-minute-llms/
6•yakkomajuri•1h ago•0 comments

Surface owner loses their limited 50th Anniversary edition after a repair swap

https://www.windowscentral.com/hardware/surface/this-surface-owner-lost-their-limited-50th-annive...
3•Oblivion8442•1h ago•0 comments

Nitsum: Serving Tiered LLM Requests with Adaptive Tensor Parallelism

https://mlsys.wuklab.io/posts/nitsum/
2•matt_d•1h ago•0 comments

SuperInfer: SLO-Aware Rotary Scheduling and Memory Management for LLM Inference

https://supercomputing-system-ai-lab.github.io/projects/superinfer/
2•matt_d•1h ago•0 comments

What can a local model do for you in early May 2026?

https://manichord.com/blog/posts/what-can-local-model-do-in-may-2026
3•mkss•1h ago•1 comments

Guess where someone works based on their profile picture

https://tools.crustdata.com/guessthecompany
2•mhi3•1h ago•0 comments

Sony Pulls Back from PlayStation Games on PC

https://www.bloomberg.com/news/articles/2026-03-04/sony-pulls-back-from-playstation-games-on-pc
2•embedding-shape•1h ago•1 comments

Museum of Innocence (Museum)

https://en.wikipedia.org/wiki/The_Museum_of_Innocence_(museum)
3•brudgers•1h ago•0 comments