MCPcopy Create free account
hub / github.com/ampproject/amphtml / __hash__

Method __hash__

validator/validator_gen_js.py:90–91  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

88 self.digest = hashlib.sha1(proto_message.SerializeToString()).hexdigest()
89
90 def __hash__(self):
91 return hash((self.type_name, self.digest))
92
93 def __eq__(self, other):
94 return (self.type_name, self.digest) == (other.type_name, other.digest)

Callers

nothing calls this directly

Calls 1

hashFunction · 0.50

Tested by

no test coverage detected