Skip to content

ci: publish crates all at once#3232

Merged
Alenar merged 7 commits intomainfrom
djo/3230/ci/publish-crates-test-run-all-at-once
Apr 27, 2026
Merged

ci: publish crates all at once#3232
Alenar merged 7 commits intomainfrom
djo/3230/ci/publish-crates-test-run-all-at-once

Conversation

@Alenar
Copy link
Copy Markdown
Collaborator

@Alenar Alenar commented Apr 27, 2026

Content

This PR includes reworks the publication of rust crates to leverage the new ability of cargo to works on multiple crates at once.

Currently our publish have huge limitations which hurt our ability to deliver crates with correct dependencies to crates.io :

  • we can't use exact versions for published crates depending on another published crates. We set those versions using >=x.y.z as a stopgap, but this means that a published mithril-client can be seen as compatible with an older mithril-common even if they are not.
  • we are forced to do a first manual publication when we want to publish a new package

Those limitations are mostly due to the fact that we are publishing the crates one at a time, meaning that if crates B depends on a updated version of A, versions which is not yet published (likely because running publish in dry-run for the CI), the

The idea behind the introduction of the publish test in the CI was to protect ourselves against unpublished dependency graphs when releasing a new version. E.G., if crates A was already published but we want to publish a new version which introduce a dependency against a crate B we want this CI job to fail if B was not taken into account for the publication.

This PR removes those limitations by running cargo publish, dry run or not, on all crates that needs it at once. This means that now cargo publish is able to verify that the whole sets of crates to publish is coherent, solving our issues.

Pre-submit checklist

  • Branch
    • 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
    • No new TODOs introduced

Issue(s)

Closes #3230

as it will now operate on a list

+ rename "package" input arg to "packages"
@Alenar Alenar requested review from jpraynaud and turmelclem April 27, 2026 13:37
@Alenar Alenar self-assigned this Apr 27, 2026
@Alenar Alenar added the CI/CD 🏭 CI/CD label Apr 27, 2026
@Alenar Alenar force-pushed the djo/3230/ci/publish-crates-test-run-all-at-once branch from 223ab07 to 6a021ce Compare April 27, 2026 13:43
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Apr 27, 2026

Test Results

     5 files  ±0     199 suites  ±0   55m 41s ⏱️ - 2m 33s
 2 905 tests ±0   2 905 ✅ ±0  0 💤 ±0  0 ❌ ±0 
10 268 runs  ±0  10 268 ✅ ±0  0 💤 ±0  0 ❌ ±0 

Results for commit fb386eb. ± Comparison against base commit 44502bd.

♻️ This comment has been updated with latest results.

@Alenar Alenar temporarily deployed to testing-preview April 27, 2026 14:01 — with GitHub Actions Inactive
@Alenar Alenar force-pushed the djo/3230/ci/publish-crates-test-run-all-at-once branch from 6a021ce to f56e446 Compare April 27, 2026 14:15
@Alenar Alenar temporarily deployed to testing-preview April 27, 2026 14:32 — with GitHub Actions Inactive
Copy link
Copy Markdown
Member

@jpraynaud jpraynaud left a comment

Choose a reason for hiding this comment

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

LGTM 👍

@Alenar Alenar force-pushed the djo/3230/ci/publish-crates-test-run-all-at-once branch from f56e446 to cf9c5ea Compare April 27, 2026 15:03
Copy link
Copy Markdown
Collaborator

@turmelclem turmelclem left a comment

Choose a reason for hiding this comment

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

LGTM 👍

@Alenar Alenar temporarily deployed to testing-preview April 27, 2026 15:20 — with GitHub Actions Inactive
@Alenar Alenar force-pushed the djo/3230/ci/publish-crates-test-run-all-at-once branch from cf9c5ea to 79e1c94 Compare April 27, 2026 15:41
@Alenar Alenar marked this pull request as ready for review April 27, 2026 15:53
@Alenar Alenar force-pushed the djo/3230/ci/publish-crates-test-run-all-at-once branch from 79e1c94 to fb386eb Compare April 27, 2026 15:58
@Alenar Alenar temporarily deployed to testing-preview April 27, 2026 16:21 — with GitHub Actions Inactive
@Alenar Alenar merged commit 09ad14a into main Apr 27, 2026
136 of 140 checks passed
@Alenar Alenar deleted the djo/3230/ci/publish-crates-test-run-all-at-once branch April 27, 2026 16:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Refactor the crates publication

3 participants