#Workspace cargo check dependency features potential bug

8 messages · Page 1 of 1 (latest)

glass urchin
#

I think the issue is that

  1. any path dependency of the workspace becomes a member (https://doc.rust-lang.org/cargo/reference/workspaces.html#the-members-and-exclude-fields)
    1a. specifying exclude = ["double_features"] fixes the above issue
  2. I think with any resolver a workspace member's default feature is activated, it's as if there was a hidden crate which just depends on double_features with default config
    2a. using cargo check --workspace --no-default-features fixes issue number 2
#

I didn't use the same numbers as you

#

also, exclusive features is an abuse of the feature system and they're not designed to support this

glass urchin
#

I didn't use the same numbers as you
just that you numbered the issues 1 and 2 and I had a different way of doing it lol

#

yeah, I guess with crates that have these kinds of features you gotta work with what you have

#

they'd use different apis

#

that'd be complicated if some other library wants to depend on them and support both

#

I'm not sure what is a good way to solve this problem