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

gil: try to initialize threads on Python 3.6 if possible #1874

Merged
merged 1 commit into from Sep 17, 2021

Conversation

davidhewitt
Copy link
Member

Fixes #1870

@@ -52,10 +52,12 @@ pub(crate) fn gil_is_acquired() -> bool {
/// software). Support for this is tracked on the
/// [PyPy issue tracker](https://foss.heptapod.net/pypy/pypy/-/issues/3286).
///
/// Python 3.6 only: If the Python interpreter is initialized but Python threading is not, this

Choose a reason for hiding this comment

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

Is it only for python3.6? I can't see that python36 is different from the previous versions from the FFI doc. But I haven't tested on python35 or earlier though.

Copy link
Member Author

Choose a reason for hiding this comment

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

We don't support Python 3.5 or earlier, as their end of life date has already been reached.

Note also that we will stop supporting Python 3.6 next year: #1782

Choose a reason for hiding this comment

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

Got it. Thank you!

@davidhewitt davidhewitt merged commit 56ef7c9 into PyO3:main Sep 17, 2021
@davidhewitt davidhewitt deleted the py36-threads-panic branch September 17, 2021 12:02
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.

PyEval_InitThreads is not called in #[pymodule] for Python3.6
2 participants