atuinsh/atuin · error
unknown version {version:?}
Error message
unknown version {version:?} What it means
Error "unknown version {version:?}" thrown in atuinsh/atuin.
Source
Thrown at crates/atuin-client/src/history.rs:284
encode::write_str(&mut output, &self.command)?;
encode::write_str(&mut output, &self.cwd)?;
encode::write_str(&mut output, &self.session)?;
encode::write_str(&mut output, &self.hostname)?;
encode::write_optional(
&mut output,
self.deleted_at.map(|d| d.unix_timestamp_nanos() as u64),
encode::write_u64,
)?;
encode::write_str(&mut output, self.author.as_str())?;
encode::write_optional(&mut output, self.intent.as_deref(), encode::write_str)?;
encode::write_optional(&mut output, self.shell.as_deref(), encode::write_str)?;
Ok(DecryptedData(output.into_vec()))
}
pub fn deserialize(bytes: &[u8], version: &str) -> Result<History> {
let Some(version) = Version::from_name(version) else {
bail!("unknown version {version:?}");
};
let mut bytes = Bytes::new(bytes);
let real_version = decode::read_u16(&mut bytes).map_err(DecodeError::from)?;
if real_version != version.as_int() {
bail!("expected to decode {version} record, found v{real_version}");
}
let nfields = decode::read_array_len(&mut bytes).map_err(DecodeError::from)?;
let min_fields = version.min_fields();
if nfields < min_fields || version.max_fields().is_some_and(|max| nfields > max) {
bail!("unexpected number of fields ({nfields}) for history version {version}");
}
let id = decode::read_string(&mut bytes)?;
let timestamp = decode::read_u64(&mut bytes).map_err(DecodeError::from)?;
let duration = decode::read_int(&mut bytes).map_err(DecodeError::from)?;View on GitHub (pinned to 15fe1318f1)
Solutions
- Upgrade atuin to a version that understands this history record version.
When it happens
Trigger: Fires when deserializing a history record whose version byte matches no known history format version.
Common situations: See trigger scenarios.
AI-assisted analysis of atuinsh/atuin@15fe1318f1 (2026-08-19).
Data as JSON: /api/errors/310a57ad614c2acd.
Report an issue: GitHub.