Skip to content

Commit d3b04f3

Browse files
committed
Update rust version to 1.77, chrono to 0.4.35
1 parent 1f86133 commit d3b04f3

File tree

68 files changed

+283
-189
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

68 files changed

+283
-189
lines changed

Cargo.lock

Lines changed: 66 additions & 9 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,7 @@ resolver = "2"
138138

139139
[workspace.package]
140140
edition = "2021"
141-
rust-version = "1.76.0"
141+
rust-version = "1.77.0"
142142

143143
[profile.dev]
144144
split-debuginfo = "unpacked"

bin/ci-builder

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
set -euo pipefail
1818

19-
NIGHTLY_RUST_DATE=2024-01-01
19+
NIGHTLY_RUST_DATE=2024-02-01
2020

2121
cd "$(dirname "$0")/.."
2222

bin/lint-versions

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,5 +11,5 @@
1111
#
1212
# lint-versions - Check rust version
1313

14-
grep "rust-version = " Cargo.toml | grep -q "1\.76\.0" || \
14+
grep "rust-version = " Cargo.toml | grep -q "1\.77\.0" || \
1515
(echo "Please validate new Rust versions for compilation time performance regressions or ask Team Testing to do so. Afterwards change the tested version in bin/lint-versions" && exit 1)

misc/cargo-vet/config.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -267,7 +267,7 @@ version = "0.4.25"
267267
criteria = "safe-to-deploy"
268268

269269
[[exemptions.chrono-tz]]
270-
version = "0.8.1"
270+
version = "0.8.6"
271271
criteria = "safe-to-deploy"
272272

273273
[[exemptions.chrono-tz-build]]

src/adapter/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ anyhow = "1.0.66"
1414
async-trait = "0.1.68"
1515
bytes = "1.3.0"
1616
bytesize = "1.1.0"
17-
chrono = { version = "0.4.23", default-features = false, features = ["std"] }
17+
chrono = { version = "0.4.35", default-features = false, features = ["std"] }
1818
dec = "0.4.8"
1919
deadpool-postgres = "0.10.3"
2020
derivative = "2.2.0"

src/adapter/src/catalog/builtin_table_updates.rs

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ mod notice;
1212
use std::net::Ipv4Addr;
1313

1414
use bytesize::ByteSize;
15-
use chrono::{DateTime, Utc};
1615
use mz_audit_log::{EventDetails, EventType, ObjectType, VersionedEvent, VersionedStorageUsage};
1716
use mz_catalog::builtin::{
1817
MZ_AGGREGATES, MZ_ARRAY_TYPES, MZ_AUDIT_EVENTS, MZ_AWS_CONNECTIONS,
@@ -1324,7 +1323,7 @@ impl CatalogState {
13241323
.iter()
13251324
.next()
13261325
.expect("details created above with a single jsonb column");
1327-
let dt = mz_ore::now::to_datetime(occurred_at).naive_utc();
1326+
let dt = mz_ore::now::to_datetime(occurred_at);
13281327
let id = event.sortable_id();
13291328
Ok(BuiltinTableUpdate {
13301329
id: self.resolve_builtin_table(&MZ_AUDIT_EVENTS),
@@ -1337,7 +1336,7 @@ impl CatalogState {
13371336
Some(user) => Datum::String(user),
13381337
None => Datum::Null,
13391338
},
1340-
Datum::TimestampTz(DateTime::from_utc(dt, Utc).try_into().expect("must fit")),
1339+
Datum::TimestampTz(dt.try_into().expect("must fit")),
13411340
]),
13421341
diff: 1,
13431342
})

src/adapter/src/coord/appends.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -650,5 +650,6 @@ impl GroupCommitWaiter {
650650
///
651651
/// Note: We sometimes want to throttle how many group commits are running at once, which this
652652
/// permit allows us to do.
653+
#[allow(dead_code)]
653654
#[derive(Debug)]
654655
pub struct GroupCommitPermit(OwnedSemaphorePermit);

src/adapter/src/coord/timestamp_selection.rs

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
use std::fmt;
1313

1414
use async_trait::async_trait;
15-
use chrono::{DateTime, NaiveDateTime, Utc};
15+
use chrono::{DateTime, Utc};
1616
use differential_dataflow::lattice::Lattice;
1717
use mz_compute_types::ComputeInstanceId;
1818
use mz_expr::MirScalarExpr;
@@ -659,9 +659,11 @@ impl Coordinator {
659659
ScalarType::TimestampTz { .. } => {
660660
evaled.unwrap_timestamptz().timestamp_millis().try_into()?
661661
}
662-
ScalarType::Timestamp { .. } => {
663-
evaled.unwrap_timestamp().timestamp_millis().try_into()?
664-
}
662+
ScalarType::Timestamp { .. } => evaled
663+
.unwrap_timestamp()
664+
.and_utc()
665+
.timestamp_millis()
666+
.try_into()?,
665667
_ => coord_bail!(
666668
"can't use {} as a mz_timestamp for AS OF or UP TO",
667669
catalog.for_session(session).humanize_column_type(&ty)
@@ -730,7 +732,7 @@ impl DisplayableInTimeline for mz_repr::Timestamp {
730732
if let Some(Timeline::EpochMilliseconds) = timeline {
731733
let ts_ms: u64 = self.into();
732734
if let Ok(ts_ms) = i64::try_from(ts_ms) {
733-
if let Some(ndt) = NaiveDateTime::from_timestamp_millis(ts_ms) {
735+
if let Some(ndt) = DateTime::from_timestamp_millis(ts_ms) {
734736
return write!(f, "{:13} ({})", self, ndt.format("%Y-%m-%d %H:%M:%S%.3f"));
735737
}
736738
}
@@ -822,7 +824,7 @@ impl<T: fmt::Display + fmt::Debug + DisplayableInTimeline + TimestampManipulatio
822824
writeln!(
823825
f,
824826
" session wall time: {:13} ({})",
825-
self.session_wall_time.naive_local().timestamp_millis(),
827+
self.session_wall_time.timestamp_millis(),
826828
self.session_wall_time.format("%Y-%m-%d %H:%M:%S%.3f"),
827829
)?;
828830

src/avro/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ workspace = true
1717
[dependencies]
1818
anyhow = "1.0.66"
1919
byteorder = { version = "1.4.3", optional = true }
20-
chrono = { version = "0.4.23", default-features = false, features = ["std"] }
20+
chrono = { version = "0.4.35", default-features = false, features = ["std"] }
2121
crc32fast = { version = "1.3.2", optional = true }
2222
digest = "0.10.6"
2323
enum-kinds = "0.5.1"

0 commit comments

Comments
 (0)