Live data from Hacker News

Hunting a 16-year-old SQLite WAL bug with TLA+

ubuntu.com

21–30 of 37 posts

Re: Hunting a 16-year-old SQLite WAL bug with TLA+

#21
post #8

Author of the article here. I am surprised to see the post was submitted and made it to the front page! Happy to answer any questions

Thanks for the nice article. The SQLite docs that explain this bug are emphatic about how utterly rare, even irreproducible it is. How, then, was it found, one wonders?

We found it at Tailscale and bought an enterprise support contract from SQLite to debug it for us. Worth every penny.

We should probably blog about it.

Re: Hunting a 16-year-old SQLite WAL bug with TLA+

#24
post #8

Author of the article here. I am surprised to see the post was submitted and made it to the front page! Happy to answer any questions

You’re in a desert walking along in the sand when all of the sudden you look down, and you see a tortoise, it’s crawling toward you. You reach down, you flip the tortoise over on its back. The tortoise lays on its back, its belly baking in the hot sun, beating its legs trying to turn itself over, but it can’t, not without your help. But you’re not helping. Why is that?

What’s a tortoise?

Re: Hunting a 16-year-old SQLite WAL bug with TLA+

#25

Earlier quoted context omitted.

Thanks for the nice article. The SQLite docs that explain this bug are emphatic about how utterly rare, even irreproducible it is. How, then, was it found, one wonders?

We found it at Tailscale and bought an enterprise support contract from SQLite to debug it for us. Worth every penny. We should probably blog about it.

What mission critical purpose does sqlite provide at Tailscale exactly? Why use it at all?

Re: Hunting a 16-year-old SQLite WAL bug with TLA+

#26
This is so cool and I wonder how effective it would be using this technique when using LLMs to generate code. Have the llm generate code and a TLA+ model. Use the TLA+ model as the test bed of the code (instead of writing tests in the original language).

Re: Hunting a 16-year-old SQLite WAL bug with TLA+

#27

Earlier quoted context omitted.

You’re in a desert walking along in the sand when all of the sudden you look down, and you see a tortoise, it’s crawling toward you. You reach down, you flip the tortoise over on its back. The tortoise lays on its back, its belly baking in the hot sun, beating its legs trying to turn itself over, but it can’t, not without your help. But you’re not helping. Why is that?

What’s a tortoise?

You know what a turtle is? Same thing, Leon.

Re: Hunting a 16-year-old SQLite WAL bug with TLA+

#28

Earlier quoted context omitted.

You’re in a desert walking along in the sand when all of the sudden you look down, and you see a tortoise, it’s crawling toward you. You reach down, you flip the tortoise over on its back. The tortoise lays on its back, its belly baking in the hot sun, beating its legs trying to turn itself over, but it can’t, not without your help. But you’re not helping. Why is that?

What’s a tortoise?

A turtle-like animal that only lives on land.

Re: Hunting a 16-year-old SQLite WAL bug with TLA+

#29

Earlier quoted context omitted.

We found it at Tailscale and bought an enterprise support contract from SQLite to debug it for us. Worth every penny. We should probably blog about it.

What mission critical purpose does sqlite provide at Tailscale exactly? Why use it at all?

It's in Chrome, Firefox, Safari, Windows 10, macOS because it efficiently solves a huge number of use cases while giving plenty of headroom for flexible querying.

If you have data more complicated than a single CSV or tab-separated text file that you will only ever process in sequential order, and you don't need inter-process interaction, you should be asking why not use SQLite.

Re: Hunting a 16-year-old SQLite WAL bug with TLA+

#30

Earlier quoted context omitted.

We found it at Tailscale and bought an enterprise support contract from SQLite to debug it for us. Worth every penny. We should probably blog about it.

What mission critical purpose does sqlite provide at Tailscale exactly? Why use it at all?

sqlite is useful everywhere CSV files are useful but you'd like them to have more data integrity and faster updates. sqlite can replace some uses of MySQL, but more commonly it replaces fopen. https://sqlite.org/whentouse.html
Post reply on HN