Skip to content

Commit

Permalink
Fix assertion and url.
Browse files Browse the repository at this point in the history
  • Loading branch information
johanneskoester committed Feb 19, 2017
1 parent 08ef880 commit 0bba853
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion bio/bowtie2/align/test/Snakefile
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ rule bowtie2:
"" # optional parameters
threads: 8
wrapper:
"master/bio/bowtie/align"
"master/bio/bowtie2/align"
5 changes: 3 additions & 2 deletions bio/bowtie2/align/wrapper.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,10 @@

log = snakemake.log_fmt_shell(stdout=True, stderr=True)

assert len(snakemake.input.sample) == 1, "input->sample must have 1 (single-end) or 2 (paired-end) elements."
n = len(snakemake.input.sample)
assert n == 1 or n == 2, "input->sample must have 1 (single-end) or 2 (paired-end) elements."

if len(snakemake.input.sample) == 1:
if n == 1:
reads = "-U {}".format(*snakemake.input.sample)
else:
reads = "-1 {} -2 {}".format(*snakemake.input.sample)
Expand Down

0 comments on commit 0bba853

Please sign in to comment.