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

Comments

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

Board games, cognitive decline and dementia

https://pmc.ncbi.nlm.nih.gov/articles/PMC3758967/
1•RickJWagner•1m ago•0 comments

Show HN: Forecast Planner, personal finance app that forecasts instead of tracks

https://www.forecast-planner.com/
1•curiousweb•2m ago•0 comments

From Chile to the Philippines, meet the people pushing back on AI

https://restofworld.org/2026/ai-pushback-chile-mexico-kenya-philippines/
1•Brajeshwar•2m ago•0 comments

Unified RISC-V IP Access Platform

https://openhwgroup.github.io/uap/
1•Tomte•3m ago•0 comments

Secure Domain Name System (DNS) Deployment 2026 Guide [pdf]

https://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-81r3.pdf
1•XzetaU8•4m ago•0 comments

Game Devs Reveal All Their Ugly Placeholder Assets Made Without AI

https://kotaku.com/crimson-desert-ai-art-placeholder-game-devs-share-assets-images-genai-2000681053
2•cainxinth•5m ago•0 comments

Vulkanised 2026 talks now available (playlist)

https://www.youtube.com/playlist?list=PLMLurvdlOpWNFlPD0kumIYtivIpUx1V0a
2•pjmlp•7m ago•0 comments

Hung cron jobs: what causes them and how to detect them without a sidecar

https://crontify.com/blog/hung-cron-jobs-detection
2•vincentabolarin•9m ago•0 comments

Static IPv4 address on outbound connections from a Cloud Run Job

https://omnitroid.bearblog.dev/giving-a-docker-container-a-static-ip-on-outbound-connections/
1•OmniTroid•9m ago•0 comments

LiteLLM PyPI has been compromised an hour ago, do not update

https://futuresearch.ai/blog/litellm-pypi-supply-chain-attack/
8•Bullhorn9268•11m ago•1 comments

Tell HN: Litellm 1.82.7 and 1.82.8 on PyPI are compromised

3•dot_treo•12m ago•0 comments

Cardputer-Adv (40€ ESP32-S3): Evil Portal and Deauth Attack, with/Without PMF

https://paolocostanzo.github.io/cardputer-adv-wifi-security/
1•PCostanzo•12m ago•0 comments

Designing a Python Language Server: Lessons from Pyre That Shaped Pyrefly

https://pyrefly.org/blog/lessons-from-pyre/
2•ocamoss•15m ago•0 comments

A Tom-Inspired Agenda for AI Safety Research

https://www.lesswrong.com/posts/2BFifEBfCCWtkGsTp/a-tom-inspired-agenda-for-ai-safety-research
2•joozio•16m ago•1 comments

God, I hate .env files

3•zidoo•17m ago•3 comments

How do you ensure consistency in test results generated via AI models?

1•allenmatthew•18m ago•0 comments

OpenAI offering Private Equity a return of 17.5% and early access to models

https://www.reuters.com/business/openai-sweetens-private-equity-pitch-amid-enterprise-turf-war-wi...
2•alecco•18m ago•2 comments

Mathematical framework maps landscape of student knowledge via short quizzes

https://phys.org/news/2026-03-mathematical-framework-landscape-student-knowledge.html
2•Brajeshwar•20m ago•0 comments

Show HN: Running AI agents across environments needs a proper solution

https://github.com/liquidos-ai/Odyssey
5•human_hack3r•21m ago•3 comments

Delve.co and SoC Type 2 Compliance Scandal and Audit

https://www.kaggle.com/datasets/dheerajmpai/delve-data-leaks
1•dheerajmp•22m ago•0 comments

Cortex – Local-first AI memory engine, beats Mem0 on LoCoMo, encrypted, free

3•gambletan•22m ago•1 comments

Show HN: Claude's Code – tracking the 19M+ commits generated by Claude on GitHub

https://www.claudescode.dev/
7•phantomCupcake•23m ago•0 comments

Turn any REST API into an MCP server. No code required

https://github.com/Work90210/APIFold
1•KyleFuehri•25m ago•0 comments

PetClaw: A Desktop Pet Companion That Works 24/7

https://petclaw.ai/
2•limoce•26m ago•0 comments

New digital hall passes track bathroom breaks, gather data in NYC schools

https://gothamist.com/news/new-digital-hall-passes-track-bathroom-breaks-gather-data-in-nyc-schools
2•geox•28m ago•0 comments

Archive.is Reads Bitwarden Data?

6•ppap3•29m ago•0 comments

Lexical Analysis of Markdown in Go

https://xnacly.me/posts/2023/lexer-markdown/
3•ibobev•29m ago•0 comments

Show HN: zbot – an AI agent for MCU with Telegram chat (runs on Zephyr or Linux)

https://github.com/LingaoM/zbot
4•menggithub•31m ago•1 comments

Detecting file changes on macOS with kqueue

https://www.vegardstikbakke.com/kqueue/
2•v3gas•31m ago•0 comments

A unique NASA satellite is deorbiting – this team is trying to rescue it

https://arstechnica.com/space/2026/03/a-unique-nasa-satellite-is-falling-out-of-orbit-this-team-i...
1•agos•33m ago•0 comments