Wytamma / snk

Snakemake workflow management system and CLI generation tool
https://snk.wytamma.com
MIT License
31 stars 2 forks source link

Arbitrary snakemake parameters do not work #42

Closed mmcguffi closed 1 year ago

mmcguffi commented 1 year ago

First, thank you so much for making this -- this is an incredible project and Im shocked that it's so under-the-radar right now. Really impressive work!

I cant seem to get snk to take arbitrary (and often important) snakemake command line parameters. For example:

variant-calling run -r .test/config -r .test/data -n --cores 20 --keep-going 

╭─ Error ──────────────────────────────────────────────────────────────────────────────────────────────────╮
│ No such command '--keep-going'.                                                                          │
╰──────────────────────────────────────────────────────────────────────────────────────────────────────────╯

Re-arrange parameters:

variant-calling run -r .test/config -r .test/data --cores 20 --keep-going -n
╭─ Error ──────────────────────────────────────────────────────────────────────────────────────────────────╮
│ No such command '-n'.                                                                                    │
╰──────────────────────────────────────────────────────────────────────────────────────────────────────────╯

Perhaps Im just missing something? Any help / tips would be appreciated :)

Wytamma commented 1 year ago

Hey @mmcguffi! Thanks for the kind words :) I've fixed this bug in v0.13.0. I also added the ability to pass snakemake options that are masked by the CLI to snakemake by adding the --snake prefix to the option.

e.g. --snake-r will use the snakmake reason option -r not the snk resource option -r

e.g.2 Run the pipeline in verbose mode and print the snakemake version pipeline run -v (snk verbose) --snake-v (snakemake version)

e.g.3 pipeline run --snake--cores all

mmcguffi commented 1 year ago

Seems to work perfectly! Thank you for the (insanely fast) fix :)