Replace .inp and .out for Node with .inputs and .outputs for CalculationNode and WorkflowNode#2569
Merged
sphuber merged 3 commits intoMar 5, 2019
Conversation
In the case there is more than one matching node with the same label. This fixes aiidateam#2558
ce963e0 to
2102430
Compare
This fixes aiidateam#2230. In particular, now: - CalculationNode have a `.inputs.<LABEL>` property that returns a manager to navigate incoming INPUT_CALC nodes - CalculationNode have a `.outputs.<LABEL>` property that returns a manager to navigate outgoing CREATE nodes - WorkflowNode have a `.inputs.<LABEL>` property that returns a manager to navigate incoming INPUT_WORK nodes - WorkflowNode have a `.outputs.<LABEL>` property that returns a manager to navigate outgoing RETURN nodes - Node *does not have anymore* `.inp` and `.out` as these were referring to incoming and outgoing and were ambiguous Moreover, `Data.created_by` and `ProcessNode.called_by` methods were already implemented and have been renamed to `Data.creator` and `ProcessNode.caller`. Also tests added for all these methods, including the already existing ones.
2102430 to
a93c5f6
Compare
This was referenced Mar 5, 2019
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Now:
.inputs.<LABEL>property that returnsa manager to navigate incoming INPUT_CALC nodes
.outputs.<LABEL>property that returnsa manager to navigate outgoing CREATE nodes
.inputs.<LABEL>property that returnsa manager to navigate incoming INPUT_WORK nodes
.outputs.<LABEL>property that returnsa manager to navigate outgoing RETURN nodes
.inpand.outas these werereferring to incoming and outgoing and were ambiguous
Moreover,
Data.created_byandProcessNode.called_bymethods werealready implemented and have been renamed to
Data.creatorandProcessNode.caller.Also tests added for all these methods, including the already existing
ones. This fixes #2230.
Moreover,
LinkTypehas been added to the classes pre-loaded inthe shell (fixes #2560), and we now ensure that
get_node_by_labelraises in case there is more than one matching node with the same label
(fixes #2558).