DEV Community

loading...

Discussion on: A Pythonic Guide to SOLID Design Principles

Collapse
hanpari profile image
Pavel Morava • Edited

You did not need to step out from Python for interfaces.

You could use Protocol from typing module. :)

Great article, anyway. Thank you.

Collapse
ezzy1337 profile image
Derek D. Author

I didn't know about that module. Thanks for the tip. I look forward to playing around with it.

Collapse
hanpari profile image
Pavel Morava

You'll need mypy or an internal static typing analyzer (as in PyCharm) to appreciate it. Otherwise, it is ignored in runtime.