Skip to content

Commit

Permalink
Update pegasus_workflow.py (#4936)
Browse files Browse the repository at this point in the history
* Update pegasus_workflow.py

* Update pycbc/workflow/pegasus_workflow.py

Co-authored-by: Tito Dal Canton <[email protected]>

---------

Co-authored-by: Tito Dal Canton <[email protected]>
  • Loading branch information
sebastiangomezlopez and titodalcanton authored Nov 14, 2024
1 parent 717509d commit 3efc80c
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions pycbc/workflow/pegasus_workflow.py
Original file line number Diff line number Diff line change
Expand Up @@ -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)

Expand Down

0 comments on commit 3efc80c

Please sign in to comment.