Skip to content

Conversation

@potiuk
Copy link
Member

@potiuk potiuk commented Nov 22, 2024

The eval-type-backport is a tool to replace some of the controversial new type hints added with from future imoport __annotations__ to "classic" type hint (| and list - into Union and List).

This helps to battle some of the issues where Pydantic has troubles when they are used for classes that Pydantic uses.

The library was initially added in #42196 but it was added for all Python versions - this change limits it only to Python < 3.10


^ Add meaningful description above
Read the Pull Request Guidelines for more information.
In case of fundamental code changes, an Airflow Improvement Proposal (AIP) is needed.
In case of a new dependency, check compliance with the ASF 3rd Party License Policy.
In case of backwards incompatible changes please leave a note in a newsfragment file, named {pr_number}.significant.rst or {issue_number}.significant.rst, in newsfragments.

The `eval-type-backport` is a tool to replace some of the controversial
new type hints added with `from future imoport __annotations__`
to "classic" type hint (| and list - into `Union` and `List`).

This helps to battle some of the issues where Pydantic has troubles
when they are used for classes that Pydantic uses.

The library was initially added in apache#42196 but it was added for all
Python versions - this change limits it only to Python < 3.10
@potiuk
Copy link
Member Author

potiuk commented Nov 22, 2024

Also see #44249 (comment) for context.

Copy link
Member

@pierrejeambrun pierrejeambrun left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice thanks.

@potiuk
Copy link
Member Author

potiuk commented Nov 23, 2024

Issues unrelated. Merging.

@potiuk potiuk closed this Nov 23, 2024
@potiuk potiuk reopened this Nov 23, 2024
@potiuk potiuk merged commit 2948338 into apache:main Nov 23, 2024
@potiuk potiuk deleted the only-install-eval-type-backport-for-3.8-3.9 branch November 23, 2024 23:28
@github-actions
Copy link

Backport failed to create: v2-10-test. View the failure log Run details

Status Branch Result
v2-10-test Commit Link

@potiuk
Copy link
Member Author

potiuk commented Nov 23, 2024

Backport failed to create: v2-10-test. View the failure log Run details

Yeah - expected that. Will cherry pick manually.

potiuk added a commit to potiuk/airflow that referenced this pull request Nov 23, 2024
…e#44294)

The `eval-type-backport` is a tool to replace some of the controversial
new type hints added with `from future imoport __annotations__`
to "classic" type hint (| and list - into `Union` and `List`).

This helps to battle some of the issues where Pydantic has troubles
when they are used for classes that Pydantic uses.

The library was initially added in apache#42196 but it was added for all
Python versions - this change limits it only to Python < 3.10
(cherry picked from commit 2948338)

Co-authored-by: Jarek Potiuk <jarek@potiuk.com>
jscheffl pushed a commit that referenced this pull request Nov 24, 2024
… (#44315)

The `eval-type-backport` is a tool to replace some of the controversial
new type hints added with `from future imoport __annotations__`
to "classic" type hint (| and list - into `Union` and `List`).

This helps to battle some of the issues where Pydantic has troubles
when they are used for classes that Pydantic uses.

The library was initially added in #42196 but it was added for all
Python versions - this change limits it only to Python < 3.10
(cherry picked from commit 2948338)
utkarsharma2 pushed a commit that referenced this pull request Dec 4, 2024
… (#44315)

The `eval-type-backport` is a tool to replace some of the controversial
new type hints added with `from future imoport __annotations__`
to "classic" type hint (| and list - into `Union` and `List`).

This helps to battle some of the issues where Pydantic has troubles
when they are used for classes that Pydantic uses.

The library was initially added in #42196 but it was added for all
Python versions - this change limits it only to Python < 3.10
(cherry picked from commit 2948338)
utkarsharma2 pushed a commit that referenced this pull request Dec 9, 2024
… (#44315)

The `eval-type-backport` is a tool to replace some of the controversial
new type hints added with `from future imoport __annotations__`
to "classic" type hint (| and list - into `Union` and `List`).

This helps to battle some of the issues where Pydantic has troubles
when they are used for classes that Pydantic uses.

The library was initially added in #42196 but it was added for all
Python versions - this change limits it only to Python < 3.10
(cherry picked from commit 2948338)
got686-yandex pushed a commit to got686-yandex/airflow that referenced this pull request Jan 30, 2025
The `eval-type-backport` is a tool to replace some of the controversial
new type hints added with `from future imoport __annotations__`
to "classic" type hint (| and list - into `Union` and `List`).

This helps to battle some of the issues where Pydantic has troubles
when they are used for classes that Pydantic uses.

The library was initially added in apache#42196 but it was added for all
Python versions - this change limits it only to Python < 3.10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants