-
Notifications
You must be signed in to change notification settings - Fork 2.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Less aggressively poison sources on builds #5288
Conversation
I think we'll want to backport this to beta as well |
tests/testsuite/freshness.rs
Outdated
authors = [] | ||
|
||
#[dependencies] | ||
#registry2 = { version = "*", optional = true } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why is this commented out?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh I left that in by accident, either version of this triggers a bug and I was confirming that they both do
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
r=me when tests exercise both non-transitive and optional conditions
tests/testsuite/freshness.rs
Outdated
[dev-dependencies] | ||
registry2 = "*" | ||
"#, | ||
) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No need for raw literal at the next line
af80341
to
9add385
Compare
Updated! |
authors = [] | ||
|
||
[dev-dependencies] | ||
registry2 = "*" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So this checks only non-transitive case? Let’s add a separate test for optional dep as well?
Discovered in rust-lang#5257 the changes in rust-lang#5215 were slightly too aggressively poisoning sources to require updates, thinking that a manifest changed when it actually hadn't. Non-workspace-member path dependencies with optional/dev-dependencies don't show up in the lock file, so the previous logic would recognize this and think that the dependency missing from the lock file was just added and would require a registry update. The fix in this commit effectively just skips all of these dependencies in non-workspace members. This means that this will be slightly buggy if an optional dependency that's activated is added, but that's hopefully something we can tackle later. Closes rust-lang#5257
9add385
to
0790db9
Compare
@bors: r=matklad |
📌 Commit 0790db9 has been approved by |
⌛ Testing commit 0790db9 with merge 428b4a56a896ee3d57584e1b5fbb37821d59f2f4... |
💔 Test failed - status-travis |
@bors: retry
…On Tue, Apr 3, 2018 at 4:38 PM, bors ***@***.***> wrote:
💔 Test failed - status-travis
<https://travis-ci.org/rust-lang/cargo/builds/361855623?utm_source=github_status&utm_medium=notification>
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#5288 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AAD95ApkicOzmC6d1UQPq1_TUKKM6b_2ks5tk-u8gaJpZM4TFl0_>
.
|
⌛ Testing commit 0790db9 with merge 6727709d01ebef705d3ef97bbaf587d9aa65d0e9... |
💔 Test failed - status-travis |
@bors: retry
…On Tue, Apr 3, 2018 at 4:56 PM, bors ***@***.***> wrote:
💔 Test failed - status-travis
<https://travis-ci.org/rust-lang/cargo/builds/361857496?utm_source=github_status&utm_medium=notification>
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#5288 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AAD95M62vTMb_qeuFouN8SfT4An-ZsuZks5tk-_0gaJpZM4TFl0_>
.
|
⌛ Testing commit 0790db9 with merge 4e392fc60a50e733c3ca4d4b0533829c12290731... |
💔 Test failed - status-travis |
@bors: retry
…On Tue, Apr 3, 2018 at 5:18 PM, bors ***@***.***> wrote:
💔 Test failed - status-travis
<https://travis-ci.org/rust-lang/cargo/builds/361866326?utm_source=github_status&utm_medium=notification>
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#5288 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AAD95JV6vqA8TViQVanzNZYTNqOskXijks5tk_UdgaJpZM4TFl0_>
.
|
Less aggressively poison sources on builds Discovered in #5257 the changes in #5215 were slightly too aggressively poisoning sources to require updates, thinking that a manifest changed when it actually hadn't. Non-workspace-member path dependencies with optional/dev-dependencies don't show up in the lock file, so the previous logic would recognize this and think that the dependency missing from the lock file was just added and would require a registry update. The fix in this commit effectively just skips all of these dependencies in non-workspace members. This means that this will be slightly buggy if an optional dependency that's activated is added, but that's hopefully something we can tackle later. Closes #5257
☀️ Test successful - status-appveyor, status-travis |
This includes at least two notable changes: * a regression is fixed where Cargo would update index on every operation rust-lang/cargo#5288 * a new unstable `--out-dir` option is implemented rust-lang/cargo#5203
Will do the backports! |
rust-lang/cargo#5288 fixes a regression where cargo would update registry on every operation.
rustc backport PR: rust-lang/rust#49640 |
Update Cargo This includes at least two notable changes: * a regression is fixed where Cargo would update index on every operation rust-lang/cargo#5288 * a new unstable `--out-dir` option is implemented rust-lang/cargo#5203
[beta] Update cargo and backport #49612 rust-lang/cargo#5288 fixes a regression where cargo would update registry on every operation.
This commit extends the fix in rust-lang#5288 by moving the logic added farther up in the loop over package dependencies. This means that we won't recursively look at optional/dev path dependencies which aren't members of the workspace. This should fix the new issue that came up in rust-lang#5257 Closes rust-lang#5257
Fix another issue of poisoning too eagerly This commit extends the fix in #5288 by moving the logic added farther up in the loop over package dependencies. This means that we won't recursively look at optional/dev path dependencies which aren't members of the workspace. This should fix the new issue that came up in #5257 Closes #5257
This commit extends the fix in rust-lang#5288 by moving the logic added farther up in the loop over package dependencies. This means that we won't recursively look at optional/dev path dependencies which aren't members of the workspace. This should fix the new issue that came up in rust-lang#5257 Closes rust-lang#5257
Discovered in #5257 the changes in #5215 were slightly too aggressively
poisoning sources to require updates, thinking that a manifest changed when it
actually hadn't.
Non-workspace-member path dependencies with optional/dev-dependencies
don't show up in the lock file, so the previous logic would recognize this and
think that the dependency missing from the lock file was just added and would
require a registry update.
The fix in this commit effectively just skips all of these dependencies in
non-workspace members. This means that this will be slightly buggy if an
optional dependency that's activated is added, but that's hopefully something we
can tackle later.
Closes #5257