nix-community / crate2nix

rebuild only changed crates in CI with crate2nix and nix
https://nix-community.github.io/crate2nix/
Apache License 2.0
364 stars 86 forks source link

WIP: Merge metatadata better #259

Closed Ericson2314 closed 11 months ago

Ericson2314 commented 2 years ago

We do need to deduplicate on package ID, but we shouldn't assume packages with the same ID are in fact the same. In fact they are not.

I am not sure why, but I think it has something to do with feature resolution, where features / optional deps might be dropped in different cases if they are deemed non-buildable.

In any event, we to combine the packages how on conflict, or at least assert they are the same (if the real solution is, say, to have better keys).

This doesn't deal with the conflict yet, but it at least uses a map rather than vector and "known key" set, so we are ready to handle conflicts next.