projects
/
htsworkflow.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
11f2361
)
Indicate when desplit_fastq didn't get any files to process
author
Diane Trout
<diane@caltech.edu>
Mon, 12 May 2014 23:12:08 +0000
(16:12 -0700)
committer
Diane Trout
<diane@ghic.org>
Tue, 10 Jun 2014 23:29:16 +0000
(16:29 -0700)
htsworkflow/pipelines/desplit_fastq.py
patch
|
blob
|
history
diff --git
a/htsworkflow/pipelines/desplit_fastq.py
b/htsworkflow/pipelines/desplit_fastq.py
index 83a995588079f34088e5b07ac7d098bfb08b3072..c9947a2ef2317b0a05f7c36e966eb152949fc1f3 100644
(file)
--- a/
htsworkflow/pipelines/desplit_fastq.py
+++ b/
htsworkflow/pipelines/desplit_fastq.py
@@
-89,7
+89,9
@@
class DesplitFastq(object):
This is here so we can run via threading/multiprocessing APIs
"""
state = SEQ_HEADER
+ files_read = 0
for stream in self.sources:
+ files_read += 1
for line in stream:
line = line.rstrip()
if state == SEQ_HEADER:
@@
-106,6
+108,8
@@
class DesplitFastq(object):
state = SEQ_HEADER
self.destination.write(os.linesep)
+ if files_read == 0:
+ raise RuntimeError("No files processed")
if __name__ == "__main__":
main()