Skip to content

Commit 7cb637b

Browse files
authored
chore: Bump Rust version and workflow actions (#1112)
* chore: Bump Rust toolchains to 1.89.0 and nightly-2025-05-26 * ci: Bump Rust toolchains to 1.89.0 and nightly-2025-05-26 * ci: Bump actions/checkout to v5.0.0 * ci: Bump Swatinem/rust-cache to v2.8.1 * ci: Bump EmbarkStudios/cargo-deny-action to v2.0.13 * ci: Bump stackabletech/actions to v0.10.3 * ci: Bump actions/upload-pages-artifact to v4.0.0 * ci: Bump cargo-udeps to 0.1.59 * chore(ci): Make quoted YAML values consistent * chore: Fix Clippy's mismatched_lifetime_syntaxes lint * chore: Fix Clippy's collapsible_if lint * chore: Remove unused test code * chore: Update Rust toolchain in pre-commit config * chore(issue-template): Add nightly Rust toolchain task
1 parent 184423d commit 7cb637b

File tree

15 files changed

+70
-78
lines changed

15 files changed

+70
-78
lines changed

.github/ISSUE_TEMPLATE/release-workspace-members.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@ Replace the items in the task lists below with the applicable Pull Requests
3939
- [ ] Also adjust the nightly Rust toolchain version used for formatting (this should be kept in
4040
sync across here, operator-templating and docker-images).
4141
- `.github/workflows/pre_commit.yaml`
42+
- `.pre-commit-config.yaml`
4243
- `.vscode/settings.json`
4344
- [ ] Add a changelog entry.
4445
- [ ] Update any actions (using the Git commit hash) in the workflows. Hint: Also make sure that the

.github/workflows/build.yml

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,9 @@ on:
1515

1616
env:
1717
CARGO_TERM_COLOR: always
18-
CARGO_INCREMENTAL: '0'
19-
CARGO_PROFILE_DEV_DEBUG: '0'
20-
RUST_TOOLCHAIN_VERSION: "1.87.0"
18+
CARGO_INCREMENTAL: "0"
19+
CARGO_PROFILE_DEV_DEBUG: "0"
20+
RUST_TOOLCHAIN_VERSION: "1.89.0"
2121
RUSTFLAGS: "-D warnings"
2222
RUSTDOCFLAGS: "-D warnings"
2323
RUST_LOG: "info"
@@ -32,16 +32,16 @@ jobs:
3232
env:
3333
RUSTC_BOOTSTRAP: 1
3434
steps:
35-
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
35+
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
3636
with:
3737
persist-credentials: false
3838
- uses: dtolnay/rust-toolchain@master
3939
with:
4040
toolchain: ${{ env.RUST_TOOLCHAIN_VERSION }}
41-
- uses: Swatinem/rust-cache@98c8021b550208e191a6a3145459bfc9fb29c4c0 # v2.8.0
41+
- uses: Swatinem/rust-cache@f13886b937689c021905a6b90929199931d60db1 # v2.8.1
4242
with:
4343
key: udeps
44-
- run: cargo install --locked cargo-udeps@0.1.57
44+
- run: cargo install --locked cargo-udeps@0.1.59
4545
- run: cargo udeps --all-targets --all-features
4646

4747
run_cargodeny:
@@ -57,28 +57,28 @@ jobs:
5757
continue-on-error: ${{ matrix.checks == 'advisories' }}
5858

5959
steps:
60-
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
60+
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
6161
with:
6262
persist-credentials: false
6363
- uses: dtolnay/rust-toolchain@master
6464
with:
6565
toolchain: ${{ env.RUST_TOOLCHAIN_VERSION }}
66-
- uses: EmbarkStudios/cargo-deny-action@30f817c6f72275c6d54dc744fbca09ebc958599f # v2.0.12
66+
- uses: EmbarkStudios/cargo-deny-action@f2ba7abc2abebaf185c833c3961145a3c275caad # v2.0.13
6767
with:
6868
command: check ${{ matrix.checks }}
6969

7070
run_rustdoc:
7171
name: Run RustDoc
7272
runs-on: ubuntu-latest
7373
steps:
74-
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
74+
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
7575
with:
7676
persist-credentials: false
7777
- uses: dtolnay/rust-toolchain@master
7878
with:
7979
toolchain: ${{ env.RUST_TOOLCHAIN_VERSION }}
8080
components: rustfmt
81-
- uses: Swatinem/rust-cache@98c8021b550208e191a6a3145459bfc9fb29c4c0 # v2.8.0
81+
- uses: Swatinem/rust-cache@f13886b937689c021905a6b90929199931d60db1 # v2.8.1
8282
with:
8383
key: doc
8484
- run: cargo doc --document-private-items
@@ -89,7 +89,7 @@ jobs:
8989
- run_rustdoc
9090
runs-on: ubuntu-latest
9191
steps:
92-
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
92+
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
9393
with:
9494
persist-credentials: false
9595
- uses: dtolnay/rust-toolchain@master
@@ -99,7 +99,7 @@ jobs:
9999
# for our cases.
100100
# See: https://github.com/dtolnay/trybuild/issues/236#issuecomment-1620950759
101101
components: rust-src
102-
- uses: Swatinem/rust-cache@98c8021b550208e191a6a3145459bfc9fb29c4c0 # v2.8.0
102+
- uses: Swatinem/rust-cache@f13886b937689c021905a6b90929199931d60db1 # v2.8.1
103103
with:
104104
key: test
105105
- run: cargo test --no-default-features --workspace

.github/workflows/daily_security.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ name: Security audit
33

44
on:
55
schedule:
6-
- cron: '15 4 * * *'
6+
- cron: "15 4 * * *"
77
workflow_dispatch:
88

99
permissions: {}
@@ -12,7 +12,7 @@ jobs:
1212
audit:
1313
runs-on: ubuntu-latest
1414
steps:
15-
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
15+
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
1616
with:
1717
persist-credentials: false
1818
- uses: rustsec/audit-check@69366f33c96575abad1ee0dba8212993eecbe998 # v2.0.0

.github/workflows/pr_pre-commit.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,19 +7,19 @@ on:
77

88
env:
99
CARGO_TERM_COLOR: always
10-
RUST_TOOLCHAIN_VERSION: "nightly-2025-05-26"
10+
RUST_TOOLCHAIN_VERSION: "nightly-2025-10-23"
1111

1212
permissions: {}
1313

1414
jobs:
1515
pre-commit:
1616
runs-on: ubuntu-latest
1717
steps:
18-
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
18+
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
1919
with:
2020
persist-credentials: false
2121
fetch-depth: 0
22-
- uses: stackabletech/actions/run-pre-commit@4483641a7e24057bd2ba51cb4c3f2f0010ad21b7 # v0.8.4
22+
- uses: stackabletech/actions/run-pre-commit@75e0756966dea229d697165bfd06ba79abcda72c # v0.10.3
2323
with:
2424
rust: ${{ env.RUST_TOOLCHAIN_VERSION }}
2525
# rust-src is required for trybuild stderr output comparison to work

.github/workflows/publish-docs.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ on:
1313
- crates/**
1414

1515
env:
16-
RUST_TOOLCHAIN_VERSION: "1.87.0"
16+
RUST_TOOLCHAIN_VERSION: "1.89.0"
1717

1818
permissions: {}
1919

@@ -22,7 +22,7 @@ jobs:
2222
runs-on: ubuntu-latest
2323
steps:
2424
- name: Checkout Repository
25-
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
25+
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
2626
with:
2727
persist-credentials: false
2828

@@ -37,7 +37,7 @@ jobs:
3737
run: echo '<meta http-equiv="refresh" content="0;url=stackable_operator/index.html">' > target/doc/index.html
3838

3939
- name: Upload Documentation Artifacts
40-
uses: actions/upload-pages-artifact@56afc609e74202658d3ffba0e8f6dda462b719fa # v3.0.1
40+
uses: actions/upload-pages-artifact@7b1f4a764d45c48632c6b24a0339c27f5614fb0b # v4.0.0
4141
with:
4242
path: target/doc
4343

.pre-commit-config.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ repos:
5151
name: cargo-rustfmt
5252
language: system
5353
# Pinning to a specific rustc version, so that we get consistent formatting
54-
entry: cargo +nightly-2025-05-26 fmt --all -- --check
54+
entry: cargo +nightly-2025-10-23 fmt --all -- --check
5555
stages: [pre-commit, pre-merge-commit]
5656
pass_filenames: false
5757
files: \.rs$

.vscode/settings.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
"rust-analyzer.imports.granularity.group": "crate",
44
"rust-analyzer.rustfmt.overrideCommand": [
55
"rustfmt",
6-
"+nightly-2025-05-26",
6+
"+nightly-2025-10-23",
77
"--edition",
88
"2024",
99
"--"

crates/stackable-operator/src/config/fragment.rs

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -246,13 +246,6 @@ mod tests {
246246
optional: Option<WithFields>,
247247
}
248248

249-
#[derive(Fragment, Debug, PartialEq, Eq)]
250-
#[fragment(path_overrides(fragment = "super"))]
251-
struct GenericNested<T: super::FromFragment> {
252-
required: T,
253-
optional: Option<T>,
254-
}
255-
256249
#[test]
257250
fn validate_empty() {
258251
assert_eq!(validate::<Empty>(EmptyFragment {}).unwrap(), Empty {});

crates/stackable-operator/src/product_logging/spec.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ where
8585
T: Clone + Display + Ord,
8686
{
8787
/// Get the logging configuration for `container`, falling back to the default.
88-
pub fn for_container(&self, container: &T) -> Cow<ContainerLogConfig> {
88+
pub fn for_container(&'_ self, container: &T) -> Cow<'_, ContainerLogConfig> {
8989
self.containers
9090
.get(container)
9191
.map(Cow::Borrowed)

crates/stackable-operator/src/utils/option.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ pub trait OptionExt<T> {
99
/// Compared to [`Option::unwrap_or_else`], this saves having to [`Clone::clone`] the value to make the types line up.
1010
///
1111
/// Consider using [`Self::as_deref_or_else`] instead if the type implements [`Deref`] (such as [`String`] or [`PathBuf`]).
12-
fn as_ref_or_else(&self, default: impl FnOnce() -> T) -> Cow<T>
12+
fn as_ref_or_else(&'_ self, default: impl FnOnce() -> T) -> Cow<'_, T>
1313
where
1414
T: Clone;
1515

@@ -18,22 +18,22 @@ pub trait OptionExt<T> {
1818
/// Compared to [`Option::unwrap_or_else`], this saves having to [`Clone::clone`] the value to make the types line up.
1919
///
2020
/// Consider using [`Self::as_ref_or_else`] instead if the type does not implement [`Deref`].
21-
fn as_deref_or_else(&self, default: impl FnOnce() -> T) -> Cow<T::Target>
21+
fn as_deref_or_else(&'_ self, default: impl FnOnce() -> T) -> Cow<'_, T::Target>
2222
where
2323
T: Deref,
2424
T::Target: ToOwned<Owned = T>;
2525
}
2626

2727
impl<T> OptionExt<T> for Option<T> {
28-
fn as_ref_or_else(&self, default: impl FnOnce() -> T) -> Cow<T>
28+
fn as_ref_or_else(&'_ self, default: impl FnOnce() -> T) -> Cow<'_, T>
2929
where
3030
T: Clone,
3131
{
3232
self.as_ref()
3333
.map_or_else(|| Cow::Owned(default()), Cow::Borrowed)
3434
}
3535

36-
fn as_deref_or_else(&self, default: impl FnOnce() -> T) -> Cow<<T>::Target>
36+
fn as_deref_or_else(&'_ self, default: impl FnOnce() -> T) -> Cow<'_, <T>::Target>
3737
where
3838
T: Deref,
3939
<T>::Target: ToOwned<Owned = T>,

0 commit comments

Comments
 (0)