Repository navigation
Conversation
StreamFeatureView.to_proto() built spec.features from self.schema, which includes the entity (join key) columns, while FeatureView.to_proto_spec() uses self.features. A stream feature view read back from the registry therefore listed its join key as a feature, and a FeatureService built from it failed historical retrieval with a duplicate join key column. Serialize self.features, matching FeatureView. Entity columns are still stored in spec.entity_columns and restored by from_proto. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Vidit Patankar <vidit.patankar16@gmail.com>
This was referenced Oct 18, 2026
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #7033 +/- ##
=======================================
Coverage 50.98% 50.98%
=======================================
Files 455 455
Lines 56964 56964
Branches 8313 8313
=======================================
Hits 29044 29044
Misses 25935 25935
Partials 1985 1985
Continue to review full report in Codecov by Harness.
🚀 New features to boost your workflow:
|
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
What this PR does / why we need it:
StreamFeatureView.to_proto()serializesspec.featuresfromself.schema, andschemaincludes the entity (join key) columns.FeatureView.to_proto_spec()usesself.features, so every other feature view type keeps join keys only inspec.entity_columns. Because of this mismatch, a stream feature view loaded back from the registry lists its join key as a feature.Repro with the local provider (file offline store, SQLite online store):
The same
spec.featuresfield is read by the Go feature server (NewFeatureViewFromStreamFeatureViewProto) and the UI, so they also see the join key as a feature.This PR serializes
self.featuresinstead ofself.schema, the same asFeatureView.to_proto_spec().from_protoalready restoresentity_columnsfromspec.entity_columns, so nothing is lost. With the change, the registry copy above has features['conv_rate']and the historical retrieval returns the expected frame.A registry written by an earlier version keeps the extra column until the next
feast apply. That apply reports the stream feature view as updated and rewritesspec.features. I checked this locally: apply on master, then re-apply with this change. If you would rather also filter entity columns out on the read side for registries that are never re-applied, I can add that here.Merge order: please merge #7034 first (or together with this). Today the extra join key in the registry copy happens to make
StreamFeatureView.__eq__return False; once this PR removes it, the existing__eq__short-circuit for UDF-less views makes the SQL registry skip writes when onlyaggregationschange. #7034 fixes that equality.Which issue(s) this PR fixes:
No existing issue. I found this while checking feature view proto round-trips, and searched open and closed issues and PRs for a duplicate before opening this.
Checks
git commit -s)Testing Strategy
New test
test_stream_feature_view_serialization_excludes_entity_columns_from_featuresinsdk/python/tests/unit/test_stream_feature_view.pydefines the join key inschema. It checks thatspec.featuresandspec.entity_columnsare disjoint and thatfrom_proto(to_proto(sfv)) == sfv. It fails on master (['dummy_field', 'driver_id'] == ['dummy_field']) and passes with this change. Manual test: the repro above, end to end, with the local provider.Misc
Developed with Claude Code (AI) under my direction; the new unit test fails on master and passes with this change.