Loading pkgs/build-support/rust/fetch-cargo-vendor-util-v2.py +3 −1 Original line number Diff line number Diff line Loading @@ -69,7 +69,9 @@ def get_download_url_for_tarball(pkg: dict[str, Any]) -> str: if pkg["source"] != "registry+https://github.com/rust-lang/crates.io-index": raise Exception("Only the default crates.io registry is supported.") return f"https://crates.io/api/v1/crates/{pkg["name"]}/{pkg["version"]}/download" # Use static.crates.io (CDN) instead of crates.io/api to avoid the 1 req/sec # rate limit on the API servers. return f"https://static.crates.io/crates/{pkg["name"]}/{pkg["version"]}/download" def download_tarball(session: requests.Session, pkg: dict[str, Any], out_dir: Path) -> None: Loading Loading
pkgs/build-support/rust/fetch-cargo-vendor-util-v2.py +3 −1 Original line number Diff line number Diff line Loading @@ -69,7 +69,9 @@ def get_download_url_for_tarball(pkg: dict[str, Any]) -> str: if pkg["source"] != "registry+https://github.com/rust-lang/crates.io-index": raise Exception("Only the default crates.io registry is supported.") return f"https://crates.io/api/v1/crates/{pkg["name"]}/{pkg["version"]}/download" # Use static.crates.io (CDN) instead of crates.io/api to avoid the 1 req/sec # rate limit on the API servers. return f"https://static.crates.io/crates/{pkg["name"]}/{pkg["version"]}/download" def download_tarball(session: requests.Session, pkg: dict[str, Any], out_dir: Path) -> None: Loading