• UndercoverUlrikHD@programming.dev
      link
      fedilink
      arrow-up
      0
      ·
      3 days ago

      OP suggested that linters for python won’t catch attribute errors, which they 100% will if you use type hints, as you should.

      What happens at runtime is really relevant in this case.

        • UndercoverUlrikHD@programming.dev
          link
          fedilink
          arrow-up
          0
          ·
          edit-2
          2 days ago

          I don’t want to get into an Internet argument over pedantry. Linter is often used as a catch-all term for static analysis tools.

          Wikipedia defines it as

          Lint is the computer science term for a static code analysis tool used to flag programming errors, bugs, stylistic errors and suspicious constructs.

          Catching type errors and attribute errors would fit under this description, if you use a different, more precise definition at your workplace, cool, then we just have different definitions for it. The point is that your IDE should automatically detect the errors regardless of what you call it.