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

CI: Bump Python to 3.13 and mypy to 1.12 in mypy workflow #125592

Merged
merged 3 commits into from
Oct 16, 2024

Conversation

Eclips4
Copy link
Member

@Eclips4 Eclips4 commented Oct 16, 2024

I think that we're ready to bump python to 3.12 in mypy workflow, from what I can see at python/mypy#15277, mypy almost supports 3.12 except for python/mypy#15313.

Copy link
Member

@sobolevn sobolevn left a comment

Choose a reason for hiding this comment

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

A big +1 from me :)

@Eclips4
Copy link
Member Author

Eclips4 commented Oct 16, 2024

FYI: There is a PR which failed due to Python 3.11 in the mypy workflow: #125589

Copy link
Member

@JelleZijlstra JelleZijlstra left a comment

Choose a reason for hiding this comment

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

Note that "supporting" a version in the mypy issue tracker is often a bit of a misnomer. Mypy has long supported running on Python 3.12 fine; it just may not necessarily have good support for type checking all new features in Python 3.12.

@JelleZijlstra
Copy link
Member

We could even run it on 3.13 if we update to the latest mypy release (1.12).

@AlexWaygood
Copy link
Member

AlexWaygood commented Oct 16, 2024

(Mypy will still reject new-in-Python 3.12 features in some of the various directories it checks, even with this change, without changes such as the one Pablo is proposing to make to the mypy.ini file in #125589. And that's deliberate: we want to ensure that some of our build tools can be run on older versions of Python.)

@Eclips4 Eclips4 changed the title CI: Bump Python to 3.12 in mypy workflow CI: Bump Python to 3.13 and mypy to 1.12 in mypy workflow Oct 16, 2024
@AlexWaygood
Copy link
Member

You get to remove a type: ignore comment from Argument Clinic that we don't need anymore, now 😃

Copy link
Member

@AlexWaygood AlexWaygood left a comment

Choose a reason for hiding this comment

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

Thanks!

@Eclips4 Eclips4 enabled auto-merge (squash) October 16, 2024 14:14
@Eclips4 Eclips4 merged commit d83fcf8 into python:main Oct 16, 2024
40 checks passed
@Eclips4 Eclips4 deleted the bump-python-ci branch October 16, 2024 14:27
@Eclips4
Copy link
Member Author

Eclips4 commented Oct 16, 2024

Do you think this should be backported to 3.13?

@AlexWaygood
Copy link
Member

If it backports cleanly, it's nice to have a consistent "CI experience" between the actively maintained branches. But I also wouldn't spend too much time on it if it doesn't backport cleanly :-)

@Eclips4 Eclips4 added the needs backport to 3.13 bugs and security fixes label Oct 16, 2024
@miss-islington-app
Copy link

Thanks @Eclips4 for the PR 🌮🎉.. I'm working now to backport this PR to: 3.13.
🐍🍒⛏🤖

@miss-islington-app
Copy link

Sorry, @Eclips4, I could not cleanly backport this to 3.13 due to a conflict.
Please backport using cherry_picker on command line.

cherry_picker d83fcf8371f2f33c7797bc8f5423a8bca8c46e5c 3.13

@bedevere-app
Copy link

bedevere-app bot commented Oct 16, 2024

GH-125596 is a backport of this pull request to the 3.13 branch.

@bedevere-app bedevere-app bot removed the needs backport to 3.13 bugs and security fixes label Oct 16, 2024
Eclips4 added a commit to Eclips4/cpython that referenced this pull request Oct 16, 2024
…honGH-125592)

* Bump mypy to 1.12 & Python to 3.13

* Remove unnecessary `type: ignore`
(cherry picked from commit d83fcf8)

Co-authored-by: Kirill Podoprigora <kirill.bast9@mail.ru>
@Eclips4
Copy link
Member Author

Eclips4 commented Oct 16, 2024

If it backports cleanly, it's nice to have a consistent "CI experience" between the actively maintained branches. But I also wouldn't spend too much time on it if it doesn't backport cleanly :-)

Talking about the 3.12 branch, I'm not sure if this should be done there. Running mypy on the 3.13 version may give false positives for the 3.12 version, so... what do you think?

@AlexWaygood
Copy link
Member

Talking about the 3.12 branch, I'm not sure if this should be done there. Running mypy on the 3.13 version may give false positives for the 3.12 version, so... what do you think?

As long as the python_version field is set to 3.12 or less in all the mypy.ini files on the 3.12 branch, it shouldn't theoretically be an issue to backport it to the 3.12 branch

@Eclips4 Eclips4 added the needs backport to 3.12 bug and security fixes label Oct 16, 2024
@miss-islington-app
Copy link

Thanks @Eclips4 for the PR 🌮🎉.. I'm working now to backport this PR to: 3.12.
🐍🍒⛏🤖

@miss-islington-app
Copy link

Sorry, @Eclips4, I could not cleanly backport this to 3.12 due to a conflict.
Please backport using cherry_picker on command line.

cherry_picker d83fcf8371f2f33c7797bc8f5423a8bca8c46e5c 3.12

Eclips4 added a commit to Eclips4/cpython that referenced this pull request Oct 16, 2024
…honGH-125592)

* Bump mypy to 1.12 & Python to 3.13

* Remove unnecessary `type: ignore`
(cherry picked from commit d83fcf8)

Co-authored-by: Kirill Podoprigora <kirill.bast9@mail.ru>
Eclips4 added a commit that referenced this pull request Oct 16, 2024
#125596)

[3.13] CI: Bump Python to 3.13 and mypy to 1.12 in mypy workflow (GH-125592)

(cherry picked from commit d83fcf8)
@Eclips4 Eclips4 removed the needs backport to 3.12 bug and security fixes label Oct 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants