Better HN
topnewbestaskshowjobs
Log inSign up

zadikian

243 karma · joined Feb 11, 2026 (9mo ago) · 316 submissions

Alec
Submissions

comment 1mo ago · link · parent

This app would work with a Bluetooth speaker that has a mic in it, right?

comment 1mo ago · link · parent

Was about to guess

comment 3mo ago · link · parent

You do sometimes get to unlock it by being allowed to use calculators in more advanced classes

comment 4mo ago · link · parent

And then the 100 lines of JS/Py ends up being way slower than the manual SQL, plus the autogen'd SQL part of it is slow, plus you can't even get the SQL query to profile without running the actual thing with prints.

comment 4mo ago · link · parent

I never use ORMs. But slightly before 2014, there was still kind of a reason to use them, getting/setting a whole nested bag of fields at once that you don't care about individually. Json/jsonb now handles that better.

comment 5mo ago · link · parent

The part about durable workflows is technically correct, but it's focusing on different things than what I've ever run into in practice. Any mildly complex system will have side effects outside your DB, then you want idempotency. If you have no side effects, you probably don't need a durable workflow in the first place? Maybe there's a more concrete example.

I have rolled my own little durable workflows in Postgres before, in fact before I even knew durable workflows were a thing with solutions like Temporal. That's fine for many cases where you aren't doing enough steps for it to be tedious, and/or you want permanent records. Would do it again, but not for atomicity reasons.

Other comments have already discussed the issue with the outbox UDF, your external system has to poll and retry either way. It works though. Maybe I'm misunderstanding this?

comment 5mo ago · link · parent

So the author made a Rust to C transpiler and immediately used it to transpile... the Rust compiler. I love it.

comment 5mo ago · link · parent

They have an AAAA for v6 as of right now, but it wasn't always there https://www.nslookup.io/domains/news.ycombinator.com/dns-rec...

comment 5mo ago · link · parent

Almost all mobile carriers use v6, but not exclusively. They also hand out a v4 to every customer. The v6-only part is their internal network.

comment 5mo ago · link · parent

The saying is you build better abstractions if you don't build them too early.

comment 5mo ago · link · parent

Yep. Keyword "tried," as in they did it for a while then hit a point where it's impossible to faithfully follow the abstractions because they're wrong.

comment 5mo ago · link · parent

I always felt like I abstract and modularize things way less eagerly than other programmers. Was pleasantly surprised to find that LLMs do it mostly my way by default, then again they're also bad at abstracting when it's actually needed.

comment 5mo ago · link · parent

Not necessarily. I've gone down this rabbit hole in another thread, tldr there are alternatives that would've been easier initially but with the downside of leaving the routes fragmented.

comment 5mo ago · link · parent

I agree, also making it do useful work could detract from how well it works as bot-prevention. Recaptcha suffered from its own success eventually, having to ask people to read nearly impossible things, and now many sites are instead asking me to solve puzzles with no practical use.

P.S. Great to see you, omoikane

comment 5mo ago · link · parent

This is exciting. INSERT (SELECT ...) doesn't work though, right? The docs only mention VALUES inserts.

comment 5mo ago · link · parent

The "transaction safety" part is confusing. What they mean is if you use SERIALIZABLE, transactions need to be retried, so your code inside the xact should be idempotent. I guess this is safer in Haskell because there are no variables, but that doesn't stop your code from having other side effects.

comment 5mo ago · link · parent

Oh I misremembered, yeah just tested and the second INSERT errors.

comment 5mo ago · link · parent

> TBH I think I've seen more database use than not specifically because it serves as the central race-resolver in a system

But you usually don't need serializable for this, cause READ COMMITTED locks the rows during updates.

comment 5mo ago · link · parent

Cause I want relations and SQL. But also I kinda get what you mean and would not use serializable in Postgres.

comment 5mo ago · link · parent

In my experience, the performance hit is so bad that it's not feasible to use that way. It's also not strictly safer behavior-wise because retries can trip people up.

comment 5mo ago · link · parent

Tbh I always forget the specifics soon after reading them. Basically you can do an atomic UPDATE WHERE if there are no subqueries involved. 90% of the time that's good enough, and for anything else I end up refreshing on features like SELECT FOR UPDATE.

Well also I know Postgres UNIQUE indexes provide additional locking. Like you can do an INSERT... WHERE NOT EXISTS or INSERT... ON CONFLICT that is guaranteed to succeed.

comment 5mo ago · link · parent

Was curious about the Flexcoin hack, but the article wasn't loading, so here's an archive: https://web.archive.org/web/20240423000007/https://hackingdi... Supposedly it was this simple:

  mybalance = database.read("account-number")
  newbalance = mybalance - amount
  database.write("account-number", newbalance)
  dispense_cash(amount)   // or send bitcoins to customer
and MongoDB didn't even have a way to do this atomically? An RDBMS with read-committed would handle this fine if you did "read for update" on that row.

comment 6mo ago · link · parent

Even if it were reproducible, realistically most people are using some service like Claude that makes no guarantee that the model or hardware didn't change. Which is fine, it doesn't need reproducibility.

This is interesting though, I didn't know PyTorch had a debug mode for reproducibility.

comment 6mo ago · link · parent

This is sorta how I've felt working the past ~7 years.

Simple example, we've been striving for 90% unit test coverage and thorough code review when there's 0% integration test coverage. I blame the metrics only looking at unit tests, but also many people think unit tests should come first. I would prioritize integration. There are some small pieces that need to work reliably, but if your system relies so hard on all of them working right, it's a bad system. That, and too many things will work in pieces but not overall.

Broadly I'm gonna assume that the team will later hire solid SWEs who don't necessarily know how our stuff works, and aren't going to read 100 docs about it. If this is a backend+DB combo, get your DB right and there won't be too many wrong ways to code against it in the future, get it wrong and it becomes a black hole for SWE-time. Or if someone on their first day can't run a system locally for debugging, no matter how elegant the code is, don't count on that system getting fixed quickly during an outage.

comment 7mo ago · link · parent

Want to add, it's not too late to do this on top of the ipv6 we have today.

comment 7mo ago · link · parent

If you throw away the code then yeah, but I've never seen anyone do this.

comment 7mo ago · link · parent

The home solution is supposed to be mDNS. I just checked right now, my mDNS isn't working on my LAN, idk why.
12345
11