title: What do I do when Shiny won't read my files?
body: <p>My Shiny app works on my local computer, but when I upload it to the shinyapps.io server, I get an error message that says:</p>
  
  <blockquote>
    <p>Warning in gzfile(file, "rb") :   cannot open compressed file
    './data/treemap_master.rds', probable reason 'No such file or
    directory' Error in value[3L] : cannot open the connection
    Calls: local ... tryCatch -> tryCatchList -> tryCatchOne ->
     Execution halted</p>
  </blockquote>
  
  <p>You can find the full github repository at: <a href="https://github.com/ethantenison/UWATX_Shiny_App" rel="noreferrer">https://github.com/ethantenison/UWATX_Shiny_App</a></p>
  
  <p>This app is supposed to be uploaded to the Shinyapps linux server. I've made sure that all of the files use relative paths, that the app.R file is inside the directory containing all my files, and I've updated all of my packages including R itself. </p>
  
  <pre><code>library(devtools)
  library(shinydashboard)
  library(shiny)
  library(V8)
  library(shinyjs)
  library(rintrojs)
  library(highcharter)
  library(RColorBrewer)
  library(htmlwidgets)
  library(dplyr)
  library(stringr)
  library(magrittr)
  library(viridis)
  library(viridisLite)
  library(readr)
  library(tidyr)
  library(leaflet)
  library(treemap)
  library(leaflet.extras)
  library(sf)
  
  # ------------------------------- #
  # ------------------------------- #
  # ------------------------------- #
  # ------------SECTION:----------- #
  # ----Reference Data &amp; Styles---- #
  # ------------------------------- #
  # ------------------------------- #
  # ------------------------------- #
  
  # IMPORT MAP STYLES
  blank &lt;- "https://api.mapbox.com/styles/v1/mrw03b/cjjd6srrl7ot42so3cbjxn6ot/tiles/256/{z}/{x}/{y}?access_token=pk.eyJ1IjoibXJ3MDNiIiwiYSI6IlYwb2FiOWcifQ.RWUm2a87fEC9XrDxzvZKKg"
  northstar &lt;- "https://api.mapbox.com/styles/v1/mrw03b/cj48wz0xh15td2st5hcmeqmsv/tiles/256/{z}/{x}/{y}?access_token=pk.eyJ1IjoibXJ3MDNiIiwiYSI6IlYwb2FiOWcifQ.RWUm2a87fEC9XrDxzvZKKg"
  map_attr &lt;- "© &lt;a href='https://www.mapbox.com/map-feedback/'&gt;Mapbox&lt;/a&gt; | Map © &lt;a href='http://www.unitedwayaustin.org/our-work/2gen/'&gt;United Way of Greater Austin&lt;/a&gt;"
  
  full_zips_list &lt;- "78705|78617|78641|78645|78652|78653|78660|78701|78702|78703|78704|78719|78721|78722|78723|78724|78725|78727|78728|78730|78731|78732|78733|78734|78735|78736|78738|78739|78741|78742|78743|78744|78745|78746|78747|78748|78749|78750|78751|78752|78753|78754|78756|78757|78758|78759|78654|78610|78621|78615|78669|78737|78620|78726"
  
  filter_out &lt;- "78712|78743"
  
  treemap_master &lt;- read_rds('./data/treemap_master.rds') %&gt;%
    ungroup() %&gt;%
    mutate(age = as.character(age))
  
  #TREEMAP DATA - ZIP &amp; NEEDS
  needs_zip_treemap &lt;- read_rds('./data/needs_zip_treemap.rds') %&gt;%
    ungroup() %&gt;% 
    janitor::clean_names() %&gt;%
    mutate(day = as.character("01"),
           month = as.character("01")) %&gt;% 
    unite(date, c("year", "month", "day"), sep = "-") %&gt;% 
    mutate(date = as.Date(date, "%Y-%m-%d")) %&gt;% 
    rename(year = date)
  
  travis_dl &lt;- read_rds('./data/data_4_download.rds')
  
  travis &lt;- read_rds('./data/data_4_analysis.rds') %&gt;%
    filter(!str_detect(zipcode, filter_out))  %&gt;% 
    group_by(Year, measure) %&gt;% 
    mutate(rank = dense_rank(desc(value))) %&gt;% 
    ungroup()
  
  travis_summ &lt;- read_rds('./data/summ211.rds')
  
  travis_county_sf &lt;- read_rds('./data/traviscounty_boundary.rds')
  
  </code></pre>
  
  <p>The app is supposed to look something like this: <a href="https://uwatx.shinyapps.io/211Explorer/" rel="noreferrer">https://uwatx.shinyapps.io/211Explorer/</a></p>
  
  <p>You can find the full error message here:
  <a href="https://uwatx.shinyapps.io/UWATX_Shiny_App/" rel="noreferrer">https://uwatx.shinyapps.io/UWATX_Shiny_App/</a></p>