[-] gedhrel@lemmy.world 22 points 3 weeks ago

The issue here is that the author of that post, and potentially the fictional author of the thing being lampooned, are not drawing a distinction between a tutorial (or an explanation) and a how-to.

https://diataxis.fr/

Either you want to get a task done, or you want to spend a lot longer learning how to work that out for yourself.

(Many tutorials will include small set of how-to-like instructions because emulating the actions of a master will improve one's vocabulary of what can be done as well as how it is achieved.)

[-] gedhrel@lemmy.world 36 points 2 months ago

Unsolicited "good morning message" - is that what it's called now?

[-] gedhrel@lemmy.world 21 points 2 months ago

It won't (using your example explicitly) but in general what you've discovered is that:

  1. Variables hold values
  2. Some of those values are references to shared mutable objects.

Lists fall into the second category. There are ways to copy lists if you want distinct behaviour.

list2 = list1[:]

will perform a "shallow copy". If you have a list of lists, however, the nested lists are still shared references. There is copy.deepcopy available to make a complete clone of something (including all its nested members).

[-] gedhrel@lemmy.world 44 points 4 months ago

I use "are you calling me a liar?" which is probably more effective in the UK than the US.

[-] gedhrel@lemmy.world 79 points 6 months ago

570 recorded homicides between March 2023 and 2024.

Data on "hundreds of thousands" of people can't provide the distinguishing markers to even have a stab at this.

It can reliably predict when people are black, though.

[-] gedhrel@lemmy.world 77 points 8 months ago

Grimes is on 4chan?!

[-] gedhrel@lemmy.world 53 points 10 months ago

More like because you're eating broccoli.

[-] gedhrel@lemmy.world 38 points 1 year ago

"I love life on Earth... but I love capitalism more."

[-] gedhrel@lemmy.world 24 points 1 year ago* (last edited 1 year ago)

It does rather sound like proposing an immediate 25k hike in house prices, yeah.

[-] gedhrel@lemmy.world 22 points 1 year ago

Check Crowdstrike's blurb about the 1-10-60 rule.

You can bet that they have a KPI that says they can deliver a patch in under 15m; that can preclude testing.

Although that would have caught it, what happened here is that 40k of nuls got signed and delivered as config. Which means that unparseable config on the path from CnC to ring0 could cause a crash and was never covered by a test.

It's a hell of a miss, even if you're prepared to accept the argument about testing on the critical path.

(There is an argument that in some cases you want security aystems to fail closed; however that's an extreme case - PoS systems don't fall into that - and you want to opt into that explicitly, not due to a test omission.)

[-] gedhrel@lemmy.world 45 points 2 years ago

Incidentally, this kind of passive-aggressive pressure is the kind of thing that might be considered a legitimate security threat, post xz. If you need to vent, vent in private. If "it works for you" but the maintainer is asking legitimate questions about the implementation, consider engaging with that in good faith and evaluating their questions with an open mind.

[-] gedhrel@lemmy.world 43 points 2 years ago

Casey's video is interesting, but his example is framed as moving from 35 cycles/object to 24 cycles/object being a 1.5x speedup.

Another way to look at this is, it's a 12-cycle speedup per object.

If you're writing a shader or a physics sim this is a massive difference.

If you're building typical business software, it isn't; that 10,000-line monster method does crop up, and it's a maintenance disaster.

I think extracting "clean code principles lead to a 50% cost increase" is a message that needs taking with a degree of context.

view more: next ›

gedhrel

joined 2 years ago