remove default timezone from dateRange()
Closed this issue · 0 comments
jonathancallahan commented
Having date parsing functions default to timezone = "UTC"
may lead to confusion. We should require that users be explicit about the timezone just as the max()
function requires users to explicitly set na.rm = TRUE
.
Because of the dangers associated with not explicitly specifying a timezone, we should provide and encourage people to use date parsing functions that require this. Thus should have:
MazamaCoreUtils::parseDatetime()
MazamaCoreUtils::dateRange()
So the function signature should have timezone = NULL
and there should be parameter validation that requires timezone
to be defined.
This new requirement will have downstream effects that will need to be dealt with but this function has not yet been widely adopted so now is a good time.