Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
chriswarbo
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
9 ms
·
91.
▲
by
chriswarbo
10mo ago
Legislation often bounces back and forth between the Commons and the Lords a few times. The Lords won't block things which have a strong mandate, e.g. things promised in an election manifesto; but they can at least stall and amend thin
92.
▲
by
chriswarbo
10mo ago
If HN is social media, then so are PHPBB, NNTP, BBS, etc. and the term loses its semantic relevance. My heuristic is that social media focuses on particular people, regardless of what they're talking about. In contrast, forums (like HN
93.
▲
by
chriswarbo
10mo ago
> I don't see why hasattr(mySet, 'pop') should be a problem here? I never said it's a problem (and I never said it's not!). I was specifically addressing two things: - The "theoretical" nature of the qu
94.
▲
by
chriswarbo
10mo ago
> Theoretically, could `set` be a subclass of `frozenset` (and `dict` of `frozendict`)? At one extreme: sure, anything can be made a subclass of anything else, if we wanted to. At the other extreme: no, since Liskov substitution is an im
95.
▲
Multibase CLI
(chriswarbo.net)
1 points
by
chriswarbo
10mo ago
|
0 comments
96.
▲
by
chriswarbo
10mo ago
Very nice! One thing I've found useful about MathML is that, since it's XML, it's easy to generate (e.g. from scripts) and transform (e.g. with XSLT). My preferred workflow at the moment is to programatically-generate "C
97.
▲
by
chriswarbo
10mo ago
> Heavy semi-trailer trucks disproportionally damage the roads Which is another reason why freight should be delivered by rail. Yet haulage companies have no incentive to maintain an efficient rail network, when they could exploit a subs
98.
▲
by
chriswarbo
10mo ago
> TLDR, UK road users pay for far more than the road network. Right, but driving has far more externalities than just the cost of the roads. For example: > Results suggest that each kilometer driven by car incurs an external cost of €
99.
▲
by
chriswarbo
11mo ago
I don't think that's a worthwhile distinction. All software bugs are human errors, since the machine is correctly following the human programmer's incorrect instructions; whether that's at the level of assembly instructi
100.
▲
by
chriswarbo
11mo ago
EDE is a standalone WM/DE with a Windows 9x look XPde was a similar project, but with a Windows XP look. Their site seems dead, though I'm sure the software could be found out there somewhere https://web.archive.org
101.
▲
by
chriswarbo
11mo ago
> I have some idea of what the way forward is going to look like but I don't want to accelerate the development of such a dangerous technology so I haven't told anyone about it. Ever since "AI" was named at Dartmouth,
102.
▲
by
chriswarbo
11mo ago
I prefer bevels for that. In particular, I grew up with the Amiga's "3-D look" where embossed = interactive and recessed = informative https://archive.org/details/amiga-user-interface-style-guide... On a
103.
▲
by
chriswarbo
11mo ago
Border-radius makes it easier to implement rounded-rectangles, etc. compared to the tables-of-offset-image-sprites they needed back in the day. That says nothing about whether rounded-rectangles are "good" or "bad" tho
104.
▲
by
chriswarbo
11mo ago
That's circular reasoning (which is ironic, given the subject at hand).
105.
▲
by
chriswarbo
11mo ago
> Just doing this as an afterthought by playing lottery and trying to come up with smart properties after the fact is not going to get you the best outcome. This sounds backwards to me. How could you write any tests, or indeed implement
106.
▲
by
chriswarbo
11mo ago
QuickCheck won't preserve invariants, since its shrinkers are separate from its generators. For example: data Rat = Rat Int Nat deriving (Eq, Show) genRat = do (num, den) <- arbitrary pure (Rat num (1 + den))
107.
▲
by
chriswarbo
11mo ago
Yeah, reimplementing the solution just to have something to check against is a bad idea. I find that most tutorials talk about "properties of function `foo`", whereas I prefer to think about "how is function `foo` related to
108.
▲
by
chriswarbo
11mo ago
Here's a property check I wrote yesterday, which found a couple of bugs in a large, decade-old codebase. I'd just changed a data structure with three components, and made sure the test suite was still passing. I happened to notice
109.
▲
by
chriswarbo
11mo ago
When I'm "up to my armpits in trying to understand the on-the-ground problem", I find PBT great for quickly find mistakes in the assumptions/intuitions I'm making about surrounding code and helper functions. Wheneve
110.
▲
by
chriswarbo
11mo ago
Hypothesis is a search algorithm for finding ways that we have misunderstood our code (whether that be in the codebase, or the claims we have made about it in the spec/tests). Conceptually, that's the inverse of "a unit test
111.
▲
by
chriswarbo
1y ago
Your filesystem question is actually far from simple, due to all manner of edge-cases. In particular, since you say things like "globally accessible to be read and written to by all programs", I'll assume we're not tal
112.
▲
by
chriswarbo
1y ago
I think you misunderstand my point. Forget mutation; that was a minor technicality, but isn't important for my point. My point is that environment variables are "dynamic variables" (AKA they are "dynamically bound",
113.
▲
by
chriswarbo
1y ago
That's what the apt sources are for; point them to a snapshot of known-good packages (e.g. S3, AptOnCD, whatever), and disable everything else. I remember doing such things (via .deb packages, rather than random scripts) a couple of de
114.
▲
by
chriswarbo
1y ago
> environment variables are to programs (especially chains of programs, parent processes, sub processes and sub-sub processes, etc.) what parameters are to functions -- and/or what command-line parameters are... they're sort of
115.
▲
by
chriswarbo
1y ago
Env vars are unordered name=value pairs, so are suited for such data. In contrast, arguments are an ordered sequence of strings, so are more suited for present/not-present flags (e.g. --dry-run) , or listing a variable number of values
116.
▲
by
chriswarbo
1y ago
I would agree with this if the author's examples were using hashes, rather than "version numbers". Specifying a hash lets us check whether any random blob of code is or isn't what we specified; versions can't do t
117.
▲
by
chriswarbo
1y ago
> And users are definitely not typing a hash when adding a new dependency to package.json or Cargo.toml I actually much prefer that: specify the git revision to use (i.e. a SHA1 hash). I don't particularly care what "version nu
118.
▲
by
chriswarbo
1y ago
> Maven artifacts are immutable, so the whole resolution is deterministic Nope, Maven will grab anything which happens to have a particular filename from `~/.m2`, or failing that it will accept whatever a HTTP server gives it for a
119.
▲
by
chriswarbo
1y ago
> modern package manger (npm, cargo, ...) experience Lol, the word "modern" has truly lost all meaning. Your list of "modern package managers" seems to coincide with a list of legacy tooling I wrote four years ago!
120.
▲
by
chriswarbo
1y ago
I certainly wouldn't focus on getting a Haskell job. Yet they are out there; e.g. my current job is Haskell, and happens to be in the same sector (public transport) as my last job (which was mostly Scala). Also, I've found Has
More ›