SmokeDetector
SmokeDetector copied to clipboard
Should we use type hints?
Is your feature request related to a problem? Please describe.
Python has support for type hints. They have advantages (IDEs and other tools can help users avoid making type-related errors by checking, for one). I'm not aware of any major disadvantages currently (SD supports Python 3.6 and they were added in 3.5, so compatibility isn't a huge concern I think). Overall, I personally tend to like them as having my IDE verify I don't mess up types is handy.
Describe the solution you'd like
Use type hints on new code added to SD (and maybe some existing code, although I don't think that is really a priority).
Describe alternatives you've considered
N/A
Additional context
I asked if they should be used and Makyen said it would be reasonable to open an issue on GH to discuss it
Personal opinion: yes.
However implementation code-base wise will be complex and may introduce some headaches for syntax, etc. While generally I agree with us using type hinting, this is really a wider scale change than you think it is.