add attempt variable to log

Create issue
Issue #1198 new
Nicholas Youngblut created an issue

I almost always run snakemake with --restart-times 2, which works great except that when the qsub job dies, the log file from that attempt is immediately deleted, even prior to the restart of the next attempt. This prevents me from checking the log on why the job died. I can sometimes use qacct -j <JOBID> to determine if the job died from lack of resources or something else, but if it's "something else", then I can't check the log file until after the failure on the 3rd attempt. This can waste a lot of time if the job fails only after many hours. It would be helpful if I could use a function for creating the log file (eg., lambda wildcards, attempt: log_dir + 'my_rule_attempt-{attempt}.log'). This way, the log files could be persistent for each attempt of the qsub job.

snakemake 5.4.5

Comments (0)

  1. Log in to comment