jdx/mise · error

vfox plugin artifacts must not declare host requirements

Error message

vfox plugin artifacts must not declare host requirements

What it means

The vfox plugin contract rejects artifacts whose manifest declares a `requires` section (host requirements such as minimum vfox/mise versions or runtime features). `validate_artifact` in src/plugins/packslip.rs enforces `artifact.requires.is_none()` because mise embeds vfox and manages compatibility itself.

Source

Thrown at src/plugins/packslip.rs:194

pub(crate) fn validate_artifact(artifact: &packslip::model::Artifact) -> Result<()> {
    ensure!(
        artifact
            .extensions
            .get("mise")
            .and_then(|v| v.get("plugin"))
            .and_then(|v| v.as_str())
            == Some("vfox"),
        "packslip artifact must declare extensions.mise.plugin = vfox"
    );
    ensure!(
        artifact.bin.is_empty(),
        "vfox plugin artifacts must not declare executables"
    );
    ensure!(
        artifact.os.is_none() && artifact.arch.is_none() && artifact.libc.is_none(),
        "vfox plugin artifact must be portable"
    );
    ensure!(
        artifact.requires.is_none(),
        "vfox plugin artifacts must not declare host requirements"
    );
    ensure!(
        matches!(artifact.format.as_deref(), Some("tar.gz" | "tgz")),
        "vfox plugin artifacts currently require tar.gz format"
    );
    Ok(())
}

/// Reject links and special files before extraction, including links whose
/// targets might otherwise be resolved while unpacking a later archive entry.
pub(crate) fn validate_archive(path: &Path) -> Result<()> {
    let reader = flate2::read::GzDecoder::new(std::fs::File::open(path)?);
    let mut archive = jdx_tar::Archive::new(reader);
    for entry in archive.entries()? {
        let entry = entry?;
        ensure!(

View on GitHub (pinned to afd2eddd3a)

Solutions

  1. Delete the `requires` section from the plugin artifact's manifest and republish.
  2. Document any minimum-version constraints in the plugin README or repository metadata instead of the artifact manifest.
  3. If version-gated behavior is needed, implement a runtime check inside the plugin's Lua code.

Example fix

// before (manifest)
[artifacts.plugin.requires]
vfox = ">=0.3"

// after (manifest)
[artifacts.plugin]
# requires section removed
Defensive patterns

Strategy: validation

Validate before calling

jq -e '.artifacts[] | select(.extensions.mise.plugin == "vfox" and (.requires == null))' manifest.json \
  || { echo "vfox plugin artifact must not declare requires"; exit 1; }

Prevention

When it happens

Trigger: A packslip artifact manifest contains a `requires` object/table (e.g. requires.vfox = ">=0.3" or host requirement entries) while the artifact is being validated as a vfox plugin.

Common situations: Author copied a manifest shape from another plugin ecosystem (asdf/vfox upstream metadata) that declares host requirements; a release generator emits requires blocks unconditionally.

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@afd2eddd3a (2026-09-09). Data as JSON: /api/errors/d7a44d93f5ad21cc. Report an issue: GitHub.