atuinsh/atuin · error
You are not logged in to a sync server - cannot show sync…
Error message
You are not logged in to a sync server - cannot show sync status
What it means
`atuin sync status` requires an authenticated session with a sync server. If settings indicate the user is not logged in (no token/identity), the command bails early because it cannot query sync state.
Solutions
- Run `atuin register` to create an account or `atuin login` with existing credentials
- Import your atuin key (`atuin key` output from the old machine) and log in
- Skip `sync status` when offline/not registered - guard scripts with a login check
Example fix
// before atuin sync status # fails when not logged in // after atuin login -u <username> && atuin sync status
Defensive patterns
Strategy: try-catch
Validate before calling
if !settings.logged_in().await? {
eprintln!("skipping: not logged in");
return Ok(());
}
Try / catch
match atuin_sync_status().await {
Err(e) if e.to_string().contains("not logged in") => eprintln!("not logged in, skipping"),
other => other?,
}
Prevention
- Run `atuin register`/`atuin login` before scripting sync commands
- Back up and restore ~/.local/share/atuin/key when migrating machines
When it happens
Trigger: Running `atuin sync status` before ever running `atuin register` or `atuin login`, or after the local key/session was removed.
Common situations: Fresh machine without importing the atuin key, cleared config directory, or a CI/environment where atuin was never registered.
Related errors
- unexpected two-factor requirement during registration
- 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…
AI-assisted analysis of atuinsh/atuin@900007c480 (2026-09-19).
Data as JSON: /api/errors/6c0dfd34574b3af3.
Report an issue: GitHub.
Appendix: source
Thrown at crates/atuin/src/command/client/sync/status.rs:11
use atuin_client::api_client;
use atuin_client::settings::Settings;
use atuin_common::time::DurationExt;
use colored::Colorize;
use eyre::{Result, bail};
use crate::{SHA, VERSION};
pub async fn run(settings: &Settings) -> Result<()> {
if !settings.logged_in().await? {
bail!("You are not logged in to a sync server - cannot show sync status");
}
let caps = api_client::caps_client(settings)?;
let client = api_client::Client::new(
settings.sync_address.clone(),
&settings.sync_auth_token().await?,
settings.network_connect_timeout,
settings.network_timeout,
&settings.extra_headers,
caps,
)?;
let me = client.me().await?;
let last_sync = Settings::last_sync().await?;
println!("Atuin v{VERSION} - Build rev {SHA}\n");
println!("{}", "[Local]".green());View on GitHub (pinned to 900007c480)