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

p_loaded via p_load messes up R session and terminates execution #117

Open
LogIN- opened this issue Mar 15, 2019 · 0 comments
Open

p_loaded via p_load messes up R session and terminates execution #117

LogIN- opened this issue Mar 15, 2019 · 0 comments

Comments

@LogIN-
Copy link

LogIN- commented Mar 15, 2019

Hello,
First I want to thank you very much for this amazing package!

I have an issue by running following command, issue happens randomly and I cannot unfortunately give you reproducible example:

p_load(c(package), install = TRUE, update=FALSE, character.only = TRUE)

Error that's terminates script:

# Error in system(paste(which, shQuote(names[i])), intern = TRUE, ignore.stderr = TRUE) : 
# cannot popen '/usr/bin/which 'uname' 2>/dev/null', probable reason 'Cannot allocate memory'
# Calls: p_load ... FUN -> p_install -> p_loaded -> <Anonymous> -> Sys.which

Unfortunately as I can see this happens since p_loaded is called with default arguments and
all = FALSE is used as default, that makes
utils::sessionInfo() function call

loaded <- names(utils::sessionInfo()[["otherPkgs"]])

This is the place where error occurs. I am not sure why sessionInfo is behaving like this in such cases.

To solve this is would be great to pass custom deep arguments from p_load to other functions that p_load is using like p_loaded so we can set all = TRUE for example.

@LogIN- LogIN- changed the title p_load via p_loaded messes up R session p_loaded via p_load messes up R session and terminates execution Mar 15, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant