Skip to content

Tags: blisspixel/deepr

Tags

v2.9.1

Toggle v2.9.1's commit message
Use mkstemp and robust atomic file save

Write provider metrics using tempfile.mkstemp in the same directory and os.fdopen to ensure atomic writes and avoid cross-filesystem issues. Add a retry loop for os.replace on Windows to handle transient PermissionError, and improve temp-file cleanup by handling UnboundLocalError/OSError. Also add required imports (sys, tempfile, time) and adjust comments for clarity.