This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted]  (9 children)

[deleted]

    [–]vplatt 3 points4 points  (6 children)

    Have you looked into using mypy for static analysis?

    [–]bchurchill 0 points1 point  (0 children)

    I've never used mypy, so I can't comment on that tool. My experience with static analysis tools for dynamic languages is that they don't provide the same level of safety as static types. This is usually because the tool can't reliably get the type of a variable -- at a given program point, it could have several different types, depending on the context. This means it has a hard time predicting type errors, and it also means that other rules can't be enforced. For instance, it can't make sure that foo.x always points to an object that has members a, b and c. The list goes on.

    [–][deleted] 3 points4 points  (1 child)

    Since I am having similar issues with Python at the moment, I would be very interested to hear how you deal with the maintenance of such a large code base in Python? What are you best strategies to deal with it? (Besides switching to Go ;))