HenrikBengtsson / parallelly

R package: parallelly - Enhancing the 'parallel' Package
https://parallelly.futureverse.org
130 stars 7 forks source link

BUG: 'rscript_envs' only accepts certain environment-variable names #49

Closed HenrikBengtsson closed 3 years ago

HenrikBengtsson commented 3 years ago

Issue

parallelly::makeNodePSOCK("localhost", port = 10001, rscript_envs = c("_R_CLASS_MATRIX_ARRAY_"))
Error in value[[3L]](cond) : 
  Argument 'rscript_envs' appears to contain invalid values: '_R_CLASS_MATRIX_ARRAY_'='true'

Troubleshooting

This is because makeNodePSOCK() dynamically creates code where these are set via an R character vector, and it is the parse(text = code) validation of this code that fails.