5

I am getting the error " The application failed to start (exited with code 1)" while deploying shiny app.

Error Message The error message is attached.In console I get the following message after deploying:

Preparing to deploy application...DONE
Uploading bundle for application: 365672...DONE
Deploying bundle: 1444503 for application: 365672 ...
Waiting for task: 533366947
building: Parsing manifest
building: Building image: 1457861
building: Fetching packages
building: Installing packages
building: Installing files
building: Pushing image: 1457861
deploying: Starting instances
rollforward: Activating new instances
success: Stopping old instances
Application successfully deployed to 
https://programmingrpython.shinyapps.io/shinyapp/

The application runs locally. However I get these messages in the console when I run the app:

The following object is masked from ‘package:ggplot2’:

last_plot

The following object is masked from ‘package:stats’:

filter

The following object is masked from ‘package:graphics’:

layout

Warning in origRenderFunc() :
Ignoring explicitly provided widget ID "52982fb160e2"; Shiny doesn't use them
Warning in origRenderFunc() :
Ignoring explicitly provided widget ID "5298324e516f"; Shiny doesn't use them

Packages I am using are :

library(shiny)
library(plotly)
library(data.table)

Is it because of the warning messages ? I have followed https://github.com/ropensci/plotly/issues/985 but still I am getting this warning.

Can any please suggest why the error message is shown after deployment?

amjear
  • 75
  • 1
  • 1
  • 4

3 Answers3

2

Do you have a setwd() function at the beginning of your app? You need to comment or delete it before deploying your app. I always #comment it.

Comment any section of your code which specifys a local path on your computers directory

mral
  • 118
  • 1
  • 8
  • 2
    This should have been a comment (asking @amjear for clarification), not an answer. Also, I am having the same issue, but it's not due to the presence of `setwd()` function. – Vishal Oct 01 '18 at 18:50
  • Was there ever an answer to this? – william3031 Nov 29 '18 at 06:12
0

I had the same issue. I commented the library(Shiny) line that I had on while creating the app and it deployed successfully.

double-beep
  • 5,031
  • 17
  • 33
  • 41
Elbee
  • 1
0

In my case, the problem was authorities since I was pulling data from Google Sheets. Once I set the authorities correctly, it seemed to work fine. See my answer Trying to deploy shiny app with a google drive connection

AEH
  • 21
  • 1