thedufer

Joined 15 years ago

Karma
3,203
Submissions
1,325
Member since
Apr 4
I'm a software developer in NYC. I previously worked at Trello, Inc (formerly part of Fog Creek Software). I have interned (Software Engineering) for a total of about 13 months spread among Gridpoint, Skyline Innovations, and Fog Creek Software. I graduated from the College of William and Mary in 2012 with a double major in Computer Science and Physics and a minor in Math.
View on Hacker News

Recent submissions

Comment · 16 days ago
I think this is because Haskell allows hiding the tuples construction/unwrapping with do-notation. My primary interaction with parser combinators, in OCaml, uses a similar trick with binding operators. If you don't have some sort of syntactic sugar like that they do become a lot more unwieldy.
Comment · 9 months ago
> Can't log in when standing up

This reminds me of a recent issue I had. I had just gotten a new laptop from IT. While picking it up from them, I had generated myself a password, put it in my password manager on my phone, and then entered it twice to set it on the laptop. Everything worked great. But when I got back to my desk, the password didn't work! I tried a bunch of times, watched myself hit each key to eliminate typos, etc.

I went back to IT and they asked me to demonstrate. But this time it worked! I walked back to my desk, thoroughly embarrassed. But a couple hours later I had to log in again and once again could not.

After thinking about it for awhile, I realized that I was typing at IT while standing over a sitting-height desk. Sure enough, typing in that position fixed my issue. I carefully watched what I was doing this time - something about the exact layout of the keyboard and the weird angle I was typing at ensured that I was making a particular typo I typed in that position - just a single letter switched to another, every time. Sure enough, making that one substitution to my intended password got me in.

Comment · 11 months ago
OCaml predates multicore CPUs. Having a global lock was basically free at the time it was invented. It's totally crazy to dislike a language because the authors made a decision that was obviously correct at the time.
Comment · 1 year ago
> if you reduce latency from one second to a hundred milliseconds, could you celebrate that you've made it 10x faster

Yes you can, because speed has units of inverse time and latency has units of time. So it could be correct to say that cutting latency to 1/10 of its original value is equivalent to making it 10x the original speed - that's how inverses work.

Savings are not, to my knowledge, measured in units of inverse dollars.

Comment · 1 year ago
> you actually need to get a service ticket (TGS)

If we're being pedantic, TGS ("ticket granting server") is the service you get service tickets from. Service tickets are (occasionally) abbreviated ST, as you'd expect. The TGS is a logical part of the KDC, distinguished from the AS which grants TGTs.

Comment · 1 year ago
That's an interesting update. I remain a bit skeptical based on the fact that the obvious sources I'd look to for this sort of thing haven't updated on that study (it seems to be https://www.tandfonline.com/doi/full/10.1676/23-00045), and I'm not really able to evaluate it on my own. USFWS (https://www.fws.gov/story/threats-birds-collisions-buildings...) is citing the previous numbers, as is Wikipedia (https://en.wikipedia.org/wiki/Bird%E2%80%93window_collisions).

FWIW 3.5 billion is not the top estimate, although I'm not sure how to interpret the way the estimate is stated ("annual mortality may be minimally 1.28 billion–3.46 billion or as high as 1.92 billion–5.19 billion"). What does it mean to have a range for each end of the range? The author only quotes the absolute lowest number from the study in press about it (see https://www.lehighvalleynews.com/environment-science/3-5-mil...), but maybe is just preferring to be conservative.

Comment · 1 year ago
> At the same time 3.5 billion birds die hitting glass of the buildings.

Do you have a citation for this? Are you comparing North American cat deaths to worldwide building collisions? Estimates I'm seeing of North American center around 600 million, a far cry from deaths due to cats.

Comment · 1 year ago
I'm not sure what conclusions you think we should draw from that. California's advantage over Washington is primarily one of size - Washington's GDP per capita is actually about 3% higher than California's. The most generous interpretation I can think of is that you're crediting the non-compete difference for California's far larger population, which is tenuous at best.
Comment · 1 year ago
Typewriter keys cost money, and dropping the 1 allowed them to drop a key without significantly affecting the use of it. As far as I can tell, that's effectively the entire rationale.

This wasn't meaningfully the case prior; the printing press would've just needed more copies of 'l' if they'd dropped the 1s, and letters weren't as significant a portion of the cost of the machine, anyway. And afterwards came computers, which need to distinguish between the characters even if they're displayed the same way.

Comment · 1 year ago
Labeled tuples are effectively order-independent. Your implementation's order has to match your interface's order, but callers can destruct the labeled tuples in any order and the compiler will do the necessary reordering (just like it does for destructing records, or calling functions with labeled arguments). I don't think this is materially different from what you're describing in F#, except that labeled tuples don't allow labeling a single value (that is, there's no 1-tuple, which is also the case for normal tuples).
Comment · 1 year ago
Why would that be more correct? A trailing dot indicates that a domain is fully-qualified, but that's not the issue here. The browser is trying to decide whether your query is a search string or a URL.

Also, a trailing dot would indicate the opposite of what we want - we're using single-label domains that only work if we can rely on search suffixes to qualify them.

Comment · 1 year ago
> But you'll never get a test that can prevent errors like [email protected], [email protected], [email protected] etc. So is it really worth doing any checks at all?

You can do quite well at this, if you're willing to not restrict yourself to regexes and commit to some amount of hackery. One system I worked on used a simple regex (just what is described here IIRC - assert the existence of an @ sign), plus did an MX check on the domain, plus warned (not errored) if the domain was within 1 or 2 Levenshtein distance of any of a list of most common email domains (yahoo, gmail, etc). Statistically it seems like we saved people a lot of grief with this simple filtering.

Comment · 1 year ago
Putting a slash '/' at the end consistently gets you there, at least in Chromium-based browsers. We use this a lot at work (via DNS search suffixes, not private TLDs).
Comment · 1 year ago
I think the author was pointing at the fact that "Venessa" looks like a typo.
Comment · 1 year ago
> I'm curious though, what is your solution to this?

Cookies work fine, and are the usual way auth is handled in browsers.

> Secondly, not every client is a browser (my OpenAI / fine tune example is non-browser based).

That's fair. It still seems easier, to me, to save any browser-based clients some work (and avoid writing your own spec) by using existing technologies. In fact, what you described isn't even incompatible with SSE - all you have to do is have the server close the connection every 60 seconds on an otherwise normal SSE connection, and all of your points are covered except for the auth one (I've never actually seen bearer tokens used in a browser context, to be fair - you'd have to allow cookies like every other web app).

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton