Closed aylapear closed 1 year ago
Fixed with latest commit
chk::chk_null_or(2000, vld = chk::vld_whole_number)
chk::chk_null_or(NULL, vld = chk::vld_whole_number)
chk::chk_null_or("2000", vld = chk::vld_whole_number)
#> Error:
#> ! `"2000"` must be a whole number (non-missing integer scalar or double equivalent) or NULL.
#> Backtrace:
#> ▆
#> 1. └─chk::chk_null_or("2000", vld = chk::vld_whole_number)
#> 2. └─chk::abort_chk(msg, x = x) at chk/R/chk-null-or.R:54:2
#> 3. └─chk::err(..., n = n, tidy = tidy, class = "chk_error", call = call) at chk/R/utils.R:19:2
#> 4. └─rlang::abort(msg, class = class, !!!args[named], call = call) at chk/R/err.R:90:2
Created on 2023-09-30 with reprex v2.0.2
This old thread has been automatically locked. If you think you have found something related to this, please open a new issue and link to this old issue if necessary.
The
chk
argument was deprecated but when trying to use thevld
argument instead the error that is thrown is odd. It has the right behaviour that it throws an error but the error it throws seems wrong.