Skip to main content

Tempfile wrapper to ensure output files are either complete, or empty. Also handles stdout, which gives no truncation guarantees.

Project description

Tool to facilitate console script output redirection. When scripts run, often they have an output file option. If no output option is specified, its common to write to stdout. Its common to use tempfiles as output, and then rename the tempfile to the output name as the last step of the program so that the flip of output is atomic and partial/truncated/corrupt output is not confused as successful output. This is especially true when dealing with make, as exiting with error will stop make, but subsequent runs will assume that partial output files left in the workspace are complete. Writing to stdout gives no guarantees about partial results due to truncation.

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for safeoutput, version 2.0
Filename, size File type Python version Upload date Hashes
Filename, size safeoutput-2.0.tar.gz (3.1 kB) File type Source Python version None Upload date Hashes View

Supported by

Pingdom Pingdom Monitoring Google Google Object Storage and Download Analytics Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page