Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Have to remove the equality test for the new fields...for now we're g…
…oing to ignore them so it is backwards compatible

Signed-off-by: Francisco Javier Arceo <farceo@redhat.com>
  • Loading branch information
franciscojavierarceo committed Dec 17, 2024
commit 1035cd4abd4e33040613974d6cad6619085cd37f
14 changes: 4 additions & 10 deletions sdk/python/feast/field.py
Original file line number Diff line number Diff line change
Expand Up @@ -80,8 +80,8 @@ def __eq__(self, other):
or self.dtype != other.dtype
or self.description != other.description
or self.tags != other.tags
or self.vector_index != other.vector_index
or self.vector_search_metric != other.vector_search_metric
# or self.vector_index != other.vector_index
# or self.vector_search_metric != other.vector_search_metric
):
return False
return True
Expand Down Expand Up @@ -129,14 +129,8 @@ def from_proto(cls, field_proto: FieldProto):
field_proto: FieldProto protobuf object
"""
value_type = ValueType(field_proto.value_type)
vector_search_metric = (
field_proto.vector_search_metric
if field_proto.HasField("vector_search_metric")
else None
)
vector_index = (
field_proto.vector_index if field_proto.HasField("vector_index") else False
)
vector_search_metric = getattr(field_proto, 'vector_search_metric', '')
vector_index = getattr(field_proto, 'vector_index', False)
return cls(
name=field_proto.name,
dtype=from_value_type(value_type=value_type),
Expand Down