Showcase Mode in CentOS throwing closure error

Hello,

I have been trying to run an app in showcase mode from Rstudio 1.3.1093 and keep getting the error "cannot coerce type 'closure' to vector of type 'character' [No stack trace available]"

The same error appears when I run runExample("01_hello")

I am trying to run this on a CentOS 7 machine with R 3.6.0 and Shiny 1.4.0.2 (I don't have any control over OS, R, or Shiny version I can use).

Do you have any suggestions about what is going wrong here?

This error is usually due to an attempt to perform an operation on an object with the same name as a function. Common examples are D df data and c.

I'm familiar with the error type, but I don't understand why it's happening in an included example application. If it was just happening in my code I could understand it, but the fact that it occurs in the runExample() function befuddles me.

Hard to say without a reprex. See the FAQ: How to do a minimal reproducible example reprex for beginners.

The reprex is runExample("01_hello").

I get this isn't going to be an issue for all setups, hence the inclusion of OS and version information.

Ideally, a reprex is cut-and-paste for the reader to reproduce the behavior.

library(shiny)
if (interactive()) {
  # List all available examples
  runExample()
  
  # Run one of the examples
  runExample("01_hello")
  
  # Print the directory containing the code for all examples
  system.file("examples", package="shiny")
}

This code is good, but only in an interactive environment. I have it working under Ubuntu 20.10; for CentOS, you'll want to review CRAN notes. I think that's probably where the problem lies.

shiny is ok with R (≥ 3.0.2). Cairo is ok with R (≥ 2.4.0).

This topic was automatically closed 54 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.