shiny app works locally but not on server

I have browsed here some similar posts and realized that this error may result from vary reasons. So I still post my problem here. I am sorry that I am not able to provide a reproducible example, because I need to use some other local files (thousands of png files) in the code.

So here is the code:


  titlePanel('hello shiny'),

server <- function(input, output,session) {
  fullnames=list.files(path = "/Users/u/Documents/myapp/www", pattern = ".png");
            input$ID=gsub(pattern = '\\.png','',fullnames)
    deleteFile = F


the error:

Listening on
Warning in normalizePath(file.path("/Users/u/Documents/myapp/www",  :
  path[1]="/Users/u/Documents/myapp/www/.png": No such file or directory

I am guessing something is wrong with the input, as the warning shows incomplete path. It still works locally, but not on server, with the same warning (error) on the server log. Any idea how to fix it? Thank you very much.

This path doesn't exist in the server, you have to use a relative path (relative to the application's root directory) instead of an absolute one.

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.