⬅︎ Back to tempfile in Python standard library
NM... Follow Richard's suggestion.
tmp_fd, tmp_name = tempfile.mkstemp(suffix='.tgz') f = os.fdopen(tmp_name, 'w+b') f.write(content) ...
Comment
NM... Follow Richard's suggestion.
Parent comment
tmp_fd, tmp_name = tempfile.mkstemp(suffix='.tgz') f = os.fdopen(tmp_name, 'w+b') f.write(content) ...