BIMSBbioinfo / pigx_bsseq

bisulfite sequencing pipeline from fastq to methylation reports
https://bioinformatics.mdc-berlin.de/pigx/
GNU General Public License v3.0
9 stars 4 forks source link

possibility to quickly rerun given target, without all upstream rules #188

Open alexg9010 opened 1 year ago

alexg9010 commented 1 year ago

It would be great to quickly rerun a given target, if .e.g. a setting has changed in the settings file, without having to rerun the whole upstream workflow.

Snakemake exposes a potentially helpful argument

 --forcerun [TARGET ...], -R [TARGET ...]
                        Force the re-execution or creation of the given rules
                        or files. Use this option if you changed a rule and
                        want to have all its output in your workflow updated.
                        (default: None)

but this requires the target/output files to be specified already at the subshell where we call snakemake.

The quick and dirty way is to manually remove the target files by hand. I already implemented a rule "clean" to rm the list of requested output files with ad975dd66286b9adda2cc0ab5ac439183db8580a but this is quite rough and will through an error at the end.

I need to either find a better way or at least improve the error handling.