Closed hcindyl closed 2 years ago
This should have no impact on using the crate from crates.io. What error are you getting and what do you have in your Cargo.toml?
Here is the error message I got
$ cd <package dir>; cargo build --release
Updating crates.io index
error: failed to get `core2` as a dependency of package `<package name>`
Caused by:
failed to fetch `https://github.com/rust-lang/crates.io-index`
Caused by:
error reading from the zlib stream; class=Zlib (5)
The package has the Cargo.toml set as
[dependencies]
core2 = { version = "0.3", default-features = false }
The cargo version is 1.59.0 (49d8809dc 2022-02-10)
If I add cargo search core2
before calling cd <package dir>; cargo build --release
, then somehow the index can be updated correctly and core2 0.3.3 can be downloaded and compiled.
Or if I set the environment variable export CARGO_NET_GIT_FETCH_WITH_CLI=true
, crates.io-index and core2 can be downloaded without issues.
We don't have issues downloading other crates in our code base, and core2 breakage showed up since July 25. Do you have ideas what could cause the error?
This does not seem to be related to this crate. See https://github.com/rust-lang/cargo/issues/10303.
Note the part of your logs:
Caused by:
failed to fetch `https://github.com/rust-lang/crates.io-index`
Caused by:
error reading from the zlib stream; class=Zlib (5)
Your local crates.io checkout is outdated.
0.4.0 is shown as the latest release in crates.io
https://crates.io/crates/core2/versions
but 0.4.0 tag is no longer in the codebase
https://github.com/technocreatives/core2/tags
which causes the crates download breakage.