BoundaryML/baml · error

manifest for {version} has target set {actual:?}; expected {

Error message

manifest for {version} has target set {actual:?}; expected {expected:?}

What it means

During release manifest validation, the set of artifact target keys in the manifest is compared against SUPPORTED_RELEASE_TARGETS. If they differ (missing target, extra target, or typo), the manifest is rejected. This ensures every release ships exactly the full, expected matrix of platform binaries.

Source

Thrown at baml_language/crates/baml_release/src/manifest.rs:144

fn validate_schema(schema: u32) -> anyhow::Result<()> {
    if schema > MANIFEST_SCHEMA {
        anyhow::bail!(
            "manifest schema {schema} is newer than this wrapper; run `baml self-update`"
        );
    }
    if schema != MANIFEST_SCHEMA {
        anyhow::bail!("unsupported manifest schema {schema}");
    }
    Ok(())
}

fn validate_artifacts(version: &str, artifacts: &BTreeMap<String, Artifact>) -> anyhow::Result<()> {
    let expected: std::collections::BTreeSet<_> =
        SUPPORTED_RELEASE_TARGETS.iter().copied().collect();
    let actual: std::collections::BTreeSet<_> = artifacts.keys().map(String::as_str).collect();
    if actual != expected {
        anyhow::bail!("manifest for {version} has target set {actual:?}; expected {expected:?}");
    }
    for (target, artifact) in artifacts {
        validate_artifact(target, artifact)?;
    }
    Ok(())
}

fn validate_artifact(name: &str, artifact: &Artifact) -> anyhow::Result<()> {
    if !artifact.url.starts_with("https://") {
        anyhow::bail!("artifact {name} URL must use HTTPS");
    }
    validate_sha256(&artifact.sha256)?;
    Ok(())
}

fn validate_sdk(language: &str, package: &SdkPackage) -> anyhow::Result<()> {
    if package.registry.is_empty() || package.package.is_empty() || package.version.is_empty() {
        anyhow::bail!("sdk {language} has an empty registry, package, or version");

View on GitHub (pinned to bd85ce9dee)

Solutions

  1. Diff the manifest's artifact keys against SUPPORTED_RELEASE_TARGETS and add/remove entries so the sets match exactly
  2. Fix typos in target names in the manifest (e.g. wrong triple spelling)
  3. If a new platform is intentional, update SUPPORTED_RELEASE_TARGETS in baml_release and regenerate the manifest

Example fix

// before
[artifacts]
x86_64-unknown-linux-musl = { ... }
# aarch64-unknown-linux-musl missing

// after
[artifacts]
x86_64-unknown-linux-musl = { ... }
aarch64-unknown-linux-musl = { ... }
Defensive patterns

Strategy: validation

Validate before calling

let expected: std::collections::BTreeSet<_> = SUPPORTED_RELEASE_TARGETS.iter().copied().collect();
let actual: std::collections::BTreeSet<_> = manifest.artifacts.keys().cloned().collect();
assert_eq!(actual, expected, "artifact target sets differ: missing={:?} extra={:?}", expected.difference(&actual).collect::<Vec<_>>(), actual.difference(&expected).collect::<Vec<_>>());

Prevention

When it happens

Trigger: Calling validate() on a manifest whose artifacts map contains keys not exactly equal to SUPPORTED_RELEASE_TARGETS — a missing target, a hand-added target, or a misspelled target name.

Common situations: Hand-editing baml_release manifest files; adding support for a new platform in artifacts without updating SUPPORTED_RELEASE_TARGETS (or vice versa after a library upgrade); merging manifests that dropped a target.

Understand the failure class

Background: Schema validation failed / invalid input schema: payload rejected because its shape doesn't match the expected schema — this error's family across 28 libraries.

Related errors


AI-assisted analysis of BoundaryML/baml@bd85ce9dee (2026-09-12). Data as JSON: /api/errors/ae39d9af6c413f2f. Report an issue: GitHub.