Closed DaniMori closed 5 years ago
When argument x in either stamp() or guess_formats() has at least one NA value, these functions crash.
x
stamp()
guess_formats()
NA
library(lubridate, quietly = TRUE) #> #> Attaching package: 'lubridate' #> The following object is masked from 'package:base': #> #> date ## OK: stamp(c("2019-04-26", "2019-04-25")) #> Multiple formats matched: "%Y-%Om-%d"(2), "%Y-%m-%d"(2) #> Using: "%Y-%Om-%d" #> function (x, locale = "Spanish_Spain.1252") #> { #> { #> old_lc_time <- Sys.getlocale("LC_TIME") #> if (old_lc_time != locale) { #> on.exit(Sys.setlocale("LC_TIME", old_lc_time)) #> Sys.setlocale("LC_TIME", locale) #> } #> } #> format(x, format = "%Y-%Om-%d") #> } #> <environment: 0x0000000019c7a8a0> ## Not run: stamp(c("2019-04-26", NA_character_)) #> Error in if (any(matched)) {: valor ausente donde TRUE/FALSE es necesario
Created on 2019-04-26 by the reprex package (v0.2.1)
Hi @DaniMori, I think you might have the wrong repository. This looks like a lubridate issue (https://github.com/tidyverse/lubridate/issues/new).
Yes, I just noticed that. So sorry, I'll close it straight away.
When argument
x
in eitherstamp()
orguess_formats()
has at least oneNA
value, these functions crash.Created on 2019-04-26 by the reprex package (v0.2.1)