Skip to content

Commit 8de83d4

Browse files
authored
GH-39754: [R] Docs are not clear on expected behaviour of date parsing functions (e.g. dmy()) on Windows vs. Linux/MacOS (#49708)
### Rationale for this change Unclear from docs where some time formats don't work on Windows ### What changes are included in this PR? Update docs to make behaviour clearer ### Are these changes tested? No ### Are there any user-facing changes? No * GitHub Issue: #39754 Authored-by: Nic Crane <thisisnic@gmail.com> Signed-off-by: Nic Crane <thisisnic@gmail.com>
1 parent ca47cd1 commit 8de83d4

12 files changed

Lines changed: 214 additions & 248 deletions

r/DESCRIPTION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,6 @@ Imports:
4444
utils,
4545
vctrs
4646
Roxygen: list(markdown = TRUE, r6 = FALSE, load = "source")
47-
RoxygenNote: 7.3.3
4847
Config/testthat/edition: 3
4948
Config/build/bootstrap: TRUE
5049
Suggests:
@@ -151,3 +150,4 @@ Collate:
151150
'schema.R'
152151
'udf.R'
153152
'util.R'
153+
Config/roxygen2/version: 8.0.0

r/R/dplyr-funcs-datetime.R

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -671,7 +671,7 @@ register_bindings_datetime_parsers <- function() {
671671
notes = c(
672672
"`quiet = FALSE` is not supported",
673673
"Available formats are H, I, j, M, S, U, w, W, y, Y, R, T.",
674-
"On Linux and OS X additionally a, A, b, B, Om, p, r are available."
674+
"On Linux and macOS additionally a, A, b, B, Om, p, r are available."
675675
)
676676
)
677677

@@ -724,7 +724,7 @@ register_bindings_datetime_parsers <- function() {
724724
register_binding(
725725
paste0("lubridate::", tolower(order)),
726726
parser_map_factory(order),
727-
notes = "`locale` argument not supported"
727+
notes = "`locale` argument not supported; see docs for `parse_date_time()` mapping for supported formats"
728728
)
729729
}
730730

r/R/dplyr-funcs-doc.R

Lines changed: 22 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -241,17 +241,17 @@
241241
#' * [`dmilliseconds()`][lubridate::dmilliseconds()]
242242
#' * [`dminutes()`][lubridate::dminutes()]
243243
#' * [`dmonths()`][lubridate::dmonths()]
244-
#' * [`dmy()`][lubridate::dmy()]: `locale` argument not supported
245-
#' * [`dmy_h()`][lubridate::dmy_h()]: `locale` argument not supported
246-
#' * [`dmy_hm()`][lubridate::dmy_hm()]: `locale` argument not supported
247-
#' * [`dmy_hms()`][lubridate::dmy_hms()]: `locale` argument not supported
244+
#' * [`dmy()`][lubridate::dmy()]: `locale` argument not supported; see docs for `parse_date_time()` mapping for supported formats
245+
#' * [`dmy_h()`][lubridate::dmy_h()]: `locale` argument not supported; see docs for `parse_date_time()` mapping for supported formats
246+
#' * [`dmy_hm()`][lubridate::dmy_hm()]: `locale` argument not supported; see docs for `parse_date_time()` mapping for supported formats
247+
#' * [`dmy_hms()`][lubridate::dmy_hms()]: `locale` argument not supported; see docs for `parse_date_time()` mapping for supported formats
248248
#' * [`dnanoseconds()`][lubridate::dnanoseconds()]
249249
#' * [`dpicoseconds()`][lubridate::dpicoseconds()]: not supported
250250
#' * [`dseconds()`][lubridate::dseconds()]
251251
#' * [`dst()`][lubridate::dst()]
252252
#' * [`dweeks()`][lubridate::dweeks()]
253253
#' * [`dyears()`][lubridate::dyears()]
254-
#' * [`dym()`][lubridate::dym()]: `locale` argument not supported
254+
#' * [`dym()`][lubridate::dym()]: `locale` argument not supported; see docs for `parse_date_time()` mapping for supported formats
255255
#' * [`epiweek()`][lubridate::epiweek()]
256256
#' * [`epiyear()`][lubridate::epiyear()]
257257
#' * [`fast_strptime()`][lubridate::fast_strptime()]: non-default values of `lt` and `cutoff_2000` not supported
@@ -273,17 +273,17 @@
273273
#' * [`make_difftime()`][lubridate::make_difftime()]: only supports `units = "secs"` (the default);
274274
#' providing both `num` and `...` is not supported
275275
#' * [`mday()`][lubridate::mday()]
276-
#' * [`mdy()`][lubridate::mdy()]: `locale` argument not supported
277-
#' * [`mdy_h()`][lubridate::mdy_h()]: `locale` argument not supported
278-
#' * [`mdy_hm()`][lubridate::mdy_hm()]: `locale` argument not supported
279-
#' * [`mdy_hms()`][lubridate::mdy_hms()]: `locale` argument not supported
276+
#' * [`mdy()`][lubridate::mdy()]: `locale` argument not supported; see docs for `parse_date_time()` mapping for supported formats
277+
#' * [`mdy_h()`][lubridate::mdy_h()]: `locale` argument not supported; see docs for `parse_date_time()` mapping for supported formats
278+
#' * [`mdy_hm()`][lubridate::mdy_hm()]: `locale` argument not supported; see docs for `parse_date_time()` mapping for supported formats
279+
#' * [`mdy_hms()`][lubridate::mdy_hms()]: `locale` argument not supported; see docs for `parse_date_time()` mapping for supported formats
280280
#' * [`minute()`][lubridate::minute()]
281281
#' * [`month()`][lubridate::month()]
282-
#' * [`my()`][lubridate::my()]: `locale` argument not supported
283-
#' * [`myd()`][lubridate::myd()]: `locale` argument not supported
282+
#' * [`my()`][lubridate::my()]: `locale` argument not supported; see docs for `parse_date_time()` mapping for supported formats
283+
#' * [`myd()`][lubridate::myd()]: `locale` argument not supported; see docs for `parse_date_time()` mapping for supported formats
284284
#' * [`parse_date_time()`][lubridate::parse_date_time()]: `quiet = FALSE` is not supported
285285
#' Available formats are H, I, j, M, S, U, w, W, y, Y, R, T.
286-
#' On Linux and OS X additionally a, A, b, B, Om, p, r are available.
286+
#' On Linux and macOS additionally a, A, b, B, Om, p, r are available.
287287
#' * [`pm()`][lubridate::pm()]
288288
#' * [`qday()`][lubridate::qday()]
289289
#' * [`quarter()`][lubridate::quarter()]
@@ -295,17 +295,17 @@
295295
#' * [`week()`][lubridate::week()]
296296
#' * [`with_tz()`][lubridate::with_tz()]
297297
#' * [`yday()`][lubridate::yday()]
298-
#' * [`ydm()`][lubridate::ydm()]: `locale` argument not supported
299-
#' * [`ydm_h()`][lubridate::ydm_h()]: `locale` argument not supported
300-
#' * [`ydm_hm()`][lubridate::ydm_hm()]: `locale` argument not supported
301-
#' * [`ydm_hms()`][lubridate::ydm_hms()]: `locale` argument not supported
298+
#' * [`ydm()`][lubridate::ydm()]: `locale` argument not supported; see docs for `parse_date_time()` mapping for supported formats
299+
#' * [`ydm_h()`][lubridate::ydm_h()]: `locale` argument not supported; see docs for `parse_date_time()` mapping for supported formats
300+
#' * [`ydm_hm()`][lubridate::ydm_hm()]: `locale` argument not supported; see docs for `parse_date_time()` mapping for supported formats
301+
#' * [`ydm_hms()`][lubridate::ydm_hms()]: `locale` argument not supported; see docs for `parse_date_time()` mapping for supported formats
302302
#' * [`year()`][lubridate::year()]
303-
#' * [`ym()`][lubridate::ym()]: `locale` argument not supported
304-
#' * [`ymd()`][lubridate::ymd()]: `locale` argument not supported
305-
#' * [`ymd_h()`][lubridate::ymd_h()]: `locale` argument not supported
306-
#' * [`ymd_hm()`][lubridate::ymd_hm()]: `locale` argument not supported
307-
#' * [`ymd_hms()`][lubridate::ymd_hms()]: `locale` argument not supported
308-
#' * [`yq()`][lubridate::yq()]: `locale` argument not supported
303+
#' * [`ym()`][lubridate::ym()]: `locale` argument not supported; see docs for `parse_date_time()` mapping for supported formats
304+
#' * [`ymd()`][lubridate::ymd()]: `locale` argument not supported; see docs for `parse_date_time()` mapping for supported formats
305+
#' * [`ymd_h()`][lubridate::ymd_h()]: `locale` argument not supported; see docs for `parse_date_time()` mapping for supported formats
306+
#' * [`ymd_hm()`][lubridate::ymd_hm()]: `locale` argument not supported; see docs for `parse_date_time()` mapping for supported formats
307+
#' * [`ymd_hms()`][lubridate::ymd_hms()]: `locale` argument not supported; see docs for `parse_date_time()` mapping for supported formats
308+
#' * [`yq()`][lubridate::yq()]: `locale` argument not supported; see docs for `parse_date_time()` mapping for supported formats
309309
#'
310310
#' ## methods
311311
#'

r/man/CsvReadOptions.Rd

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

r/man/JsonFileFormat.Rd

Lines changed: 0 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)