con / duct

A helper to run a command, capture stdout/stderr and details about running
MIT License
1 stars 1 forks source link

Bug: user-provided output-prefix is formatted too soon #34

Closed asmacdo closed 1 month ago

asmacdo commented 1 month ago

We need to be able to open files for writing to stdout and stderr prior to executing the inner program. The only PID we have access to at this time is os.getpid(), ie the PID of duct, not the PID of the running processes. So, stdout, stderr, and system stats should go to the duct pid.

However currently we call .format once and use it everywhere. Instead we need to call .format each time we have a different PID.