con / duct

A helper to run a command, capture stdout/stderr and details about running
https://pypi.org/project/con-duct/
MIT License
4 stars 2 forks source link

add --keep-empty and remove empty ones by default #212

Open yarikoptic opened 4 weeks ago

yarikoptic commented 4 weeks ago

e.g. if command just immediately exits due to misspecification -- typically there is no point to keep those logs

dandi@drogon:~/proj/s5cmd-dandi$ duct ../s5cmd/s5cmd --dry-run sync s3://dandiarchive/ dandiarchive/
2024-10-28T10:07:12-0400 [INFO    ] con-duct: duct is executing '../s5cmd/s5cmd --dry-run sync s3://dandiarchive/ dandiarchive/'...
2024-10-28T10:07:12-0400 [INFO    ] con-duct: Log files will be written to .duct/logs/2024.10.28T10.07.12-2667364_
ERROR "sync s3://dandiarchive/ dandiarchive/": source argument must contain wildcard character
2024-10-28T10:07:12-0400 [INFO    ] con-duct: Summary:
Exit Code: 1
Command: ../s5cmd/s5cmd --dry-run sync s3://dandiarchive/ dandiarchive/
Log files location: .duct/logs/2024.10.28T10.07.12-2667364_
Wall Clock Time: 0.009 sec
Memory Peak Usage (RSS): -
Memory Average Usage (RSS): -
Virtual Memory Peak Usage (VSZ): -
Virtual Memory Average Usage (VSZ): -
Memory Peak Percentage: -%
Memory Average Percentage: -%
CPU Peak Usage: -%
Average CPU Usage: -%