jdx/mise · error
{}: API metadata has no formula checksum
Error message
{}: API metadata has no formula checksum What it means
mise downloads the formula's .rb pinned to the API snapshot commit and verifies it against the sha256 recorded in ruby_source_checksum. If that checksum is absent from the API metadata, the formula file cannot be verified and check_buildable rejects the source build — evaluating an unverified formula against the source metadata could build the wrong thing.
Source
Thrown at src/system/packages/brew/source.rs:91
if src.checksum.is_none() {
bail!("{}: source archive has no sha256 in the API", formula.name);
}
// the formula .rb must be pinned to the API snapshot's commit and
// verifiable — evaluating a newer/unverified formula against older
// source metadata would build the wrong thing
if formula.ruby_source_path.is_none() {
bail!("{}: API metadata has no ruby_source_path", formula.name);
}
if formula.tap_git_head.is_none() {
bail!("{}: API metadata has no tap_git_head", formula.name);
}
if formula
.ruby_source_checksum
.as_ref()
.and_then(|c| c.sha256.as_deref())
.is_none()
{
bail!("{}: API metadata has no formula checksum", formula.name);
}
Ok(())
}
/// Build a formula from source into its keg and link it.
pub async fn build(
rf: &ResolvedFormula,
closure: &[ResolvedFormula],
pr: &dyn SingleReport,
) -> Result<()> {
let formula = &rf.formula;
let name = &formula.name;
let pkg_version = formula.pkg_version()?;
check_buildable(formula)?;
pr.set_message("resolve ruby".to_string());
let ruby = ruby_bin().await?;
let formula_rb = fetch_formula_rb(rf, pr).await?;View on GitHub (pinned to 9dcfcaa0dc)
Solutions
- Clear mise's Homebrew API cache and retry to refresh metadata
- Update mise to the latest version
- Install the formula with native Homebrew, which does not depend on mise's verification chain
Defensive patterns
Strategy: retry
Try / catch
match check_buildable(&formula) {
Err(e) if e.to_string().contains("formula checksum") => {
clear_homebrew_api_cache()?;
check_buildable(&formula)
}
other => other,
} Prevention
- Never skip the .rb verification these errors guard — stale metadata builds the wrong thing
- Refresh the Homebrew API cache before source builds on machines used infrequently
- Fall back to native brew if the formula checksum never appears in the API
When it happens
Trigger: formula.ruby_source_checksum (or its sha256 field) is None during check_buildable on a source-build path.
Common situations: Partial or stale Homebrew API cache; upstream metadata anomalies; taps that do not publish formula checksums.
Related errors
- {}: formula has no stable source URL
- {}: source archive has no sha256 in the API
- {}: API metadata has no ruby_source_path
- {}: API metadata has no tap_git_head
- {}: source uses the {using:?} download strategy, which mise
AI-assisted analysis of jdx/mise@9dcfcaa0dc (2026-08-17).
Data as JSON: /api/errors/831581c08f8e9032.
Report an issue: GitHub.