-
Notifications
You must be signed in to change notification settings - Fork 20
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
R CMD check freezes when a test contains parallel calls #36
Comments
And here is a travis build that timeout b/c of no output in the last 10 minutes |
Thanks, I've now confirmed this locally. Bit of a riddle at the moment, I have to dig through some documentation to see where this comes from. Also, big thanks for setting up the test package. |
Ok it seems to be similar to this issue in testthat. I managed to avoid the trouble by setting
in the beginning of the test file. Note: you do not need to unset the envvar at the end because tinytest does this automatically for you after running the test file (so It is a hack and a workaround but maybe you can now at least keep working while I look for a real solution. |
Yes, that seems to work fine. Thanks! |
Awesome, thanks! |
I've been trying to switch some of my R packages to the tinytest framework. In some of them, I use the parallel package, i.e.
parallel::makeCluster()
and that doesn't seem to work withtinytest
. To show this, I've created a small toy package with a single function:hello_parallel
, which creates a cluster objectcl
and callsparallel::clusterEvalQ(cl, "hello")
. Runningtinytest::test_all
works fine, butR CMD check
freezes.Here is the repo where I put the toy package:
https://github.com/USCbiostats/tinytesttest
Here is one example of tinytest failing (freezing) during
R CMD check
:https://travis-ci.org/USCbiostats/tinytesttest/builds/584236824#L728
I had to stop this build after 9 minutes running.
Also, a similar issue happens when I call R using system calls, e.g.
system2("R", ...)
.The text was updated successfully, but these errors were encountered: