[Python-Dev] PEP 446: Add new parameters to configure the inherance of files and for non-blocking sockets
Cameron Simpson
cs at zip.com.au
Sun Jul 7 02:30:56 CEST 2013
On 06Jul2013 11:23, Charles-François Natali <cf.natali at gmail.com> wrote:
| > I've read your "Rejected Alternatives" more closely and Ulrich
| > Drepper's article, though I think the article also supports adding
| > a blocking (default True) parameter to open() and os.open(). If you
| > try to change that default on a platform where it doesn't work, an
| > exception should be raised.
|
| Contrarily to close-on-exec, non-blocking only applies to a limited
| type of files (e.g. it doesn't work for regular files, which represent
| 90% of open() use cases).
sockets, pipes, serial devices, ...
And you can set it on anything. Just because some things don't block
anyway isn't really a counter argument.
Cheers,
--
Cameron Simpson <cs at zip.com.au>
Hofstadter's Law: It always takes longer than you expect, even when you take
into account Hofstadter's Law.
- Douglas Hosfstadter, Godel, Escher, Bach: an Eternal Golden Braid
More information about the Python-Dev
mailing list