rsconnect says package is sourced from CRAN but I installed from GitHub....leads to failure of Shiny app to deploy correctly.

283 views
Skip to first unread message

Kevin Little

unread,
Apr 1, 2016, 7:24:55 PM4/1/16
to ShinyApps Users
Hi, I have an app previously uploaded to shinyapps.io server and functional two months ago.   I have worked locally on related project in the last few weeks and appear to have loaded the openxlsx package from GitHub since the last app deployment 

I used devtools, version 1.10.0 to install openxlsx

On attempt to redeploy the app today, I seem to have confused things.  Hoping for suggestions to get the Shiny app loaded successfully without reverting back to the CRAN version of openxlsx and to understand what happened here!.

Thanks

DETAILS

rsconnect::appDependencies shows that the openxlsx package is from CRAN??      

rsconnect::appDependencies()
        package  version source
1            BH 1.60.0-1   CRAN
2           DBI    0.3.1   CRAN
3           PKI    0.1-3   CRAN
4            R6    2.1.2   CRAN
5         RCurl 1.95-4.8   CRAN
6       RJSONIO    1.3-0   CRAN
7          Rcpp   0.12.4   CRAN
8       Rmonkey    0.3.1   CRAN
9           XML 3.98-1.4   CRAN
10   assertthat      0.1   CRAN
11    base64enc    0.1-3   CRAN
12       bitops    1.0-6   CRAN
13   cellranger    1.0.0   CRAN
14         curl    0.9.6   CRAN
15     devtools   1.10.0   CRAN
16       digest    0.6.9   CRAN
17        dplyr    0.4.3   CRAN
18        git2r   0.13.1   CRAN
19 googlesheets    0.2.0   CRAN
20    htmltools      0.3   CRAN
21       httpuv    1.3.3   CRAN
22         httr    1.1.0   CRAN
23     jsonlite   0.9.19   CRAN
24     lazyeval   0.1.10   CRAN
25     magrittr      1.5   CRAN
26      memoise    1.0.0   CRAN
27         mime      0.4   CRAN
28       miniUI    0.1.1   CRAN
29      openssl    0.9.2   CRAN
30     openxlsx    3.1.9   CRAN
31      packrat  0.4.7-1   CRAN
32         plyr    1.8.3   CRAN
33        purrr    0.2.1   CRAN
34        readr    0.2.2   CRAN
35     reshape2    1.4.1   CRAN
36    rsconnect  0.4.2.1   CRAN
37   rstudioapi      0.5   CRAN
38        shiny   0.13.2   CRAN
39    shinyapps   0.3.63 github
40      shinyjs    0.5.2   CRAN
41      stringi    1.0-1   CRAN
42      stringr    1.0.0   CRAN
43        tidyr    0.4.1   CRAN
44      whisker    0.3-2   CRAN
45        withr    1.0.1   CRAN
46         xml2    0.1.2   CRAN
47       xtable    1.8-2   CRAN
48         yaml   2.1.13   CRAN

But the CRAN version is clearly 3.0.0 not 3.1.9.  

Error occurs on building the app on shinyio server, as the build routine can't find openxlsx 3.1.9 on CRAN (which is correct, the CRAN version is 3.0.0, https://cran.r-project.org/ )   

sessionInfo()

R version 3.2.3 (2015-12-10)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 7 x64 (build 7601) Service Pack 1

locale:
[1] LC_COLLATE=English_United States.1252  LC_CTYPE=English_United States.1252   
[3] LC_MONETARY=English_United States.1252 LC_NUMERIC=C                          
[5] LC_TIME=English_United States.1252    

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base     

loaded via a namespace (and not attached):
 [1] httr_1.1.0        R6_2.1.2          rsconnect_0.4.2.1 tools_3.2.3      
 [5] withr_1.0.1       curl_0.9.6        memoise_1.0.0     knitr_1.12.3     
 [9] git2r_0.13.1      digest_0.6.9      packrat_0.4.7-1   devtools_1.10.0  

Tareef Kawaf

unread,
Apr 2, 2016, 7:57:29 AM4/2/16
to Kevin Little, ShinyApps Users
I wonder if there is a bug in the rsconnect package.

I am guessing here, but I would try the following, one step at a time and see if they make a difference:

1. Update to the latest version of rsconnect:  devtools::install_github("rstudio/rsconnect"), and try again.
2. Uninstall the openxlsx package and re-install it, and try again.
3. Upgrade devtools , and repeat steps #1 and #2.



--
You received this message because you are subscribed to the Google Groups "ShinyApps Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to shinyapps-use...@googlegroups.com.
To post to this group, send email to shinyap...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/shinyapps-users/fe0e1834-ddbf-40f8-9719-cb95bb9620cf%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Kevin Little

unread,
Apr 2, 2016, 11:05:27 AM4/2/16
to ShinyApps Users, kli...@iecodesign.com

Thanks, did not fix.   rsconnect still has openxlsx as sourced on CRAN.    Here are the details:

1.      After step 1, rsconnect::appDependencies() still shows source for openxlsx as CRAN.

 

 

2.      After step 2, on reinstall of openxlsx from GitHub, I get:

 

Warning message:

In library(package, lib.loc = lib.loc, character.only = TRUE, logical.return = TRUE,  :

  there is no package called ‘openxlsx’

 

However the directory exists in my library

(I did note that using remove.packages(“openxlsx”) did not remove everything—there was openxlsx.dll file still in the libs folder).

 

This may be related to the information seen on loading:

 

> devtools::install_github("awalker89/openxlsx")
Downloading GitHub repo awalker89/openxlsx@master
from URL https://api.github.com/repos/awalker89/openxlsx/zipball/master
Installing openxlsx
"C:/PROGRA~1/R/R-32~1.3/bin/x64/R" --no-site-file --no-environ --no-save --no-restore CMD INSTALL  \
  "C:/Users/Kevin/AppData/Local/Temp/RtmpMRWH8P/devtools36a85c647e70/awalker89-openxlsx-7ecbcfa"  \
  --library="C:/Users/Kevin/Documents/R/win-library/3.2" --install-tests 
 
* installing *source* package 'openxlsx' ...
** libs
g++ -m64 -I"C:/PROGRA~1/R/R-32~1.3/include" -DNDEBUG    -I"C:/Users/Kevin/Documents/R/win-library/3.2/Rcpp/include" -I"d:/RCompile/r-compiling/local/local323/include"     -O2 -Wall  -mtune=core2 -c RcppExports.cpp -o RcppExports.o
g++ -m64 -I"C:/PROGRA~1/R/R-32~1.3/include" -DNDEBUG    -I"C:/Users/Kevin/Documents/R/win-library/3.2/Rcpp/include" -I"d:/RCompile/r-compiling/local/local323/include"     -O2 -Wall  -mtune=core2 -c cppFunctions.cpp -o cppFunctions.o
cppFunctions.cpp: In function 'SEXPREC* loadworksheets(Rcpp::Reference, Rcpp::List, std::vector<std::basic_string<char> >, Rcpp::LogicalVector)':
cppFunctions.cpp:3335:41: warning: suggest parentheses around comparison in operand of '&' [-Wparentheses]
g++ -m64 -shared -s -static-libgcc -o openxlsx.dll tmp.def RcppExports.o cppFunctions.o -Ld:/RCompile/r-compiling/local/local323/lib/x64 -Ld:/RCompile/r-compiling/local/local323/lib -LC:/PROGRA~1/R/R-32~1.3/bin/x64 -lR
installing to C:/Users/Kevin/Documents/R/win-library/3.2/openxlsx/libs/x64
** R
** inst
** tests
** preparing package for lazy loading
** help
*** installing help indices
** building package indices
** installing vignettes
** testing if installed package can be loaded
* DONE (openxlsx)

 

In any case, the openxlsx package is still listed by appDependencies as sourced on CRAN.

36    rsconnect  0.4.2.2 github
37   rstudioapi      0.5   CRAN
38        shiny   0.13.2   CRAN
39    shinyapps   0.3.63 github
40      shinyjs    0.5.2   CRAN
41      stringi    1.0-1   CRAN
42      stringr    1.0.0   CRAN
43        tidyr    0.4.1   CRAN
44      whisker    0.3-2   CRAN
45        withr    1.0.1   CRAN
46         xml2    0.1.2   CRAN
47       xtable    1.8-2   CRAN
48         yaml   2.1.13   CRAN

 

Step 3.    Trying to install devtools, also the system cannot automatically remove the devtools.dll in folder devtools/libs/x64   Removed the .dll file manually.  Reran the install.packages for devtools.

 

> devtools::install_github("rstudio/rsconnect")
Downloading GitHub repo rstudio/rsconnect@master
from URL https://api.github.com/repos/rstudio/rsconnect/zipball/master
Installing rsconnect
"C:/PROGRA~1/R/R-32~1.3/bin/x64/R" --no-site-file --no-environ --no-save --no-restore CMD INSTALL  \
  "C:/Users/Kevin/AppData/Local/Temp/RtmpgX36tV/devtools3cc064525c0d/rstudio-rsconnect-aac8077"  \
  --library="C:/Users/Kevin/Documents/R/win-library/3.2" --install-tests 
 
ERROR: failed to lock directory 'C:/Users/Kevin/Documents/R/win-library/3.2' for modifying
Try removing 'C:/Users/Kevin/Documents/R/win-library/3.2/00LOCK-rstudio-rsconnect-aac8077'
Error: Command failed (3)

 

Removed the file as suggested.   Reran the install command.  Successfully installed.

Had to manually remove the openxlsx.dll from libs/x64 folder.

 

Same messages on installing openxlsx:

> devtools::install_github("awalker89/openxlsx")
Downloading GitHub repo awalker89/openxlsx@master
from URL https://api.github.com/repos/awalker89/openxlsx/zipball/master
Installing openxlsx
"C:/PROGRA~1/R/R-32~1.3/bin/x64/R" --no-site-file --no-environ --no-save --no-restore CMD INSTALL  \
  "C:/Users/Kevin/AppData/Local/Temp/Rtmp8AVkxH/devtools444477e5bc4/awalker89-openxlsx-7ecbcfa"  \
  --library="C:/Users/Kevin/Documents/R/win-library/3.2" --install-tests 
 
* installing *source* package 'openxlsx' ...
** libs
g++ -m64 -I"C:/PROGRA~1/R/R-32~1.3/include" -DNDEBUG    -I"C:/Users/Kevin/Documents/R/win-library/3.2/Rcpp/include" -I"d:/RCompile/r-compiling/local/local323/include"     -O2 -Wall  -mtune=core2 -c RcppExports.cpp -o RcppExports.o
g++ -m64 -I"C:/PROGRA~1/R/R-32~1.3/include" -DNDEBUG    -I"C:/Users/Kevin/Documents/R/win-library/3.2/Rcpp/include" -I"d:/RCompile/r-compiling/local/local323/include"     -O2 -Wall  -mtune=core2 -c cppFunctions.cpp -o cppFunctions.o
cppFunctions.cpp: In function 'SEXPREC* loadworksheets(Rcpp::Reference, Rcpp::List, std::vector<std::basic_string<char> >, Rcpp::LogicalVector)':
cppFunctions.cpp:3335:41: warning: suggest parentheses around comparison in operand of '&' [-Wparentheses]
g++ -m64 -shared -s -static-libgcc -o openxlsx.dll tmp.def RcppExports.o cppFunctions.o -Ld:/RCompile/r-compiling/local/local323/lib/x64 -Ld:/RCompile/r-compiling/local/local323/lib -LC:/PROGRA~1/R/R-32~1.3/bin/x64 -lR
installing to C:/Users/Kevin/Documents/R/win-library/3.2/openxlsx/libs/x64
** R
** inst
** tests
** preparing package for lazy loading
** help
*** installing help indices
** building package indices
** installing vignettes
** testing if installed package can be loaded
* DONE (openxlsx)
Warning message:
In library(package, lib.loc = lib.loc, character.only = TRUE, logical.return = TRUE,  :
  there is no package called ‘openxlsx’

 

on running rsconnect::appDependencies(), shows that openxlsx was sourced from CRAN and is version 3.1.9.   


For now, I am going to use the CRAN version of openxlsx and also post an issue to awalker's github account for openxlsx, just in case there is something in the package build.

Kevin Little

unread,
Apr 2, 2016, 11:08:11 AM4/2/16
to ShinyApps Users, kli...@iecodesign.com

rsconnect still believes that openxlsx was sourced from CRAN.


Reply all
Reply to author
Forward
0 new messages