Hello,
It worked fine before but no longer the case after deployment yesterday. I created a very simple example to replicate the problem.
Anyone can lend a hand please.
Thanks very much.
Once the example app (https://mbienz.shinyapps.io/uncomtrade_test/) is deployed to shinyappio, The ct_search() from "comtradr" package will no longer work.
The error I get from log is Error in curl::curl_fetch_memory(url, handle = handle) :
2020-06-04T01:11:21.532166+00:00 shinyapps[2405335]: SSL certificate problem: certificate has expired.
The ui.R and server.R are below:
library(shiny)
library(DT)
library(comtradr)
ui <- fluidPage(
titlePanel("Hello Shiny!"),
sidebarLayout(
sidebarPanel(
# Input: Slider for the number of bins ----
selectizeInput("select_country",
tags$p("Select a country"),
choices = c("New Zealand"),
selected = NULL, width = "200px",
multiple = T)
),
mainPanel(
DTOutput(outputId = "export_table")
)
)
)
library(shiny)
library(DT)
library(comtradr)
server <- function(input, output) {
observe({
try(
dtf_exports <-
ct_search(reporters = input$select_country,
partners = "All",
trade_direction = "exports",
start_date = 2018,
end_date = 2018
)
)
})
output$export_table <- renderDT({
dtf_exports
})
}
> sessionInfo()
R version 3.5.1 (2018-07-02)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 10 x64 (build 18362)
Matrix products: default
locale:
[1] LC_COLLATE=Chinese (Simplified)_China.936 LC_CTYPE=Chinese (Simplified)_China.936 LC_MONETARY=Chinese (Simplified)_China.936
[4] LC_NUMERIC=C LC_TIME=Chinese (Simplified)_China.936
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] comtradr_0.2.2 DT_0.9 packrat_0.5.0 rsconnect_0.8.15 shiny_1.4.0
loaded via a namespace (and not attached):
[1] Rcpp_1.0.2 rstudioapi_0.10 magrittr_1.5 xtable_1.8-4 R6_2.2.2 rlang_0.4.1 fastmap_1.0.1
[8] httr_1.4.1 tools_3.5.1 htmltools_0.4.0 crosstalk_1.0.0 openssl_1.0.1 yaml_2.2.0 digest_0.6.22
[15] crayon_1.3.4 purrr_0.3.3 later_1.0.0 htmlwidgets_1.5.1 promises_1.1.0 curl_3.2 mime_0.5
[22] compiler_3.5.1 jsonlite_1.6.1 httpuv_1.5.2 Cairo_1.5-10