diff --git a/deckard/base/utils/hashing.py b/deckard/base/utils/hashing.py index f6fe067b..a8e7b1b2 100644 --- a/deckard/base/utils/hashing.py +++ b/deckard/base/utils/hashing.py @@ -72,7 +72,8 @@ def to_dict(obj: Union[dict, OrderedDict, NamedTuple]) -> dict: def my_hash(obj: Union[dict, OrderedDict, NamedTuple]) -> str: return md5(str(to_dict(obj)).encode("utf-8")).hexdigest() + @dataclass class Hashable: def __hash__(self): - return int(my_hash(self), 16) \ No newline at end of file + return int(my_hash(self), 16)