fix: Correct entity value type mapping for aliased feature views #5492
+6
−1
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
This fix addresses an issue where entity value types were incorrectly mapped when using feature views with join key aliases.
Problem
Previously, when using feature views with join key aliases (like in the example below), the
entity_type_mapwould use the original column name instead of the aliased join key:This caused
target_user_idto be interpreted asValueType.INT64instead of the correct entity value type (ValueType.INT32in this case).Solution
The fix ensures that when a feature view has a join key map, the entity type mapping uses the correct aliased column name from the projection's
join_key_map.Changes
_get_entity_mapsfunction insdk/python/feast/utils.pyTesting
This fix resolves the issue where aliased feature views would have incorrect entity value type mappings, ensuring that join keys maintain their correct data types even when aliased.
Type of Change
How Has This Been Tested?
This fix has been tested with the scenario described above where feature views are aliased with join key mappings. The entity value types are now correctly preserved for aliased join keys.