Skip to content

Commit

Permalink
🚸 Fix user feedback for db()
Browse files Browse the repository at this point in the history
  • Loading branch information
falexwolf committed Dec 1, 2024
1 parent f79f4a1 commit 4a59ab4
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions R/Instance.R
Original file line number Diff line number Diff line change
Expand Up @@ -269,15 +269,16 @@ Instance <- R6::R6Class( # nolint object_name_linter
error = function(err) {
py_err <- reticulate::py_last_error()
if (py_err$type != "NotebookNotSaved") {
cli::cli_abort(c(
"Python {py_err$message}",
"i" = "Run {.run reticulate::py_last_error()} for details"
))
cli::cli_abort(c(
"Python {py_err$message}",
"i" = "Run {.run reticulate::py_last_error()} for details"
))

Check warning on line 275 in R/Instance.R

View workflow job for this annotation

GitHub Actions / lint

file=R/Instance.R,line=275,col=15,[trailing_whitespace_linter] Trailing whitespace is superfluous.
}
cli::cli_inform(py_err$message)
message <- gsub(".*NotebookNotSaved: (.*)$", "\\1", py_err$value)
cli::cli_inform(paste("NotebookNotSaved: {message}"))
}
)
},
},

Check warning on line 281 in R/Instance.R

View workflow job for this annotation

GitHub Actions / lint

file=R/Instance.R,line=281,col=7,[trailing_whitespace_linter] Trailing whitespace is superfluous.
#' @description
#' Print an `Instance`
#'
Expand Down

0 comments on commit 4a59ab4

Please sign in to comment.