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 | christian.heimes |
|---|---|
| Recipients | christian.heimes, gvanrossum, loewis |
| Date | 2007年10月25日.09:44:27 |
| SpamBayes Score | 0.0013862243 |
| Marked as misclassified | No |
| Message-id | <1193305469.47.0.0144353397817.issue1318@psf.upfronthosting.co.za> |
| In-reply-to |
| Content | |
|---|---|
os.tmpfile() is the only method that has no duplicate in tempfile. I chose to keep it for this very reason. But you made good point, too. What do you think about renaming tmpfile to _tmpfile and make it available from the tempfile module as tempfile.tmpfile()? I totally agree with your opinion on tmpnam and tempnam. As far as I know it's impossible to prevent a child process from doing something harmful. The child must be mature enough to do the right think and open a file with the correct flags. The promise of tempfile.mkstemp is also bogus for every OS except Windows. IIRC only Windows supports O_NOINHERIT. Let me rephrase the rational for my patch: I want to remove duplicate code to have just but one implementation to create a temporary file (name). I want the one implementation be under our control and not depend on some possible broken or stupid C library like Windows where tmpnam may create the temporary files in C:\. I want an unified way to get the TEMP dir independent of the API. |
|
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2007年10月25日 09:44:29 | christian.heimes | set | spambayes_score: 0.00138622 -> 0.0013862243 recipients: + christian.heimes, gvanrossum, loewis |
| 2007年10月25日 09:44:29 | christian.heimes | set | spambayes_score: 0.00138622 -> 0.00138622 messageid: <1193305469.47.0.0144353397817.issue1318@psf.upfronthosting.co.za> |
| 2007年10月25日 09:44:29 | christian.heimes | link | issue1318 messages |
| 2007年10月25日 09:44:27 | christian.heimes | create | |