Skip to content
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

Use new cargo-metadata API to check if workspace default members can be read #474

Open
sourcefrog opened this issue Dec 12, 2024 · 0 comments
Labels
internal Internal refactors and infrastructure small

Comments

@sourcefrog
Copy link
Owner

oli-obk/cargo_metadata#282 adds a new API that we could use to avoid a panic when running with an old cargo toolchain, in

fn workspace_default_packages(metadata: &Metadata) -> PackageSelection {
// `cargo_metadata::workspace_default_packages` will panic when calling Cargo older than 1.71;
// in that case we'll just fall back to everything, for lack of a better option.
match catch_unwind(|| metadata.workspace_default_packages()) {

@sourcefrog sourcefrog added small internal Internal refactors and infrastructure labels Dec 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
internal Internal refactors and infrastructure small
Projects
None yet
Development

No branches or pull requests

1 participant