Update Rust crate chrono to 0.4.27
This MR contains the following updates:
Package | Type | Update | Change |
---|---|---|---|
chrono | dependencies | patch |
0.4.26 -> 0.4.27
|
chrono | dependencies | patch |
0.4.19 -> 0.4.27
|
Release Notes
chronotope/chrono (chrono)
v0.4.27
: 0.4.27
This release bumps the MSRV from 1.56 to 1.57. This allows us to take advantage of the panicking in const feature. In this release most methods on NaiveDate
and NaiveTime
are made const, NaiveDateTime
and others will follow in a later release.
Deprecations
- Deprecate
DateTime::{from_local, from_utc}
(https://github.com/chronotope/chrono/pull/1175)
Additions
- Let
DateTime::signed_duration_since
take argument withBorrow
(https://github.com/chronotope/chrono/pull/1119) - Implement
PartialOrd
forMonth
(https://github.com/chronotope/chrono/pull/999, thanks @Munksgaard) - Add
Ord
andEq
for types which already derivePartialOrd
andPartialEq
(https://github.com/chronotope/chrono/pull/1128, thanks @totikom) - implement
FusedIterator
forNaiveDateDaysIterator
andNaiveDateWeeksIterator
(https://github.com/chronotope/chrono/pull/1134) - Make
NaiveDateDaysIterator
andNaiveDateWeeksIterator
public (https://github.com/chronotope/chrono/pull/1134) - Add
FromStr
forFixedOffset
(https://github.com/chronotope/chrono/pull/1157, thanks @mcronce) - Remove
Tz::Offset: Display
requirement fromDateTime::to_rfc*
(https://github.com/chronotope/chrono/pull/1160) - More flexible offset formatting (not exposed yet) (https://github.com/chronotope/chrono/pull/1160)
- Make
StrftimeItems
withunstable-locales
work without allocating (https://github.com/chronotope/chrono/pull/1152) - Make
NaiveDate::from_ymd_opt
const (https://github.com/chronotope/chrono/pull/1172, thanks @kamadorueda) - Implement
Error
trait forParseWeekdayError
andParseMonthError
(https://github.com/chronotope/chrono/pull/539, thanks @mike-kfed) - Make methods on
NaiveTime
const, update MSRV to 1.57 (https://github.com/chronotope/chrono/pull/1080) - Make methods on
NaiveDate
const (https://github.com/chronotope/chrono/pull/1205) - Implement operations for
core::time::Duration
onDateTime
types (https://github.com/chronotope/chrono/pull/1229)
Fixes
- Ensure
timestamp_nanos
panics on overflow in release builds (https://github.com/chronotope/chrono/pull/1123) - Fix
offset_from_local_datetime
forwasm_bindgen
(https://github.com/chronotope/chrono/pull/1131) - Parsing: Consider
%s
to be a timestamp in UTC (https://github.com/chronotope/chrono/pull/1136) - Don't panic when formatting with
%#z
(https://github.com/chronotope/chrono/pull/1140, thanks @domodwyer) - Parsing: allow MINUS SIGN (U+2212) in offset (https://github.com/chronotope/chrono/pull/1087, thanks @jtmoon79)
- Fix locale formatting for
%c
and%r
(https://github.com/chronotope/chrono/pull/1165) - Localize decimal point with
unstable-locales
feature (https://github.com/chronotope/chrono/pull/1168) - Fix panic on macOS 10.12 caused by using version 1 of the TZif file format (https://github.com/chronotope/chrono/pull/1201, thanks to help from @jfro)
- Fix deserialization of negative timestamps (https://github.com/chronotope/chrono/pull/1194)
- Do not use
Offset
'sDebug
impl when serializingDateTime
(https://github.com/chronotope/chrono/pull/1035) - Allow missing seconds in
NaiveTime::from_str
(https://github.com/chronotope/chrono/pull/1181) - Do not depend on
android-tzdata
if theclock
feature is not enabled (https://github.com/chronotope/chrono/pull/1220, thanks @AlexTMjugador) - Small fixes to the RFC 3339 parsers (https://github.com/chronotope/chrono/pull/1145)
Documentation
- Add "Errors" and "Panics" sections to API docs (https://github.com/chronotope/chrono/pull/1120)
- Specify licenses in SPDX format (https://github.com/chronotope/chrono/pull/1132, backport of https://github.com/chronotope/chrono/issues/856, thanks @keymandll)
- Fix
NaiveTime
doc typo (https://github.com/chronotope/chrono/pull/1146, thanks @zachs18) - Clarify nanosecond formatting specifier doc (https://github.com/chronotope/chrono/pull/1173)
- Add warning against combining multiple
Datelike::with_*
(https://github.com/chronotope/chrono/pull/1199) - Fix typo "accepted" (https://github.com/chronotope/chrono/pull/1209)
- Add some examples to
Utc::now
andLocal::now
(https://github.com/chronotope/chrono/pull/1192) - Add example to
Weekday::num_days_from_monday
(https://github.com/chronotope/chrono/pull/1193) - Fix some comments and panic messages (https://github.com/chronotope/chrono/pull/1221, thanks @umanwizard)
Internal improvements
-
DateTime::to_rfc_*
optimizations (https://github.com/chronotope/chrono/pull/1200) - Move all tests into modules, fix clippy warnings (https://github.com/chronotope/chrono/pull/1138)
- Offset parsing cleanup (https://github.com/chronotope/chrono/pull/1158)
- Factor out formatting to
format/formatting.rs
(https://github.com/chronotope/chrono/pull/1156) - Format refactorings (https://github.com/chronotope/chrono/pull/1198)
- Format toml files with taplo (https://github.com/chronotope/chrono/pull/1117, thanks @tottoto)
- Stop vendoring
saturating_abs
(https://github.com/chronotope/chrono/pull/1124) - CI: shell set -eux, use bash (https://github.com/chronotope/chrono/pull/1103, thanks @jtmoon79)
- Fix dead code error when running dateutils test on Windows (https://github.com/chronotope/chrono/pull/1125)
- Remove
Makefile
(https://github.com/chronotope/chrono/pull/1133) - CI: Test
wasm-bindgen
feature (https://github.com/chronotope/chrono/pull/1131) - Stop using deprecated methods in parse module (https://github.com/chronotope/chrono/pull/1142)
- Add formatting benchmarks (https://github.com/chronotope/chrono/pull/1155)
- Feature gate tests instead of methods (https://github.com/chronotope/chrono/pull/1159, https://github.com/chronotope/chrono/pull/1162)
- Parallelize
try_verify_against_date_command
(https://github.com/chronotope/chrono/pull/1161) - CI: also run integration tests with
no_std
(https://github.com/chronotope/chrono/pull/1166) - Split
test_parse
(https://github.com/chronotope/chrono/pull/1170) - Remove
#![deny(dead_code)]
(https://github.com/chronotope/chrono/pull/1187) - Clippy fixes for Rust 1.71 (https://github.com/chronotope/chrono/pull/1186)
- Various small improvements (https://github.com/chronotope/chrono/pull/1191)
- Add unit test for uncovered regions (https://github.com/chronotope/chrono/pull/1149, thanks @CXWorks)
- Don't test the same thing twice in
test_date_extreme_offset
(https://github.com/chronotope/chrono/pull/1195) - CI: Add workflow code coverage report and upload (https://github.com/chronotope/chrono/pull/1178, https://github.com/chronotope/chrono/pull/1215, thanks @jtmoon79)
- CI: fail on warnings in
features-check
(https://github.com/chronotope/chrono/pull/1216) - Switch to windows-bindgen (https://github.com/chronotope/chrono/pull/1202, thanks to help from @MarijnS95)
Thanks to all contributors on behalf of the chrono team, @djc and @pitdicker!
Configuration
-
If you want to rebase/retry this MR, check this box
This MR has been generated by Renovate Bot.