jdx/mise · error

description output exceeded

Error message

description output exceeded {} bytes

What it means

run_with_limits caps the describe command's captured output at DIFF_LIMIT bytes. If the output exceeds this cap, mise bails with 'description output exceeded N bytes' instead of storing or processing an oversized description. The limit keeps history records and memory use bounded.

Solutions

  1. Trim the describe command's output (head -n, cut, jq projections) so it emits a concise one-line description
  2. Increase DIFF_LIMIT / the configured output size cap if large output is legitimate
  3. Redirect any diagnostic output to stderr or a file so only the intended description line reaches stdout

Example fix

# before: dumps everything
the-command --dump-all

# after: emit a bounded summary
the-command --summary | head -c 2000
Defensive patterns

Strategy: validation

Validate before calling

out=$(describe-command); [ ${#out} -le 8000 ] || echo "describe output too large; trim it" >&2

Prevention

When it happens

Trigger: The describe command prints more than DIFF_LIMIT bytes to stdout, e.g. dumping whole logs, full directory listings, or verbose tool output as the 'description'.

Common situations: Describe scripts that `cat` large files or include debug dumps; commands whose verbosity increased after an update; capturing binary output by accident.

Understand the failure class

Background: payload too large / request exceeds maximum size: why libraries cap bytes and how to fix oversize payloads — this error's family across 50 libraries.

Related errors


AI-assisted analysis of jdx/mise@533346cc37 (2026-09-17). Data as JSON: /api/errors/e9fcb20c35b721f6. Report an issue: GitHub.

Appendix: source

Thrown at src/system/history/describe_command.rs:179

        }
        if started.elapsed() >= timeout {
            // the shell and whatever it started; the reader thread ends
            // with the last writer of the pipe, so it is not waited for
            active.0.kill();
            let _ = child.kill();
            let _ = child.wait();
            bail!("took longer than {}s", timeout.as_secs());
        }
        std::thread::sleep(Duration::from_millis(100));
    };
    // a descendant that outlived the shell and kept the pipe is not the
    // shell's answer: the output is waited for a moment, not forever
    let Ok(output) = receiver.recv_timeout(output_grace) else {
        active.0.kill();
        bail!("a process it started kept its output open");
    };
    if output.len() > DIFF_LIMIT {
        bail!("description output exceeded {} bytes", DIFF_LIMIT);
    }
    if !status.success() {
        bail!("exited with {status}");
    }
    let Some(line) = first_line(&output) else {
        return Ok(None);
    };
    annotate(
        store,
        entry,
        Annotation {
            description: Some(line.clone()),
            description_source: Some(DescriptionSource::Command),
            labels: None,
            updated_at: store::now_rfc3339(),
        },
    )?;
    Ok(Some(line))

View on GitHub (pinned to 533346cc37)