xai-org/grok-build · error · ManagedConfigError
{} exited with {status}
Error message
{} exited with {status} What it means
The validator child process finished but with a failure: it reported an error through its output/exit path, so validation returns '{path} exited with {status}'. The library surfaces the validator's own failure status plus any teardown error, meaning the file being validated did not pass the external tool's checks or the tool itself crashed.
Source
Thrown at crates/codegen/xai-grok-config/src/managed_text/validator.rs:102
path,
format!("{} exited with {status}", validator.program.display()),
None,
));
}
Ok(None) if started.elapsed() < validator.timeout => {
std::thread::sleep(Duration::from_millis(10));
}
Ok(None) => {
let teardown = ops.teardown(&mut child, group.as_ref()).err();
return Err(validation_error(
path,
format!("timed out after {:?}", validator.timeout),
teardown,
));
}
Err(source) => {
let teardown = ops.teardown(&mut child, group.as_ref()).err();
return Err(validation_error(path, source.to_string(), teardown));
}
}
}
}
fn validation_error(path: &Path, primary: String, teardown: Option<String>) -> ManagedConfigError {
let reason = match teardown {
Some(teardown) => format!("{primary}; process teardown also failed: {teardown}"),
None => primary,
};
ManagedConfigError::Validation {
path: path.to_path_buf(),
reason,
}
}
fn teardown_child(
child: &mut Child,View on GitHub (pinned to bc7f02eddd)
Solutions
- Read the captured validator output/teardown detail to see the exact exit status and diagnostics.
- Run the validator command manually against the file to reproduce and fix the underlying syntax/quality error it reports.
- Verify the validator binary is installed and on PATH in the environment where validation runs.
- Update the configured validator command/flags to match the installed tool's version.
Example fix
// before: file has a syntax error, validator exits 1 // myconf.toml key = value // after: fix the file key = "value"
Defensive patterns
Strategy: validation
Validate before calling
# validate the file content and tool availability before invoking managed validation
command -v $VALIDATOR_BIN || { echo "validator not installed"; exit 1; }
$VALIDATOR_BIN --check /path/to/file.conf Try / catch
match validate_temp(path) {
Err(ManagedConfigError::Validation(msg)) if msg.contains("exited with") => {
eprintln!("validator rejected the file: {msg}");
eprintln!("run the validator manually for full diagnostics");
}
Err(e) => return Err(e),
Ok(v) => apply(v),
} Prevention
- Lint/validate config files in the editor before running managed validation
- Ensure the validator binary is installed and on PATH in every environment
- Pin validator versions and keep configured flags in sync
- Capture and read the validator's full output on failure
When it happens
Trigger: The spawned validator command exits non-zero or signals (e.g. `ExitStatus` failure) while validating the config file — syntax errors in the target file, missing validator dependencies, bad CLI arguments in the configured command, or the binary crashing.
Common situations: Malformed config file content that the linter rejects; validator binary not installed or not on PATH in a different environment (CI vs dev); validator invoked with flags that changed between versions; resource limits (OOM) killing the process.
Related errors
- timed out after {:?}
- Profile '{name}' extends '{base_name}', but 'off'/'none' is
- Profile '{name}' extends '{base_name}', but custom profiles
- invalid deny glob {glob:?}: {e}
- hook JSON alias validation failed: {e}
AI-assisted analysis of xai-org/grok-build@bc7f02eddd (2026-08-31).
Data as JSON: /api/errors/dba89c154bac403f.
Report an issue: GitHub.