๐ฌ Advanced Deep Dives
Typed Attributes with Descriptors
Enforce a type on every assignment.
Descriptors run code when an attribute is read or written. __set_name__ learns the attribute name at class-creation time so the descriptor can store its value on the instance.