Skip to content

Cargo fails at loading git dependency #9191

@aWeinzierl

Description

@aWeinzierl

Problem
Failure with the following reported message when trying to build repo:

error: failed to get `windows` as a dependency of package `minesweeper-rs v0.1.0 (C:\Users\andre\[directory]\minesweeper-rs)`

Caused by:
  failed to load source for dependency `windows`

Caused by:
  Unable to update https://github.com/microsoft/windows-rs#031b4736

Caused by:
  the given reference name 'refs/heads/' is not valid; class=Reference (4)

Steps

  1. Clone https://github.com/robmikh/minesweeper-rs
  2. Switch to uwp branch
  3. Delete C:\Users\andre\.cargo\git
  4. Run cargo update or cargo +nightly build -Z build-std=std,panic_abort --target x86_64-uwp-windows-msvc or cargo +stable update

Notes

  • deleting Cargo.lock does not help
  • requiring master for windows-rs does not help

Perhaps related issues: #8957 #9133

Output of cargo version:
cargo 1.52.0-nightly (bf5a5d5 2021-02-18)
cargo 1.50.0 (f04e7fa 2021-02-04)

OS:
Windows 10.0.19042 Pro

Metadata

Metadata

Assignees

No one assigned

    Labels

    C-bugCategory: bug

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions