I'm trying to use the scholar package to develop a shiny app. It works really well when I run it locally, but I get this warning (and the code doesnt work) when deploying to shinyapps.io:
Warning in get_scholar_resp(url, 5) :
2021-12-04T14:56:08.621126+00:00 shinyapps[5266206]:   194: <Anonymous>
2021-12-04T14:56:08.603929+00:00 shinyapps[5266206]:   Page 404. Please check whether the provided URL is correct.
2021-12-04T14:56:08.610531+00:00 shinyapps[5266206]: Warning: Error in httr::content: is.response(x) is not TRUE
It's not an encoding problem. I'm not sure what's is causing this, if anyone could help it'd be great.
This is an reproducible example:
library(shiny)
library(scholar)
library(dplyr)
ui <- fluidPage(
    titlePanel("Scholar package example"),
    sidebarLayout(
        sidebarPanel(
            textInput(
              'id',
              'Insert scholar id',
              value = 'LBHrWsIAAAAJ'
            ),
            actionButton(
              'search',
              'Plot network'
            )
        ),
        mainPanel(
           plotOutput("network")
        )
    )
)
server <- function(input, output) {
  observeEvent(input$search, {
    output$network <- renderPlot({
      scholar::get_coauthors(input$id) %>% 
        scholar::plot_coauthors()
    })
  })
}
 
shinyApp(ui = ui, server = server)