jdx/mise · error
pacman cannot install a pinned version
Error message
pacman cannot install a pinned version ('{p}'): Arch repositories only provide the latest version What it means
Arch repositories only host the latest version of each package and pacman has no syntax to install an older one, so mise refuses `install` calls whose request list contains a version-pinned package. The pinned package can still be *checked* (status), but it cannot be *satisfied* through pacman. Normally the CLI filters pinned requests out before reaching the backend; hitting this error means a pinned request leaked through.
Solutions
- Remove the version pin for that tool (use bare `tool = "latest"` or just the name) and let Arch provide its current version.
- Switch the tool to a mise-managed backend (aqua/github/cargo/etc.) that supports arbitrary versions, via `mise use aqua:<owner/repo>` or similar.
- Install the specific older version manually with pacman-compatible means (e.g. a cached .pkg.tar.zst via `pacman -U`) outside mise, then let mise detect it as installed.
- Update mise — newer CLI versions filter pinned requests before invoking the pacman backend.
Example fix
# before (mise.toml) [tools] ripgrep = "14.1.0" # after [tools] ripgrep = "latest" # or use a versioned backend: mise use aqua:BurntSushi/ripgrep
Defensive patterns
Strategy: validation
Validate before calling
// Refuse pinned versions for pacman-backed tools before invoking mise
const pacmanTools = { ripgrep: 'pacman' };
for (const [tool, version] of Object.entries(tools)) {
if (pacmanTools[tool] && version && version !== 'latest') {
throw new Error(`${tool}: remove the pin or switch to a backend that supports versions (aqua:, cargo:, ...)`);
}
} Type guard
const isPinned = (req) => typeof req === 'string' && /[0-9]/.test(req) && req !== 'latest';
Try / catch
try { await miseInstall('ripgrep@14.1.0') } catch (e) { if (String(e).includes('cannot install a pinned version')) { console.error('Use `mise use aqua:BurntSushi/ripgrep` for pinned installs'); } else throw e; } Prevention
- Never pin versions on tools resolved to system package backends (pacman/apk/dnf); pin only with versioned backends.
- Keep mise updated so the CLI's pinned-request filtering stays in effect.
- If you need an exact version on Arch, use `mise use aqua:<owner/repo>` or `mise use cargo:<crate>` instead.
- Document in team mise.toml why a tool is unpinned to prevent someone adding a pin later.
When it happens
Trigger: Calling the pacman backend's `install` directly (or via an API path that does not pre-filter) with a `PackageRequest` whose `version` field is `Some`, e.g. `mise install` of a tool whose mise.toml entry pins a version but which is backed by pacman.
Common situations: A mise.toml/.tool-versions entry pins e.g. `ripgrep@14.1.0` while the tool resolves to the pacman backend; an older mise version or a plugin path bypasses the pinned-request filter; a user hand-edits config to add a version to a system-package tool.
Understand the failure class
Background: UnsupportedOperationException and "is not supported" errors: when a library deliberately refuses a call — this error's family across 30 libraries.
Related errors
- flatpak cannot upgrade a pinned version
- mas cannot install a pinned version
- Nix cannot install package version pin
- pacman -Q failed
- pacman -Qi failed
AI-assisted analysis of jdx/mise@533346cc37 (2026-09-17).
Data as JSON: /api/errors/ef7d235bb18aca0f.
Report an issue: GitHub.
Appendix: source
Thrown at src/system/packages/pacman.rs:494
let provider = apply_provider_query(status, &packages, constraint_satisfied)?;
debug!(
"pacman: {} is satisfied by installed provider {}",
status.request.name, provider.name,
);
}
Ok(statuses)
}
fn supports_version_pins(&self) -> bool {
false
}
async fn install(&self, pkgs: &[PackageRequest], opts: &InstallOpts) -> Result<()> {
// Arch repos only carry the latest version — pacman has no syntax to
// install an older one, so a pin can be checked (status) but not
// satisfied here; the CLI filters pinned requests out before calling
if let Some(p) = pkgs.iter().find(|p| p.version.is_some()) {
bail!(
"pacman cannot install a pinned version ('{p}'): Arch repositories only \
provide the latest version"
);
}
if opts.update || self.dbs_missing() {
self.refresh(opts)?;
}
let mut args = vec![
"-S".to_string(),
"--noconfirm".to_string(),
"--needed".to_string(),
// `--` keeps package operands from being parsed as pacman options
"--".to_string(),
];
args.extend(pkgs.iter().map(|p| p.name.clone()));
if opts.dry_run {
miseprintln!("{}", sudo::argv("pacman", &args).join(" "));
return Ok(());View on GitHub (pinned to 533346cc37)