top | item 44033601

(no title)

bpshaver | 9 months ago

Sometimes, but maybe you haven't written any tests! Type hints and immediate feedback from mypy are a lot easier than writing unit tests.

discuss

order

igouy|9 months ago

> haven't written any

Any!

Then maybe the immediate feedback of consistent types conveys a false impression.

bpshaver|9 months ago

Hard to conceive of a case where that would occur. Can you think of one?

The implication of what you're saying seems to be that if you're concerned about some kind of correctness you should be writing unit tests anyway and not being so fussed about type checking in a language like Python. I suppose if you are strictly following TDD that might work, but in all other cases type checks give you feedback much more quickly than unit tests ever can. I guess I don't understand.