Skip to content

Change internal references from input to batch_source#1729

Merged
feast-ci-bot merged 4 commits intofeast-dev:masterfrom
felixwang9817:deprecate_input
Jul 27, 2021
Merged

Change internal references from input to batch_source#1729
feast-ci-bot merged 4 commits intofeast-dev:masterfrom
felixwang9817:deprecate_input

Conversation

@felixwang9817
Copy link
Copy Markdown
Collaborator

@felixwang9817 felixwang9817 commented Jul 22, 2021

Signed-off-by: Felix Wang wangfelix98@gmail.com

What this PR does / why we need it: FeatureViews have always required a batch data source as input; this argument is currently named input. We recently introduced stream sources here, so now we have three arguments: a required input, an optional batch_source, and an optional stream_source. We should remove input as an argument, make batch_source required, and leave stream_source optional; this is a breaking change, so we prepare for it by adding a deprecation warning. We also change internal references and docs to use batch_source instead of input, to point people in the right direction.

Which issue(s) this PR fixes:

Fixes #

Does this PR introduce a user-facing change?:

There is now a deprecation warning in FeatureView.

Comment thread sdk/python/feast/feature_view.py Outdated
@codecov-commenter
Copy link
Copy Markdown

codecov-commenter commented Jul 22, 2021

Codecov Report

Merging #1729 (cd0c62d) into master (bf557bc) will decrease coverage by 17.29%.
The diff coverage is 89.28%.

Impacted file tree graph

@@             Coverage Diff             @@
##           master    #1729       +/-   ##
===========================================
- Coverage   79.06%   61.77%   -17.30%     
===========================================
  Files          80       78        -2     
  Lines        6849     6762       -87     
===========================================
- Hits         5415     4177     -1238     
- Misses       1434     2585     +1151     
Flag Coverage Δ
integrationtests ?
unittests 61.77% <89.28%> (+0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
sdk/python/feast/repo_operations.py 31.33% <0.00%> (ø)
...alization/test_offline_online_store_consistency.py 58.24% <ø> (-41.76%) ⬇️
...gration/offline_store/test_historical_retrieval.py 50.17% <ø> (-48.78%) ⬇️
...sts/integration/registration/test_feature_store.py 68.38% <ø> (-31.62%) ⬇️
...on/tests/integration/registration/test_registry.py 69.56% <ø> (-30.44%) ⬇️
...ests/integration/scaffolding/test_partial_apply.py 50.00% <ø> (-50.00%) ⬇️
sdk/python/feast/feature_view.py 84.61% <90.00%> (-4.37%) ⬇️
sdk/python/feast/feature_store.py 91.33% <100.00%> (-2.17%) ⬇️
sdk/python/feast/inference.py 58.33% <100.00%> (-31.26%) ⬇️
sdk/python/feast/infra/local.py 92.15% <100.00%> (ø)
... and 41 more

Continue to review full report at Codecov.

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

@felixwang9817 felixwang9817 changed the title Rename input to batch_source in FeatureView Change internal references from input to batch_source Jul 23, 2021
Comment thread sdk/python/feast/feature_view.py Outdated
Signed-off-by: Felix Wang <wangfelix98@gmail.com>
Signed-off-by: Felix Wang <wangfelix98@gmail.com>
Signed-off-by: Felix Wang <wangfelix98@gmail.com>
Comment thread sdk/python/feast/feature_view.py Outdated
Signed-off-by: Felix Wang <wangfelix98@gmail.com>
Copy link
Copy Markdown
Member

@achals achals left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm

@feast-ci-bot
Copy link
Copy Markdown
Collaborator

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: achals, felixwang9817

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@felixwang9817
Copy link
Copy Markdown
Collaborator Author

/retest

@feast-ci-bot feast-ci-bot merged commit 489a0f8 into feast-dev:master Jul 27, 2021
@felixwang9817 felixwang9817 deleted the deprecate_input branch July 27, 2021 18:02
tags: Optional[Dict[str, str]] = None,
online: bool = True,
):
warnings.warn(
Copy link
Copy Markdown
Contributor

@tedhtchang tedhtchang Jul 28, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@felixwang9817 Should we warn users only when the input is assigned ?

Copy link
Copy Markdown
Collaborator Author

@felixwang9817 felixwang9817 Jul 28, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@tedhtchang That's a good point, I think ideally we would have done that. However, given that (a) input was a required parameter before this change, so almost all users will continue to use input, and (b) releases are fairly frequent so this deprecation warning will soon become outdated, I think we can leave this change as is.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@tedhtchang btw, I managed to insert this change into a separate PR (#1746). Thanks for pointing this one out!

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@felixwang9817 Thanks. Looks good.

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.

6 participants