-
Notifications
You must be signed in to change notification settings - Fork 239
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
Forked evaluators don't work as expected on macOS 11 with R 4.1 #641
Comments
pkgload::load_all()
ex <- mock_exercise("Sys.sleep(1)\n1:100", check = I("last_value"))
forked_eval_ex <- forked_evaluator_factory(evaluate_exercise(ex, new.env()), 2)
forked_eval_ex$start()
|
Seems like we really shouldn't be forking from macOS either, so we'd probably want to use something other than |
|
So, that particular problem was because I used a too harsh method to test what happens when a worker get killed (the purpose of my test script). I used Having said that, yes, forked processing in R can be finicky. Strictly speaking, it's only safe to use if you are in 100% control of the full code, including any package dependencies. Since you cannot control package dependencies, forked parallelization code that has been validated but break suddenly if a dependency introduces something that is not fork safe. So, multicore/forked parallelization can only be one alternative among several. Unfortunately. |
ooh thanks @HenrikBengtsson -- I didn't intend to tag you into this issue 🙈 but I appreciate your insight! I think in this case there's something about the code we're evaluating in the forked process that's causing the issue. The good news is that we're going to move toward a process based on future (via promises), so thanks also for the work you do there! |
Surfaced here — https://github.com/rstudio/learnr/runs/4874272940?check_suite_focus=true#step:7:205 — and reproducible locally.
The text was updated successfully, but these errors were encountered: