Dmitry Khalanskiy [JB]
10/05/2026, 10:20 AMkotlinx-datetime will include a breaking change without an automatic migration path!
• Currently, TimeZone.toString() returns TimeZone.id. For example, TimeZone.of("Europe/Berlin").toString() == "Europe/Berlin".
• After the change, toString will include additional information to help you debug where the timezone data is coming from, in an unspecified format. For example, TimeZoneContext.System.get("Europe/Berlin").toString() could be Europe/Berlin[JVM], or JvmTimeZone(Europe/Berlin), or TimeZone(TimeZoneContext.System, Europe/Berlin).
Please review your usages of TimeZone.toString() and see if you need to replace them with explicit calls to `id`: TimeZoneContext.System.get("Europe/Berlin").id == "Europe/Berlin" will continue to work like it did.
The purpose of this breaking change is to allow you to easily distinguish between time zones obtained from TimeZoneContext.System and TimeZoneContext.Bundled and potentially, custom timezone databases. We don't encourage mixing several timezone databases in one code base—and would therefore like to help you notice a mixup when it does happen by accident.ursus
11/03/2026, 2:36 AMDmitry Khalanskiy [JB]
11/03/2026, 6:42 AMtimeZone.toString() == timeZone.id, so we're breaking a literal written promise.
2. We made no promises yet! kotlinx-datetime is marked as experimental, so we reserve the right to break anything at any moment until 1.0. In theory, if you're only going by formal written contracts, you shouldn't trust anything we currently say about the behavior of kotlinx-datetime.
3. We try our best not to bother you anyway. Library authors should think twice before changing any aspect of behavior, even an unspecified one, if it can be realistically expected that people rely on it. Not creating pointless extra work on a library version bump is important. We take this principle so seriously that people often forget that kotlinx-datetime is experimental at all.