Skip to content
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

cargo update --package X updates other git repositories #8821

Closed
jyn514 opened this issue Oct 29, 2020 · 2 comments · Fixed by #12975
Closed

cargo update --package X updates other git repositories #8821

jyn514 opened this issue Oct 29, 2020 · 2 comments · Fixed by #12975
Labels
A-dependency-resolution Area: dependency resolution and the resolver C-bug Category: bug Command-update

Comments

@jyn514
Copy link
Member

jyn514 commented Oct 29, 2020

Problem

cargo update -p should only update the specify package. Instead, it updates git repositories as well.

Steps

  1. git clone https://github.com/rust-lang/crater/
  2. cd crater
  3. git checkout dcc54566d5ec82cabca435c0145cbd06f32d3602
  4. cargo update -p crater
$ cargo update -p crater
    Updating crates.io index
    Updating git repository `https://github.com/rust-lang/team`
    Updating rust_team_data v1.0.0 (https://github.com/rust-lang/team#8d8902d7) -> #a3c474be

Output of cargo version: cargo 1.47.0 (f3c7e06 2020-08-28)

@jyn514 jyn514 added the C-bug Category: bug label Oct 29, 2020
jyn514 added a commit to jyn514/crater that referenced this issue Oct 29, 2020
This also contains an update to `rust_lang_teams`, due to
rust-lang/cargo#8821.
bors added a commit to rust-lang/crater that referenced this issue Nov 2, 2020
Convert lockfile to new format

This also contains an update to `rust_lang_team`, due to
rust-lang/cargo#8821.

The hope is this will make the diff in #543 easier to read. There are no changes other than the `team` update.
@epage epage added the A-dependency-resolution Area: dependency resolution and the resolver label Nov 3, 2023
@epage
Copy link
Contributor

epage commented Nov 3, 2023

Git support is sort of hacked in and the resolver has to make a best guess as to when a git dependency should be updated or not.

@epage
Copy link
Contributor

epage commented Nov 3, 2023

#12599 is similar in not wanting git updates to happen when --workspace is specified.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-dependency-resolution Area: dependency resolution and the resolver C-bug Category: bug Command-update
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants