Uh oh!
There was an error while loading. Please reload this page.
GH-77609: Support following symlinks in pathlib.Path.glob() - #104176
GH-77609: Support following symlinks in pathlib.Path.glob()#104176barneygale wants to merge 4 commits into
pathlib.Path.glob()#104176Conversation
barneygale
commented
May 8, 2023
zooba
commented
May 8, 2023
How does this help us fix the mixed up behaviour of the current function? |
barneygale
commented
May 8, 2023
I don't think the current behaviour is wrong, just difficult to optimize. With this PR, users would be able to recursively walk symlinks, and we'd be able to optimize |
zooba
commented
May 8, 2023
I'm surprised, because you closed the other PR saying you were convinced this was the way forward. Personally, I preferred the other way. It's a bit more work, but in ~5 years time we'll have forgotten about it and will just have sensible defaults. Adding this way and leaving the other one leaves us with two warts (okay, maybe 1.5, if people like this, but I feel like special patterns specifically for symlinks is too much). |
barneygale
commented
May 8, 2023
I know. I literally changed my mind again last night while playing around with the
👍 fair point, thanks for the advice. |
barneygale
commented
May 23, 2023
Closing in favour of #102616 |
Add support for
***wildcard inpathlib.Path.glob()andrglob(). This wildcard works like**, except that it also recurses into symlinks.See Recursive Globbing in the zshexpn manpage for prior art.
Alternative to #102616