Skip to content
This repository has been archived by the owner on Jun 5, 2020. It is now read-only.

Allow [patch] to change the sourceID but still appear in tree #53

Merged
merged 1 commit into from
Nov 29, 2018

Conversation

bossmc
Copy link
Contributor

@bossmc bossmc commented Nov 29, 2018

[patch] (unlike [replace]) occurs before dependency resolution (or maybe during) so that the patched dependency appears in resolve.deps_not_replaced().

Since a patched dependency can have (and often will have) a separate source_id (e.g. git instead of crates.io) it seems to make sense to compare them to the pkg.dependencies() in a way that ignores the source.

Without this change, [patch]ed dependencies just disappear from the tree silently, which is a little surprising 👻.

(Change also includes a cargo update - full disclosure)

@sfackler
Copy link
Owner

Yay! I spent a while trying to figure out why patched dependencies disappeared but never could. This should fix #27.

@sfackler sfackler merged commit 2dc2c60 into sfackler:master Nov 29, 2018
@bossmc bossmc deleted the handle-replaced-crates branch November 29, 2018 21:46
@bossmc
Copy link
Contributor Author

bossmc commented Nov 29, 2018

No problem, thanks for cargo-tree!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants