Warning: Error in print: trying to get slot "..." from an object (class "reactivevalues") that is not an S4 object

Viewed 10

In a shiny module, I have the following pickerInput()

pickerInput(inputId = ns('zebra'), label = NULL, choices = c("Truck", "Train", "Barge", "Shipment"))

In the server of this module I try to fetch this value with:

  input@zebra %>% print()

And this produces the following error:

Warning: Error in print: trying to get slot "zebra" from an object (class "reactivevalues") that is not an S4 object
1 Answers

The problem was a typo in the line of code in the server, which should have been:

input$zebra %>% print()

Thus a $instead of a @. I just overlooked it for a few hours.

Related