ruby-progressbar icon indicating copy to clipboard operation
ruby-progressbar copied to clipboard

Output estimated total time

Open donv opened this issue 4 years ago • 6 comments

Potential Solution or New Behavior

I propose a new format marker, perhaps %T, which displays the estimated total time, that is (%e + %a).

If there is a way to display this already, I'll gladly settle for that.

donv avatar Apr 24 '20 08:04 donv

Hey @donv! Thanks for opening the issue. What is the use case here exactly?

jfelchner avatar Jun 08 '20 23:06 jfelchner

I am very often interested in knowing how long an operation takes in total, and we already show how long it has taken until now and how much longer it will take. The sum of those two are what I am interested in.

Typically I wonder if the early estimates predict the end outcome, and looking at the estimated total time and see if it changes a lot will give me that.

donv avatar Jun 09 '20 06:06 donv

Another variant of this info is the estimated wall clock time the operation will end. If the operation will take 55 more minutes, and it is 14:03 now, we could display 14:58 as the estimated end time.

donv avatar Jun 09 '20 06:06 donv

Let me think on this a bit and see how much code complexity would be involved. :)

jfelchner avatar Jun 26 '20 02:06 jfelchner

@donv I'm still thinking on this and waiting to see if anyone else chimes in that they might be wanting such a feature. Thanks for your patience.

jfelchner avatar Dec 27 '20 05:12 jfelchner

@donv I don't think this would be too terrible to add. No promises if extra complexity crops up but I'll try to get to this before the end of the year. :)

jfelchner avatar Sep 02 '21 04:09 jfelchner

@donv I'm gonna meet you halfway with this one and give you wall clock completion time. I just can't convince myself of a use case for being halfway done with the progress and wanting to know the elapsed time plus the estimated time left. I understand I might not be groking something but I'm going to skip that one for now. Sorry!

Wall clock time will be in the next version!

jfelchner avatar Feb 26 '23 03:02 jfelchner