• 0 Posts
  • 5 Comments
Joined 1 year ago
cake
Cake day: September 29th, 2024

help-circle
  • here is the official NASA press release. primary sources are always preferable, especially compared to this fuckass “digital trends” clickbait website.

    “This finding by Perseverance, launched under President Trump in his first term, is the closest we have ever come to discovering life on Mars. The identification of a potential biosignature on the Red Planet is a groundbreaking discovery, and one that will advance our understanding of Mars,” said acting NASA Administrator Sean Duffy. “NASA’s commitment to conducting Gold Standard Science will continue as we pursue our goal of putting American boots on Mars’ rocky soil.”

    quick fact check: it was launched in 2020, but announced back in 2012. giving Trump credit here is idiotic, but it’s about what you’d expect from Sean Duffy, he’s a Trump crony through-and-through. before being the NASA administrator he was Trump’s Secretary of Transportation, and before that he was a Republican congressman, and reality TV contestant (on The Real World and the *checks notes* Lumberjack World Championship)

    I think it’s important to remember that everything, even basic scientific research, is liable to be politicized if it suits their ends. so it’s totally possible this biosignature is legitimate, but it’s also totally possible that they’re hyping up questionable findings because they want to persuade Trump that funding a NASA mission to Mars would boost his TV ratings.




  • this is a big ol’ “it depends”

    if it’s a hobby project, then by all means rewrite it if you want to.

    if it’s a commercial project of some kind - there’s a business that’s making money, and part of the business making money relies on this code working properly - then rewrites are almost always a bad idea.

    read Things You Should Never Do, Part I, an almost 25-year-old blog post (man, that’s a weird sentence to write) about why giant rewrites in a commercial setting are a bad idea.

    in general, people greatly underestimate how much work is involved in a rewrite. it feels like it should be simpler to start from a blank slate, and tell yourself you’re going to avoid all the mistakes that you hate with the existing codebase. maybe you’re writing it in a new language, or at least a newer dialect/version of the same language.

    if the current codebase is a mess…how did it get that way? lack of engineering discipline? a “just make it work now, we can go back and tidy it up later” attitude towards accumulation of tech debt? if those same attitudes are present on the team doing the rewrite, you’re going to end up right back where you started after the rewrite is “done”.

    the main things you need for refactoring to be successful is a) tests, and b) a plan.

    the tests allow you to refactor with the confidence that if you break something, the tests will point it out for you. trying to refactor something that lacks tests is the worst place to be in, because you’ll want to add tests, and often adding tests requires refactoring the code to be more testable, placing you in a catch-22.

    the plan allows you to make those refactoring changes gradually, over time, while still maintaining the system. in the context of a business that’s paying developers to do this work, the businesspeople tend to look poorly on an engineer coming to them and saying “we’re gonna spend the next year or two doing a big rewrite, so in the meantime you can’t ask us for any new features or bugfixes to the existing system. but once it’s done the new system will be really cool, trust me.”

    successful refactoring is a Ship of Thesus - you can replace the entire thing, but you have to do it one component at a time.


  • you read a post about how awesome C is, asking why more people don’t use it and instead gravitate towards replacements.

    you ctrl-F for “security” - no mention

    “buffer overflow” - nope

    “memory safety” - nothing

    “undefined behavior” - nada

    this is sort of a reverse Chesterton’s Fence situation. the fence is getting replaced, and you’re talking about how great the old fence was, without understanding any of the actual problems it had.

    you wrote some C and found it simple? OK, great, congratulations.

    go work on a C codebase that spans 100 or more engineers all contributing to it.

    go write some C code that listens on a TCP socket and has to deserialize potentially-malicious data received from the public internet.

    go write some C code that will be used on an aircraft and has to comply with DO-178C.

    and so on. after you’ve done that, come back here and tell us if you still think it’s “simple and effective” and “applicable everywhere”.

    there is a reason C has stood the test of time over many decades. but there is also a reason it is being replaced with more modern languages.