projects
/
rnaseq-cwl-training.git
/ commitdiff
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
1044395
)
Raising exception instead of printing error on bad YAML
author
Greg Wilson <gvwilson@third-bit.com>
Wed, 22 Jun 2016 17:17:02 +0000
(13:17 -0400)
committer
Greg Wilson <gvwilson@third-bit.com>
Wed, 22 Jun 2016 17:17:02 +0000
(13:17 -0400)
bin/util.py
patch
|
blob
|
history
diff --git
a/bin/util.py
b/bin/util.py
index 23245be8a7858d04a0b8e3d89ba1748224439573..cb85cf25340ff00455d79bcd40ceb0b9412c2d23 100644
(file)
--- a/
bin/util.py
+++ b/
bin/util.py
@@
-68,8
+68,7
@@
def read_markdown(parser, path):
try:
metadata = yaml.load(pieces[1])
except yaml.YAMLError as e:
- print('Unable to parse YAML header in {0}:\n{1}'.format(path, e))
- sys.exit(1)
+ raise ValueError('Unable to parse YAML header in {0}:\n{1}'.format(path, e))
metadata_len = pieces[1].count('\n')
body = pieces[2]