René's URL Explorer Experiment


Title: gh-89727: Fix os.walk RecursionError on deep trees by jonburdo · Pull Request #99803 · python/cpython · GitHub

Open Graph Title: gh-89727: Fix os.walk RecursionError on deep trees by jonburdo · Pull Request #99803 · python/cpython

X Title: gh-89727: Fix os.walk RecursionError on deep trees by jonburdo · Pull Request #99803 · python/cpython

Description: The Python programming language. Contribute to python/cpython development by creating an account on GitHub.

Open Graph Description: Use a stack to implement os.walk iteratively instead of recursively to avoid hitting recursion limits on deeply nested trees. Issue: Change shutil.rmtree and os.walk to support very deep hierarch...

X Description: Use a stack to implement os.walk iteratively instead of recursively to avoid hitting recursion limits on deeply nested trees. Issue: Change shutil.rmtree and os.walk to support very deep hierarch...

Opengraph URL: https://github.com/python/cpython/pull/99803

X: @github

direct link

Domain: github.com

route-pattern/:user_id/:repository/pull/:id/commits(.:format)
route-controllerpull_requests
route-actioncommits
fetch-noncev2:ddbb963d-ef4f-fcfe-4f70-e012aeba9742
current-catalog-service-hashae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b
request-idC20C:1E6D3F:8C081D:BB004E:69697B69
html-safe-nonce6cd9e840ab6e7187f3157433971176314518ed8fa34fb8441ab5bdf15ad4dd0c
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJDMjBDOjFFNkQzRjo4QzA4MUQ6QkIwMDRFOjY5Njk3QjY5IiwidmlzaXRvcl9pZCI6IjEyODgyNDYwODE4MDcyODUwOTciLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ==
visitor-hmac3475d37c4ff2d01366517d3550a314ffdda4b04c4b077dc80999b6d06273af5d
hovercard-subject-tagpull_request:1136570177
github-keyboard-shortcutsrepository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///pull_requests/show/commits
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/python/cpython/pull/99803/commits
twitter:imagehttps://opengraph.githubassets.com/613e96a0e2fb71af410c99cf0855f54fae2766b10136f597d8cb3ef70b295fcd/python/cpython/pull/99803
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/613e96a0e2fb71af410c99cf0855f54fae2766b10136f597d8cb3ef70b295fcd/python/cpython/pull/99803
og:image:altUse a stack to implement os.walk iteratively instead of recursively to avoid hitting recursion limits on deeply nested trees. Issue: Change shutil.rmtree and os.walk to support very deep hierarch...
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:usernamejonburdo
hostnamegithub.com
expected-hostnamegithub.com
Nonef33e4b94c8824ab2b434d82a94139432fb5ebee9df4b75304140ad22508c4a77
turbo-cache-controlno-cache
go-importgithub.com/python/cpython git https://github.com/python/cpython.git
octolytics-dimension-user_id1525981
octolytics-dimension-user_loginpython
octolytics-dimension-repository_id81598961
octolytics-dimension-repository_nwopython/cpython
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id81598961
octolytics-dimension-repository_network_root_nwopython/cpython
turbo-body-classeslogged-out env-production page-responsive
disable-turbofalse
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release48f380098b30acbb700b04f1724481ca10d574fc
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/python/cpython/pull/99803/commits#start-of-content
https://github.com/
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fpython%2Fcpython%2Fpull%2F99803%2Fcommits
GitHub CopilotWrite better code with AIhttps://github.com/features/copilot
GitHub SparkBuild and deploy intelligent appshttps://github.com/features/spark
GitHub ModelsManage and compare promptshttps://github.com/features/models
MCP RegistryNewIntegrate external toolshttps://github.com/mcp
ActionsAutomate any workflowhttps://github.com/features/actions
CodespacesInstant dev environmentshttps://github.com/features/codespaces
IssuesPlan and track workhttps://github.com/features/issues
Code ReviewManage code changeshttps://github.com/features/code-review
GitHub Advanced SecurityFind and fix vulnerabilitieshttps://github.com/security/advanced-security
Code securitySecure your code as you buildhttps://github.com/security/advanced-security/code-security
Secret protectionStop leaks before they starthttps://github.com/security/advanced-security/secret-protection
Why GitHubhttps://github.com/why-github
Documentationhttps://docs.github.com
Bloghttps://github.blog
Changeloghttps://github.blog/changelog
Marketplacehttps://github.com/marketplace
View all featureshttps://github.com/features
Enterpriseshttps://github.com/enterprise
Small and medium teamshttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
App Modernizationhttps://github.com/solutions/use-case/app-modernization
DevSecOpshttps://github.com/solutions/use-case/devsecops
DevOpshttps://github.com/solutions/use-case/devops
CI/CDhttps://github.com/solutions/use-case/ci-cd
View all use caseshttps://github.com/solutions/use-case
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
View all industrieshttps://github.com/solutions/industry
View all solutionshttps://github.com/solutions
AIhttps://github.com/resources/articles?topic=ai
Software Developmenthttps://github.com/resources/articles?topic=software-development
DevOpshttps://github.com/resources/articles?topic=devops
Securityhttps://github.com/resources/articles?topic=security
View all topicshttps://github.com/resources/articles
Customer storieshttps://github.com/customer-stories
Events & webinarshttps://github.com/resources/events
Ebooks & reportshttps://github.com/resources/whitepapers
Business insightshttps://github.com/solutions/executive-insights
GitHub Skillshttps://skills.github.com
Documentationhttps://docs.github.com
Customer supporthttps://support.github.com
Community forumhttps://github.com/orgs/community/discussions
Trust centerhttps://github.com/trust-center
Partnershttps://github.com/partners
GitHub SponsorsFund open source developershttps://github.com/sponsors
Security Labhttps://securitylab.github.com
Maintainer Communityhttps://maintainers.github.com
Acceleratorhttps://github.com/accelerator
Archive Programhttps://archiveprogram.github.com
Topicshttps://github.com/topics
Trendinghttps://github.com/trending
Collectionshttps://github.com/collections
Enterprise platformAI-powered developer platformhttps://github.com/enterprise
GitHub Advanced SecurityEnterprise-grade security featureshttps://github.com/security/advanced-security
Copilot for BusinessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/premium-support
Pricinghttps://github.com/pricing
Search syntax tipshttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
documentationhttps://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%2F99803%2Fcommits
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%2Fpull_requests%2Fshow%2Fcommits&source=header-repo&source_repo=python%2Fcpython
Reloadhttps://github.com/python/cpython/pull/99803/commits
Reloadhttps://github.com/python/cpython/pull/99803/commits
Reloadhttps://github.com/python/cpython/pull/99803/commits
python https://github.com/python
cpythonhttps://github.com/python/cpython
Please reload this pagehttps://github.com/python/cpython/pull/99803/commits
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 pagehttps://github.com/python/cpython/pull/99803/commits
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
JelleZijlstrahttps://github.com/JelleZijlstra
python:mainhttps://github.com/python/cpython/tree/main
jonburdo:iterative-os-walkhttps://github.com/jonburdo/cpython/tree/iterative-os-walk
Conversationhttps://github.com/python/cpython/pull/99803
Commits16 (16)https://github.com/python/cpython/pull/99803/commits
Checkshttps://github.com/python/cpython/pull/99803/checks
Files changedhttps://github.com/python/cpython/pull/99803/files
gh-89727: Fix os.walk RecursionError on deep treeshttps://github.com/python/cpython/pull/99803/commits#top
JelleZijlstrahttps://github.com/JelleZijlstra
python:mainhttps://github.com/python/cpython/tree/main
jonburdo:iterative-os-walkhttps://github.com/jonburdo/cpython/tree/iterative-os-walk
gh-89727: Fix os.walk RecursionError on deep treeshttps://github.com/python/cpython/pull/99803/commits/99f4691399229be2daacfacdba09ab4d4805f5c4
https://github.com/jonburdo
jonburdohttps://github.com/python/cpython/commits?author=jonburdo
99f4691https://github.com/python/cpython/pull/99803/commits/99f4691399229be2daacfacdba09ab4d4805f5c4
https://github.com/python/cpython/tree/99f4691399229be2daacfacdba09ab4d4805f5c4
add unit test to ensure os.walk is not affect by recursion limithttps://github.com/python/cpython/pull/99803/commits/3552d4989724e9086774e76b21c6871fc83f820f
https://github.com/jonburdo
jonburdohttps://github.com/python/cpython/commits?author=jonburdo
3552d49https://github.com/python/cpython/pull/99803/commits/3552d4989724e9086774e76b21c6871fc83f820f
https://github.com/python/cpython/tree/3552d4989724e9086774e76b21c6871fc83f820f
move os._walk code to os.walkhttps://github.com/python/cpython/pull/99803/commits/3078ea601feae31baecb36fc2eecfe5e0c19040f
https://github.com/jonburdo
jonburdohttps://github.com/python/cpython/commits?author=jonburdo
3078ea6https://github.com/python/cpython/pull/99803/commits/3078ea601feae31baecb36fc2eecfe5e0c19040f
https://github.com/python/cpython/tree/3078ea601feae31baecb36fc2eecfe5e0c19040f
fix blurb to mention os.walkhttps://github.com/python/cpython/pull/99803/commits/f37bbe8aaa3ffd91b879a17bc5d0daee2cbd20e2
https://github.com/jonburdo
jonburdohttps://github.com/python/cpython/commits?author=jonburdo
f37bbe8https://github.com/python/cpython/pull/99803/commits/f37bbe8aaa3ffd91b879a17bc5d0daee2cbd20e2
https://github.com/python/cpython/tree/f37bbe8aaa3ffd91b879a17bc5d0daee2cbd20e2
use deque in os.walkhttps://github.com/python/cpython/pull/99803/commits/f26a5b88b8636d2ffd27f5410d94a795b8ec0d4d
https://github.com/jonburdo
jonburdohttps://github.com/python/cpython/commits?author=jonburdo
f26a5b8https://github.com/python/cpython/pull/99803/commits/f26a5b88b8636d2ffd27f5410d94a795b8ec0d4d
https://github.com/python/cpython/tree/f26a5b88b8636d2ffd27f5410d94a795b8ec0d4d
Merge branch 'main' into iterative-os-walkhttps://github.com/python/cpython/pull/99803/commits/955d21b55fe5b548405b80576159e7a8b3b7b8fb
https://github.com/jonburdo
jonburdohttps://github.com/python/cpython/commits?author=jonburdo
955d21bhttps://github.com/python/cpython/pull/99803/commits/955d21b55fe5b548405b80576159e7a8b3b7b8fb
https://github.com/python/cpython/tree/955d21b55fe5b548405b80576159e7a8b3b7b8fb
Merge branch 'main' into iterative-os-walkhttps://github.com/python/cpython/pull/99803/commits/8fbfb2e7261faf5ad414a43470cfe4cd15513345
https://github.com/jonburdo
jonburdohttps://github.com/python/cpython/commits?author=jonburdo
8fbfb2ehttps://github.com/python/cpython/pull/99803/commits/8fbfb2e7261faf5ad414a43470cfe4cd15513345
https://github.com/python/cpython/tree/8fbfb2e7261faf5ad414a43470cfe4cd15513345
move deque import inside os.walkhttps://github.com/python/cpython/pull/99803/commits/ef46eda965d1c8dc1a63dbf464a79ab19fc8d80d
https://github.com/jonburdo
jonburdohttps://github.com/python/cpython/commits?author=jonburdo
ef46edahttps://github.com/python/cpython/pull/99803/commits/ef46eda965d1c8dc1a63dbf464a79ab19fc8d80d
https://github.com/python/cpython/tree/ef46eda965d1c8dc1a63dbf464a79ab19fc8d80d
rename temp_recursion_limit to set_recursion_limithttps://github.com/python/cpython/pull/99803/commits/e261b9fd1b2628f578ceff19b86df9bc02206601
https://github.com/jonburdo
jonburdohttps://github.com/python/cpython/commits?author=jonburdo
e261b9fhttps://github.com/python/cpython/pull/99803/commits/e261b9fd1b2628f578ceff19b86df9bc02206601
https://github.com/python/cpython/tree/e261b9fd1b2628f578ceff19b86df9bc02206601
Merge branch 'main' into iterative-os-walkhttps://github.com/python/cpython/pull/99803/commits/5ec53f7cdd277c9ca8a267a2efcb3783d66e8659
https://github.com/jonburdo
jonburdohttps://github.com/python/cpython/commits?author=jonburdo
5ec53f7https://github.com/python/cpython/pull/99803/commits/5ec53f7cdd277c9ca8a267a2efcb3783d66e8659
https://github.com/python/cpython/tree/5ec53f7cdd277c9ca8a267a2efcb3783d66e8659
switch back to list instead of deque for os.walk stackhttps://github.com/python/cpython/pull/99803/commits/507b650a7d8dc01b6115f434591238699ef8ad38
https://github.com/jonburdo
jonburdohttps://github.com/python/cpython/commits?author=jonburdo
507b650https://github.com/python/cpython/pull/99803/commits/507b650a7d8dc01b6115f434591238699ef8ad38
https://github.com/python/cpython/tree/507b650a7d8dc01b6115f434591238699ef8ad38
Apply suggestions from code reviewhttps://github.com/python/cpython/pull/99803/commits/1c356102d80ac154b9379c86603d975d2dfe20e0
jonburdohttps://github.com/python/cpython/commits?author=jonburdo
JelleZijlstrahttps://github.com/python/cpython/commits?author=JelleZijlstra
1c35610https://github.com/python/cpython/pull/99803/commits/1c356102d80ac154b9379c86603d975d2dfe20e0
https://github.com/python/cpython/tree/1c356102d80ac154b9379c86603d975d2dfe20e0
clean up os.walk commentshttps://github.com/python/cpython/pull/99803/commits/73138a6363e5b8276e10d4639e66788bcd7323f4
https://github.com/jonburdo
jonburdohttps://github.com/python/cpython/commits?author=jonburdo
73138a6https://github.com/python/cpython/pull/99803/commits/73138a6363e5b8276e10d4639e66788bcd7323f4
https://github.com/python/cpython/tree/73138a6363e5b8276e10d4639e66788bcd7323f4
test correct value in test_walk_above_recursion_limithttps://github.com/python/cpython/pull/99803/commits/2814cc5f728a054fe463dd8aa65ccfd0b14c6f74
https://github.com/jonburdo
jonburdohttps://github.com/python/cpython/commits?author=jonburdo
2814cc5https://github.com/python/cpython/pull/99803/commits/2814cc5f728a054fe463dd8aa65ccfd0b14c6f74
https://github.com/python/cpython/tree/2814cc5f728a054fe463dd8aa65ccfd0b14c6f74
set islink and join before loop in os.walkhttps://github.com/python/cpython/pull/99803/commits/37f3cc77d8cc9380561280bf49f4979c68437657
https://github.com/jonburdo
jonburdohttps://github.com/python/cpython/commits?author=jonburdo
37f3cc7https://github.com/python/cpython/pull/99803/commits/37f3cc77d8cc9380561280bf49f4979c68437657
https://github.com/python/cpython/tree/37f3cc77d8cc9380561280bf49f4979c68437657
Merge branch 'main' into iterative-os-walkhttps://github.com/python/cpython/pull/99803/commits/d9c766c05c0b3e49f6f4d1051fd80fb3c651d304
https://github.com/jonburdo
jonburdohttps://github.com/python/cpython/commits?author=jonburdo
d9c766chttps://github.com/python/cpython/pull/99803/commits/d9c766c05c0b3e49f6f4d1051fd80fb3c651d304
https://github.com/python/cpython/tree/d9c766c05c0b3e49f6f4d1051fd80fb3c651d304
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.