Add Git resolver in lieu of static hash map (#3954)

## Summary

This PR removes the static resolver map:

```rust
static RESOLVED_GIT_REFS: Lazy<Mutex<FxHashMap<RepositoryReference, GitSha>>> =
    Lazy::new(Mutex::default);
```

With a `GitResolver` struct that we now pass around on the
`BuildContext`. There should be no behavior changes here; it's purely an
internal refactor with an eye towards making it cleaner for us to
"pre-populate" the list of resolved SHAs.
This commit is contained in:
Charlie Marsh 2024-05-31 22:44:42 -04:00 committed by GitHub
parent a0652921fc
commit b7d77c04cc
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
31 changed files with 475 additions and 384 deletions

View file

@ -1,7 +1,6 @@
pub use distribution_database::{DistributionDatabase, HttpArchivePointer, LocalArchivePointer};
pub use download::LocalWheel;
pub use error::Error;
pub use git::{git_url_to_precise, is_same_reference};
pub use index::{BuiltWheelIndex, RegistryWheelIndex};
pub use metadata::{ArchiveMetadata, Metadata};
pub use reporter::Reporter;
@ -12,7 +11,6 @@ mod archive;
mod distribution_database;
mod download;
mod error;
mod git;
mod index;
mod locks;
mod metadata;