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: Disable Persistence cache for snakemake jobs (#1159)
* Implement test_github_issue1158 * Disable Persistence cache for snakemake jobs * test_github_issue1158 mark xfail if no strace * Add tests/test_github_issue1158/expected-results
- Loading branch information
Showing
6 changed files
with
36 additions
and
1 deletion.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
rule Test: | ||
output: "output" | ||
shell: "touch {output}" |
Empty file.
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,20 @@ | ||
#!/usr/bin/env python3 | ||
import sys | ||
import os | ||
import random | ||
import re | ||
|
||
jobscript = sys.argv[1] | ||
|
||
os.system("strace -f -o trace {}".format(jobscript)) | ||
|
||
with open("trace", "r") as fp: | ||
lines = fp.readlines() | ||
|
||
regex = re.compile('.*openat\(.*.snakemake/incomplete".*') | ||
matches = list(filter(lambda l: regex.match(l), lines)) | ||
if len(matches) > 0: | ||
sys.stderr.write(repr(matches)) | ||
sys.exit(1) | ||
|
||
print(random.randint(1, 100)) |
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