Skip to content

Commit 6face3a

Browse files
author
Daniel Abercrombie
committed
Split up 'special' actions by selected action
1 parent 016db1f commit 6face3a

2 files changed

Lines changed: 7 additions & 3 deletions

File tree

workflowwebtools/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,6 @@
44
:author: Daniel Abercrombie <dabercro@mit.edu>
55
"""
66

7-
__version__ = '0.7.2'
7+
__version__ = '0.7.3'
88

99
__all__ = []

workflowwebtools/actionshistorylink.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,8 @@ def dump_json(file_name=None):
3434

3535
for workflow in actions:
3636
for subtask in history.get_step_list(workflow):
37-
if actions[workflow]['Action'] in ['acdc', 'recovery']:
37+
action = actions[workflow]['Action']
38+
if action in ['acdc', 'recovery']:
3839
parameters = actions[workflow]['Parameters'].get(
3940
'/'.join(subtask.split('/')[2:]), {})
4041
else:
@@ -52,7 +53,10 @@ def dump_json(file_name=None):
5253
'parameters':
5354
parameters
5455
}
55-
output[subtask]['parameters']['action'] = actions[workflow]['Action']
56+
57+
output[subtask]['parameters']['action'] = \
58+
action if action != 'special' else \
59+
actions[workflow]['Parameters']['action']
5660

5761
if file_name:
5862
with open(file_name, 'w') as output_file:

0 commit comments

Comments
 (0)