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

gh-112070: make functools.lru_cache threadsafe in --disable-gil build #112111

Merged
merged 5 commits into from
Nov 17, 2023

Conversation

wanderxjtu
Copy link
Contributor

@wanderxjtu wanderxjtu commented Nov 15, 2023

Copy link

cpython-cla-bot bot commented Nov 15, 2023

All commit authors signed the Contributor License Agreement.
CLA signed

@bedevere-app
Copy link

bedevere-app bot commented Nov 15, 2023

Most changes to Python require a NEWS entry. Add one using the blurb_it web app or the blurb command-line tool.

If this change has little impact on Python users, wait for a maintainer to apply the skip news label instead.

@AlexWaygood AlexWaygood changed the title gh-112070: make functools.lrucacle threadsafe in --disable-gil build gh-112070: make functools.lru_cache threadsafe in --disable-gil build Nov 15, 2023
@bedevere-app
Copy link

bedevere-app bot commented Nov 15, 2023

Most changes to Python require a NEWS entry. Add one using the blurb_it web app or the blurb command-line tool.

If this change has little impact on Python users, wait for a maintainer to apply the skip news label instead.

Copy link
Contributor

@colesbury colesbury left a comment

Choose a reason for hiding this comment

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

Thanks @wanderxjtu! I left a few comments inline. I don't think this change needs a NEWS entry, so I added the "skip news" label and removed the NEWS file.

Modules/_functoolsmodule.c Outdated Show resolved Hide resolved
Modules/_functoolsmodule.c Outdated Show resolved Hide resolved
Copy link
Contributor

@colesbury colesbury left a comment

Choose a reason for hiding this comment

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

Thanks @wanderxjtu!

@corona10, would you please review this PR?

@corona10
Copy link
Member

I will take a look

@corona10 corona10 self-assigned this Nov 16, 2023
Copy link
Member

@corona10 corona10 left a comment

Choose a reason for hiding this comment

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

lgtm

@corona10 corona10 merged commit 0ee2d77 into python:main Nov 17, 2023
34 checks passed
aisk pushed a commit to aisk/cpython that referenced this pull request Feb 11, 2024
…il build (pythongh-112111)

* pythongh-112070: make `functools.lrucacle` threadsafe in --disable-gil build

* pythongh-112070: update generate `functoolsmodule` files

* pythongh-112070: add NEWS file

* Delete Misc/NEWS.d/next/Library/2023-11-15-20-19-45.gh-issue-112070.q6OhcU.rst

* pythongh-112070: reformat functoolsmodule.c

---------

Co-authored-by: Sam Gross <colesbury@gmail.com>
Glyphack pushed a commit to Glyphack/cpython that referenced this pull request Sep 2, 2024
…il build (pythongh-112111)

* pythongh-112070: make `functools.lrucacle` threadsafe in --disable-gil build

* pythongh-112070: update generate `functoolsmodule` files

* pythongh-112070: add NEWS file

* Delete Misc/NEWS.d/next/Library/2023-11-15-20-19-45.gh-issue-112070.q6OhcU.rst

* pythongh-112070: reformat functoolsmodule.c

---------

Co-authored-by: Sam Gross <colesbury@gmail.com>
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.

Make functools.lru_cache thread-safe in --disable-gil builds
3 participants