Better HN
topnewbestaskshowjobs
Log inSign up

sa46

1,425 karma · joined Dec 2, 2015 (10y ago) · 427 submissions

Building AI for distributors, contractors, and manufacturers.

Paratrooper to programmer.

http://github.com/jschaf

hn@schafer.dev

Submissions

comment 3d ago · link · parent

I think slides hide information rather than compress it.

> You begin high-level and then dive into the details.

Also common in writing as tl;dr or bottom line up front (BLUF).

For a more detailed treatment, see Tufte: https://diverdi.colostate.edu/all_courses/%20oral%20presenta...

comment 3w ago · link · parent

Many recent relational databases speak the Postgres wire protocol. For wholesale replacement, pgrust is a recent, contentious contender.

comment 1mo ago · link · parent

IntelliJ supports pretty decent GitHub code review in the editor. It shows the modified code in the gutter and review comments.

I use it when I need to deeply understand a PR.

comment 1mo ago · link · parent

Has anyone done this on the cheap? I've gotten a few quotes with a payback period of 8-12 years, which isn't great.

comment 1mo ago · link · parent

> but this time the author and his wife pushed harder for it to happen

This is the essence of how to make the medical system work for you. Advocate for yourself. AI helps know what to ask, why you should ask, and how to get past the first few layers of dismissals.

comment 1mo ago · link · parent

I understood the OP's point as follows:

The fee agreement was an hourly rate for producing a legal document. The resulting document looks like it took 10 seconds to produce. The lawyer billed $1000 worth of hours.

So, either the document was much more complex than anticipated (in which case the lawyer should have said so), or the lawyer inflated the hours.

comment 1mo ago · link · parent

The difference is that lawyers typically charge by the hour. Software is not sold based on how long it took to create.

So, if a lawyer bills $1000 for "10 seconds of work", it smells fraudulent.

If $1000 was a flat rate, then it's similar to software: you're purchasing some IP and passing off legal liability to the lawyer. How long the lawyer spent on it doesn't matter.

comment 2mo ago · link · parent

> But you also went 13 years without generics

Go shipped with generics (aka bounded parametric polymorphism), but only for built-in types: slices, arrays, and maps. That, with subtyping via interfaces, handled most demand for generics. The most common pain point was custom containers.

Go was first released in November 2009. Russ Cox posted "The Generic Dilemma" [1] in December 2009. The comments show the generics debate raging from the earliest days.

As a fun side note, I forgot I posted a comment on that post pointing to Ada's generics. I was in college, and Ada was our intro language.

[1]: https://research.swtch.com/generic

> the designers didn't want that complexity inside Go.

Yes, with some nuance. Go's goal of writing server programs didn't require the type-system complexity and run-time hit of user-defined generics. [2]

> Go was intended as a language for writing server programs [...] Polymorphic programming did not seem essential [...] so was initially left out for simplicity. > > Generics are convenient but they come at a cost in complexity in the type system and run-time. It took a while to develop a design that we believe gives value proportionate to the complexity.

[2]: https://go.dev/doc/faq#beginning_generics

Out of curiosity, I collected all proposals for Go's journey to generics. https://gist.github.com/jschaf/eaa7aff1af14ea7276a18a1b7370d...

comment 2mo ago · link · parent

Tests typically drive the browser on the same machine. What round trip are we talking about here? Process-to-process over CDP?

comment 2mo ago · link · parent

Weather is fun choice since it’s a contronym. It has opposing definitions: to endure and to erode.

“He weathered the storm” vs “the stone weathered into an arch”.

comment 3mo ago · link · parent

That’s a great blog post, lots of details, helpful animations, historical context, and an interspersing of war stories.

https://cursor.com/blog/git-at-any-scale

comment 3mo ago · link · parent

IntelliJ added worktree “support” but it’s really just a way to create a new project.

I suspect it’ll take a while before we see a shared configuration across worktrees because the .idea folder contains mutable state.

https://www.jetbrains.com/help/idea/use-git-worktrees.html

comment 3mo ago · link · parent

I was confused. The title is bad. “its” is ambiguous and usually refers to the first subject in this sentence structure.

comment 3mo ago · link · parent

Weird take. The author corresponded with Dunning and reproduced the classic graph using random data.

comment 6mo ago · link · parent

Railway has an overwhelming incentive to pin the blame on Google. This report doesn't answer why Google suspended Railway's account.

I'd wait for more details before adjudicating.

comment 7mo ago · link · parent

Presumably, OP refers to the generated rust types which depend on the specific protobuf framework.

I had the same issue when looking to adopt ConnectRPC for Go, which uses a custom wrapper type to model requests.

comment 7mo ago · link · parent

It might interest you to know JS has real private fields, formally introduced in ES2022. [1]

[1]: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe...

comment 7mo ago · link · parent

A new Go protobuf parser [1] made the rounds here eight months ago [2] with a specialized VM that outperforms the default generated protobuf code by 3x.

[1]: https://mcyoung.xyz/2025/07/16/hyperpb/

[2]: https://news.ycombinator.com/item?id=44591605

comment 8mo ago · link · parent

About 15 years ago, our brigade conducted a training exercise to test overall readiness. The opposing force (OPFOR) figured out how to triangulate the brigade headquarters' position using Tinder.

Tinder provided 1-mile granularity, so OPFOR would roam around until they had enough points to locate the headquarters. Then, they'd artillery it out of existence. The brigade commander was most displeased—moving a brigade headquarters is not for the weak or fainthearted.

comment 8mo ago · link · parent

govulncheck analyzes symbol usage and only warns if your code reaches the affected symbol(s).

I’m not sure about cargo audit specifically, but most other security advisories are package scoped and will warn if your code transitively references the package, regardless of which symbols your code uses.

comment 9mo ago · link · parent

The problem is that pre-commit hooks are much slower with a much higher false-positive rate than type checking.

Pre-commit checks should be opt-in with CI as the gate. It's useful to be able to commit code in a failing state.

comment 11mo ago · link · parent

Wouldn’t a mono space font provide more information since you can extrapolate the exact number of characters?

comment 11mo ago · link · parent

I’ve been very happy with Pganalyze.

comment 11mo ago · link · parent

Advisory locks aren’t all sunshine and rainbows. They can only be unlocked by the Postgres connection that acquired the lock. That means you need to track the connection, typically by dedicating a connection to the job that needs locking.

Here’s a good issue describing the tradeoffs between a lock table and advisory locks.

https://github.com/bensheldon/good_job/discussions/831

comment 11mo ago · link · parent

That's quite a strong claim. I disagree. Military leadership, like business leadership, is imperfect. Both vary based on individuals, the operating environment, and culture.

comment 1y ago · link · parent

Depends on the state and child age. California is on the stricter end of legally mandated ratios:

0-18 months: 1:3

18 months to 3 years: 1:4

3-5 years: 1:5

comment 1y ago · link · parent

Trickle-down titles? I’m familiar with operator to refer to tier-1 special operations personnel like Seal Team 6 and Delta Force.

comment 1y ago · link · parent

Sold if you provide a rock or something.

comment 1y ago · link · parent

Weight loss in Ranger School is additionally “aided” by limiting students to 2 MREs per patrol day (2400 calories) to increase stress.

Anecdotally, I lost 26 lbs in Ranger School.

comment 1y ago · link · parent

Why not use the standard-library adjacent semaphore package?

One problem with using a channel as a semaphore is you need to track if you've closed the channel when "releasing".

https://pkg.go.dev/golang.org/x/sync/semaphore#Weighted.Acqu...

12345
15