Certain ShinyApp Widgets will not display in browser hrough ShinyServer, but will display on local machine and on RStudio Server

leaflet
plotly
dt

#1

I've got a strange problem that is neither easily reproducible nor verbose in the sense of giving me errors or warning flags. I have a Shiny App with multiple widgets and tabs hosted on an Ubuntu EC2 running open source Shiny Server. I have RStudio Server hosted on the same instance. Packages and Ubuntu utilities are shared in common (I install packages from the terminal to be available to all users). I have verified that the app works using a Windows machine running RStudio and also using RStudio Server on the Ubuntu machine. The code is common between development and hosting on Shiny Server as all three are linked to the same Gitlab repository.

The problem I'm having is that certain widgets will not display when accessing the app through the URL using Chrome or Internet Explorer, but this behavior is very inconsistent. The three things that will sometimes not display are: 1) MarkerClusters in a leaflet map using leaflet proxy and an observer responding to SelectInput, 2) a plotly plot responding to several inputs, and 3) a DT::datatable that is not reactive. A separate leaflet with CircleMarkers, ggplot plot, and dygraphs plots all work consistently.

All these will display locally on a Windows desktop. They will also display when I run the app through RStudio Server using either Chrome or Internet Explorer. So the Ubuntu server is clearly capable of displaying these widgets. Even weirder it seems like they will start to display consistently on my machine after I log into RStudio Server and run the app, and then check it again running through Shiny Server. But not when I check on another computer or a smart phone. Sometimes one or two out of the three will display. It seems as though the DT:datatable is the least likely to display. I'm not getting any R error codes and nothing jumps out at me when I inspect element. Restarting the Shiny Server also seems to result in the app working properly sometimes.

I know this is probably very hard to address given the weirdness and lack of reproducible example, but I'm hoping for at least a clue. Is there a better way to figure out what's going on using Inspect Element or the like? What should I be looking for? Could connectivity be an issue? (Our lab shares a 3 MBPS T1 line for a few dozen people, so sometimes we have bandwidth issues when lots of folk are in the office. I work in a beautiful remote place, but crappy internet is one of the few negatives...)


#2

Update:

So I'm learning a bit more about how to use inspect element to get some more information. Here are the errors displayed during an instance when the MarkerClusters will not display in the app.

image


#3

Very strange. Do you see any errors or warnings in /var/log/shiny-server.log?


#4

No errors in /var/log/shiny-server.log

I have messages about Starting listener, stopping listener, shutting down worker processes (with notification) and notes on using pidfile and config file; which all seem fairly routine.

I've got Shiny Server v1.5.6.875, Node.js v6.10.3, R 3.4.4, and all R/Shiny packages and dependencies updated within the last week.