Skip to content

Commit 4e03a00

Browse files
committed
add hash function to make test run (already in draft PR #33)
1 parent 0f76ece commit 4e03a00

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/modacor/dataclasses/process_step.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,11 @@ class ProcessStep:
5555
# internal variables:
5656
__prepared: bool = field(default=False, validator=v.instance_of(bool))
5757

58+
# add hash function. equality can be checked
59+
def __hash__(self):
60+
return hash((self.documentation.__repr__(), self.configuration.__repr__(), self.step_id))
61+
62+
5863
def prepare_execution(self):
5964
"""
6065
Prepare the execution of the ProcessStep

0 commit comments

Comments
 (0)