[Unable to load shiny package]

2,359 views
Skip to first unread message

cho7tom

unread,
Dec 1, 2012, 5:05:34 PM12/1/12
to shiny-...@googlegroups.com
Hello,

First of all, thank you very much for the Shiny package, it looks great!

I encounter some difficulties in installing the package, as I cannot install 'websockets' and 'caTools' dependent packages.
Would anyone be able to help me solve this issue?

Please find below my log while trying to install Shiny.

Thank you in advance for your help - I'm quite new to R! -

LOG

 library(shiny)
Error in loadNamespace(i, c(lib.loc, .libPaths())) : 
  there is no package called ‘caTools’
Error: package/namespace load failed for ‘shiny’

install.packages("websockets")
Installing package(s) into ‘C:/Users/thomas.filaire/Documents/R/win-library/2.15’
(as ‘lib’ is unspecified)
also installing the dependency ‘caTools’

Warning in install.packages :
  InternetOpenUrl failed: 'The operation timed out'
Warning in install.packages :
  unable to access index for repository http://cran.cict.fr/bin/windows/contrib/2.15

   packages ‘caTools’, ‘websockets’ are available as source packages but not as binaries

Warning in install.packages :
  packages ‘caTools’, ‘websockets’ are not available (for R version 2.15.2)

install.packages("caTools")
Installing package(s) into ‘C:/Users/thomas.filaire/Documents/R/win-library/2.15’
(as ‘lib’ is unspecified)
Content type 'application/zip' length 227240 bytes (221 Kb)
opened URL
downloaded 221 Kb

package ‘caTools’ successfully unpacked and MD5 sums checked

The downloaded binary packages are in
C:\Users\thomas.filaire\AppData\Local\Temp\RtmpwPPSgm\downloaded_packages

 library("shiny", lib.loc="C:/Users/thomas.filaire/Documents/R/win-library/2.15")
Error in loadNamespace(i, c(lib.loc, .libPaths())) : 
  there is no package called ‘xtable’
Error: package/namespace load failed for ‘shiny’
> install.packages("xtable")
Installing package(s) into ‘C:/Users/thomas.filaire/Documents/R/win-library/2.15’
(as ‘lib’ is unspecified)
Warning in install.packages :
  InternetOpenUrl failed: 'The operation timed out'
Error in download.file(url, destfile, method, mode = "wb", ...) : 
Warning in install.packages :
  download of package ‘xtable’ failed

Joe Cheng

unread,
Dec 1, 2012, 5:09:10 PM12/1/12
to shiny-...@googlegroups.com
Please try a different CRAN repository, it sounds like that server might be having some issues. Or just like this:

install.packages("shiny", repos=c("http://rstudio.org/_packages", "http://cran.rstudio.com"))

Sent from my phone
--
 
 

cho7tom

unread,
Dec 1, 2012, 5:51:31 PM12/1/12
to shiny-...@googlegroups.com
Many thanks Joe for your answer.

The install was successful. 
However, using the 8100 port doesn't seem to work.. How can I proceed? - it is probably not R- or shiny- related, but you may already have had the question...

> library(shiny)
> runExample("01_hello")

Listening on port 8100
Error in http_response(ws, status = response$status, content_type = response$content_type,  : 
  unused argument(s) (headers = response$headers)

I will mark the post as solved,

Regards,

cho7tom

Joe Cheng

unread,
Dec 1, 2012, 7:53:40 PM12/1/12
to shiny-...@googlegroups.com
It looks like you need to upgrade the websockets package to 1.1.6, not sure how that happened.

install.packages('websockets')

Sent from my phone
--
 
 

Theodore Van Rooy

unread,
Jan 16, 2013, 8:22:35 PM1/16/13
to shiny-...@googlegroups.com
I also had this problem using R 2.14.2 and Rstudio (the http response error).

I ended up goign to the CRAN page, downloading the .tar.gz source file for web sockets 1.1.7 and installing for source.

That fixed it...

Kai Wang

unread,
Apr 3, 2013, 6:01:15 PM4/3/13
to shiny-...@googlegroups.com


I encounter a problem when running "01_hello" example too.  When generating a webpage, I got the following error "

Oops! Google Chrome could not connect to localhost:8100", I have been using rstudio and already updated "websockets" package.

Joe Cheng

unread,
Apr 3, 2013, 7:25:16 PM4/3/13
to shiny-...@googlegroups.com
Hi Kai,

Are you using the desktop or server (web browser based) version of RStudio?


--
You received this message because you are subscribed to the Google Groups "Shiny - Web Framework for R" group.
To unsubscribe from this group and stop receiving emails from it, send an email to shiny-discus...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Parth khare

unread,
Jun 6, 2013, 12:50:23 AM6/6/13
to shiny-...@googlegroups.com
Hi Joe,
 
I have the same problem ("localhost not found") i am first time user of R studio server, and starting to work on shiny.

Joe Cheng

unread,
Jun 6, 2013, 3:48:55 AM6/6/13
to shiny-...@googlegroups.com
Parth, it won't really work with RStudio Server that way; you need Shiny Server also installed on the server and instead of calling runApp you just let Shiny Server deploy it automatically and you point your browser to a special URL. If you want you can sign up for our beta hosting service which is set up to work in this way, and you will be e-mailed instructions when you're added to the beta.

Parth khare

unread,
Jun 6, 2013, 7:38:26 AM6/6/13
to shiny-...@googlegroups.com
Thanks Joe, i have registered for it and using the same shiny server, i installed shiny package and just gave the commant to run first example as stated in the tutorials, there is where i got the error. I know this sounds a little too dumb question but i couldn't figure out what to do. 

Anant Mithal

unread,
Jun 6, 2013, 11:41:18 PM6/6/13
to shiny-...@googlegroups.com
Hi,

I got the below error : 
Listening on port 8100
Error in makeTcpServer(host, port, appWrapper$onHeaders, appWrapper$onBodyData,  : 
  '.Random.seed' is not an integer vector but of type 'list'

Could you please help me out with this?
P.S. - I am a newbie in R too and just learning how to use Shiny.

rtre...@gmail.com

unread,
Jun 7, 2013, 6:49:17 AM6/7/13
to shiny-...@googlegroups.com

advice for new (I am one)
sometimes you have to move the directory in the root shiny

Joe Cheng

unread,
Jun 7, 2013, 12:13:29 PM6/7/13
to shiny-...@googlegroups.com
Anant, can you try rm(.Random.seed) and then try again? If that doesn't work, try restarting your R session (if you're in RStudio then it's "Session | Restart R").
Reply all
Reply to author
Forward
0 new messages