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

Kani builds don't enable features the same as ordinary cargo builds #2112

Open
Tracked by #2138
tedinski opened this issue Jan 12, 2023 · 0 comments
Open
Tracked by #2138

Kani builds don't enable features the same as ordinary cargo builds #2112

tedinski opened this issue Jan 12, 2023 · 0 comments
Labels
[C] Bug This is a bug. Something isn't working.

Comments

@tedinski
Copy link
Contributor

Many projects use workspaces, with dependencies between crates in the workspace.

A common pattern is to have a feature named something like "test_utilities" that, when enabled, exports more symbols that are generally just for testing and other crates request this feature for their own tests.

When building a workspace, if a crate has any dependents with a feature enabled, then the crate is built in that workspace with the feature enabled, which is what's used for all dependents. This means it's common for one crate to properly ask for "test_utilities" and other crates to forget, because they're accidentally getting it for free.

Kani, however, builds one crate at a time with -p at present, and so we no longer benefit(?) from this behavior, and that means customers trying Kani immediate run into build failures if they have this common misconfiguration problem. It's normally hidden from them.

We shouldn't get in customer's way, if cargo test works, then cargo kani should too. We should fix this.

@tedinski tedinski added the [C] Bug This is a bug. Something isn't working. label Jan 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[C] Bug This is a bug. Something isn't working.
Projects
None yet
Development

No branches or pull requests

1 participant