~/talk

Coding to interfaces: Structural Subtyping in Python

TalkinItalianat PyCon Italia 2023 · 2023-05-25..05-28· [typescript]
links:none on file
links:none on file
slides:none on file

How to separate interface from implementation in dynamically typed Python using structural subtyping. It introduces Python typing Protocols and shows how to code to interfaces with structural subtyping, covering related best practices such as type hinting, static analysis, and clean code principles.

AI-written summary · about

  1. 0:00Introduction
  2. 0:46What are interfaces
  3. 3:57Static type checking
  4. 7:08Type hints with mypy
  5. 9:19Defining interfaces with ABC
  6. 13:13Structural subtyping with Protocols
  7. 16:42Benefits of decoupling
  8. 18:08Interface aggregation
  9. 21:44Protocol vs ABC
  10. 22:04Q&A
  11. 25:19TDD with interfaces
  12. 26:02Closing
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.