Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork33.7k
Closed
Description
pathlib.Path.glob() currently generatesPath objects for intermediate paths that might never be yielded to the user, which is slow and unnecessary. For example, a pattern like**/*.mp3 is evaluated by creating aPath object for every directory visited.
There are already few tricks employed to avoid instantiation, but it would be better if onlyreal results were converted to path objects.