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

[BUGZILLA #17193] Console is cleared when using progress bar #6368

Open
MichaelChirico opened this issue May 19, 2020 · 0 comments
Open

[BUGZILLA #17193] Console is cleared when using progress bar #6368

MichaelChirico opened this issue May 19, 2020 · 0 comments

Comments

@MichaelChirico
Copy link
Owner

I have noticed that the console is cleared after x iterations when the progress bar is called in a function which is wrapped in a loop. In the example below, this happened for me every∼44th iteration. Interestingly, it seems that reduction of the sleep times in this function increases the number of iterations before clearing. In my real application, where the progress bar is used in a much slower function, the console is cleared every 2-3 iteration, which means that I cannot scroll back to check the output.

testit <- function(x = sort(runif(20)), ...)
{
pb <- txtProgressBar(...)
for(i in c(0, x, 1)) {Sys.sleep(0.2); setTxtProgressBar(pb, i)}
Sys.sleep(1)
close(pb)
}

iter = 0
while (TRUE) {testit(style = 3); iter = iter + 1; print(paste("done", iter))}

This seems to be a Windows RGUI issue, I am not able to reproduce in RStudio, and AFAIK it has not been reproduced under Linux.


METADATA

  • Bug author - Jon Skoien
  • Creation time - 2016-12-14 07:58:23 UTC
  • Bugzilla link
  • Status - UNCONFIRMED
  • Alias - None
  • Component - Windows GUI / Window specific
  • Version - R 3.3.*
  • Hardware - x86_64/x64/amd64 (64-bit) Windows 64-bit
  • Importance - P5 minor
  • Assignee - R-core
  • URL -
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant