在运行snakemake文档中的CWL支持示例时:https://snakemake.readthedocs.io/en/stable/snakefiles/modularization.html#common-workflow-language-cwl-support
我得到了以下错误输出,
(snakemake) pedro@Gen83-ubuntu:~/projects/sandbox/cwl-test$ snakemake -j12 "mapped/foo.sorted.bam"
Building DAG of jobs...
Using shell: /bin/bash
Provided cores: 12
Rules claiming more threads will be scaled down.
Job stats:
job count min threads max threads
------------- ------- ------------- -------------
samtools_sort 1 8 8
total 1 8 8
Select jobs to execute...
[Wed Oct 20 11:20:03 2021]
rule samtools_sort:
input: mapped/foo.unsorted.bam
output: mapped/foo.sorted.bam
jobid: 0
wildcards: sample=foo
threads: 8
resources: tmpdir=/tmp
/usr/bin/cwltool 1.0.20180302231433
I'm sorry, I couldn't load this CWL file, try again with --debug for more information.
The error was: mapping values are not allowed here
in "https://github.com/common-workflow-language/workflows/blob/fb406c95/tools/samtools-sort.cwl", line 137, column 65
Snakefile几乎是文档代码的复制-粘贴:
rule samtools_sort:
input:
input="mapped/{sample}.unsorted.bam"
output:
output_name="mapped/{sample}.sorted.bam"
params:
threads=lambda wildcards, threads: threads,
memory="4G"
threads: 8
cwl:
"https://github.com/common-workflow-language/workflows/blob/"
"fb406c95/tools/samtools-sort.cwl"
conda环境中的Snakemake和cwltool版本是,
(snakemake) pedro@Gen83-ubuntu:~/projects/sandbox/cwl-test$ cwltool --version
/usr/bin/cwltool 1.0.20180302231433
(snakemake) pedro@Gen83-ubuntu:~/projects/sandbox/cwl-test$ snakemake --version
6.9.1
如何成功运行此示例?
发布于 2021-10-25 12:47:00
如果其他人也有同样的问题,那么问题出在cwl URL中的"blob“,它应该是"raw”。
...
cwl:
"https://github.com/common-workflow-language/workflows/raw/"
"fb406c95/tools/samtools-sort.cwl"
应该行得通。
https://stackoverflow.com/questions/69644179
复制相似问题