Conversation
|
Thanks @krlmlr. Couple of points (some also discussed in #277):
|
Codecov Report
@@ Coverage Diff @@
## master #682 +/- ##
==========================================
- Coverage 90.43% 90.15% -0.28%
==========================================
Files 47 47
Lines 2226 2234 +8
==========================================
+ Hits 2013 2014 +1
- Misses 213 220 +7
Continue to review full report at Codecov.
|
|
|
I see.
slow_sqrt <- function(xs) {
p <- progressor(along = xs)
future.apply::future_lapply(xs, function(x) {
message("Calculating the square root of ", x)
Sys.sleep(2)
p(sprintf("x=%g", x))
sqrt(x)
})
}
library(progressr)
handlers("progress")
with_progress(y <- slow_sqrt(1:10))
That said, I understand your point that 99% of the users probably don't want to bother with future strategies and progress bar settings but I think it's important to keep things transparent if possible. |
- simplify set_arg_paths (#682).
|
OK, I will try to finish this up. |
|
Thanks! Happy to review. The startup costs are a problem. On Linux we could start one child process with callr, which then could spawn subprocesses very efficiently with the multicore plan. We could do the same on Windows and multiprocess: In both cases this would also eliminate the problem of temporarily altering the local plan. What do you think? |
|
But going through another sub-process will probably not decrease the start-up costs, would it? Because on top of |
e8615e8 to
b79ff02
Compare
|
I thought about it again. There is an additional problem: When using future, setting a plan is time consuming, even when it's sequential. Hence, when there are less than 3 files to style and we don't set I think we should make a short vignette for this. |

via furrr.
Closes #277.
Closes #617 (=supersedes).
Things to consider:
/stylecommand in r-lib/actions.