Skip to content

fix: add future annotations for Python 3.14 compatibility#893

Open
Aryamanz29 wants to merge 1 commit intomainfrom
BLDX-944
Open

fix: add future annotations for Python 3.14 compatibility#893
Aryamanz29 wants to merge 1 commit intomainfrom
BLDX-944

Conversation

@Aryamanz29
Copy link
Copy Markdown
Member

Python 3.14 (PEP 649) defers annotation evaluation by default, which breaks pydantic v1's type inference for the uppercase field names (CREATE, UPDATE, DELETE, PARTIAL_UPDATE) in MutatedEntities.

Adding from __future__ import annotations ensures annotations are stored as strings, which pydantic v1 can parse correctly regardless of the Python version's annotation evaluation strategy.

Fixes: BLDX-944

Python 3.14 (PEP 649) defers annotation evaluation by default,
which breaks pydantic v1's type inference for the uppercase field
names (CREATE, UPDATE, DELETE, PARTIAL_UPDATE) in MutatedEntities.

Adding `from __future__ import annotations` ensures annotations are
stored as strings, which pydantic v1 can parse correctly regardless
of the Python version's annotation evaluation strategy.

Fixes: BLDX-944
@Aryamanz29 Aryamanz29 self-assigned this Apr 13, 2026
@Aryamanz29 Aryamanz29 added the bugfix Bug fix pull request label Apr 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bugfix Bug fix pull request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant