-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
progress: display vertex status name #4041
base: master
Are you sure you want to change the base?
Conversation
Chiming in as the one that did the remapping in Dagger/Progrock. I was also confused when I saw there was both an ID and a Name, and Name never seemed to be used, but ID seemed to be used like a Name. Do we need both? It sounds OK in theory, for the same reason that vertices have an ID and a name, but in practice nothing ever keys on a status ID independently of a vertex, and I don't think you'd ever have duplicate names within a vertex, so having both just seems like cruft to me. But maybe I'm missing something. |
We don't need both at the moment - however, if we want to be able to change the |
@jedevc Playing devil's advocate: wouldn't it be better to create a new status instead of replacing the name on an old one? That way you can distinguish between the "downloading" and "extracting" duration. Your point definitely stands if there's still some reason to update the name though. 👍 |
@vito you're definitely not wrong 😄 Though then, you have to have two separate statuses ( taking up two lines), even if it's "one operation". e.g. imagine downloading and unpacking a set of artifacts, or layers in an image, etc - having to have double of all of those is a bit tricky, and then takes up a lot more space than wanted. |
Signed-off-by: Justin Chadwell <[email protected]>
Signed-off-by: Justin Chadwell <[email protected]>
Signed-off-by: Justin Chadwell <[email protected]>
9f4160f
to
ba78154
Compare
Did some more updates for this - TL;DR, I think we should completely get rid of the old I've then added a new With this change, we could change:
into
As a layer moves between "downloading", "extracting" and "done" stages, we can change the message. This halves the number of lines needed to display layer downloads, which could be incredibly useful for large builds. |
So, it seems that
VertexStatus.Name
isn't actually used anywhere. Originally, I was attempting to try and update the display name for a vertex status, thinking thatName
would be the way to go, but that's not plumbed through in the same way.I'm not quite sure what the original intention of
Name
was, but it appears like it was probably something like determining how this would get displayed? The issue is, that over time, theID
field for vertex status has been the thing to display (as a name), and isn't entirely used purely as an identifier.The
Name
field gets populated (by setting.Action
) by the local file transfers, so taking a change like this could mean that progress on older clients would change, so maybe the safest option would be doing a protobuf field number bump on.Name
(since it doesn't appear used anywhere client-side as far as I can tell 🤔).@sipsma I know you worked a lot on progress things, so maybe you have some insight? I poked around to see how dagger handles this and found this similar kind of remapping: https://github.com/dagger/dagger/blob/35da30bbd9452e16f7e68f3d4fdea93a5c3ec2e2/core/bk2progrock.go#L64.