Skip to content

Wrong workspace publication order in the presence of dev-dependencies #15412

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
fpoli opened this issue Apr 10, 2025 · 0 comments · Fixed by #15470
Closed

Wrong workspace publication order in the presence of dev-dependencies #15412

fpoli opened this issue Apr 10, 2025 · 0 comments · Fixed by #15470
Labels
C-bug Category: bug Command-publish S-accepted Status: Issue or feature is accepted, and has a team member available to help mentor or review Z-package-workspace Nightly: package-workspace

Comments

@fpoli
Copy link

fpoli commented Apr 10, 2025

Problem

cargo +nightly publish -Zpackage-workspace --workspace ignores the dev-dependencies when computing the order in which to publish the packages of a workspace.

Steps

  1. Create a new workspace in which crate X has a dev-dependency on crate Y.
  2. cargo +nightly publish -Zpackage-workspace --workspace.
  3. cargo tries to publish X first, but fails to do so because Y has not been published yet.

Possible Solution(s)

A possible workaround: #1169 (comment) However, in our case we declare the dev dependency in X as Y = { workspace = true }. So, the workaround cannot be applied easily.

Notes

Original discussion: #1169 (comment)

Version

cargo +nightly --version --verbose:

cargo 1.88.0-nightly (0e93c5bf6 2025-04-05)
release: 1.88.0-nightly
commit-hash: 0e93c5bf6a1d5ee7bc2af63d1afb16cd28793601
commit-date: 2025-04-05
host: aarch64-apple-darwin
libgit2: 1.9.0 (sys:0.20.0 vendored)
libcurl: 8.7.1 (sys:0.4.80+curl-8.12.1 system ssl:(SecureTransport) LibreSSL/3.3.6)
ssl: OpenSSL 3.4.1 11 Feb 2025
os: Mac OS 14.6.1 [64-bit]
@fpoli fpoli added C-bug Category: bug S-triage Status: This issue is waiting on initial triage. labels Apr 10, 2025
@epage epage added Z-package-workspace Nightly: package-workspace S-accepted Status: Issue or feature is accepted, and has a team member available to help mentor or review Command-publish and removed S-triage Status: This issue is waiting on initial triage. labels Apr 10, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-bug Category: bug Command-publish S-accepted Status: Issue or feature is accepted, and has a team member available to help mentor or review Z-package-workspace Nightly: package-workspace
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants