Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
fix: improved error handling for cluster status scripts and smarter j…
…ob selector choice in case of cluster submission (use greedy for single jobs). (#1142) * fix: improved error handling for cluster status scripts and smarter job selector choice in case of cluster submission (use greedy for single jobs). * refactor: fmt * temporarily deactivate greedy fallback in case of a single job (see if this is the reason for the failure in GLS). * handle missing file in job reward.
- Loading branch information
1 parent
68c13fd
commit 48d2dd9
Showing
15 changed files
with
143 additions
and
21 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
from snakemake import shell | ||
|
||
chromosomes = [1,2,3,4,5] | ||
|
||
envvars: | ||
"TESTVAR" | ||
|
||
|
||
|
||
rule all: | ||
input: 'test.predictions', 'test.2.inter2' | ||
|
||
rule compute1: | ||
input: '{name}.in' | ||
output: ['{name}.%s.inter'%c for c in chromosomes] | ||
params: prefix="{name}" | ||
run: | ||
for out in output: | ||
shell('(cat {input[0]} && echo "Part {out}") > {out}') | ||
|
||
rule compute2: | ||
input: '{name}.{chromosome}.inter' | ||
output: '{name}.{chromosome}.inter2' | ||
params: test="a=b" | ||
threads: workflow.cores * 0.5 | ||
shell: 'echo copy; cp {input[0]} {output[0]}' | ||
|
||
rule gather: | ||
input: ['{name}.%s.inter2'%c for c in chromosomes] | ||
output: '{name}.predictions' | ||
run: | ||
shell('cat {} > {}'.format(' '.join(input), output[0])) |
2 changes: 2 additions & 0 deletions
2
tests/test_cluster_statusscript/expected-results/test.1.inter
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
testz0r | ||
Part test.1.inter |
2 changes: 2 additions & 0 deletions
2
tests/test_cluster_statusscript/expected-results/test.1.inter2
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
testz0r | ||
Part test.1.inter |
2 changes: 2 additions & 0 deletions
2
tests/test_cluster_statusscript/expected-results/test.2.inter
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
testz0r | ||
Part test.2.inter |
2 changes: 2 additions & 0 deletions
2
tests/test_cluster_statusscript/expected-results/test.2.inter2
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
testz0r | ||
Part test.2.inter |
2 changes: 2 additions & 0 deletions
2
tests/test_cluster_statusscript/expected-results/test.3.inter
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
testz0r | ||
Part test.3.inter |
2 changes: 2 additions & 0 deletions
2
tests/test_cluster_statusscript/expected-results/test.3.inter2
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
testz0r | ||
Part test.3.inter |
10 changes: 10 additions & 0 deletions
10
tests/test_cluster_statusscript/expected-results/test.predictions
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
testz0r | ||
Part test.1.inter | ||
testz0r | ||
Part test.2.inter | ||
testz0r | ||
Part test.3.inter | ||
testz0r | ||
Part test.4.inter | ||
testz0r | ||
Part test.5.inter |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
#!/bin/bash | ||
echo `date` >> qsub.log | ||
tail -n1 $1 >> qsub.log | ||
# simulate printing of job id by a random number | ||
echo $RANDOM | ||
cat $1 >> qsub.log | ||
sh $1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
echo success |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
testz0r |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters