{"record":{"id":"7117ad136990676c","repo":"Morganamilo/paru","slug":"get-sync","errorCode":null,"errorMessage":"get {}: {}","messagePattern":"get \\{\\}: \\{\\}","errorType":"http","errorClass":"anyhow::Error","httpStatus":null,"severity":"error","filePath":"src/sync.rs","lineNumber":106,"sourceCode":"                    name.as_bytes(),\n                    &repo.name,\n                    &pkg.srcinfo.version(),\n                )\n            }\n        }\n    }\n}\n\npub async fn list_aur(config: &Config) -> Result<()> {\n    let url = config.aur_url.join(\"packages.gz\")?;\n    let client = config.raur.client();\n    let resp = client\n        .get(url.clone())\n        .send()\n        .await\n        .with_context(|| format!(\"get {}\", url))?;\n    let success = resp.status().is_success();\n    ensure!(success, \"get {}: {}\", url, resp.status());\n\n    let data = resp.bytes().await?;\n    let mut decoder = GzDecoder::new(&*data);\n    let mut data = Vec::new();\n    decoder\n        .read_to_end(&mut data)\n        .with_context(|| tr!(\"failed to decode package list\"))?;\n\n    let stdout = std::io::stdout();\n    let mut stdout = stdout.lock();\n\n    for line in data.split(|b| *b == b'\\n').filter(|l| !l.is_empty()) {\n        print_pkg(config, &mut stdout, line, \"aur\", \"unknown-version\");\n    }\n\n    Ok(())\n}\n","sourceCodeStart":88,"sourceCodeEnd":124,"githubUrl":"https://github.com/Morganamilo/paru/blob/9ac3578807a87858651e81a02586ceb947686e7c/src/sync.rs#L88-L124","documentation":"list_aur fetches the AUR RPC metadata over HTTP and fails when the GET request cannot be sent (network/DNS error, surfaced via with_context) or when the server returns a non-success status. The message 'get {}: {}' carries the URL and the HTTP status or transport error. It guards the rest of the sync pipeline, which assumes a fully downloaded, gunzipped response body.","triggerScenarios":"Calling list (which calls list_aur) when the AUR RPC endpoint (https://aur.archlinux.org/rpc) is unreachable, DNS fails, TLS fails, or the server replies 4xx/5xx (rate limit, maintenance, captive portal).","commonSituations":"No internet connection or behind a proxy/captive portal; AUR website outage or maintenance window; mirrored/patched aur_url in paru.conf pointing at a dead host; aggressive request rate triggering 429.","solutions":["Check connectivity to https://aur.archlinux.org/rpc/v5/info?arg[]=paru (curl -v) and fix network/proxy.","Retry later if the AUR is down or rate-limiting (wait, back off).","Verify the aur_url setting in paru.conf if customized; reset to https://aur.archlinux.org/.","Update paru; older versions can hit changed RPC endpoints."],"exampleFix":"// before\nlet resp = client.get(url.clone()).send().await?;\n// after\nlet resp = client.get(url.clone()).send().await\n    .with_context(|| format!(\"get {}\", url))?;\nensure!(resp.status().is_success(), \"get {}: {}\", url, resp.status());","handlingStrategy":"retry","validationCode":"curl -fsS 'https://aur.archlinux.org/rpc/v5/info?arg[]=paru' >/dev/null && echo ok","typeGuard":null,"tryCatchPattern":"match paru's exit status; on network/http errors, retry with exponential backoff before giving up","preventionTips":["Check connectivity before running AUR operations","Avoid custom aur_url overrides unless necessary","Watch for AUR status/maintenance announcements"],"tags":["network","http","aur","sync"],"backgroundTag":"http-error-response","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"}