You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
pb_tick(self, private, len, tokens) : !self$finished is not TRUE #137
try(rm(pb0));
pb0 <- progress_bar$new(format = " got :current rows at :tick_rate/sec, total time :elapsed, total rows :total", clear = FALSE);
for(ii in 1:10) {Sys.sleep(1/10);pb0$tick(1000)};
pb0$terminate();
Expected behavior:
# got 10000 rows at 10989/sec, total time 1s
Observed behavior:
# Error in pb_tick(self, private, len, tokens) : !self$finished is not TRUE
Workaround:
try(rm(pb0));
pb0 <- progress_bar$new(format = " got :current rows at :tick_rate/sec, total time :elapsed", clear = FALSE, total=NA);
for(ii in 1:10) {Sys.sleep(1/10);pb0$tick(1000)};
pb0$terminate();
Both changes are necessary-- removing any reference to :total when the total is unknown and adding an explicit total=NA.
I think that when the tick-count exceeds the default value for total (100), this error is triggered unless total is explicitly set to NA.
Yes, it's on me for failing to register that :total is redundant with :current when the total is unknown. But I see a number of downstream unresolved problems featuring this error over the years:
Activity