frontpage.
newsnewestaskshowjobs

Open Source @Github

fp.

Open in hackernews

Learning a few things about running SQLite

https://jvns.ca/blog/2026/07/17/learning-about-running-sqlite/
57•surprisetalk•2h ago

Comments

simonw•42m ago
> I’ve been backing up to AWS, which is always a pain because it’s annoying to navigate the AWS console to generate credentials.

I got so annoyed with that a few years ago that I ended up building a whole tool just to solve that one problem:

  uvx s3-credentials create my-existing-s3-bucket
This spits out read-write credentials that are scoped JUST for that bucket. You can add --read-only or --write-only to have credentials that are further locked down, or even add --prefix foo/bar for credentials that can only read/write keys that start with that prefix within the bucket.

> Maybe one day I’ll move away to some other S3-compatible alternative.

I've used Restic with Cloudflare R2 and it worked great.

datadrivenangel•37m ago
"Maybe one day I’ll learn to read a query plan."

Query plans aren't that hard to read! [0]

0 - https://xkcd.com/2501/

striking•31m ago
> Maybe one day I’ll learn to read a query plan.

With SQLite's `.expert` mode you can delay that day a little longer: https://www.sqlite.org/cli.html#index_recommendations_sqlite...

  sqlite> CREATE TABLE x1(a, b, c);                  -- Create table in database 
  sqlite> .expert
  sqlite> SELECT * FROM x1 WHERE a=? AND b>?;        -- Analyze this SELECT 
  CREATE INDEX x1_idx_000123a7 ON x1(a, b);

  0|0|0|SEARCH TABLE x1 USING INDEX x1_idx_000123a7 (a=? AND b>?)

  sqlite> CREATE INDEX x1ab ON x1(a, b);             -- Create the recommended index 
  sqlite> .expert
  sqlite> SELECT * FROM x1 WHERE a=? AND b>?;        -- Re-analyze the same SELECT 
  (no new indexes)

  0|0|0|SEARCH TABLE x1 USING INDEX x1ab (a=? AND b>?)
Also wrt

> My approach so far has been to just do these cleanup operations in small batches so that I don’t need to do database queries that take more than 5 seconds to run. This whole experience has given me more of an appreciation for why someone might want to use a “real” database like Postgres which can have more than one writer at the same time though.

The advice for those " “real” " databases is generally to also do cleanup operations in small batches, they just tend to make it less obvious you're doing something unperformant in the smaller case. You're more right than you thought!

DANmode•15m ago
> they just tend to make it less obvious you're doing something unperformant

Is this being positioned as a strength, in your comment?

simonw•10m ago
I've worked with large MySQL databases that used row-based replication and things like an UPDATE or DELETE that affected millions of rows had to be applied in batches there, because otherwise one SQL query might result in a million updated rows needing to be sent to all of the replicas at once.
cogman10•2m ago
Yeah, I think anyone that's done significant database work has come to the understanding that large updates need to be done in batches, otherwise you nuke performance.

Once you get to about 1M rows of data, batching is essential.

masklinn•12m ago
> and presumably other things?

Various statistical views over the value distributions of the indexes, so that the planner can estimate how useful (selective) the index should be.

sqlite_stat1 just gives an average (number of records in the index, and average number of records per value), and if enabled sqlite_stat4 stores histogram data.

m0ose•9m ago
What does he mean by "I do usually try to monitor them with a dead man’s switch.", when talking about backups?
ryan42•5m ago
If you're not using them, adding in silk and/or debug toolbar to your django app will be able to get some good automatic reporting and guidance on performance issues.

AWS: Inaccurate Estimated Billing Data – $1.7 billion

825•nprateem•10h ago•454 comments

First atmosphere found on Earth-like planet in habitable zone of distant star

https://www.bbc.com/news/articles/cy4kdd1e0ejo
246•neversaydie•5h ago•175 comments

Learning a few things about running SQLite

https://jvns.ca/blog/2026/07/17/learning-about-running-sqlite/
58•surprisetalk•2h ago•9 comments

Kimi K3, and what we can still learn from the pelican benchmark

https://simonwillison.net/2026/Jul/16/kimi-k3/
173•droidjj•5h ago•101 comments

Frame – Linux X server in Assembly

https://isene.org/2026/07/Frame.html
91•guybedo•4h ago•52 comments

ICE Flight Monitor Interactive Dashboard

https://www.humanrightsfirst.org/ice-flight-monitor-interactive-dashboard
13•mooreds•56m ago•1 comments

Mozilla: The state of open source AI

https://stateofopensource.ai/
286•rellem•5h ago•194 comments

The Zilog Z80 has turned 50

https://goliath32.com/blog/z80.html
6•st_goliath•14m ago•0 comments

Three ways people respond to a problem (other than solving it)

https://improvesomething.today/responses-to-problems/
143•surprisetalk•5h ago•68 comments

A Road to Lisp: Which Lisp

https://scotto.me/blog/2026-07-17-which-lisp/
132•silcoon•5h ago•82 comments

Frank Lloyd Wright's First Home

https://www.architecturaldigest.com/story/frank-lloyd-wright-home-and-studio-everything-you-need-...
40•NaOH•4d ago•19 comments

AI Meets Cryptography 2: What AI Found in OpenVM's ZkVM

https://blog.zksecurity.xyz/posts/openvm-bugs/
64•duha•5h ago•0 comments

Show HN: Watch bots interact with an SSH honeypot in real time

https://honeypotlive.cc/
107•tusksm•5h ago•42 comments

Show HN: A zoomable timeline of 4M Wikipedia events

https://app.everything.diena.co/
9•lortex•1h ago•2 comments

More Bounce to the Ounce

https://mceglowski.substack.com/p/more-bounce-to-the-ounce
76•pavel_lishin•6h ago•25 comments

Show HN: Explore the Workspaces of Modern Creators

https://workspaces.xyz/
41•ryangilbert•4h ago•30 comments

EEG shows brain can simultaneous encode two speech streams

https://journals.plos.org/plosbiology/article?id=10.1371/journal.pbio.3003876
234•giuliomagnifico•14h ago•152 comments

MoonBASIC: A modern BASIC for building 2D and 3D games

https://github.com/CharmingBlaze/moonbasic
11•klaussilveira•3d ago•2 comments

Manufact (YC S25) Is Hiring a Senior infra engineer to build the MCP cloud

https://www.ycombinator.com/companies/manufact/jobs/Dh6PYP5-senior-infrastructure-engineer
1•luigipederzani•6h ago

Pebble Mega Update – July 2026

https://repebble.com/blog/pebble-mega-update-july-2026
243•crazysaem•16h ago•157 comments

Apple targets dozens of OpenAI employees with legal letters

https://www.ft.com/content/1b8c9d52-88a9-426b-ba47-f1811f859166
316•merksittich•7h ago•259 comments

SpaceX stock drops to a new low and loses $1T in value in a month

https://www.businessinsider.com/spacex-stock-drops-new-low-ipo-price-starship-launch-scrubbed-2026-7
38•01-_-•1h ago•25 comments

Faster binary search: from compiled code to mechanical sympathy

https://pythonspeed.com/articles/branchless-binary-search/
46•enz•5d ago•11 comments

Latent Space as a New Medium

https://kevinkelly.substack.com/p/latent-space-as-a-new-medium
58•thm•4d ago•18 comments

Short sellers notch $8.7B profit as SpaceX shares dip to IPO price

https://www.reuters.com/business/media-telecom/short-sellers-rack-up-87-bln-profit-spacex-slips-b...
103•1vuio0pswjnm7•4h ago•76 comments

Camera Chase Vehicle

https://transistor-man.com/gimbal_camera_rover.html
171•geerlingguy•1w ago•18 comments

Homomorphically encrypted CIFAR-10 inference in 200ms

https://sofar.belfortlabs.cloud/
16•j2kun•3h ago•15 comments

VulnHunter: Capital One's agentic AI code security tool

https://www.capitalone.com/tech/open-source/announcing-vulnhunter/
47•medina•7h ago•28 comments

Decoy Font

https://www.mixfont.com/experiments/decoy-font
677•ray__•1d ago•152 comments

Kimi K3: Open Frontier Intelligence

https://www.kimi.com/blog/kimi-k3
1962•vincent_s•1d ago•1137 comments