{"action":"created","issue":{"url":"https://api.github.com/repos/rust-lang/cargo/issues/3136","repository_url":"https://api.github.com/repos/rust-lang/cargo","labels_url":"https://api.github.com/repos/rust-lang/cargo/issues/3136/labels{/name}","comments_url":"https://api.github.com/repos/rust-lang/cargo/issues/3136/comments","events_url":"https://api.github.com/repos/rust-lang/cargo/issues/3136/events","html_url":"https://github.com/rust-lang/cargo/pull/3136","id":180191423,"number":3136,"title":"Warn about path overrides that won't work","user":{"login":"alexcrichton","id":64996,"avatar_url":"https://avatars.githubusercontent.com/u/64996?v=3","gravatar_id":"","url":"https://api.github.com/users/alexcrichton","html_url":"https://github.com/alexcrichton","followers_url":"https://api.github.com/users/alexcrichton/followers","following_url":"https://api.github.com/users/alexcrichton/following{/other_user}","gists_url":"https://api.github.com/users/alexcrichton/gists{/gist_id}","starred_url":"https://api.github.com/users/alexcrichton/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alexcrichton/subscriptions","organizations_url":"https://api.github.com/users/alexcrichton/orgs","repos_url":"https://api.github.com/users/alexcrichton/repos","events_url":"https://api.github.com/users/alexcrichton/events{/privacy}","received_events_url":"https://api.github.com/users/alexcrichton/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2016-09-29T23:56:34Z","updated_at":"2016-09-29T23:57:06Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/rust-lang/cargo/pulls/3136","html_url":"https://github.com/rust-lang/cargo/pull/3136","diff_url":"https://github.com/rust-lang/cargo/pull/3136.diff","patch_url":"https://github.com/rust-lang/cargo/pull/3136.patch"},"body":"Cargo has a long-standing [bug] in path overrides where they will cause spurious\r\nrebuilds of crates in the crate graph. This can be very difficult to diagnose\r\nand be incredibly frustrating as well. Unfortunately, though, it's behavior that\r\nfundamentally can't be fixed in Cargo.\r\n\r\nThe crux of the problem happens when a `path` replacement changes something\r\nabout the list of dependencies of the crate that it's replacing. This alteration\r\nto the list of dependencies *cannot be tracked by Cargo* as the lock file was\r\npreviously emitted. In the best case this ends up causing random recompiles. In\r\nthe worst case it cause infinite registry updates that always result in\r\nrecompiles.\r\n\r\nA solution to this intention, changing the dependency graph of an overridden\r\ndependency, was [implemented] with the `[replace]` feature in Cargo awhile back.\r\nWith that in mind, this commit implements a *warning* whenever a bad dependency\r\nreplacement is detected. The message here is pretty wordy, but it's intended to\r\nconvey that you should switch to using `[replace]` for a more robust\r\nimpelmentation, and it can also give security to anyone using `path` overrides\r\nthat if they get past this warning everything should work as intended.\r\n\r\n[bug]: https://github.com/rust-lang/cargo/issues/2041\r\n[implemented]: http://doc.crates.io/specifying-dependencies.html#overriding-dependencies\r\n\r\nCloses #2041"},"comment":{"url":"https://api.github.com/repos/rust-lang/cargo/issues/comments/250624971","html_url":"https://github.com/rust-lang/cargo/pull/3136#issuecomment-250624971","issue_url":"https://api.github.com/repos/rust-lang/cargo/issues/3136","id":250624971,"user":{"login":"alexcrichton","id":64996,"avatar_url":"https://avatars.githubusercontent.com/u/64996?v=3","gravatar_id":"","url":"https://api.github.com/users/alexcrichton","html_url":"https://github.com/alexcrichton","followers_url":"https://api.github.com/users/alexcrichton/followers","following_url":"https://api.github.com/users/alexcrichton/following{/other_user}","gists_url":"https://api.github.com/users/alexcrichton/gists{/gist_id}","starred_url":"https://api.github.com/users/alexcrichton/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alexcrichton/subscriptions","organizations_url":"https://api.github.com/users/alexcrichton/orgs","repos_url":"https://api.github.com/users/alexcrichton/repos","events_url":"https://api.github.com/users/alexcrichton/events{/privacy}","received_events_url":"https://api.github.com/users/alexcrichton/received_events","type":"User","site_admin":false},"created_at":"2016-09-29T23:57:06Z","updated_at":"2016-09-29T23:57:06Z","body":"r? @brson "}}
{"actor":{"display_login":"alexcrichton"}}