pbakaus/impeccable · error
[impeccable live] {msg}
Error message
[impeccable live] {msg}
What it means
`enter_live_root` validates the `--target` argument consumed from the CLI args before booting live mode. If `consume_target_arg` returns an error (missing or malformed target), the message is printed with the `[impeccable live]` prefix and the process exits with code 1. It is a CLI usage error, not a runtime failure.
Source
Thrown at crates/live/src/roots.rs:491
}
let v = v.to_string();
argv.remove(i);
return Ok(Some(v));
}
i += 1;
}
Ok(None)
}
/// JS: enterLiveRoot(cwd). Consumes `--target` from `args`, resolves the
/// governing roots, and moves `io.cwd` onto the appRoot. `Err(code)` means
/// the process must exit with that code (the message is already on stderr);
/// `Ok(None)` is the selection-ambiguity case (stay put).
pub fn enter_live_root(args: &mut Vec<String>, io: &mut Io) -> Result<Option<RootsManifest>, i32> {
let target = match consume_target_arg(args) {
Ok(t) => t,
Err(msg) => {
io.err(&format!("[impeccable live] {}\n", msg));
return Err(1);
}
};
let cwd = io.cwd.to_string_lossy().into_owned();
let resolved = resolve_live_roots(&cwd, target.as_deref(), io);
let Some(manifest) = resolved.manifest else {
return Ok(None);
};
let app_root = manifest.app_root.clone();
if jsp::resolve(&cwd, &[]) != jsp::resolve(&app_root, &[]) {
if !is_dir(&app_root) {
io.err(&format!(
"[impeccable live] resolved app root does not exist: {} (stale roots manifest? re-run the live boot, or pass --target <path>)\n",
app_root
));
return Err(1);
}
io.cwd = std::path::PathBuf::from(&app_root);View on GitHub (pinned to 2bc2879276)
Solutions
- Re-run with a valid explicit target: `impeccable live --target ./path-to-app`.
- Run `impeccable live --help` to see accepted target argument forms.
- If a shell variable supplies the path, quote it and verify it is non-empty: `echo "$TARGET"`.
- Run from the project/app directory and omit `--target` to use auto-detection.
Example fix
// before impeccable live --target= // after impeccable live --target ./webapp
Defensive patterns
Strategy: validation
Validate before calling
[ -n "$TARGET" ] && [ -d "$TARGET" ] && impeccable live --target "$TARGET" || echo 'TARGET must be a non-empty existing path'
Prevention
- Always quote --target values in scripts so empty variables are caught early.
- Verify the target path exists before passing it.
- Check `impeccable live --help` for the accepted target format.
When it happens
Trigger: Running `impeccable live` with a `--target` value that fails target-argument validation — e.g. an empty `--target`, an unexpected extra positional argument, or a value that cannot be resolved to a live root.
Common situations: Typos like `--target=` with no value; passing a flag where a path is expected; scripting the command with a variable that expands to empty; copying a command example that uses an unsupported target form.
Understand the failure class
Background: "Unknown argument", "Invalid value", and "must be one of": invalid CLI argument errors explained — this error's family across 35 libraries.
Related errors
- concept-seed: --candidate-count must be an integer from 5 to
- serve-question: --wait needs --key
- serve-question: --stop needs --key
- serve-question: --update needs --key and --payload
- serve-question: --start needs --payload <file>
AI-assisted analysis of pbakaus/impeccable@2bc2879276 (2026-09-08).
Data as JSON: /api/errors/117c77a4a3429b89.
Report an issue: GitHub.