Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
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
5 changes: 5 additions & 0 deletions sdk/python/tests/dataframes.py
Original file line number Diff line number Diff line change
Expand Up @@ -116,5 +116,10 @@
np.array([b"one", b"two", b"three"]),
np.array([b"one", b"two", b"three"]),
],
"bool_list_feature": [
[True, False, True],
[True, False, True],
[True, False, True],
],
}
)
4 changes: 1 addition & 3 deletions sdk/python/tests/test_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -986,9 +986,7 @@ def test_feature_set_types_success(self, test_client, dataframe, mocker):
Feature(name="int32_list_feature", dtype=ValueType.INT32_LIST),
Feature(name="string_list_feature", dtype=ValueType.STRING_LIST),
Feature(name="bytes_list_feature", dtype=ValueType.BYTES_LIST),
# Feature(name="bool_list_feature",
# dtype=ValueType.BOOL_LIST), # TODO: Add support for this
# type again https://github.com/feast-dev/feast/issues/341
Feature(name="bool_list_feature", dtype=ValueType.BOOL_LIST),
Feature(name="double_list_feature", dtype=ValueType.DOUBLE_LIST),
],
max_age=Duration(seconds=3600),
Expand Down
2 changes: 2 additions & 0 deletions tests/e2e/redis/all_types_parquet/all_types_parquet.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,4 +29,6 @@ spec:
valueType: STRING_LIST
- name: bytes_list_feature_parquet
valueType: BYTES_LIST
- name: bool_list_feature_parquet
valueType: BOOL_LIST
maxAge: 0s
17 changes: 8 additions & 9 deletions tests/e2e/redis/basic-ingest-redis-serving.py
Original file line number Diff line number Diff line change
Expand Up @@ -886,12 +886,11 @@ def all_types_dataframe():
np.array([b"one", b"two", b"three"]),
np.array([b"one", b"two", b"three"]),
],
# "bool_list_feature": [
# np.array([True, False, True]),
# np.array([True, False, True]),
# np.array([True, False, True]),
# ],
# TODO: https://github.com/feast-dev/feast/issues/341
"bool_list_feature": [
[True, False, True],
[True, False, True],
[True, False, True],
],
}
)

Expand All @@ -918,6 +917,7 @@ def test_all_types_register_feature_set_success(client):
Feature(name="int32_list_feature", dtype=ValueType.INT32_LIST),
Feature(name="string_list_feature", dtype=ValueType.STRING_LIST),
Feature(name="bytes_list_feature", dtype=ValueType.BYTES_LIST),
Feature(name="bool_list_feature", dtype=ValueType.BOOL_LIST),
],
max_age=Duration(seconds=3600),
)
Expand Down Expand Up @@ -970,6 +970,7 @@ def test_all_types_retrieve_online_success(client, all_types_dataframe):
"string_list_feature",
"bytes_list_feature",
"double_list_feature",
"bool_list_feature",
]

def try_get_features():
Expand Down Expand Up @@ -1179,12 +1180,10 @@ def all_types_parquet_file():
"bytes_list_feature_parquet": [
np.array([b"one", b"two", b"three"]) for _ in range(COUNT)
],
"bool_list_feature_parquet": [[True, False, True] for _ in range(COUNT)],
}
)

# TODO: Boolean list is not being tested.
# https://github.com/feast-dev/feast/issues/341

file_path = os.path.join(tempfile.mkdtemp(), "all_types.parquet")
df.to_parquet(file_path, allow_truncated_timestamps=True)
return file_path
Expand Down
4 changes: 4 additions & 0 deletions tests/load/ingest.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,9 @@
"bytes_list_feature": [
np.array([b"one", b"two", b"three"]) for _ in range(number_of_entities)
],
"bool_list_feature": [
[True, False, True] for _ in range(number_of_entities)
],
}
)

Expand All @@ -67,6 +70,7 @@
Feature(name="int32_list_feature", dtype=ValueType.INT32_LIST),
Feature(name="string_list_feature", dtype=ValueType.STRING_LIST),
Feature(name="bytes_list_feature", dtype=ValueType.BYTES_LIST),
Feature(name="bool_list_feature", dtype=ValueType.BOOL_LIST),
],
)

Expand Down