GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — gh-123471: make itertools.batched thread-safe by eendebakpt · Pull Request #129416 · python/cpython

Conversation

@eendebakpt

@eendebakpt eendebakpt commented Jan 28, 2025 •
edited by bedevere-app Bot
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Contributor
  • Make batched thread-safe using atomic loads and stores
  • Depends on gh-115999: Make list and tuple iteration more thread-safe. #128637 to make the iteration over the data = tuple(range(1000)) thread safe.
  • Also see Strategy for Iterators in Free Threading #124397
  • Issue: Make concurrent iteration over pairwise, combinations, permutations, cwr, product, etc. from itertools safe under free-threading #123471

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
eendebakpt added 2 commits January 28, 2025 20:09
@eendebakpt
Make itertools.batched thread-safe
070c877
@eendebakpt
enable tests
cc3c42b
@eendebakpt
eendebakpt requested a review from rhettinger as a code owner January 28, 2025 19:19
@bedevere-app bedevere-app Bot added the awaiting review label Jan 28, 2025
@bedevere-app bedevere-app Bot mentioned this pull request Jan 28, 2025
Make concurrent iteration over pairwise, combinations, permutations, cwr, product, etc. from itertools safe under free-threading #123471
Open
@ZeroIntensity ZeroIntensity added the topic-free-threading label Jan 29, 2025
ZeroIntensity
ZeroIntensity reviewed Jan 29, 2025
View reviewed changes
Comment thread Modules/itertoolsmodule.c Resolved

Uh oh!

There was an error while loading. Please reload this page.

eendebakpt and others added 2 commits February 19, 2025 08:08
@eendebakpt
Merge branch 'main' into batched_ft
6452c72
@blurb-it
📜🤖 Added by blurb_it.
0193795
@eendebakpt
eendebakpt requested a review from ZeroIntensity February 23, 2025 21:08
kumaraditya303
kumaraditya303 requested changes Mar 11, 2025
View reviewed changes
Comment thread Modules/itertoolsmodule.c Resolved

Uh oh!

There was an error while loading. Please reload this page.

@bedevere-app bedevere-app Bot added awaiting changes and removed awaiting review labels Mar 11, 2025
@bedevere-app

bedevere-app Bot commented Mar 11, 2025

Copy link
Copy Markdown

A Python core developer has requested some changes be made to your pull request before we can consider merging it. If you could please address their requests along with any other requests in other reviews from core developers that would be appreciated.

Once you have made the requested changes, please leave a comment on this pull request containing the phrase I have made the requested changes; please review again. I will then notify any core developers who have left a review that you're ready for them to take another look at this pull request.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@eendebakpt
review comments
71fed22
kumaraditya303
kumaraditya303 reviewed Mar 11, 2025
View reviewed changes
Comment thread Lib/test/test_free_threading/test_itertools_batched.py Resolved

Uh oh!

There was an error while loading. Please reload this page.

kumaraditya303
kumaraditya303 reviewed Mar 11, 2025
View reviewed changes
Comment thread Lib/test/test_free_threading/test_itertools_batched.py Resolved

Uh oh!

There was an error while loading. Please reload this page.

kumaraditya303
kumaraditya303 reviewed Mar 11, 2025
View reviewed changes
Comment thread Modules/itertoolsmodule.c Resolved

Uh oh!

There was an error while loading. Please reload this page.

kumaraditya303
kumaraditya303 reviewed Mar 11, 2025
View reviewed changes
Comment thread Modules/itertoolsmodule.c Resolved

Uh oh!

There was an error while loading. Please reload this page.

kumaraditya303
kumaraditya303 reviewed Mar 11, 2025
View reviewed changes
Comment thread Modules/itertoolsmodule.c Resolved

Uh oh!

There was an error while loading. Please reload this page.

kumaraditya303
kumaraditya303 reviewed Mar 11, 2025
View reviewed changes
Comment thread Modules/itertoolsmodule.c Resolved

Uh oh!

There was an error while loading. Please reload this page.

eendebakpt added 3 commits March 11, 2025 21:12
@eendebakpt
review comments
3ae3c48
@eendebakpt
review comments
560bc59
@eendebakpt
Merge branch 'main' into batched_ft
0cd92fc
kumaraditya303
kumaraditya303 reviewed Mar 12, 2025
View reviewed changes
Comment thread Lib/test/test_free_threading/test_itertools_batched.py Resolved

Uh oh!

There was an error while loading. Please reload this page.

eendebakpt
eendebakpt commented Mar 12, 2025
View reviewed changes
Comment thread Lib/test/test_free_threading/test_itertools_batched.py Resolved

Uh oh!

There was an error while loading. Please reload this page.

@eendebakpt
Update Lib/test/test_free_threading/test_itertools_batched.py
4df892d
kumaraditya303
kumaraditya303 approved these changes Mar 12, 2025
View reviewed changes
@bedevere-app bedevere-app Bot added awaiting merge and removed awaiting changes labels Mar 12, 2025
@kumaraditya303
kumaraditya303 merged commit 405a2d7 into python:main Mar 12, 2025
@bedevere-app bedevere-app Bot removed the awaiting merge label Mar 12, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@kumaraditya303 kumaraditya303 kumaraditya303 approved these changes
@rhettinger rhettinger Awaiting requested review from rhettinger rhettinger is a code owner
@ZeroIntensity ZeroIntensity Awaiting requested review from ZeroIntensity

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

topic-free-threading

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

3 participants

@eendebakpt @ZeroIntensity @kumaraditya303
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.