jdx/mise · error
history is disabled (history.enabled = false); nothing can b
Error message
history is disabled (history.enabled = false); nothing can be restored
What it means
Restoring (rollback/undo) requires the history store, which only exists when the `history.enabled` setting is true. ensure_enabled checks Settings at the start of both entry points and bails when history is disabled, since nothing could have been recorded — and nothing can be restored — with the store closed.
Source
Thrown at src/system/history/replay.rs:359
dry_run: req.dry_run,
yes: req.yes,
// the protective checkpoint is authoritative: whatever the
// operation replaced, including a type change it forced, is
// restored exactly
force: true,
},
&store,
&tracked,
&entries,
live,
)
.await
}
/// Restoring needs the store, which `history.enabled = false` closes.
fn ensure_enabled() -> Result<()> {
if !crate::config::Settings::get().history.enabled {
bail!("history is disabled (history.enabled = false); nothing can be restored");
}
Ok(())
}
struct Execution {
kind: OperationKind,
command: String,
targets: Vec<Target>,
message: String,
to: Option<String>,
sources: Vec<OperationSource>,
undoes: Option<String>,
/// Directories to recreate after the plan is applied (an empty directory
/// an operation replaced leaves no trace in a snapshot).
restore_dirs: BTreeSet<PathBuf>,
restore_modes: BTreeMap<String, u32>,
dry_run: bool,
yes: bool,View on GitHub (pinned to afd2eddd3a)
Solutions
- Enable history: set `history.enabled = true` in settings (mise.toml [settings] or global settings)
- Remove an env override like MISE_HISTORY_ENABLED=false
- Check `mise settings get history.enabled` to confirm current value
Example fix
// before [settings] history.enabled = false // after [settings] history.enabled = true
Defensive patterns
Strategy: validation
Validate before calling
const settings = await getSettings();
if (!settings.history.enabled) {
throw new Error("history is disabled; enable history.enabled to restore");
} Type guard
const historyUsable = (s: Settings): s is Settings & { history: { enabled: true } } =>
s.history.enabled === true; Try / catch
try {
await rollback(req);
} catch (e) {
if (String(e).includes("history is disabled")) {
await enableHistory();
await rollback(req);
} else throw e;
} Prevention
- Check `mise settings get history.enabled` before restore workflows
- Avoid MISE_HISTORY_ENABLED=false in shells where you plan to undo
- Keep history enabled on machines where you rely on rollback
When it happens
Trigger: Calling rollback or undo while config has history.enabled = false (set in settings.toml, mise.toml [settings], or MISE_HISTORY_ENABLED=false env).
Common situations: Users disabled history for performance/disk reasons and later forget; CI or dotfiles sync templates set history.enabled=false; fresh setups inherit a config that disables history.
Related errors
- history is disabled (history.enabled = false)
- history is disabled (history.enabled = false)
- {bin_name} is a mise bin however it is not currently active.
- [dotfiles]."{}": source does not exist: {}
- [dotfiles]."{}": mode symlink-each requires a directory sour
AI-assisted analysis of jdx/mise@afd2eddd3a (2026-09-09).
Data as JSON: /api/errors/5febc4863bb66d66.
Report an issue: GitHub.