Skip to content

Migrate stopifnot() usages to cli_abort() #2793

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
MichaelChirico opened this issue Feb 25, 2025 · 0 comments
Open

Migrate stopifnot() usages to cli_abort() #2793

MichaelChirico opened this issue Feb 25, 2025 · 0 comments
Labels
consistency 🍎 🍏 internals Issues related to inner workings of lintr, i.e., not user-visible

Comments

@MichaelChirico
Copy link
Collaborator

          We do use `stopifnot()` in a few places, so I'd make that change separately if needed:
grep -nEr "^[^#\"]*stopifnot[(]" R
# R/unnecessary_concatenation_linter.R:55:  stopifnot(
# R/undesirable_function_linter.R:59:  stopifnot(is.logical(symbol_is_undesirable))
# R/make_linter_from_xpath.R:21:  stopifnot(
# R/make_linter_from_xpath.R:57:  stopifnot(
# R/xp_utils.R:80:  stopifnot(
# R/implicit_assignment_linter.R:65:  stopifnot(is.null(except) || is.character(except))
# R/methods.R:152:  stopifnot(requireNamespace("tibble", quietly = TRUE))
# R/methods.R:158:  stopifnot(requireNamespace("data.table", quietly = TRUE))

Originally posted by @MichaelChirico in #2791 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
consistency 🍎 🍏 internals Issues related to inner workings of lintr, i.e., not user-visible
Projects
None yet
Development

No branches or pull requests

1 participant