jdx/mise · error
bootstrap plan contains resources with unknown state
Error message
bootstrap plan contains resources with unknown state
What it means
With `mise bootstrap --detailed-exitcode`, a plan whose resources have indeterminate ('unknown') state is treated as an error because mise cannot safely report whether changes would occur. This bail fires when output.summary.has_unknown() is true.
Solutions
- Rerun without --detailed-exitcode to see which resources are in an unknown state and why
- Fix the underlying check failures (connectivity, permissions, missing tools) that leave resources unknown
- Rerun bootstrap normally so state is refreshed, then retry with --detailed-exitcode
Defensive patterns
Strategy: validation
Validate before calling
if plan.summary.unknown > 0 { console.warn('unknown-state resources; fix before --detailed-exitcode') } Prevention
- Run plain `mise bootstrap` (no --detailed-exitcode) in CI first to surface unknowns
- Fix any failed resource checks before using detailed exit codes
- Treat exit code 2 vs this error distinctly in scripts
When it happens
Trigger: Running `mise bootstrap --detailed-exitcode` (or `--plan --detailed-exitcode`) when the plan output contains resources whose state could not be determined (summary.unknown > 0).
Common situations: A hook or resource check failed to run (e.g. remote host unreachable, missing permissions) so its state is unknown; the user asked for exit-code semantics but got ambiguity.
Understand the failure class
Background: "Must be a positive integer", "Invalid value", "Unsupported": the invalid-argument-value error family, when a library rejects the value you pass — this error's family across 35 libraries.
Related errors
- bootstrap from repository failed with
- --connect-timeout must be greater than zero
- --from was provided
- no remote targets configured; pass --host [user@]host or…
- refusing unsafe change to bootstrap user
AI-assisted analysis of jdx/mise@533346cc37 (2026-09-17).
Data as JSON: /api/errors/c55bbbba8eea88d0.
Report an issue: GitHub.
Appendix: source
Thrown at src/cli/bootstrap.rs:2453
.origin
.as_ref()
.map(|origin| origin.config.display_user())
.unwrap_or_default(),
]);
}
table.print()?;
miseprintln!(
"Plan: {} create, {} update, {} unchanged, {} remove, {} unknown",
output.summary.create,
output.summary.update,
output.summary.unchanged,
output.summary.remove,
output.summary.unknown,
);
}
if self.detailed_exitcode {
if output.summary.has_unknown() {
bail!("bootstrap plan contains resources with unknown state");
}
if output.summary.has_changes() {
return Err(crate::request_exit(2));
}
}
Ok(())
}
}
impl BootstrapConfigRoots {
async fn run(self) -> Result<()> {
let config = Config::get().await?;
let roots = config
.selected_bootstrap_config_maps()
.map(|(config_root, config_files)| {
let mut environments = vec![];
let mut declares = BootstrapConfigRootDeclarations::default();
for cf in config_files.values().rev() {View on GitHub (pinned to 533346cc37)