-
Thank you for crane! We noticed (and it is also mentioned at the bottom here) that for a "cargoArtifacts" to be useful it needs to share the same (or similar enough) That seems to pose a limitation on how useful artifact sharing can be in workspaces with derivations for individual crates. For example, a workspace with crates foo and bar that are bin crates, where they share dependencies, and there's an individual derivation for each. The call for building foo would have I'm not certain, but I would imagine that optimally, the same cargoArtifacts would be provided to both of them. That It seems that those foo and bar derivations would not share any cache. And that any dependencies they share would be compiled twice. And if we have another binary crate, then thrice. And if we have a workspace wide Is there any way we could optimize this, please? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
This is a standard Check through #341 and google around. I don't think there's anything for |
Beta Was this translation helpful? Give feedback.
This is a standard
cargo
behavior and tomes have been written about this problem. You'll see the same issue in a local shell when doingcargo build -p <local-crate>
vs justcargo build
, causing rebuilds etc.Check through #341 and google around. I don't think there's anything for
crane
to do here. Would be great if cargo supported some flags that say "always use the whole workspace dependency set".