tempfile

tempfile — Generate temporary files and directories

Source code: Lib/tempfile.py

This module generates temporary files and directories. It works on all supported platforms.

In version 2.3 of Python, this module was overhauled for enhanced security. It now provides three new functions, NamedTemporaryFile(), mkstemp(), and mkdtemp(), which should eliminate all remaining need to use the insecure 登录查看完整内容