-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
When discovering a workspace that excludes the current package, newer or unstable features cause a spurious failure #15320
Comments
I'm assuming that the In theory, a subset of the workspace package could be loaded to only check the fields necessary for determining membership. However, that would add a lot of complexity. Before we evaluate an option like that, it would be worthwhile to see how essential it is by exploring potential workarounds. A workaround would be adding a Another workaround is to set |
That’s correct. For ”excluded01” package, we have Rust version fixed to 1.61 (using rust-toolchain.toml). ❯ cargo --version
cargo 1.61.0 (a028ae42f 2022-04-29)
It seems like that. I was surprised to see any error related to the workspace, because my expectation was that by excluding a package from a workspace, we remove any relation to workspace and that calling
That one works.
My first instinct was to try some similar option
With the following example, the same issue remains. ❯ CARGO_RESOLVER_INCOMPATIBLE_RUST_VERSIONS=allow cargo check
error: failed to parse manifest at `/path/to/Cargo.toml`
Caused by:
`resolver` setting `3` is not valid, valid options are "1" or "2" |
The problem is that we need to read enough of the manifest to notice the use of
Switch back to $ CARGO_RESOLVER_INCOMPATIBLE_RUST_VERSIONS=fallback cargo check All To keep things simple, you can add to your repo a [resolver]
incompatible-rust-versions = "fallback" |
I see. Thanks for the elaboration.
I'm OK with the |
Should we keep this issue open? |
Might be worth to provide a lightning rod for anyone else who has workspace discovery problems to see if there is enough case to re-evaluate this. |
resolver
version affects excluded
(from a workspace) packages
Problem
Currently, excluded packages require the same resolver version that was set for workspace (members).
Steps
In the example bellow, if we set
resolver = "3"
for the workspace, we wouldn't be able to build excluded packages even though they are not a part of the workspace.Possible Solution(s)
Ignore resolver version that was set for workspace (members) for excluded packages.
Notes
No response
Version
The text was updated successfully, but these errors were encountered: