Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork34.2k
gh-145335: Fix os functions when passing fd -1 as path#145439
gh-145335: Fix os functions when passing fd -1 as path#145439vstinner merged 5 commits intopython:mainfrom
Conversation
os.listdir(-1) and os.scandir(-1) now fail with OSError(errno.EBADF)rather than listing the current directory.os.listxattr(-1) now fails with OSError(errno.EBADF) rather thanlisting extended attributes of the current directory.
bedevere-bot commentedMar 2, 2026
🤖 New build scheduled with the buildbot fleet by@vstinner for commita894262 🤖 Results will be shown at: https://buildbot.python.org/all/#/grid?branch=refs%2Fpull%2F145439%2Fmerge If you want to schedule another build, you need to add the🔨 test-with-buildbots label again. |
vstinner commentedMar 3, 2026
Tests failed on 5 buildbots, but failures are unrelated to this change.
3 tests failed: |
vstinner commentedMar 3, 2026 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
picnixz left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
LGTM! Are there actually other places where we use the path converter and that would be useful? (that is, do you plan to look at other modules as follow-up?)
52c8efa intopython:mainUh oh!
There was an error while loading.Please reload this page.
vstinner commentedMar 3, 2026
Merged. Thanks for the review! |
vstinner commentedMar 3, 2026
I had a look and I didn't find other places with the same bug.
|
Uh oh!
There was an error while loading.Please reload this page.
os.listdir(-1) and os.scandir(-1) now fail with OSError(errno.EBADF) rather than listing the current directory.
os.listxattr(-1) now fails with OSError(errno.EBADF) rather than listing extended attributes of the current directory.
os.pathconf(-1, 1)#145335