v0.7.0
Breaking changes:
- Remove
kotlinx.datetime.Instant
andkotlinx.datetime.Clock
in favor ofkotlin.time.Instant
(#506). See https://github.com/Kotlin/kotlinx-datetime?tab=readme-ov-file#deprecation-of-instant for a description of what to do if this causes problems. - Unify the range of admissible
LocalDate
andLocalDateTime
values on all platforms (#432). - Rename
dayOfMonth
today
,monthNumber
tomonth
(#84). - Make
DayOfWeek
andMonth
no longer type aliases tojava.time.DayOfWeek
andjava.time.Month
(#96). - Make
"UTC"
and not"Z"
be the timezone identifier forTimeZone.UTC
(#474). - Accept
"z"
inTimeZone.of
, with the same meaning as"Z"
(#529). - Add
DateTimeFormat
-basedKSerializer
implementations for datetime entities, and change the default serializers to be based ontoString
/parse
pairs (#415).
Additions:
- Add
java.io.Serializable
implementations for most of the entities in the library (#143). Thanks for spotting and fixing a potential vulnerability, @lukellmann! - Add
LocalDateRange
, a range ofLocalDate
values (#190). Thanks, @PeterAttardo! - Add
YearMonth
andYearMonthRange
(#457).
Tweaks and fixes:
- Support obtaining the system timezone on old Debian-based distributions (#430).
- Fix not being able to parse some valid timezone identifiers using the
timeZoneId()
directive (#444). - Use the grammar defined in RFC 9557 for parsing timezone identifiers in the
timeZoneId()
directive, allowing parsing values not present in the timezone database (#531). - Improved error messages when formatting an invalid
DateTimeComponents
value (#471). - Set the JPMS dependency on
kotlinx.serialization.core
to be optional (#496).