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•8mo ago

Comments

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

Blogroll.club – a curated collection of blogs and personal sites

https://blogroll.club
1•Curiositry•40s ago•0 comments

Feral cats and foxes have driven many Australian mammals to extinction

https://theconversation.com/yes-feral-cats-and-foxes-really-have-driven-many-australian-mammals-t...
1•defrost•2m ago•0 comments

Common bad arguments for the correct answer to the Monty Hall Problem

https://link.springer.com/article/10.1007/s11229-025-05389-6
1•mellosouls•5m ago•0 comments

VidBee: Free Open Source Video Downloader

https://vidbee.org/
1•jonbaer•6m ago•0 comments

Remotion: Make Videos Programmatically

https://www.remotion.dev/
1•jonbaer•7m ago•0 comments

Show HN: Audio AI had a wild day – 5 major open-source / real-time TTS drops

https://github.com/FlashLabs-AI-Corp/FlashLabs-Chroma
1•pratik227•9m ago•0 comments

TikTok deal finalized to stop US ban: Oracle, Silver Lake, MGX to hold 15% each

https://www.reuters.com/world/china/tiktok-reaches-deal-new-us-joint-venture-avoid-american-ban-2...
1•aarondong•10m ago•0 comments

Dynamic GHC Matrix in GitHub CI

https://hasufell.github.io/posts/2026-01-22-dynamic-ghcup-action.html
2•todsacerdoti•12m ago•0 comments

Show HN: Learning to Test Code Changes with RL

https://www.morphllm.com/blog/browser-verification
1•bhaktatejas922•14m ago•0 comments

Former FTX crypto executive Caroline Ellison released from federal custody

https://www.theguardian.com/technology/2026/jan/22/ftx-crypto-executive-caroline-ellison-prison-r...
2•treetalker•15m ago•0 comments

Bay Area software rep. lost $176K after accepting remote job she thought with FB

https://abc7news.com/post/bay-area-software-rep-lost-176k-savings-accepting-remote-job-she-though...
2•randycupertino•30m ago•1 comments

Joy of a Competent Beginner

https://xydinesh.com/posts/joy-of-competent-beginner/
1•xydinesh•30m ago•1 comments

Florida's Unprecedented Execution Pace

https://deathpenaltyinfo.org/new-report-examines-floridas-unprecedented-execution-pace-and-trends...
3•weslleyskah•31m ago•0 comments

Show HN: C/C++ Cheatsheet – a modern, practical reference for C and C++

https://github.com/crazyguitar/cppcheatsheet
3•crazyguitar•32m ago•0 comments

Show HN: The firmware that got me detained by Swiss Intelligence

https://github.com/seabass011/davos-incident-firmware
2•reutinger•35m ago•1 comments

Rust Burn 0.20.0 Release: Unifying CPU and GPU Kernels with CubeCL

https://burn.dev/blog/release-0.20.0/
2•stmw•36m ago•0 comments

Autodesk burns the village to feed AI and the Cloud – cuts 7% of workforce

https://blog.adafruit.com/2026/01/22/autodesk-burns-the-village-to-feed-ai-and-the-cloud-cuts-7-o...
3•zdw•39m ago•0 comments

Introduction to Coinduction in Agda Part 1: Coinductive Programming

https://jesper.cx/posts/coinduction-part-1.html
1•matt_d•39m ago•0 comments

Show HN: Verify Unlimited Emails with 99.9% accuracy

https://email2verify.com/
1•aswinsilvadasan•40m ago•1 comments

Show HN: Public Key Directory – Key Transparency for the Fediverse

https://publickey.directory
2•some_furry•44m ago•0 comments

Chinese AI is a risk for Europe. So is shunning it

https://www.economist.com/leaders/2026/01/22/chinese-ai-is-a-risk-for-europe-so-is-shunning-it
1•petethomas•45m ago•0 comments

Show HN: Neoment – A Matrix client, bringing chat functionality into your editor

https://github.com/Massolari/neoment
1•wsdjeg•47m ago•0 comments

I spent 3 years chasing Backlinks the wrong way, what worked in 2026?

https://webmatrices.com/post/i-spent-3-years-chasing-backlinks-the-wrong-way-heres-what-actually-...
1•bishwasbh•48m ago•0 comments

AI-Free Free-to-Use Music Shorts

https://onj.me/shorts/
1•cdvonstinkpot•51m ago•0 comments

Mortal Kombat Motion Picture Soundtrack 1995 [video]

https://www.youtube.com/watch?v=ZozxHpX4x8c
1•nomilk•52m ago•0 comments

Badgefor.me – Work from home. Look like you didn't

https://www.badgefor.me/
2•squalrus•57m ago•0 comments

Toms AI BackGround Remover Software

https://tomdahne.com/TomsBGRemover/pad/tomsbgremover.xml
1•ezimedia•57m ago•1 comments

.NET Aspire is now open source [video]

https://www.youtube.com/watch?v=crvgYrFYrrw
1•tartoran•57m ago•0 comments

Winapp, the Windows App Development CLI

https://blogs.windows.com/windowsdeveloper/2026/01/22/announcing-winapp-the-windows-app-developme...
1•thunderbong•1h ago•0 comments

I accidentally made probabilistic programming 30-200x faster

1•Aeowulf•1h ago•0 comments