New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add os.close() suggestion to mkstemp documentation #51124
Comments
As per the blog entry I think the tempfile.mkstemp() documentation could be more helpful by If some native english speaker could give a review of the language I |
Or a review of the markup I used |
I don't think it would be beneficial to just talk about closing the file I don't think the code shown in your blog post is using the library the As for your markup, your ``os.close`` should instead be |
The real question I had is why mkstemp return an os-level opened file |
Because if you want the Python file object, you should use TemporaryFile |
That one has to close open files should be common knowledge. And it's already documented that the filehandle returned is to be Insofar, I'm in agreement with David. |
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
bugs.python.org fields:
The text was updated successfully, but these errors were encountered: