From a8aeb79830f12358c2355be44fca68e61992cb46 Mon Sep 17 00:00:00 2001 From: Niklas von Maltzahn Date: Fri, 10 Jan 2025 17:22:38 +0200 Subject: [PATCH] feat: Add date field support to spark (#4913) * add date field support to spark Signed-off-by: niklasvm * add support for lists of dates Signed-off-by: niklasvm --------- Signed-off-by: niklasvm --- sdk/python/feast/type_map.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sdk/python/feast/type_map.py b/sdk/python/feast/type_map.py index 000e9cdae4..7e2b8a5362 100644 --- a/sdk/python/feast/type_map.py +++ b/sdk/python/feast/type_map.py @@ -815,6 +815,7 @@ def spark_to_feast_value_type(spark_type_as_str: str) -> ValueType: "float": ValueType.FLOAT, "boolean": ValueType.BOOL, "timestamp": ValueType.UNIX_TIMESTAMP, + "date": ValueType.UNIX_TIMESTAMP, "array": ValueType.BYTES_LIST, "array": ValueType.STRING_LIST, "array": ValueType.INT32_LIST, @@ -824,6 +825,7 @@ def spark_to_feast_value_type(spark_type_as_str: str) -> ValueType: "array": ValueType.FLOAT_LIST, "array": ValueType.BOOL_LIST, "array": ValueType.UNIX_TIMESTAMP_LIST, + "array": ValueType.UNIX_TIMESTAMP_LIST, } if spark_type_as_str.startswith("decimal"): spark_type_as_str = "decimal"