-
Notifications
You must be signed in to change notification settings - Fork 56
Open
Description
I noticed this deprecation warning from TimeZones.jl due to the use of Dates.default_format
:
┌ Warning: `Dates.default_format(ZonedDateTime)` is deprecated and has no direct replacement. Consider using refactoring to use `parse(::Type{ZonedDateTime}, ::AbstractString)` as an alternative.
│ caller = write at write.jl:338 [inlined]
└ @ Core ~/.julia/packages/JSON3/rT1w2/src/write.jl:338
–
Line 338 in cc047e0
write(::StringType, buf, pos, len, x::T; dateformat::Dates.DateFormat=Dates.default_format(T), kw...) where {T <: Dates.TimeType} = write(StringType(), buf, pos, len, Dates.format(x, dateformat); kw...) |
The deprecation notice is a bit off in that we're formatting a ZonedDateTime
and not parsing one.
We could fix this by either adding a special write
function for ZonedDateTime
or should we document that Dates.default_format
should be defined for all Dates.TimeType
subtypes?
Metadata
Metadata
Assignees
Labels
No labels