Skip to content

Upgrade to Rust 2024 edition#2613

Merged
dlachaume merged 9 commits into
mainfrom
dlachaume/2582/upgrade-to-rust-2024-edition
Jul 2, 2025
Merged

Upgrade to Rust 2024 edition#2613
dlachaume merged 9 commits into
mainfrom
dlachaume/2582/upgrade-to-rust-2024-edition

Conversation

@dlachaume

@dlachaume dlachaume commented Jun 27, 2025

Copy link
Copy Markdown
Contributor

Content

This PR migrates the project codebase to the Rust 2024 edition, following the transitioning guide and tooling.
It's based on the preparation work done in PR #2608.

Steps:

  • Run cargo fix --edition
  • Remove _2021 suffixes from macro expressions added by cargo fix --edition
  • Update the root Cargo.toml and set the edition field to the 2024 edition
  • Run cargo clippy and cargo nextest
  • Run cargo fmt

Additional step:

  • Added a rustfmt.toml file with custom formatting rules (to include all formatting changes in this same PR)

Warning

This PR updates a large portion of the codebase.
To avoid merge conflicts, this PR should be merged carefully, ideally when there are few pending PRs.

Pre-submit checklist

  • Branch
    • Tests are provided (if possible)
    • Crates versions are updated (if relevant)
    • CHANGELOG file is updated (if relevant)
    • Commit sequence broadly makes sense
    • Key commits have useful messages
  • PR
    • All check jobs of the CI have succeeded
    • Self-reviewed the diff
    • Useful pull request description
    • Reviewer requested
  • Documentation
    • Update README file (if relevant)
    • Update documentation website (if relevant)
    • Add dev blog post (if relevant)
    • Add ADR blog post or Dev ADR entry (if relevant)
    • No new TODOs introduced

Issue(s)

Closes #2582

@dlachaume dlachaume self-assigned this Jun 27, 2025
@github-actions

github-actions Bot commented Jun 27, 2025

Copy link
Copy Markdown

Test Results

    3 files  ±0    105 suites  ±0   17m 52s ⏱️ +34s
2 071 tests ±0  2 071 ✅ ±0  0 💤 ±0  0 ❌ ±0 
4 285 runs  ±0  4 285 ✅ ±0  0 💤 ±0  0 ❌ ±0 

Results for commit e653a67. ± Comparison against base commit d3d0037.

♻️ This comment has been updated with latest results.

@dlachaume
dlachaume temporarily deployed to testing-preview June 27, 2025 09:13 — with GitHub Actions Inactive
@dlachaume
dlachaume force-pushed the dlachaume/2582/upgrade-to-rust-2024-edition branch from 8fe0b0b to 6083e1e Compare July 2, 2025 13:54
@dlachaume
dlachaume marked this pull request as ready for review July 2, 2025 13:54

@jpraynaud jpraynaud left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 🚀

@dlachaume
dlachaume temporarily deployed to testing-preview July 2, 2025 14:08 — with GitHub Actions Inactive
 name = "client-cardano-database-v2" -version = "0.0.9" +version = "0.0.10" * client-cardano-database from `0.1.33` to `0.1.34`
* mithril-cardano-node-chain from `0.1.2` to `0.1.3`
* mithril-cardano-node-internal-database from `0.1.1` to `0.1.2`
* mithril-build-script from `0.2.23` to `0.2.24`
* mithril-cli-helper from `0.0.6` to `0.0.7`
* mithril-dmq from `0.1.1` to `0.1.2`
* mithril-doc-derive from `0.1.19` to `0.1.20`
* mithril-doc from `0.1.24` to `0.1.25`
* mithril-era from `0.1.1` to `0.1.2`
* mithril-metric from `0.1.15` to `0.1.16`
* mithril-persistence from `0.2.55` to `0.2.56`
* mithril-resource-pool from `0.0.6` to `0.0.7`
* mithril-ticker from `0.1.2` to `0.1.3`
* mithril-signed-entity-preloader from `0.0.6` to `0.0.7`
* mithril-api-spec from `0.1.0` to `0.1.1`
* mithril-aggregator from `0.7.71` to `0.7.72`
* mithril-client-cli from `0.12.17` to `0.12.18`
* mithril-client-wasm from `0.9.2` to `0.9.3`
* mithril-client from `0.12.18` to `0.12.19`
* mithril-common from `0.6.5` to `0.6.6`
* mithril-relay from `0.1.45` to `0.1.46`
* mithril-signer from `0.2.258` to `0.2.259`
* mithril-stm from `0.4.6` to `0.4.7`
* mithril-aggregator-fake from `0.4.9` to `0.4.10`
* mithril-end-to-end from `0.4.94` to `0.4.95`
* [js] mithril-client-wasm from `0.9.2` to `0.9.3`
@dlachaume
dlachaume temporarily deployed to testing-preview July 2, 2025 14:22 — with GitHub Actions Inactive

@turmelclem turmelclem left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@dlachaume
dlachaume merged commit 5f041dd into main Jul 2, 2025
66 of 67 checks passed
@dlachaume
dlachaume deleted the dlachaume/2582/upgrade-to-rust-2024-edition branch July 2, 2025 14:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Upgrade to Rust 2024 edition

4 participants