{"record":{"id":"241e465cd8591238","repo":"atuinsh/atuin","slug":"hub-registration-failed-with-status-status","errorCode":null,"errorMessage":"Hub registration failed with status {status}","messagePattern":"Hub registration failed with status (.+?)","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"crates/atuin-client/src/auth.rs","lineNumber":353,"sourceCode":"            .send()\n            .await\n            .context(\"failed to connect to Atuin Hub\")?;\n\n        let status = resp.status();\n\n        if status.is_success() {\n            let reg: RegisterResponse = resp.json().await?;\n            return Ok(AuthResponse::Success {\n                session: reg.session,\n                auth_type: reg.auth,\n            });\n        }\n\n        if let Ok(err) = resp.json::<HubErrorResponse>().await {\n            bail!(\"{}\", err.reason);\n        }\n\n        bail!(\"Hub registration failed with status {status}\");\n    }\n\n    async fn change_password(\n        &self,\n        current_password: &str,\n        new_password: &str,\n        totp_code: Option<&str>,\n    ) -> Result<MutateResponse> {\n        let hub_token = self.hub_token.as_deref().ok_or_else(|| {\n            eyre::eyre!(\"Not logged in to Atuin Hub. Please run 'atuin login' to authenticate.\")\n        })?;\n\n        if !hub_token.starts_with(\"atapi_\") {\n            bail!(\n                \"Your Hub session token is invalid. Please run 'atuin login' to re-authenticate \\\n                 with Atuin Hub.\"\n            );\n        }","sourceCodeStart":335,"sourceCodeEnd":371,"githubUrl":"https://github.com/atuinsh/atuin/blob/c0c717ab04c881764bcad4b3d169a507e2432643/crates/atuin-client/src/auth.rs#L335-L371","documentation":"Final fallback in the auth-module register: registration on the Hub failed with a non-success status whose body did not decode as a HubErrorResponse, so only the HTTP status is reported. The username may already be taken, but here the server gave an unparseable or unexpected response.","triggerScenarios":"Thrown at crates/atuin-client/src/auth.rs:353 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Retry registration; if the username is taken, choose another","Check the interpolated {status}: 5xx indicates a server-side issue","Confirm connectivity and that no proxy is intercepting the request"],"exampleFix":null,"handlingStrategy":"retry","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"c0c717ab04c881764bcad4b3d169a507e2432643","analyzedAt":"2026-09-12T07:40:01.341Z","contentChangedAt":"2026-09-12T07:40:01.341Z","schemaVersion":2},"datasetVersion":"2026-09-14T00:17:10.932Z"}