mirror of
https://github.com/headroomlabs-ai/headroom.git
synced 2026-08-27 14:17:10 -04:00
deps: bump md-5 from 0.10.6 to 0.11.0 (#3146)
Bumps [md-5](https://github.com/RustCrypto/hashes) from 0.10.6 to 0.11.0. <details> <summary>Commits</summary> <ul> <li><a href="b5051e5a5e"><code>b5051e5</code></a> Cut new releases (<a href="https://redirect.github.com/RustCrypto/hashes/issues/812">#812</a>)</li> <li><a href="451c446d28"><code>451c446</code></a> md5: replace <code>force-soft</code> crate feature with <code>md5_backend</code> configuration flag...</li> <li><a href="2f00175af9"><code>2f00175</code></a> Release sha1 v0.11.0 (<a href="https://redirect.github.com/RustCrypto/hashes/issues/810">#810</a>)</li> <li><a href="07d370c4a0"><code>07d370c</code></a> sha1: refactor backends selection (<a href="https://redirect.github.com/RustCrypto/hashes/issues/808">#808</a>)</li> <li><a href="7c7cb76e8a"><code>7c7cb76</code></a> Fix md5 project link in README (<a href="https://redirect.github.com/RustCrypto/hashes/issues/809">#809</a>)</li> <li><a href="ffe093984c"><code>ffe0939</code></a> Release sha2 0.11.0 (<a href="https://redirect.github.com/RustCrypto/hashes/issues/806">#806</a>)</li> <li><a href="8991b65fe4"><code>8991b65</code></a> Use the standard order of the <code>[package]</code> section fields (<a href="https://redirect.github.com/RustCrypto/hashes/issues/807">#807</a>)</li> <li><a href="3d2bc57db4"><code>3d2bc57</code></a> sha2: refactor backends (<a href="https://redirect.github.com/RustCrypto/hashes/issues/802">#802</a>)</li> <li><a href="faa55fb836"><code>faa55fb</code></a> sha3: bump <code>keccak</code> to v0.2 (<a href="https://redirect.github.com/RustCrypto/hashes/issues/803">#803</a>)</li> <li><a href="d3e6489e56"><code>d3e6489</code></a> sha3 v0.11.0-rc.9 (<a href="https://redirect.github.com/RustCrypto/hashes/issues/801">#801</a>)</li> <li>Additional commits viewable in <a href="https://github.com/RustCrypto/hashes/compare/md-5-v0.10.6...md2-v0.11.0">compare view</a></li> </ul> </details> <br /> [](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- <details> <summary>Dependabot commands and options</summary> <br /> You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) </details> --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: JerrettDavis <mxjerrett@gmail.com>
This commit is contained in:
parent
c8db13d5ad
commit
c6dd823384
6 changed files with 16 additions and 8 deletions
6
Cargo.lock
generated
6
Cargo.lock
generated
|
|
@ -2698,12 +2698,12 @@ dependencies = [
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "md-5"
|
name = "md-5"
|
||||||
version = "0.10.6"
|
version = "0.11.0"
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "d89e7ee0cfbedfc4da3340218492196241d89eefb6dab27de5df917a6d2e78cf"
|
checksum = "69b6441f590336821bb897fb28fc622898ccceb1d6cea3fde5ea86b090c4de98"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"cfg-if",
|
"cfg-if",
|
||||||
"digest 0.10.7",
|
"digest 0.11.3",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
|
|
|
||||||
|
|
@ -25,7 +25,7 @@ tokenizers = "0.23"
|
||||||
hf-hub = { version = "0.5", default-features = false, features = ["ureq", "rustls-tls"] }
|
hf-hub = { version = "0.5", default-features = false, features = ["ureq", "rustls-tls"] }
|
||||||
# `md5` for the CCR cache_key. Python's compression_store hashes the original
|
# `md5` for the CCR cache_key. Python's compression_store hashes the original
|
||||||
# diff with MD5 truncated to 24 hex chars; we must match byte-for-byte.
|
# diff with MD5 truncated to 24 hex chars; we must match byte-for-byte.
|
||||||
md-5 = "0.10"
|
md-5 = "0.11"
|
||||||
# `sha2` for `_hash_field_name` in smart_crusher (SHA256 truncated to 16
|
# `sha2` for `_hash_field_name` in smart_crusher (SHA256 truncated to 16
|
||||||
# hex chars). Python uses `hashlib.sha256` so we need byte-exact parity.
|
# hex chars). Python uses `hashlib.sha256` so we need byte-exact parity.
|
||||||
sha2 = "0.11"
|
sha2 = "0.11"
|
||||||
|
|
|
||||||
|
|
@ -350,7 +350,7 @@ fn calculate_structural_uniqueness(item: &Value, all_items: &[Value]) -> f64 {
|
||||||
pub fn compute_item_hash(item: &Value) -> String {
|
pub fn compute_item_hash(item: &Value) -> String {
|
||||||
let content = python_json_dumps_sort_keys(item);
|
let content = python_json_dumps_sort_keys(item);
|
||||||
let digest = Md5::digest(content.as_bytes());
|
let digest = Md5::digest(content.as_bytes());
|
||||||
let hex = format!("{:x}", digest);
|
let hex: String = digest.iter().map(|byte| format!("{byte:02x}")).collect();
|
||||||
hex[..16].to_string()
|
hex[..16].to_string()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -305,7 +305,11 @@ fn item_content_hash(item: &Value, idx: usize) -> String {
|
||||||
_ => format!("__idx_{}__", idx),
|
_ => format!("__idx_{}__", idx),
|
||||||
};
|
};
|
||||||
let digest = Md5::digest(content.as_bytes());
|
let digest = Md5::digest(content.as_bytes());
|
||||||
format!("{:x}", digest)[..16].to_string()
|
digest
|
||||||
|
.iter()
|
||||||
|
.map(|byte| format!("{byte:02x}"))
|
||||||
|
.collect::<String>()[..16]
|
||||||
|
.to_string()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -390,7 +390,11 @@ impl<'a> SmartCrusherPlanner<'a> {
|
||||||
.unwrap_or("");
|
.unwrap_or("");
|
||||||
let truncated: String = msg.chars().take(50).collect();
|
let truncated: String = msg.chars().take(50).collect();
|
||||||
let digest = Md5::digest(truncated.as_bytes());
|
let digest = Md5::digest(truncated.as_bytes());
|
||||||
let hash = format!("{:x}", digest)[..8].to_string();
|
let hash = digest
|
||||||
|
.iter()
|
||||||
|
.map(|byte| format!("{byte:02x}"))
|
||||||
|
.collect::<String>()[..8]
|
||||||
|
.to_string();
|
||||||
clusters.entry(hash).or_default().push(i);
|
clusters.entry(hash).or_default().push(i);
|
||||||
}
|
}
|
||||||
// Keep up to 2 representatives from each cluster.
|
// Keep up to 2 representatives from each cluster.
|
||||||
|
|
|
||||||
|
|
@ -92,7 +92,7 @@ async-trait = "0.1"
|
||||||
# ordering — never persisted, never compared cross-host. Same crate
|
# ordering — never persisted, never compared cross-host. Same crate
|
||||||
# the core uses for the CCR cache_key, so no additional hash backend
|
# the core uses for the CCR cache_key, so no additional hash backend
|
||||||
# enters the dep tree.
|
# enters the dep tree.
|
||||||
md-5 = "0.10"
|
md-5 = "0.11"
|
||||||
|
|
||||||
[dev-dependencies]
|
[dev-dependencies]
|
||||||
tower = { workspace = true, features = ["util"] }
|
tower = { workspace = true, features = ["util"] }
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue