{"record":{"id":"fcd2ea08bfca7f75","repo":"atuinsh/atuin","slug":"current-password-is-incorrect-fcd2ea","errorCode":null,"errorMessage":"current password is incorrect","messagePattern":"current password is incorrect","errorType":"http","errorClass":null,"httpStatus":401,"severity":"error","filePath":"crates/atuin-client/src/auth.rs","lineNumber":205,"sourceCode":"        new_password: &str,\n        _totp_code: Option<&str>,\n    ) -> Result<MutateResponse> {\n        let client = self.authenticated_client()?;\n        let url = self.address.append_path(\"account/password\")?;\n\n        let resp = client\n            .patch(url)\n            .json(&ChangePasswordRequest {\n                current_password: current_password.to_string(),\n                new_password: new_password.to_string(),\n            })\n            .send()\n            .await?;\n\n        match resp.status().as_u16() {\n            200 => Ok(MutateResponse::Success),\n            401 => {\n                bail!(\"current password is incorrect\");\n            }\n            403 => {\n                bail!(\"invalid login details\");\n            }\n            _ => {\n                bail!(\"unknown error\");\n            }\n        }\n    }\n\n    async fn delete_account(\n        &self,\n        password: &str,\n        _totp_code: Option<&str>,\n    ) -> Result<MutateResponse> {\n        let client = self.authenticated_client()?;\n        let url = self.address.append([\"account\"])?;\n","sourceCodeStart":187,"sourceCodeEnd":223,"githubUrl":"https://github.com/atuinsh/atuin/blob/c0c717ab04c881764bcad4b3d169a507e2432643/crates/atuin-client/src/auth.rs#L187-L223","documentation":"Match arm in the auth-module change_password: the PATCH /account/password response was HTTP 401, so the current_password sent with ChangePasswordRequest failed verification on the Hub. Semantically identical to the api_client.rs variant; the password remains unchanged.","triggerScenarios":"Thrown at crates/atuin-client/src/auth.rs:205 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Re-enter the current password and retry the change","If the password is genuinely forgotten, use account recovery before changing it"],"exampleFix":null,"handlingStrategy":"validation","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-14T05:17:10.506Z"}