-
Type: Sub-task
-
Resolution: Fixed
-
Priority: Major
-
Affects Version/s: master, 5.0.2
-
Component/s: Workflow API Libraries
-
None
To avoid errors like the following, Mixins._to_mb should use a better regex to parse value in _to_mb(value). Example: (\d+) *([MGTPE]?B)
Traceback (most recent call last):
File "/project/xwang787_675/software/pegasus/default/lib64/python3.6/site-packages/Pegasus/api/mixins.py", line 204, in to_mb
return int(tokens[0])
ValueError: invalid literal for int() with base 10: '4GB'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/project/xwang787_675/workflow/YifanLab/src/pacbio/_main_.py", line 37, in pacbio
generate(sub_bam, ref_genome, base_path, site)
File "/project/xwang787_675/workflow/YifanLab/src/pacbio/_workflow.py", line 27, in generate
wf = _generate(sub_bam, ref_genome, base_path, site)
File "/project/xwang787_675/workflow/YifanLab/src/pacbio/_workflow.py", line 125, in _generate
wf.add_transformation_catalog(_generate_tc(base_path, site))
File "/project/xwang787_675/workflow/YifanLab/src/pacbio/_workflow.py", line 197, in _generate_tc
).add_condor_profile(request_memory="4GB")
File "/project/xwang787_675/software/pegasus/default/lib64/python3.6/site-packages/Pegasus/api/mixins.py", line 179, in wrapped_f
new_kw[nk] = vf(v)
File "/project/xwang787_675/software/pegasus/default/lib64/python3.6/site-packages/Pegasus/api/mixins.py", line 221, in to_mb
value
ValueError: value: 4GB should be a str formatted as '<int> [MB | GB | TB | PB | EB]'