astral-sh/uv · error · anyhow::Error
Executable already exists at `{}` but could not be removed:
Error message
Executable already exists at `{}` but could not be removed: {err} What it means
Error "Executable already exists at `{}` but could not be removed: {err}" thrown in astral-sh/uv.
Source
Thrown at crates/uv/src/commands/python/install.rs:1156
);
} else {
debug!(
"Executable already exists for `{}` at `{}`. Use `--force` to replace it",
existing.key(),
target.simplified_display()
);
continue;
}
}
}
}
// Replace the existing link
if let Err(err) = fs_err::remove_file(&target) {
errors.push((
InstallErrorKind::Bin,
installation.key().clone(),
anyhow::anyhow!(
"Executable already exists at `{}` but could not be removed: {err}",
target.simplified_display()
),
));
continue;
}
if let Some(existing) = existing {
// Ensure we do not report installation of this executable for an existing
// key if we undo it
changelog
.installed_executables
.entry(existing.key().clone())
.or_default()
.remove(&target);
}
if let Err(err) =View on GitHub (pinned to f1a42680ff)
When it happens
Trigger: Thrown at crates/uv/src/commands/python/install.rs:1156 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of astral-sh/uv@f1a42680ff (2026-08-16).
Data as JSON: /api/errors/fc08d58bf16ba2e3.
Report an issue: GitHub.