vectordotdev/vector · error
{}
Error message
{} What it means
A single example validation case failed: `vdev` ran the built `vector` binary against the generated example config and it exited non-zero. The error message is the summarized relevant portion of Vector's stdout/stderr produced by `summarize_error`.
Solutions
- Read the summarized error text in the message; it contains Vector's own validation error.
- Fix the source docs/metadata that generates the example (or the component config schema).
- Regenerate with `make generate-docs` and re-run the check.
Defensive patterns
Strategy: try-catch
Validate before calling
let out = Command::new("./target/debug/vector").arg("validate").arg("--no-environment").arg(config).output()?;
assert!(out.status.success(), "{}", String::from_utf8_lossy(&out.stderr)); Try / catch
let output = cmd.output().context("failed to run vector")?;
if !output.status.success() {
bail!("vector validate failed (exit {:?}): {}", output.status.code(), String::from_utf8_lossy(&output.stderr));
} Prevention
- Run the failing example config through `vector validate` locally to see the full error.
- Keep examples regenerated after schema changes.
- Ensure required features are compiled into the validation binary.
When it happens
Trigger: `vector validate <example>` returns a non-zero exit code for one validation case — e.g. schema errors, unknown fields, failed component builds — and `validate_case` bails with the summarized output.
Common situations: Generated example references a config option that no longer exists, an option changed type, or the example requires features not compiled into the debug binary.
Understand the failure class
Background: "Invalid value" and "allowed values are" config errors: what your library rejected and how to fix it — this error's family across 41 libraries.
Related errors
- completing more than 2^16 data files at a time is obviously…
- component name must be non-empty
- config should not have any errors
- The drain_timeout_ms
- UNSUPPORTED_DYNAMIC_FEATURE_SELECTOR
AI-assisted analysis of vectordotdev/vector@bdb87aeaa4 (2026-09-16).
Data as JSON: /api/errors/dae432be7e8f81a7.
Report an issue: GitHub.
Appendix: source
Thrown at vdev/src/commands/check/component_examples.rs:459
let output = Command::new(vector_bin)
.current_dir(repo_root)
.args(["validate", "--no-environment", "--skip-healthchecks"])
.arg(temporary.path())
.output()
.with_context(|| format!("Failed to validate {}", case.key))?;
if output.status.success() {
return Ok(());
}
let stderr = String::from_utf8_lossy(&output.stderr);
let stdout = String::from_utf8_lossy(&output.stdout);
let details = if stderr.trim().is_empty() {
&stdout
} else {
&stderr
};
bail!("{}", summarize_error(details))
}
fn summarize_error(error: &str) -> &str {
error
.lines()
.find(|line| {
let line = line.trim();
!line.contains("Failed to load") && !line.starts_with("error[") && line.contains("x ")
})
.or_else(|| error.lines().find(|line| !line.trim().is_empty()))
.unwrap_or(error)
.trim()
.trim_start_matches("x ")
}
#[cfg(test)]
mod tests {
use super::*;View on GitHub (pinned to bdb87aeaa4)