Skip to content

fix: Keep tiling, offline and stream engine settings when copying a StreamFeatureView - #6924

Open
Rodrigo-Palma wants to merge 2 commits into
feast-dev:masterfrom
Rodrigo-Palma:fix/stream-feature-view-copy
Open

Rodrigo-Palma wants to merge 2 commits into
feast-dev:masterfrom
Rodrigo-Palma:fix/stream-feature-view-copy

Conversation

@Rodrigo-Palma

Copy link
Copy Markdown
Contributor

What this PR does / why we need it:

StreamFeatureView.__copy__ doesn't pass offline, enable_tiling, tiling_hop_size or stream_engine to the constructor, so the copy falls back to the defaults. Since with_name, with_projection and __getitem__ all go through __copy__, a projected stream view silently loses tiling and its engine config. FeatureView.__copy__ already passes offline.

sfv = StreamFeatureView(..., offline=True, enable_tiling=True,
                        tiling_hop_size=timedelta(minutes=1),
                        stream_engine={"spark.sql.shuffle.partitions": "4"})
copy.copy(sfv).enable_tiling   # False
sfv == copy.copy(sfv)          # False (offline differs)

The registry also uses __copy__() to build the version snapshot for no_promote (registry.py:905), so that snapshot is saved without the tiling config.

Which issue(s) this PR fixes:

N/A

Checks

  • I've made sure the tests are passing.
  • My commits are signed off (git commit -s)
  • My PR title follows conventional commits format

Testing Strategy

  • Unit tests
  • Integration tests
  • Manual tests
  • Testing is not required for this change

Extended test_stream_feature_view_copy to set these fields; it fails on master and passes with the fix.

…treamFeatureView

Signed-off-by: Rodrigo-Palma <email.rodrigopalma@gmail.com>
@Rodrigo-Palma
Rodrigo-Palma requested a review from a team as a code owner October 1, 2026 15:49
@codecov-commenter

codecov-commenter commented Oct 1, 2026 •

Copy link
Copy Markdown

⚠️ Please install the 'codecov app svg image' to ensure uploads and comments are reliably processed by Codecov.

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 48.62%. Comparing base (652b7f9) to head (a8bcd00).
❗ Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff           @@
##           master    #6924   +/-   ##
=======================================
  Coverage   48.62%   48.62%           
=======================================
  Files         427      427           
  Lines       53845    53845           
  Branches     7844     7844           
=======================================
  Hits        26181    26181           
  Misses      25797    25797           
  Partials     1867     1867           
Flag Coverage Δ
go-feature-server 30.58% <ø> (ø)
python-unit 49.99% <ø> (ø)
Files with missing lines Coverage Δ
sdk/python/feast/stream_feature_view.py 70.35% <ø> (ø)

Continue to review full report in Codecov by Harness.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 652b7f9...a8bcd00. Read the comment docs.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants