Beartype API: It Bears Bookmarking

Beartype isn’t just the beartype.beartype() decorator.

Beartype is a menagerie of public APIs for type-checking, introspecting, and manipulating type hints at runtime – all accessible under the beartype package installed when you installed beartype. But all beartype documentation begins with beartype.beartype(), just like all rivers run to the sea. [1]

The Left-Paw Path

See the left sidebar for links to human-readable API documentation – including:

Or see these autogenerated indices for machine-readable laundry lists. For those about to put on the 90’s-era Geocities nostalgia goggles, you prefer inscrutable enumerations in lexicographic (i.e., effectively arbitrary) order of all public beartype:

  • Attributes. This is literally everything. By everything, we mean modules, classes, functions, and globals. If it’s not here, it doesn’t exist. If it actually exists, it’s private and you shouldn’t have gone there. But curiosity killed your codebase, didn’t it? You went there. You violated privacy encapsulation and now nothing works. So this is what it’s like when doves cry.

  • Modules. Look. It’s just modules. Never click this.