Skip to main content

Like `typing._eval_type`, but lets older Python versions use newer typing features.

Project description

eval_type_backport

Build Status Coverage Status Supports Python versions 3.7+, including PyPy

This is a tiny package providing a replacement for typing._eval_type to support newer typing features in older Python versions.

Yes, that's very specific, and yes, typing._eval_type is a protected function that you shouldn't normally be using. Really this package is specifically made for https://github.com/pydantic/pydantic/issues/7873.

Currently, it allows unions to be written like int | str which is normally only supported in Python 3.10+.

Project details


Download files

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

Source Distribution

eval_type_backport-0.0.1.tar.gz (6.8 kB view details)

Uploaded Source

Built Distribution

eval_type_backport-0.0.1-py3-none-any.whl (4.7 kB view details)

Uploaded Python 3

File details

Details for the file eval_type_backport-0.0.1.tar.gz.

File metadata

  • Download URL: eval_type_backport-0.0.1.tar.gz
  • Upload date:
  • Size: 6.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.5

File hashes

Hashes for eval_type_backport-0.0.1.tar.gz
Algorithm Hash digest
SHA256 3328c532f0d159f84756b11bd932ff2b5f93a7c605a603af02de0e38566c86df
MD5 f9e337e52361d59952be7a03ae474c56
BLAKE2b-256 45e427462fa20f6c9557c5e852d57982428e0e5cb3663508870d67e25ea5ef3e

See more details on using hashes here.

File details

Details for the file eval_type_backport-0.0.1-py3-none-any.whl.

File metadata

File hashes

Hashes for eval_type_backport-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 3aa0d990e642af9d8f9480c84dcaeabaaef83207bdcf5cb018706db6bb77d692
MD5 761ec22b1751c7b70d9d8d51cee92bf8
BLAKE2b-256 cb798f6a58b9329da56d2374d9fda17469d6eeaf432f99bebc723fa811c1463b

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page