Skip to main content

Backports python3.10 typing features into python3.8 and python3.9.

Project description

sigparse

Backports python3.10 typing features into python3.8 and 3.9.

Example

import sigparse

def func(param_a: list[str], param_b: str | int, param_c: tuple[int | None]):
    ...

# This returns the same result in python 3.8, 3.9, and 3.10!
sigparse.sigparse(func)

Notes

Inspect

This module uses inspect behind the scenes. For that reason:

  • sigparse.Parameter.default is inspect._empty when there is no default value.
  • sigparse.Parameter.kind is inspect._ParameterKind.

Annotated

typing.Annotated will always be evaluated with include_extras=True in python3.9.

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

sigparse-1.0.1.tar.gz (3.1 kB view details)

Uploaded Source

Built Distribution

sigparse-1.0.1-py3-none-any.whl (3.8 kB view details)

Uploaded Python 3

File details

Details for the file sigparse-1.0.1.tar.gz.

File metadata

  • Download URL: sigparse-1.0.1.tar.gz
  • Upload date:
  • Size: 3.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.2.0 CPython/3.8.13 Linux/5.15.0-1019-azure

File hashes

Hashes for sigparse-1.0.1.tar.gz
Algorithm Hash digest
SHA256 4ec616b96239d92fe58b882c6564cd25b67b6c3ccb3d82eb217159cc1cb0e1b9
MD5 bc8654c4c553485054f2ac6b7b7a55a8
BLAKE2b-256 f819abf304d50ee442f8a9d17a40585c61199b449a3ac16181bc3a3df128fb2b

See more details on using hashes here.

File details

Details for the file sigparse-1.0.1-py3-none-any.whl.

File metadata

  • Download URL: sigparse-1.0.1-py3-none-any.whl
  • Upload date:
  • Size: 3.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.2.0 CPython/3.8.13 Linux/5.15.0-1019-azure

File hashes

Hashes for sigparse-1.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 17d28c4906f7780467d73211dbb645dcb5d2cb1f848ff01c2688a6905132f782
MD5 bc20b7e09bc81a5d03779eaeac9602dd
BLAKE2b-256 e3fc1edc0926fc152964fee424c7af74df3fed4d9745f3e4965c1a31f4ee6a2a

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