Protocols - Static duck typing for decoupled code - presented by Ran Zvi
EuroPython 2022 - Protocols - Static duck typing for decoupled code - presented by Ran Zvi [Liffey B on 2022-07-13] Python introduces Protocols to support static duck typing, where static type checkers (mypy) and other tools can verify code correctness prior to runtime. This was added in order to circumvent explicitly inheriting from ABCs (Abstract base classes) which is ""unpythonic and unlike what one would normally do in idiomatic dynamically typed Python code"" - according to PEP 544. We will explore the different use cases for Protocols and how to use them correctly. This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License http://creativecommons.org/licenses/by-nc-sa/4.0/