| route-pattern | /_view_fragments/voltron/pull_requests/show/:user_id/:repository/:id/pull_request_layout(.:format) |
| route-controller | voltron_pull_requests_fragments |
| route-action | pull_request_layout |
| fetch-nonce | v2:52f9a9b8-68e4-eb0c-e387-61c57f073338 |
| current-catalog-service-hash | ae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b |
| request-id | 965E:3244AB:205DE9:2BA3EA:696977F6 |
| html-safe-nonce | 38a3fb45ade286cb6dad3e1599375bd59bd356469a0cea85624092c3f7dcf74a |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI5NjVFOjMyNDRBQjoyMDVERTk6MkJBM0VBOjY5Njk3N0Y2IiwidmlzaXRvcl9pZCI6IjYzNjIxOTU2NzY1MDE3MzU0MTQiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | 120427d87f1c9abf0e734e31c7f33dbe971f811ea99f11951411f3217dc25666 |
| hovercard-subject-tag | pull_request:1091437032 |
| github-keyboard-shortcuts | repository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | ///voltron/pull_requests_fragments/pull_request_layout |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/voltron/pull_requests/show/python/cpython/98419/pull_request_layout |
| twitter:image | https://opengraph.githubassets.com/ae93ea6e1710933c5c88911bc0ff07e7e35efe1b6f03b6e4718a1f12f6e35824/python/cpython/pull/98419 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/ae93ea6e1710933c5c88911bc0ff07e7e35efe1b6f03b6e4718a1f12f6e35824/python/cpython/pull/98419 |
| og:image:alt | Presizing the result lists saves space from list over-allocation and is faster than the PyList_Append() approach.
This is a short PR but it took a while to figure out that PyList_GetSlice() would m... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | rhettinger |
| hostname | github.com |
| expected-hostname | github.com |
| None | c6f193beb8ff08443adc07685d75302ab8aaf0a135f6e251c3ff3112c8deb881 |
| turbo-cache-control | no-preview |
| go-import | github.com/python/cpython git https://github.com/python/cpython.git |
| octolytics-dimension-user_id | 1525981 |
| octolytics-dimension-user_login | python |
| octolytics-dimension-repository_id | 81598961 |
| octolytics-dimension-repository_nwo | python/cpython |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 81598961 |
| octolytics-dimension-repository_network_root_nwo | python/cpython |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 212e3e3d3298bf5b313830edfd2399e869f7ea76 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| Skip to content | https://github.com/python/cpython/pull/98419#start-of-content |
|
| https://github.com/ |
|
Sign in
| https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fpython%2Fcpython%2Fpull%2F98419 |
| GitHub CopilotWrite better code with AI | https://github.com/features/copilot |
| GitHub SparkBuild and deploy intelligent apps | https://github.com/features/spark |
| GitHub ModelsManage and compare prompts | https://github.com/features/models |
| MCP RegistryNewIntegrate external tools | https://github.com/mcp |
| ActionsAutomate any workflow | https://github.com/features/actions |
| CodespacesInstant dev environments | https://github.com/features/codespaces |
| IssuesPlan and track work | https://github.com/features/issues |
| Code ReviewManage code changes | https://github.com/features/code-review |
| GitHub Advanced SecurityFind and fix vulnerabilities | https://github.com/security/advanced-security |
| Code securitySecure your code as you build | https://github.com/security/advanced-security/code-security |
| Secret protectionStop leaks before they start | https://github.com/security/advanced-security/secret-protection |
| Why GitHub | https://github.com/why-github |
| Documentation | https://docs.github.com |
| Blog | https://github.blog |
| Changelog | https://github.blog/changelog |
| Marketplace | https://github.com/marketplace |
| View all features | https://github.com/features |
| Enterprises | https://github.com/enterprise |
| Small and medium teams | https://github.com/team |
| Startups | https://github.com/enterprise/startups |
| Nonprofits | https://github.com/solutions/industry/nonprofits |
| App Modernization | https://github.com/solutions/use-case/app-modernization |
| DevSecOps | https://github.com/solutions/use-case/devsecops |
| DevOps | https://github.com/solutions/use-case/devops |
| CI/CD | https://github.com/solutions/use-case/ci-cd |
| View all use cases | https://github.com/solutions/use-case |
| Healthcare | https://github.com/solutions/industry/healthcare |
| Financial services | https://github.com/solutions/industry/financial-services |
| Manufacturing | https://github.com/solutions/industry/manufacturing |
| Government | https://github.com/solutions/industry/government |
| View all industries | https://github.com/solutions/industry |
| View all solutions | https://github.com/solutions |
| AI | https://github.com/resources/articles?topic=ai |
| Software Development | https://github.com/resources/articles?topic=software-development |
| DevOps | https://github.com/resources/articles?topic=devops |
| Security | https://github.com/resources/articles?topic=security |
| View all topics | https://github.com/resources/articles |
| Customer stories | https://github.com/customer-stories |
| Events & webinars | https://github.com/resources/events |
| Ebooks & reports | https://github.com/resources/whitepapers |
| Business insights | https://github.com/solutions/executive-insights |
| GitHub Skills | https://skills.github.com |
| Documentation | https://docs.github.com |
| Customer support | https://support.github.com |
| Community forum | https://github.com/orgs/community/discussions |
| Trust center | https://github.com/trust-center |
| Partners | https://github.com/partners |
| GitHub SponsorsFund open source developers | https://github.com/sponsors |
| Security Lab | https://securitylab.github.com |
| Maintainer Community | https://maintainers.github.com |
| Accelerator | https://github.com/accelerator |
| Archive Program | https://archiveprogram.github.com |
| Topics | https://github.com/topics |
| Trending | https://github.com/trending |
| Collections | https://github.com/collections |
| Enterprise platformAI-powered developer platform | https://github.com/enterprise |
| GitHub Advanced SecurityEnterprise-grade security features | https://github.com/security/advanced-security |
| Copilot for BusinessEnterprise-grade AI features | https://github.com/features/copilot/copilot-business |
| Premium SupportEnterprise-grade 24/7 support | https://github.com/premium-support |
| Pricing | https://github.com/pricing |
| Search syntax tips | https://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax |
| documentation | https://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax |
|
Sign in
| https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fpython%2Fcpython%2Fpull%2F98419 |
|
Sign up
| https://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fvoltron%2Fpull_requests_fragments%2Fpull_request_layout&source=header-repo&source_repo=python%2Fcpython |
| Reload | https://github.com/python/cpython/pull/98419 |
| Reload | https://github.com/python/cpython/pull/98419 |
| Reload | https://github.com/python/cpython/pull/98419 |
|
python
| https://github.com/python |
| cpython | https://github.com/python/cpython |
| Please reload this page | https://github.com/python/cpython/pull/98419 |
|
Notifications
| https://github.com/login?return_to=%2Fpython%2Fcpython |
|
Fork
33.9k
| https://github.com/login?return_to=%2Fpython%2Fcpython |
|
Star
71.1k
| https://github.com/login?return_to=%2Fpython%2Fcpython |
|
Code
| https://github.com/python/cpython |
|
Issues
5k+
| https://github.com/python/cpython/issues |
|
Pull requests
2.1k
| https://github.com/python/cpython/pulls |
|
Actions
| https://github.com/python/cpython/actions |
|
Projects
31
| https://github.com/python/cpython/projects |
|
Security
Uh oh!
There was an error while loading. Please reload this page.
| https://github.com/python/cpython/security |
| Please reload this page | https://github.com/python/cpython/pull/98419 |
|
Insights
| https://github.com/python/cpython/pulse |
|
Code
| https://github.com/python/cpython |
|
Issues
| https://github.com/python/cpython/issues |
|
Pull requests
| https://github.com/python/cpython/pulls |
|
Actions
| https://github.com/python/cpython/actions |
|
Projects
| https://github.com/python/cpython/projects |
|
Security
| https://github.com/python/cpython/security |
|
Insights
| https://github.com/python/cpython/pulse |
| Sign up for GitHub
| https://github.com/signup?return_to=%2Fpython%2Fcpython%2Fissues%2Fnew%2Fchoose |
| terms of service | https://docs.github.com/terms |
| privacy statement | https://docs.github.com/privacy |
| Sign in | https://github.com/login?return_to=%2Fpython%2Fcpython%2Fissues%2Fnew%2Fchoose |
| Jump to bottom | https://github.com/python/cpython/pull/98419#issue-comment-box |
| rhettinger | https://github.com/rhettinger |
| python:main | https://github.com/python/cpython/tree/main |
| rhettinger:better_batched | https://github.com/rhettinger/cpython/tree/better_batched |
|
GH-98363: Presize the list for batched()
| https://github.com/python/cpython/pull/98419#top |
| rhettinger | https://github.com/rhettinger |
| python:main | https://github.com/python/cpython/tree/main |
| rhettinger:better_batched | https://github.com/rhettinger/cpython/tree/better_batched |
|
Conversation
6
| https://github.com/python/cpython/pull/98419 |
|
Commits
6
| https://github.com/python/cpython/pull/98419/commits |
|
Checks
0
| https://github.com/python/cpython/pull/98419/checks |
|
Files changed
| https://github.com/python/cpython/pull/98419/files |
| Please reload this page | https://github.com/python/cpython/pull/98419 |
| https://github.co/hiddenchars |
| https://github.com/python/cpython/pull/{{ revealButtonHref }} |
|
| https://github.com/rhettinger |
| rhettinger | https://github.com/rhettinger |
| Oct 18, 2022 | https://github.com/python/cpython/pull/98419#issue-1413952919 |
| Please reload this page | https://github.com/python/cpython/pull/98419 |
| Add itertools.batched() #98363 | https://github.com/python/cpython/issues/98363 |
| Please reload this page | https://github.com/python/cpython/pull/98419 |
|
| https://github.com/rhettinger |
| Presize the list for batched() | https://github.com/python/cpython/pull/98419/commits/ea9511e781dea7b25d8929332534afefdb6dadcd |
| ea9511e | https://github.com/python/cpython/pull/98419/commits/ea9511e781dea7b25d8929332534afefdb6dadcd |
| https://github.com/rhettinger |
| rhettinger | https://github.com/rhettinger |
|
performance
| https://github.com/python/cpython/issues?q=state%3Aopen%20label%3Aperformance |
|
skip news
| https://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22skip%20news%22 |
| Oct 18, 2022 | https://github.com/python/cpython/pull/98419#event-7616039368 |
| https://github.com/rhettinger |
| rhettinger | https://github.com/rhettinger |
| sweeneyde | https://github.com/sweeneyde |
| October 18, 2022 23:09 | https://github.com/python/cpython/pull/98419#event-7616039379 |
| https://github.com/bedevere-bot |
| bedevere-bot | https://github.com/bedevere-bot |
|
awaiting core review
| https://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22awaiting%20core%20review%22 |
| Oct 18, 2022 | https://github.com/python/cpython/pull/98419#event-7616039596 |
| rhettinger | https://github.com/rhettinger |
| October 18, 2022 19:29 | https://github.com/python/cpython/pull/98419#commits-pushed-88fc1b1 |
|
| https://github.com/rhettinger |
| Fast path for the common case (zero new items). | https://github.com/python/cpython/pull/98419/commits/88fc1b105a465370c1eee0e6e2a431a612e33059 |
| 88fc1b1 | https://github.com/python/cpython/pull/98419/commits/88fc1b105a465370c1eee0e6e2a431a612e33059 |
|
| https://github.com/rhettinger |
| Cleaner handling of empty result | https://github.com/python/cpython/pull/98419/commits/0e05aa486104ca6639e43f7e93fca7708696dacc |
| 0e05aa4 | https://github.com/python/cpython/pull/98419/commits/0e05aa486104ca6639e43f7e93fca7708696dacc |
|
| https://github.com/rhettinger |
| Let NULL error flow through the return | https://github.com/python/cpython/pull/98419/commits/646630efe3f69ef626d263162de684f1b0e6f7a2 |
| 646630e | https://github.com/python/cpython/pull/98419/commits/646630efe3f69ef626d263162de684f1b0e6f7a2 |
|
| https://github.com/rhettinger |
| Use n variable consistently throughout | https://github.com/python/cpython/pull/98419/commits/5e38c096ff98b319c4f45a3d857f8187f0aa98a2 |
| 5e38c09 | https://github.com/python/cpython/pull/98419/commits/5e38c096ff98b319c4f45a3d857f8187f0aa98a2 |
|
| https://github.com/rhettinger |
| Remove spurious include directive | https://github.com/python/cpython/pull/98419/commits/fd5b50871810e8228d6596d7681beb883d9ecebd |
| fd5b508 | https://github.com/python/cpython/pull/98419/commits/fd5b50871810e8228d6596d7681beb883d9ecebd |
| https://github.com/rhettinger |
| rhettinger | https://github.com/rhettinger |
|
🔨 test-with-buildbots
| https://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22%3Ahammer%3A%20test-with-buildbots%22 |
| Oct 19, 2022 | https://github.com/python/cpython/pull/98419#event-7616630928 |
| https://github.com/bedevere-bot |
| bedevere-bot | https://github.com/bedevere-bot |
| Oct 19, 2022 | https://github.com/python/cpython/pull/98419#issuecomment-1283228588 |
| @rhettinger | https://github.com/rhettinger |
| fd5b508 | https://github.com/python/cpython/commit/fd5b50871810e8228d6596d7681beb883d9ecebd |
| Please reload this page | https://github.com/python/cpython/pull/98419 |
| https://github.com/bedevere-bot |
| bedevere-bot | https://github.com/bedevere-bot |
|
🔨 test-with-buildbots
| https://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22%3Ahammer%3A%20test-with-buildbots%22 |
| Oct 19, 2022 | https://github.com/python/cpython/pull/98419#event-7616631163 |
| https://github.com/sweeneyde |
| sweeneyde | https://github.com/sweeneyde |
|
Oct 20, 2022
| https://github.com/python/cpython/pull/98419#pullrequestreview-1148458192 |
|
View reviewed changes
| https://github.com/python/cpython/pull/98419/files/fd5b50871810e8228d6596d7681beb883d9ecebd |
| Modules/itertoolsmodule.c | https://github.com/python/cpython/pull/98419/files/fd5b50871810e8228d6596d7681beb883d9ecebd#diff-dc27cbdf2b9f6e5236cade13cf301d352a7abd2a8b1988f2517d6f5b7a30c201 |
| sweeneyde | https://github.com/sweeneyde |
| Oct 20, 2022 | https://github.com/python/cpython/pull/98419#discussion_r1000074109 |
| Learn more | https://docs.github.com/articles/managing-disruptive-comments/#hiding-a-comment |
| Please reload this page | https://github.com/python/cpython/pull/98419 |
| rhettinger | https://github.com/rhettinger |
| Oct 20, 2022 | https://github.com/python/cpython/pull/98419#discussion_r1000128530 |
| Please reload this page | https://github.com/python/cpython/pull/98419 |
| Learn more | https://docs.github.com/articles/managing-disruptive-comments/#hiding-a-comment |
| Please reload this page | https://github.com/python/cpython/pull/98419 |
| sweeneyde | https://github.com/sweeneyde |
| Oct 20, 2022 | https://github.com/python/cpython/pull/98419#discussion_r1000188986 |
| Please reload this page | https://github.com/python/cpython/pull/98419 |
| Learn more | https://docs.github.com/articles/managing-disruptive-comments/#hiding-a-comment |
| Please reload this page | https://github.com/python/cpython/pull/98419 |
| https://github.com/sweeneyde |
| sweeneyde | https://github.com/sweeneyde |
|
Oct 20, 2022
| https://github.com/python/cpython/pull/98419#pullrequestreview-1148623982 |
|
View reviewed changes
| https://github.com/python/cpython/pull/98419/files/fd5b50871810e8228d6596d7681beb883d9ecebd |
| sweeneyde | https://github.com/sweeneyde |
| https://github.com/python/cpython/pull/98419#pullrequestreview-1148623982 |
| Learn more | https://docs.github.com/articles/managing-disruptive-comments/#hiding-a-comment |
| Please reload this page | https://github.com/python/cpython/pull/98419 |
| https://github.com/bedevere-bot |
| bedevere-bot | https://github.com/bedevere-bot |
|
awaiting merge
| https://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22awaiting%20merge%22 |
|
awaiting core review
| https://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22awaiting%20core%20review%22 |
| Oct 20, 2022 | https://github.com/python/cpython/pull/98419#event-7627729868 |
| https://github.com/rhettinger |
| rhettinger | https://github.com/rhettinger |
| c1e02d4 | https://github.com/python/cpython/commit/c1e02d4e4e09dfc9d57c4d36eca1bbf312d4162d |
| Oct 20, 2022 | https://github.com/python/cpython/pull/98419#event-7628119771 |
| https://github.com/bedevere-bot |
| bedevere-bot | https://github.com/bedevere-bot |
|
awaiting merge
| https://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22awaiting%20merge%22 |
| Oct 20, 2022 | https://github.com/python/cpython/pull/98419#event-7628120203 |
| https://github.com/rhettinger |
| rhettinger | https://github.com/rhettinger |
| Oct 20, 2022 | https://github.com/python/cpython/pull/98419#issuecomment-1285074797 |
| Please reload this page | https://github.com/python/cpython/pull/98419 |
| Please reload this page | https://github.com/python/cpython/pull/98419 |
| carljm | https://github.com/carljm |
|
Oct 20, 2022
| https://github.com/python/cpython/pull/98419#ref-commit-8bba5da |
|
| https://github.com/carljm |
| Merge branch 'main' into typewatch | https://github.com/carljm/cpython/commit/8bba5da3257ff3464b4d5e5913ebe3ac86644fd8 |
| 8bba5da | https://github.com/carljm/cpython/commit/8bba5da3257ff3464b4d5e5913ebe3ac86644fd8 |
| pythongh-98461 | https://github.com/python/cpython/issues/98461 |
| pythonGH-98464 | https://github.com/python/cpython/pull/98464 |
| pythongh-98421 | https://github.com/python/cpython/issues/98421 |
| pythonGH-98422 | https://github.com/python/cpython/pull/98422 |
| pythongh-98360 | https://github.com/python/cpython/issues/98360 |
| pythonGH-98462 | https://github.com/python/cpython/pull/98462 |
| python#98480 | https://github.com/python/cpython/pull/98480 |
| pythonGH-98481 | https://github.com/python/cpython/pull/98481 |
| pythonGH-98475 | https://github.com/python/cpython/pull/98475 |
| pythongh-95023 | https://github.com/python/cpython/issues/95023 |
| python#95046 | https://github.com/python/cpython/pull/95046 |
| pythonGH-98363 | https://github.com/python/cpython/issues/98363 |
| pythonGH-98419 | https://github.com/python/cpython/pull/98419 |
| pythongh-98374 | https://github.com/python/cpython/issues/98374 |
| pythongh-98450 | https://github.com/python/cpython/pull/98450 |
| python#98351 | https://github.com/python/cpython/pull/98351 |
| pythongh-98354 | https://github.com/python/cpython/issues/98354 |
| pythonGH-98412 | https://github.com/python/cpython/pull/98412 |
| pythongh-98257 | https://github.com/python/cpython/issues/98257 |
| python#98258 | https://github.com/python/cpython/pull/98258 |
| pythongh-98414 | https://github.com/python/cpython/issues/98414 |
| pythonGH-98460 | https://github.com/python/cpython/pull/98460 |
| pythongh-98417 | https://github.com/python/cpython/issues/98417 |
| pythonGH-98418 | https://github.com/python/cpython/pull/98418 |
| python#98409 | https://github.com/python/cpython/pull/98409 |
| pythonGH-98350 | https://github.com/python/cpython/pull/98350 |
| python#98441 | https://github.com/python/cpython/pull/98441 |
| pythongh-92886 | https://github.com/python/cpython/issues/92886 |
| pythonGH-93231 | https://github.com/python/cpython/pull/93231 |
| pythongh-92886 | https://github.com/python/cpython/issues/92886 |
| pythonGH-93233 | https://github.com/python/cpython/pull/93233 |
| pythongh-92886 | https://github.com/python/cpython/issues/92886 |
| pythonGH-93235 | https://github.com/python/cpython/pull/93235 |
| https://github.com/rhettinger |
| rhettinger | https://github.com/rhettinger |
| October 20, 2022 21:38 | https://github.com/python/cpython/pull/98419#event-7635210410 |
| Sign up for free | https://github.com/join?source=comment-repo |
| Sign in to comment | https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fpython%2Fcpython%2Fpull%2F98419 |
|
| https://github.com/sweeneyde |
|
sweeneyde
| https://github.com/sweeneyde |
|
| https://github.com/python/cpython/pull/98419/files/fd5b50871810e8228d6596d7681beb883d9ecebd |
|
performance
| https://github.com/python/cpython/issues?q=state%3Aopen%20label%3Aperformance |
|
skip news
| https://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22skip%20news%22 |
| Please reload this page | https://github.com/python/cpython/pull/98419 |
|
| https://github.com/rhettinger |
|
| https://github.com/bedevere-bot |
|
| https://github.com/sweeneyde |
|
| https://github.com |
| Terms | https://docs.github.com/site-policy/github-terms/github-terms-of-service |
| Privacy | https://docs.github.com/site-policy/privacy-policies/github-privacy-statement |
| Security | https://github.com/security |
| Status | https://www.githubstatus.com/ |
| Community | https://github.community/ |
| Docs | https://docs.github.com/ |
| Contact | https://support.github.com?tags=dotcom-footer |