Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use eval_type_backport on Python 3.9 if it's installed to resolve int | None etc. #773

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Commits on Nov 16, 2024

  1. Use eval_type_backport on Python 3.9 if it's installed to resolve `in…

    …t | None` etc.
    
    This uses the same module that pydantic does, and it allows people to use the
    new pipe syntax if they have to support Python3.9 too -- very useful for
    libraries.
    
    (Also it works better with many type checkers which seem to mistakenly think
    that with `from __future__ import annotations` means `int| None` will work,
    but it doesn't out of the box.)
    ashb committed Nov 16, 2024
    Configuration menu
    Copy the full SHA
    3cc6d81 View commit details
    Browse the repository at this point in the history