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

WISH: Muffle warning on 'In mccollect(jobs = jobs, wait = TRUE) : # 1 parallel job did not deliver a result' when multicore worker crashes #425

Open
HenrikBengtsson opened this issue Oct 14, 2020 · 1 comment
Labels
Backend API Part of the Future API that only backend package developers rely on enhancement

Comments

@HenrikBengtsson
Copy link
Collaborator

If a forked child process crashes/terminates, calling result() on the corresponding multicore future, directly or indirectly, will trigger a warning that comes from the parallel package:

library(future)
plan(multicore, workers = 2L)
f <- future(quit("no"))
r <- tryCatch(result(f), error = identity)
# Warning message:
# In mccollect(jobs = jobs, wait = TRUE) :
#   1 parallel job did not deliver a result
print(r)
# <FutureError: Failed to retrieve the result of MulticoreFuture (<none>) from the
# forked worker (on localhost; PID 21926). Post-mortem diagnostic: No process 
# exists with this PID, i.e. the forked localhost worker is no longer alive.>

Action

Have result() for MulticoreFuture muffle this warning.

@HenrikBengtsson HenrikBengtsson added this to the Next release milestone Oct 14, 2020
@HenrikBengtsson HenrikBengtsson added Backend API Part of the Future API that only backend package developers rely on enhancement labels Oct 14, 2020
@HenrikBengtsson
Copy link
Collaborator Author

HenrikBengtsson commented Oct 16, 2020

While thinking about it, unless we capture and relay the information in this warning, maybe it's better to let the warning stay? It'll add information when it comes to troubleshooting - and then warning only occurs when there's a serious problem so it's a rare event.

@HenrikBengtsson HenrikBengtsson removed this from the Next release milestone Oct 17, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Backend API Part of the Future API that only backend package developers rely on enhancement
Projects
None yet
Development

No branches or pull requests

1 participant