Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add 'verdi workflow kill' command #779

Closed

Conversation

greschd
Copy link
Member

@greschd greschd commented Oct 17, 2017

Adds an _abort flag to the WorkCalculation, which is checked before each step. The calculations are also sealed which usually causes them to fail pretty immediately, but also means that the report will not contain a nice abort message.

The kill is propagated to all children through the CALL links.

Fixes #661 and #741 for the "old" system, but not 0.11.

@greschd greschd requested a review from sphuber October 17, 2017 13:03
if not self.is_sealed:
self._set_attr(self.ABORTED_KEY, True)
self.seal()
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the self.seal() should be within the conditional block

self._set_attr(self.ABORTED_KEY, True)
self.seal()
for key, child in self.get_outputs_dict().items():
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can pass the desired link type to get_outputs_dict(link_type=LinkType.CALL) which is safer than relying on the label

@greschd
Copy link
Member Author

greschd commented Oct 19, 2017

@sphuber I implemented your suggestions, thanks!

@sphuber
Copy link
Contributor

sphuber commented Oct 21, 2017

I have taken your commits and created a new branch to add some necessary fixes. I created a new PR #821 so I am closing this one

@sphuber sphuber closed this Oct 21, 2017
@greschd greschd deleted the feature_add_workflow_kill branch June 12, 2018 07:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants