atuinsh/atuin · error
unknown tag
Error message
unknown tag: {tag} What it means
`atuin store rebuild <tag>` only knows how to rebuild a fixed set of record tags (history, kv, scripts, etc.). Any other tag passed on the CLI hits the catch-all match arm and bails with 'unknown tag'.
Solutions
- Run `atuin store rebuild` with no tag (or `atuin store status`) to see valid tags
- Fix the tag spelling against the match arms in the source
- Upgrade/downgrade atuin so the binary supports the record tag you need
Example fix
// before atuin store rebuild histroy // after atuin store rebuild history
Defensive patterns
Strategy: validation
Validate before calling
let valid = ["history", "kv", "scripts", "aliases", "dotfiles", "config"];
if !valid.contains(&tag.as_str()) {
eprintln!("unsupported tag: {tag}");
return Ok(());
}
Prevention
- Check `atuin store status` output for the exact tag strings
- Match atuin versions across machines so record tags are consistent
When it happens
Trigger: `atuin store rebuild <tag>` with a tag string not in the handler's match list, e.g. a typo like 'histroy' or a tag from a newer/older atuin version.
Common situations: Misspelled tag names, following docs for a different atuin version whose tag set differs, or attempting to rebuild a record type the binary was not built with.
Understand the failure class
Background: Invalid enum value errors: "Unknown type", "Invalid scope", "must be one of" — when a string is not on the library's allowed list — this error's family across 23 libraries.
Related errors
- A script named ' ' already exists
- `atuin history tail` requires Atuin to be built with the…
- `atuin hook ` is not supported. Use `atuin hook install `.
- `atuin update` is only available when atuin was installed…
- authentication canceled
AI-assisted analysis of atuinsh/atuin@900007c480 (2026-09-19).
Data as JSON: /api/errors/5531f710a585938e.
Report an issue: GitHub.
Appendix: source
Thrown at crates/atuin/src/command/client/store/rebuild.rs:39
settings: &Settings,
store: SqliteStore,
database: &Sqlite,
) -> Result<()> {
// keep it as a string and not an enum atm
// would be super cool to build this dynamically in the future
// eg register handles for rebuilding various tags without having to make this part of the
// binary big
match self.tag.as_str() {
"history" => {
self.rebuild_history(settings, store.clone(), database).await?;
}
"scripts" => {
self.rebuild_scripts(settings, store.clone()).await?;
}
tag => {
bail!("unknown tag: {tag}");
}
}
Ok(())
}
/// The daemon owns the rebuild when enabled; otherwise we rebuild locally.
async fn rebuild_history(
&self,
settings: &Settings,
store: SqliteStore,
database: &Sqlite,
) -> Result<()> {
#[cfg(feature = "daemon")]
if settings.daemon.enabled {
daemon::rebuild_history(settings).await?;
return Ok(());
}View on GitHub (pinned to 900007c480)