frontpage.
newsnewestaskshowjobs

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

A Preview of Roc 0.1.0

https://www.youtube.com/watch?v=a7qEOtkkDb8
1•torrance•20s ago•0 comments

Is HTTPS://status.claude.com loading for you all?

1•soorajsanker•32s ago•0 comments

Cory Doctorow on Why AI Won't Replace Workers, but Will Crash the Economy [video]

https://www.youtube.com/watch?v=rRRmUuxJolY
1•b800h•2m ago•1 comments

Tether Clears First Full Audit from KPMG Without Publishing the Statements

https://thedefiant.io/converge/cefi/tether-clears-first-full-audit-from-kpmg-without-publishing-t...
1•negura•5m ago•0 comments

Oxford Electric Bell

https://en.wikipedia.org/wiki/Oxford_Electric_Bell
1•gurjeet•5m ago•0 comments

Speeding Up (Small) Ruby Hashes

https://byroot.github.io/ruby/performance/2026/08/13/speeding-up-ruby-hashes.html
1•arto•6m ago•0 comments

The Master of Consilience

https://asindu.blog/posts/the-master-of-consilience
1•asxndu•7m ago•1 comments

Framework: The first ePaper design system

https://trmnl.com/blog/framework-design-system
1•goranmoomin•8m ago•0 comments

AI Stock Research Assistant · Streamlit

https://ai-stock-research-kiaan.streamlit.app
1•KiaanKothari•8m ago•0 comments

Movie theatre employee goes viral after hand drawing Spider-Man poster

https://www.cbc.ca/news/canada/british-columbia/prince-george-spiderman-movie-poster-9.7306229
1•geox•9m ago•0 comments

OpenAI slows release of Astra model citing cyber capabilities

https://www.axios.com/2026/08/07/openai-astra-model-delay-cybersecurity-risks
1•Khaine•11m ago•0 comments

Looking for Missed Alarm Bugs in a Formal Verification Tool

https://blog.regehr.org/archives/2124
1•luu•14m ago•0 comments

AI-driven surge in bond yields could be next risk for markets and growth

https://www.reuters.com/world/asia-pacific/ai-driven-surge-bond-yields-could-be-next-risk-markets...
1•petethomas•19m ago•0 comments

A desktop AI copilot for interview questions and coding screenshots

https://skillcopilotai.com
1•candyindex999•21m ago•0 comments

What's New in SuperMemo 20?

https://help.supermemo.org/wiki/What%27s_new_in_SuperMemo_20%3F
1•Tomte•23m ago•1 comments

The Natural Hierarchy of Money (2018)

https://sites.bu.edu/perry/lectures/mb-lectures/section-1/2-the-natural-hierarchy-of-money/
1•lostnfound8778•26m ago•0 comments

GLM-5.3: Frontier Coding with Emergent Cyber Capabilities

https://z.ai/blog/glm-5.3
104•pella•32m ago•20 comments

GitHub has another tough day

https://surfingcomplexity.blog/2026/08/13/github-has-another-tough-day/
1•azhenley•35m ago•0 comments

Do Apple's green text bubbles have an accessibility problem?

https://colorschemer.com/color-theory-course/utilizing-wcag-to-improve-text-readability-and-contrast
3•maxsavin•38m ago•0 comments

A Walkable ASCII Cyberpunk City in One HTML File [video]

https://www.youtube.com/watch?v=3YtygAx_C6A
2•reader9274•39m ago•0 comments

German Tank Problem

https://en.wikipedia.org/wiki/German_tank_problem
1•jxmorris12•39m ago•0 comments

Show HN: Control Claude Code, Codex, Pi and Gemini CLI from Telegram

https://github.com/choiyounggi/cliclaw
2•dch0202•45m ago•0 comments

A digestion of the proof of Sendov's conjecture

https://terrytao.wordpress.com/2026/08/12/a-digestion-of-the-proof-of-sendovs-conjecture/
2•surprisetalk•48m ago•0 comments

An Infinite Waltz – A Must Read (Docu-Video Audio/ Visual Adaptation Included)

https://iamwisdom.substack.com/p/an-infinite-waltz-the-dance-beyond
1•I_Am_Wisdom•53m ago•0 comments

The great silence: why haven't we found any aliens yet?

https://www.theguardian.com/news/2026/aug/11/the-great-silence-why-havent-we-found-any-aliens-yet
1•thm•53m ago•0 comments

Show HN: VeerHost – $1/month web hosting, limited spots

https://veerhost.com/1-dollar-web-hosting/
6•betterornotss•55m ago•0 comments

Phoebe Gates' startup Phia faces cookie stuffing allegations

https://www.bloomberg.com/news/articles/2026-08-11/phia-app-co-founders-pushed-for-features-takin...
3•saeranv•56m ago•0 comments

Show HN: Journal, Interstitial Journaling

https://journal.lasagna.pizza/
1•kinduff•58m ago•0 comments

Show HN: Lexicon AI – Exam-focused vocabulary journal for SAT and IELTS prep

https://lexicon-ai-journal.vercel.app/
1•wayne_14e•59m ago•0 comments

How to Look the Sky in the Face

https://www.raptitude.com/2026/08/how-to-look-the-sky-in-the-face/
1•inatreecrown2•1h ago•0 comments