Internal subprocess does not inherit R session options
Hi,
Recently, when using the package, I've discovered a bug (unless it's a feature :)) when using `pak::pkg_sysreqs`. However, I suspect that it might extend to other functions using subprocesses. In a nutshell, it looks like subprocesses do not inherit the R session options from their parent process. I discovered it while developing the package that has a user .RProfile. Among many lines there is one that says: `options(download.file.method = "wininet", timeout = 300)` which is part of our enterprise process for Linux. I started the session with --vanilla flag, wanting to ignore the .RProfile for the time being; however, when called `pak::pkg_sysreqs`, it led to errors as it uses the Windows option from .RProfile. I believe that the unexpected result comes from the fact that although the main process is run without .RProfile, with --vanilla mode, the subporcess which resolves requirements is run with standard options and hence reads the startup configuration. In my opinion, it is a bit of an unexpected result as if someone runs their session in the --vanilla mode, they probably expect that to be carried forward to subprocesses. Alternatively, an option to configure it using system variables would be really appreciated.
1 条评论