{"record":{"id":"56b6ff77f04d987d","repo":"Morganamilo/paru","slug":"status","errorCode":null,"errorMessage":"Status: {}","messagePattern":"Status: (.+?)","errorType":"exception","errorClass":"Status","httpStatus":null,"severity":"error","filePath":"src/install.rs","lineNumber":52,"sourceCode":"use log::debug;\nuse raur::Cache;\nuse srcinfo::{ArchVecs, Srcinfo};\nuse tr::tr;\n\n#[derive(Copy, Clone, Debug)]\npub struct Status(pub i32);\n\nimpl std::fmt::Display for Status {\n    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {\n        write!(f, \"Status: {}\", self.0)\n    }\n}\n\nimpl std::error::Error for Status {}\n\nimpl Status {\n    pub fn err(n: i32) -> Result<()> {\n        bail!(Status(n))\n    }\n}\n\nstruct Installer {\n    refresh: usize,\n    sysupgrade: usize,\n    install_targets: bool,\n    done_something: bool,\n    ran_pacman: bool,\n    upgrades: Upgrades,\n    srcinfos: HashMap<String, Srcinfo>,\n    remove_make: Vec<String>,\n    conflicts: HashSet<String>,\n    failed: Vec<Base>,\n    chroot: Chroot,\n    deps: Vec<String>,\n    exp: Vec<String>,\n    install_queue: Vec<String>,","sourceCodeStart":34,"sourceCodeEnd":70,"githubUrl":"https://github.com/Morganamilo/paru/blob/9ac3578807a87858651e81a02586ceb947686e7c/src/install.rs#L34-L70","documentation":"Status::err wraps a nonzero pacman exit code into the custom Status error type, displayed as 'Status: {n}'. It is how the installer propagates pacman's failure exit status to the top level after a transaction fails.","triggerScenarios":"Calling Status::err(n) with n != 0, which happens in the install flow whenever the child pacman process returns a nonzero exit code (e.g. build_cleanup returns Status::err(ret)).","commonSituations":"pacman transaction failing because of unresolvable dependencies, package conflicts, failed key checks, or user declining a prompt; build step returning a nonzero code that maps to a pacman-like exit status.","solutions":["Check earlier output for pacman's actual failure reason (the Status code is only the exit number)","Rerun the operation and answer pacman's prompts, or use --noconfirm consistently","Resolve dependency conflicts or file conflicts pacman reported","Refresh keyrings/mirrors (archlinux-keyring, pacman -Sy) if signature errors preceded the failure"],"exampleFix":null,"handlingStrategy":"try-catch","validationCode":"// resolve obvious conflicts before invoking pacman\n// e.g. check for installed conflicting packages first\nif !conflicts.is_empty() { eprintln!(\"resolve conflicts first: {conflicts:?}\"); }","typeGuard":null,"tryCatchPattern":"match install() {\n    Err(e) if e.to_string().starts_with(\"Status: \") => {\n        let code: i32 = e.to_string().split(\": \").nth(1).unwrap().parse().unwrap();\n        eprintln!(\"pacman exited with {code}; check preceding pacman output\");\n    }\n    Err(e) => eprintln!(\"{e}\"),\n    Ok(_) => {},\n}","preventionTips":["The Status code is only pacman's exit number — always inspect earlier pacman output","Resolve dependency/file conflicts before re-running","Keep archlinux-keyring current to avoid signature-triggered failures","Use consistent --noconfirm behavior in scripts"],"tags":["pacman","exit-code","install"],"backgroundTag":"http-error-status","analyzedSha":"9ac3578807a87858651e81a02586ceb947686e7c","analyzedAt":"2026-09-12T04:57:59.861Z","contentChangedAt":"2026-09-12T04:57:59.861Z","schemaVersion":2},"datasetVersion":"2026-09-16T09:17:16.951Z"}