Skip to content

Initial fixes for Python 3.14 #10384

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

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

Conversation

cdce8p
Copy link
Member

@cdce8p cdce8p commented May 15, 2025

Start fixing some Python 3.14 errors. Tested against 3.14.0b1 locally. Mainly

  • Adjust checkers to handle the "new" Union inference result. I.e. it's now a ClassDef instead of a FunctionDef and the builtins type is Union instead of UnionType.
  • Remove typing.ByteString and collections.abc.ByteString as these have been removed in 3.14. It's probably not worth it to add separate test cases just for them.
  • Also remove typing.re.Pattern and typing.re.Match which have been removed back in 3.13. pylint doesn't emit no-member warnings for these since the typing module has a __getattr__ function.

@cdce8p cdce8p added Skip news 🔇 This change does not require a changelog entry python 3.14 labels May 15, 2025
Copy link
Contributor

🤖 According to the primer, this change has no effect on the checked open source code. 🤖🎉

This comment was generated for commit f86b527

@cdce8p cdce8p requested a review from Pierre-Sassoulas May 15, 2025 23:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
python 3.14 Skip news 🔇 This change does not require a changelog entry
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant