diff --git a/pycbc/workflow/pegasus_workflow.py b/pycbc/workflow/pegasus_workflow.py index dd41ac21419..ba75b3d74ea 100644 --- a/pycbc/workflow/pegasus_workflow.py +++ b/pycbc/workflow/pegasus_workflow.py @@ -800,9 +800,13 @@ def set_subworkflow_properties(self, output_map_file, # change the attribute here. # WORSE, we only want to set this if the pegasus *planner* is version # 5.0.4 or larger - sproc_out = subprocess.check_output(['pegasus-version']).strip() - sproc_out = sproc_out.decode() - if version.parse(sproc_out) >= version.parse('5.0.4'): + try: + sproc_out = subprocess.check_output(['pegasus-version']).strip() + sproc_out = sproc_out.decode() + if version.parse(sproc_out) >= version.parse('5.0.4'): + output_map_file.for_planning=True + except: + logging.warning("Could not execute pegasus-version, assuming >= 5.0.4") output_map_file.for_planning=True self.add_inputs(output_map_file)