Skip to main content

Type-safe Python

Project description

pylint img

Typedpy - Strict Type System for Python

typedpy is a library for type-safe, strict, Python structures. It supports Python 3.6+.


  • Full featured, sophisticated, class-based type system

  • Supports JSON schema draft4 features, including mapping schema-to-code and code-to-schema

  • Serialization, deserialization between JSON-like dict and typedpy objects, including custom mapping. Support for pickling.

  • Easily extensible. Wrapper of any class as a Field

  • Inheritance/mixins of fields/classes

  • Embedded structures within structures/fields and fields within fields

  • Supports the common collections

  • Immutable Structures/Fields

  • Clean Java-generics-like definitions, but more flexible. e.g.: Set[AnyOf[Integer(minimum=10), Array]], Map[String(maxLength=8), String]

  • No dependencies on third-party libs

There are many examples under "tests/".


Detailed documentation is here


PyPI page is here

Conda-Forge page is here

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for typedpy, version 2.6.1
Filename, size File type Python version Upload date Hashes
Filename, size typedpy-2.6.1-py3.9.egg (109.2 kB) File type Egg Python version 3.9 Upload date Hashes View
Filename, size typedpy-2.6.1-py3-none-any.whl (43.4 kB) File type Wheel Python version py3 Upload date Hashes View
Filename, size typedpy-2.6.1.tar.gz (40.1 kB) File type Source Python version None Upload date Hashes View

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring DigiCert DigiCert EV certificate Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page