facebookincubator / reindeer

Reindeer is a tool to transform Rust Cargo dependencies into generated Buck build rules
MIT License
184 stars 30 forks source link

crates.io download URLs #43

Closed Turbo87 closed 7 months ago

Turbo87 commented 7 months ago

crates.io lately changed the way download requests are routed to reduce the load on their API servers (see https://blog.rust-lang.org/2024/03/11/crates-io-download-changes.html). This was done via https://github.com/rust-lang/crates.io-index/commit/0f11dc08f3ac7acfc356ed2d4e2711e6c023566c, but it looks like Buck2/reindeer has the URL patterns hardcoded at the moment (see https://github.com/facebookincubator/reindeer/blob/v2024.03.25.00/src/buckify.rs#L299-L302) so these requests are still going through the crates.io API.

It would be great if either the hardcoded pattern could be adjusted for the new URLs, or ideally the code adjusted to use the config.json file of the package index.