Skip to content

cargo install suggests an unrelated package #9422

@bronson

Description

@bronson

Problem

When I ask Cargo to install cargo-edit from git, it says that I'm being ambiguous and suggests the two crate as an alternative.

$ cargo install --git=https://github.com/killercup/cargo-edit --features vendored-openssl
    Updating git repository `https://github.com/killercup/cargo-edit`
error: multiple packages with binaries found: cargo-edit, two

I downloaded the two crate and glanced through it... I don't see any reason for Cargo to suggest it.

Steps

  1. cargo install --git=https://github.com/killercup/cargo-edit --features vendored-openssl
  2. Notice Cargo's suggestions. On my computer: cargo-edit, two

It's true that explicitly stating cargo-edit succeeds: cargo install cargo-edit --git=https://github.com/killercup/cargo-edit --features vendored-openssl

But, why did Cargo suggest the two crate?

Notes

Output of cargo version: cargo 1.51.0 (43b129a 2021-03-16)

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-diagnosticsArea: Error and warning messages generated by Cargo itself.C-bugCategory: bugCommand-installE-easyExperience: Easy

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions