rstudio / rsconnect

Publish Shiny Applications, RMarkdown Documents, Jupyter Notebooks, Plumber APIs, and more
http://rstudio.github.io/rsconnect/
129 stars 79 forks source link

configureApp fails with error in rlang::abort() #997

Closed suresh-advaitabio closed 9 months ago

suresh-advaitabio commented 9 months ago

I am trying to set size with configureApp and it fails with rlang::abort()

> rsconnect::configureApp("asc_seurat", size="xlarge")
Error in `rlang::abort()`:
! `message` must be a character vector, not a list.
Run `rlang::last_trace()` to see where the error occurred
> rlang::last_trace(drop = FALSE)
<error/rlang_error>
Error in `rlang::abort()`:
! `message` must be a character vector, not a list.
---
Backtrace:
     ▆
  1. └─rsconnect::configureApp("asc_seurat", size = "xlarge")
  2.   └─client$setApplicationProperty(application$id, propertyName, propertyValue)
  3.     └─rsconnect:::PUT_JSON(service, authInfo, path, v, query)
  4.       └─rsconnect:::PUT(...)
  5.         └─rsconnect:::httpRequestWithBody(...)
  6.           └─rsconnect:::handleResponse(httpResponse, error_call = error_call)
  7.             └─rsconnect (local) reportError(json$error)
  8.               └─cli::cli_abort(...)
  9.                 └─rlang::abort(message = message)
 10.                   └─rlang:::validate_signal_args(...)
 11.                     └─rlang:::check_character(message, call = env)
 12.                       └─rlang:::stop_input_type(...)
 13.                         └─rlang::abort(message, ..., call = call, arg = arg)
> session_info()
─ Session info ──────────────────────────────────────────────────────────────────────────────────
 setting  value
 version  R version 4.3.1 (2023-06-16)
 os       macOS Ventura 13.5.2
 system   aarch64, darwin20
 ui       RStudio
 language (EN)
 collate  en_US.UTF-8
 ctype    en_US.UTF-8
  rstudio  2023.06.1+524 Mountain Hydrangea (desktop)
 pandoc   3.1.7 @ /opt/homebrew/bin/pandoc

Please let me know if you have seen this error and if have a solution for this. If it is already posted and addressed, please share the link.

aronatkins commented 9 months ago

The json$error does not look to be set on this type of error. Maybe all shinyapps.io errors?

The same error happens with an unknown "size" value.

rsconnect::configureApp(..., size = "fooey")
aronatkins commented 9 months ago

@suresh-advaitabio - does the shinyapps.io UI let you assign an xlarge instance type?

Could you share the version of rsconnect?

packageVersion("rsconnect")
suresh-advaitabio commented 9 months ago

It's the error from subscription. I think shinyapps needs to set up a better way of handling subscription errors.

aronatkins commented 9 months ago

Reopening, because rsconnect should do a better job of displaying the errors from shinyapps.io.

hadley commented 9 months ago

The problem is coming from https://github.com/rstudio/rsconnect/blob/main/R/http.R#L153 — I probably assumed that the error field was a simple string, but it's clearly something more complex.

rodgpt commented 9 months ago

@suresh-advaitabio what do you mean by error from the subscription? did you manage to fix it? I am having exactly the same issue