artemklevtsov / RGA

A Google Analytics API client for R
http://cran.r-project.org/package=RGA
32 stars 13 forks source link

address already in use Rstudio cron job #56

Open simran66 opened 6 years ago

simran66 commented 6 years ago

I am using your package to import GA data. For that matter, I have a scheduled cron job. It was working fine so far since years but I recently started getting:

createTcpServer: address already in use Error in httpuv::startServer(use$host, use$port, list(call = listen)) : Failed to create server Calls: authorize ... init_oauth2.0 -> oauth_authorize -> oauth_listener -> <Anonymous> Execution halted

If I go and run this manually in RStudio now though, It runs fine without any issues. ( For it to run, I had to enable

options(httr_oob_default=TRUE) after I started getting this error. However, this, of course, cannot work for crons.

It tries to connect to port 1410

This is what netstat command says:

tcp 0 0 127.0.0.1:1410 0.0.0.0:* LISTEN If I have something running on this port, why does it not complain when I run it manually from rstudio What could be the reason that I started getting this? We did not make any changes to the server. How do I fix this?