Opaque Types in Python
Summary
The article explores using the opaque data type pattern in Python via typing.NewType to expose a public, minimal API for complex configuration objects. It demonstrates wrapping a private internal class with a public NewType to keep constructors hidden while providing public builder functions, and includes examples that evolve the API without breaking changes.