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

apply: remove latest_only, remove nested progress bar #486

Merged
merged 1 commit into from
Dec 25, 2023

Conversation

skshetry
Copy link
Member

@skshetry skshetry commented Dec 25, 2023

Removes latest_only since it's only used in a single place, and it feels more like a diff/compare than apply. Also, makes the progress bar logic simpler and avoids nesting of the callbacks (the apply gets a callback for create_files and creates one internally for diff).

Note, this does hardcore TqdmCallback explicitly, but we were doing that before in practice already. I have some plans to get rid of this soon by introducing a callback factory for now.

Diff is messed up due to indentation. Use this link for better diff:
https://github.com/iterative/dvc-data/pull/486/files?w=1

Removes `latest_only` since it's only used in a single place, and
it feels more like a `diff`/`compare` than `apply`. Also, makes
the progressbar logic simpler and avoids nesting of the callbacks.
@skshetry skshetry requested a review from efiop December 25, 2023 07:35
@codecov-commenter
Copy link

Codecov Report

Attention: 15 lines in your changes are missing coverage. Please review.

Comparison is base (a535b4b) 63.70% compared to head (b0b74b4) 63.74%.

Files Patch % Lines
src/dvc_data/index/push.py 11.76% 14 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #486      +/-   ##
==========================================
+ Coverage   63.70%   63.74%   +0.03%     
==========================================
  Files          61       61              
  Lines        4177     4173       -4     
  Branches      714      713       -1     
==========================================
- Hits         2661     2660       -1     
+ Misses       1368     1367       -1     
+ Partials      148      146       -2     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Contributor

@efiop efiop left a comment

Choose a reason for hiding this comment

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

Well, good thing is that apply is nicer now at the cost of push... :) Which is fine for now, even though incremental.

@efiop efiop merged commit f09ad12 into main Dec 25, 2023
14 of 15 checks passed
@skshetry skshetry deleted the remove-latest_only branch December 25, 2023 07:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants