• Ethan@programming.dev
    link
    fedilink
    English
    arrow-up
    0
    ·
    20 days ago

    “Assume it’s a map and treat like a map and then catch the type error if it’s not.” Paraphrased from actual advice by Guido on how you should write Python. Python isn’t a bad language but the philosophy that comes along with it is so fucked.

        • manicdave@feddit.uk
          link
          fedilink
          arrow-up
          0
          ·
          19 days ago

          Why though? I’ve genuinely never had a problem with it. If something is wrong, it was always going to be wrong. Why is it preferable to have to write a bunch of bolierplate than just deal with the stacktrace when you do encounter a type error?