New submission from Antoine Pitrou <pit...@free.fr>:

Right now it is painful to integrate openat() with the normal IO classes. You 
have to figure out the low-level flags yourself (i.e. replicate the logic and 
error handling from the FileIO constructor), then replicate the open() logic 
yourself (because you want to set the name attribute on the FileIO object 
before wrapping it).

Therefore it would be nice if the FileIO constructor and the open() function 
supported openat natively. I see two possibilities:
- allow a (dirfd, name) tuple for the first "file" argument
- allow an optional dirfd argument at the end of the arglist

----------
components: IO, Library (Lib)
messages: 142560
nosy: haypo, neologix, pitrou, rosslagerwall
priority: normal
severity: normal
stage: needs patch
status: open
title: io.FileIO and io.open should support openat
type: feature request
versions: Python 3.3

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue12797>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to