Skip to content

Commit

Permalink
Fix equality checks between schemas
Browse files Browse the repository at this point in the history
  • Loading branch information
spenczar committed Jul 7, 2020
1 parent 9361499 commit c3615d8
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions python/lsst/alert/packet/schema.py
Original file line number Diff line number Diff line change
Expand Up @@ -174,6 +174,10 @@ def __init__(self, schema_definition):
self.definition = resolve_schema_definition(schema_definition)
fastavro.schema._schema.SCHEMA_DEFS.clear()


def __eq__(self, other):
return self.definition == other.definition

def serialize(self, record):
"""Create an Avro representation of data following this schema.
Expand Down

0 comments on commit c3615d8

Please sign in to comment.