jdx/mise · error

unsupported remote cache client metadata version

Error message

unsupported remote cache client metadata version

What it means

When reading a task cache entry from a remote (CAS-based) store, the stored client metadata blob declares a version field; into_manifest only understands version 1. A metadata blob written by a newer (or otherwise incompatible) client version cannot be interpreted, so mise bails instead of misreading it.

Solutions

  1. Upgrade mise so the client understands the metadata version used on the remote
  2. Clear/re-populate the remote cache with entries written by the current version
  3. Pin all machines sharing the remote cache to the same mise version
Defensive patterns

Strategy: try-catch

Try / catch

match cache_get(key) {
    Err(e) if e.to_string().contains("metadata version") => {
        // fall back to rebuilding locally or repopulating the cache
        rebuild_locally();
    }
    r => r?,
}

Prevention

When it happens

Trigger: Fetching a cache entry via TaskCacheStore::get whose remote client metadata JSON has version != 1 — e.g. the remote cache was populated by a newer mise version with an upgraded metadata schema.

Common situations: Mixed-version fleets/CI sharing one remote cache; cache entries persisted before a mise upgrade changed the schema; corrupted metadata blob edited by tooling.

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 jdx/mise@533346cc37 (2026-09-17). Data as JSON: /api/errors/f886f7b31cda0f68. Report an issue: GitHub.

Appendix: source

Thrown at src/task/task_cache_store.rs:62

    fn from_manifest(manifest: &CacheManifest) -> Self {
        Self {
            execution_duration_ns: manifest.execution_duration_ns,
            output: manifest.output.clone(),
            restored_bytes: manifest.restored_bytes,
            roots: manifest
                .roots
                .iter()
                .map(|path| path.to_string_lossy().replace('\\', "/"))
                .collect(),
            task_identity: manifest.task_identity.clone(),
            kind: "task".to_string(),
            version: 1,
        }
    }

    fn into_manifest(self, key: &str) -> Result<CacheManifest> {
        if self.version != 1 {
            bail!("unsupported remote cache client metadata version");
        }
        if self.kind != "task" {
            bail!("remote cache metadata kind is not a task");
        }
        let roots = self.roots.into_iter().map(PathBuf::from).collect();
        Ok(CacheManifest {
            format: CACHE_FORMAT_VERSION,
            key: key.to_string(),
            task_identity: self.task_identity,
            artifact_checksum: None,
            roots,
            output: self.output,
            restored_bytes: self.restored_bytes,
            execution_duration_ns: self.execution_duration_ns,
        })
    }
}

View on GitHub (pinned to 533346cc37)