]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
[3.13] GH-89727: Fix `os.fwalk()` recursion error on deep trees (GH-119638) (#119764)
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Thu, 30 May 2024 03:28:55 +0000 (05:28 +0200)
committerGitHub <noreply@github.com>
Thu, 30 May 2024 03:28:55 +0000 (03:28 +0000)
commit810a09ad3710be60cff9e174be85ca65e76cdbd1
tree2ae4fd4efd0045bbab030984c624fa749916f94a
parent06c62d697a87822690342cd0d99d1cdbeca4ce9d
[3.13] GH-89727: Fix `os.fwalk()` recursion error on deep trees (GH-119638) (#119764)

GH-89727: Fix `os.fwalk()` recursion error on deep trees (GH-119638)

Implement `os.fwalk()` using a list as a stack to avoid emitting recursion
errors on deeply nested trees.
(cherry picked from commit 3c890b503c740767d0eb9a0e74b47f17a1e69452)

Co-authored-by: Barney Gale <barney.gale@gmail.com>
Lib/os.py
Lib/test/test_os.py
Misc/NEWS.d/next/Library/2024-05-28-00-56-59.gh-issue-89727._bxoL3.rst [new file with mode: 0644]