test: enable missing feature for test build - #2820
Open
arjan-bal wants to merge 3 commits into
Open
Conversation
arjan-bal
marked this pull request as draft
August 19, 2026 17:01
Contributor
Author
|
This may cause protoc to be built for tonic examples. I'm taking a deeper look. Update: Fixed by removing the gRPC GCP example from the default feature set. |
arjan-bal
marked this pull request as ready for review
August 20, 2026 11:23
dfawley
reviewed
Aug 20, 2026
dfawley
left a comment
Member
There was a problem hiding this comment.
I still don't understand cargo well enough, it seems....
| @@ -294,7 +294,7 @@ grpc-helloworld = ["dep:grpc", "dep:grpc-protobuf", "dep:protobuf"] | |||
| full = ["gcp", "routeguide", "reflection", "autoreload", "health", "grpc-web", | |||
Member
There was a problem hiding this comment.
Is it OK that full doesn't include a feature? I guess it's also missing "tower" and "h2" already?
But what's the point in having "full" anyway? Should we delete it and move the things to "default" so it isn't misleading?
| ready, you can run the example like so: | ||
| ```bash | ||
| $ cargo run --bin grpc-gcp-client -- <project-id> | ||
| $ cargo run --bin grpc-gcp-client --features grpc-gcp -- <project-id> |
Member
There was a problem hiding this comment.
This is still a required feature for the binary in the cargo.toml though? Does that actually mean you have to set it manually or else it won't run?
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add missing feature flags to fix
cargo testwhen run inside individual crate directories.CI previously missed this issue because running
cargo nextestfrom the workspace root automatically unifies workspace features.Additionally, because the
grpc-gcpexample depends onprotoc-gen-rust-grpc(unliketonicexamples), this PR removesgrpc-gcpfrom the default features socargo testworks out of the box. Note thatexamplescrate has no tests.