Skip to content

Conversation

@casperdcl
Copy link
Contributor

@casperdcl casperdcl commented Apr 5, 2020

  • add progress for git clone
  • add progress for git fetch/pull? to be addressed later
  • append to rather than remove initial desc
    • (perhaps even in other places in a different issue)?

asciicast

@casperdcl casperdcl added enhancement Enhances DVC ui user interface / interaction labels Apr 5, 2020
@casperdcl casperdcl requested review from efiop and shcheklein April 5, 2020 14:49
@casperdcl casperdcl self-assigned this Apr 5, 2020
@shcheklein
Copy link
Contributor

Is strange that first I'm getting:

Cloning 0.00 [00:00, ?it/s]

After a while:

900.00 KiB | 1.69 MiB/s 4.73k [00:02, 14.0it/s]

Is it expected?

Also I don't see the progress bar itself? Is it because git python does not report it?

@shcheklein
Copy link
Contributor

@casperdcl
Copy link
Contributor Author

Thanks @shcheklein again for the recording; yes it's expected:

Is strange that first I'm getting:

Cloning 0.00 [00:00, ?it/s]

After a while:

900.00 KiB | 1.69 MiB/s 4.73k [00:02, 14.0it/s]

Is it expected?

900.00 KiB | 1.69 MiB/s is actually the message string provided by git to the progress_callback. Yes, this is weird. And we can't rely on it being formatted in this way (esp. for other git operations).

Also I don't see the progress bar itself? Is it because git python does not report it?

Exactly, it doesn't report a total (specifically, it's passing in the default max_count=None to the callback), which is unfortunate.

@shcheklein
Copy link
Contributor

@casperdcl but why do we replace Cloning with the stats message (900.00 KiB | 1.69 MiB/s)? And stats itself -4.73k [00:02, 14.0it/s] - do you get what does it mean?

@casperdcl
Copy link
Contributor Author

casperdcl commented Apr 5, 2020

but why do we replace Cloning with the stats message (900.00 KiB | 1.69 MiB/s)?

Seems like a good idea to display the message provided to the callback.

And stats itself -4.73k [00:02, 14.0it/s] - do you get what does it mean?

It's from #3595 (comment): number of "items." I believe in this case it's what git would call "objects" if you ran git pull manually:

$ git pull
...
Receiving objects: 100% (576/576), 585.47 KiB | 432.00 KiB/s, done.
...

@shcheklein
Copy link
Contributor

can we show all the stats to the right? the same as we do with main progress bar for Pull you have done? (no matter what library thinks). Or at least always prepend "Cloning "?

@efiop
Copy link
Contributor

efiop commented Apr 15, 2020

@casperdcl What's the status of this PR?

@casperdcl
Copy link
Contributor Author

just updated the description - still awaiting a little tidy from me.

@casperdcl
Copy link
Contributor Author

@efiop ready to merge now I think. @shcheklein see the updated recording:

asciicast

Note that atm the py git api provides total=None to the progress callback so there's no way to guess a total hence there's no progress bar, just stats.

@shcheklein
Copy link
Contributor

LGTM! thanks @casperdcl

@efiop efiop merged commit f0c81bc into treeverse:master Apr 17, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement Enhances DVC ui user interface / interaction

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants