This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author eric.araujo
Recipients Arfrever, David.Townshend, Devin Jeanpierre, Julian, amaury.forgeotdarc, benjamin.peterson, cvrebert, docs@python, eric.araujo, neologix, pitrou, vstinner
Date 2011-12-30.20:59:04
SpamBayes Score 5.936855e-05
Marked as misclassified No
Message-id <1325278745.44.0.783137736919.issue12760@psf.upfronthosting.co.za>
In-reply-to
Content
> This is not a "duplicate issue". The openat solution is no easier than the os.open
> solution.

Amaury did not suggest to use openat, but the new opener argument to open, which was especially added for use cases such as the one discussed here:

    ...
    open_exclusive = lambda path, mode: os.open(path, mode|os.O_CREAT|os.O_EXCL))
    ...
    fp = open(filename, 'w', opener=open_exclusive)
    ...

That’s why this bug was initially closed as duplicate.
History
Date User Action Args
2011-12-30 20:59:05eric.araujosetrecipients: + eric.araujo, amaury.forgeotdarc, pitrou, vstinner, benjamin.peterson, Devin Jeanpierre, Arfrever, cvrebert, neologix, docs@python, Julian, David.Townshend
2011-12-30 20:59:05eric.araujosetmessageid: <1325278745.44.0.783137736919.issue12760@psf.upfronthosting.co.za>
2011-12-30 20:59:04eric.araujolinkissue12760 messages
2011-12-30 20:59:04eric.araujocreate