Hmbown/CodeWhale · error · anyhow::Error
bundle already installed; use `{CLI_COMMAND} update` or `rem
Error message
bundle already installed; use `{CLI_COMMAND} update` or `remove-bundle` What it means
Error "bundle already installed; use `{CLI_COMMAND} update` or `remove-bundle`" thrown in Hmbown/CodeWhale.
Source
Thrown at crates/tui/src/integrations/dsh/mod.rs:729
pub(crate) fn install_bundle(
paths: &DshPaths,
detection: &DshDetection,
runner: &dyn DshRunner,
availability: &BundleAvailability,
app: DshAppBundle,
) -> Result<DshBundleRecord> {
let pnpm_version = match availability {
BundleAvailability::Available { pnpm_version } => pnpm_version.clone(),
BundleAvailability::NotAvailable { reason } => {
anyhow::bail!("DSH plugin path not available: {reason}")
}
};
let mut doc = DshReceiptDocument::load(&paths.receipt)?;
let Some(mut record) = doc.current.take() else {
anyhow::bail!("DSH is not connected; run `{CLI_COMMAND} connect` first");
};
if record.bundle.is_some() {
anyhow::bail!("bundle already installed; use `{CLI_COMMAND} update` or `remove-bundle`");
}
let overlay_text = std::fs::read_to_string(&paths.overlay)
.with_context(|| format!("read {}", paths.overlay.display()))?;
if sha256_hex(overlay_text.as_bytes()) != record.overlay_sha256 {
anyhow::bail!("overlay is stale; run `{CLI_COMMAND} update` before install-bundle");
}
let patch_sha = bundle::write_bundle(&paths.bundle_dir, &codewhale_version(), &overlay_text)?;
let (app_source, outcomes) =
match bundle::install_into_profile(runner, detection, app, &paths.bundle_dir) {
Ok(ok) => ok,
Err(error) => {
// Leave DSH state as dsh left it; drop our half-written package.
let _ = bundle::remove_bundle_files(&paths.bundle_dir);
return Err(error);
}
};
let now = now_rfc3339();
let mut digest_input = String::new();View on GitHub (pinned to 8880682c63)
When it happens
Trigger: Thrown at crates/tui/src/integrations/dsh/mod.rs:729 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of Hmbown/CodeWhale@8880682c63 (2026-08-16).
Data as JSON: /api/errors/2b996d510d5d2f78.
Report an issue: GitHub.