Skip to content

Add Python 3.14 support#629

Merged
MarshalX merged 8 commits into
mainfrom
add-python-314-support
Oct 22, 2025
Merged

Add Python 3.14 support#629
MarshalX merged 8 commits into
mainfrom
add-python-314-support

Conversation

@MarshalX
Copy link
Copy Markdown
Owner

No description provided.

@MarshalX MarshalX linked an issue Oct 22, 2025 that may be closed by this pull request
@MarshalX MarshalX merged commit 76bd866 into main Oct 22, 2025
33 of 44 checks passed
@MarshalX MarshalX deleted the add-python-314-support branch October 22, 2025 19:45
zzstoatzz added a commit to zzstoatzz/atproto that referenced this pull request Oct 22, 2025
Pydantic 2.12.3+ warns that Field(default=None) has no effect in discriminated
union contexts, as optionality is already handled by the Optional[] wrapper.

This fix removes the default=None parameter from Field() for both:
- Discriminated unions (with discriminator='py_type')
- Unknown unions (without discriminator)

The previous fix in PR MarshalX#627 addressed optional fields with constraints,
but didn't cover discriminated unions which have their own Field() generation
logic in _get_ref_union_typehint().

Fixes issue MarshalX#625 (additional cases found in PR MarshalX#629)
zzstoatzz added a commit to zzstoatzz/atproto that referenced this pull request Oct 22, 2025
Pydantic 2.12.3+ warns that Field(default=None) has no effect in discriminated
union contexts, as optionality is already handled by the Optional[] wrapper.

This fix removes the default=None parameter from Field() for both:
- Discriminated unions (with discriminator='py_type')
- Unknown unions (without discriminator)

The previous fix in PR MarshalX#627 addressed optional fields with constraints,
but didn't cover discriminated unions which have their own Field() generation
logic in _get_ref_union_typehint().

Fixes issue MarshalX#625 (additional cases found in PR MarshalX#629)
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.

Python 3.14 support?

1 participant