Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix feast apply bugs #1754

Merged
merged 1 commit into from
Aug 1, 2021
Merged

Conversation

tsotnet
Copy link
Collaborator

@tsotnet tsotnet commented Aug 1, 2021

Signed-off-by: Tsotne Tabidze [email protected]

What this PR does / why we need it: This fixes 2 bugs during feast apply.

  1. We always initialized the empty registry (instead of loading the existing registry). This means that if during 1st apply we deployed infra for FeatureView A, and in the 2nd apply we renamed FeatureView A -> B, feast apply would create the table for B, but wouldn't remove the table for A.
  2. The registry.commit() happened before the infra update call on the provider. This means that if the infra update fails (for example bad permissions), the registry still got updated. Which means that during the next apply, Feast wouldn't do anything because it'll think that everything is up to date in the registry. I moved the commit at the very end of apply_total method, and updated the rest of the function accordingly.

Which issue(s) this PR fixes:

Fixes #

Does this PR introduce a user-facing change?:

Fix `feast apply` bugs - incorrect initialization of registry and early registry commit

Signed-off-by: Tsotne Tabidze <[email protected]>
@codecov-commenter
Copy link

codecov-commenter commented Aug 1, 2021

Codecov Report

Merging #1754 (c2e0ec1) into master (651d066) will decrease coverage by 0.08%.
The diff coverage is 11.11%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1754      +/-   ##
==========================================
- Coverage   83.94%   83.85%   -0.09%     
==========================================
  Files          73       73              
  Lines        6003     6009       +6     
==========================================
  Hits         5039     5039              
- Misses        964      970       +6     
Flag Coverage Δ
integrationtests 83.77% <11.11%> (-0.09%) ⬇️
unittests 64.08% <11.11%> (-0.07%) ⬇️

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

Impacted Files Coverage Δ
sdk/python/feast/registry.py 77.94% <7.14%> (-1.41%) ⬇️
sdk/python/feast/repo_operations.py 31.19% <9.09%> (ø)
sdk/python/feast/feature_store.py 93.07% <50.00%> (ø)

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 651d066...c2e0ec1. Read the comment docs.

Copy link
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
Collaborator

[APPROVALNOTIFIER] This PR is APPROVED

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

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

The pull request process is described here

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

@feast-ci-bot feast-ci-bot merged commit 082bbff into feast-dev:master Aug 1, 2021
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