Rules with scripts in nested paths fail when `--list-code-changes` set.

Create issue
Issue #1273 new
Former user created an issue

There's an assert in that does not resolve rule script path correctly, causing the --list-code-changes to fail for any rules that are not defined in the top level directory and have a script.

The assert in question is here:

To reproduce, create the following directory tree:

- subfolder/
- subfolder/test.smk
- foo
- Snakefile


rule brokenscriptpaths:
    input: "foo"
    output: "bar"
    script: ""


include: "subfolder/test.smk"

rule all:
    input: "bar"

The files foo and subfolder/ can be empty for the purposes of this example. With this directory structure

snakemake -np

will work as expected.


snakemake --list-code-changes

Changing the script path to subfolder/ in the rule will fix list code changes, but break the actual snakemake pipeline.

Comments (0)

  1. Log in to comment