jdx/mise · error
unsupported remote cache digest algorithm
Error message
unsupported remote cache digest algorithm
What it means
Digest::validate on a remote-cache descriptor rejected the `algorithm` field: only "blake3" and "sha256" are recognized, so any other string (typo, new algorithm, corrupted metadata) fails validation before the digest is used for cache matching or blob transfer.
Solutions
- Emit digests with algorithm "blake3" (the default produced by Digest::blake3*) or "sha256"
- Regenerate the cache entry with the current mise version if the metadata was written by an incompatible client
- Report the mismatch if the server advertises an algorithm mise does not support
Defensive patterns
Strategy: validation
When it happens
Trigger: Thrown at crates/mise-cache-core/src/lib.rs:120 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of jdx/mise@533346cc37 (2026-09-17).
Data as JSON: /api/errors/7b8b3404bd7064d4.
Report an issue: GitHub.
Appendix: source
Thrown at crates/mise-cache-core/src/lib.rs:120
algorithm: "blake3".into(),
hash: blake3::hash(bytes).to_hex().to_string(),
size: bytes.len() as u64,
}
}
/// Hash a file while counting the bytes read in the same streaming pass.
pub fn blake3_file(path: &Path) -> Result<Self> {
let (hash, size) = hash_file_blake3(path)?;
Ok(Self {
algorithm: "blake3".into(),
hash,
size,
})
}
pub fn validate(&self) -> Result<()> {
if self.algorithm != "blake3" && self.algorithm != "sha256" {
bail!("unsupported remote cache digest algorithm");
}
if self.hash.len() != 64
|| !self
.hash
.bytes()
.all(|byte| byte.is_ascii_digit() || (b'a'..=b'f').contains(&byte))
{
bail!("invalid remote cache digest");
}
Ok(())
}
pub fn matches_bytes(&self, bytes: &[u8]) -> Result<bool> {
self.validate()?;
if self.size != bytes.len() as u64 {
return Ok(false);
}
let hash = match self.algorithm.as_str() {View on GitHub (pinned to 533346cc37)