Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Support Python 3.13 beta #4253

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

Merged
merged 12 commits into from
Jun 18, 2024
Merged

Support Python 3.13 beta #4253

merged 12 commits into from
Jun 18, 2024

Conversation

harshil21
Copy link
Member

@harshil21 harshil21 commented May 11, 2024

We should probably wait for cffi to release their new version to target 3.13, otherwise passport related functionality won't work. Tracking: python-cffi/cffi#23, python-cffi/cffi#71

@harshil21 harshil21 added the πŸ”— python related technology: python label May 11, 2024
Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

Hey! Looks like you edited the (optional) requirements or the pre-commit hooks. I'm just a friendly reminder to keep the additional dependencies for the hooks in sync with the requirements :)

@harshil21 harshil21 added the πŸ“‹ do-not-merge-yet work status: do-not-merge-yet label May 11, 2024
@harshil21
Copy link
Member Author

If possible we should do #4129 before this is merged so it's easier to change setup.py. test_meta fails on 3.13 because of the change to locals() - https://docs.python.org/3.13/library/functions.html#locals. I don't want to change that part yet because I don't want to potentially break the release

@harshil21
Copy link
Member Author

I don't want to change that part yet because I don't want to potentially break the release

ironically if we don't merge this, then all ptb installations on py 3.13 will fail by default. And we don't have python version specific wheels so we can build it on another version and it should be good to go.

uses pre-release of cffi 1.17.0 since they don't plan to release the full version until 3.13 rc1

@harshil21 harshil21 removed the πŸ“‹ do-not-merge-yet work status: do-not-merge-yet label Jun 16, 2024
@harshil21
Copy link
Member Author

Merged master so we should be good to go. Also verified that pip install .[passport] correctly installs cffi 1.17.0 on python 3.13.

Not sure why type completeness is unhappy. All ruff did was remove some quotes around the annotation and that failed this test apparently.

Copy link
Member

@Bibo-Joshi Bibo-Joshi left a comment

Choose a reason for hiding this comment

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

Hi, thanks for the updates :) I left a bunch of commentsπŸ™†β€β™‚οΈ

Copy link
Member

@Bibo-Joshi Bibo-Joshi left a comment

Choose a reason for hiding this comment

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

LGTM, then, thanks for the work :) Anyhting to add from your side or should I merge?

@harshil21
Copy link
Member Author

All good from my side!

@Bibo-Joshi Bibo-Joshi merged commit 9ce0f49 into master Jun 18, 2024
27 checks passed
@Bibo-Joshi Bibo-Joshi deleted the py13-beta branch June 18, 2024 20:25
@@ -106,7 +106,7 @@ def __init__(self) -> None:

self._application: Optional[weakref.ReferenceType[Application]] = None
self._executor = AsyncIOExecutor()
self.scheduler: AsyncIOScheduler = AsyncIOScheduler(**self.scheduler_configuration)
self.scheduler: "AsyncIOScheduler" = AsyncIOScheduler(**self.scheduler_configuration)
Copy link
Member Author

Choose a reason for hiding this comment

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

ruff complains about this for me locally (i'm on py 3.13 so that's possibly why now)

@harshil21
Copy link
Member Author

also forget to mention that for some reason mypy segfaults on my build of python 3.13b1. Does anyone else have the same issue?

@Bibo-Joshi
Copy link
Member

Did not try yet ...

@github-actions github-actions bot locked and limited conversation to collaborators Jul 5, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
πŸ”— python related technology: python
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants