{"record":{"id":"38fba72f52dffd47","repo":"BigPizzaV3/CodexPlusPlus","slug":"openai-plugins-marketplace-download-is-too-large","errorCode":null,"errorMessage":"openai/plugins marketplace download is too large: {} bytes","messagePattern":"openai/plugins marketplace download is too large: (.+?) bytes","errorType":"exception","errorClass":"anyhow::Error","httpStatus":null,"severity":"error","filePath":"crates/codex-plus-core/src/plugin_marketplace.rs","lineNumber":311,"sourceCode":"    install_openai_plugins_zip(home, &bytes)\n}\n\nasync fn download_openai_plugins_zip() -> anyhow::Result<Vec<u8>> {\n    let client =\n        crate::http_client::proxied_client(&format!(\"Codex++/{}\", crate::version::VERSION))?;\n    let bytes = client\n        .get(OPENAI_PLUGINS_ZIP_URL)\n        .header(reqwest::header::ACCEPT, \"application/zip\")\n        .send()\n        .await\n        .context(\"failed to download openai/plugins marketplace\")?\n        .error_for_status()\n        .context(\"openai/plugins marketplace download returned an error status\")?\n        .bytes()\n        .await\n        .context(\"failed to read openai/plugins marketplace download body\")?;\n    if bytes.len() > OPENAI_PLUGINS_DOWNLOAD_LIMIT_BYTES {\n        anyhow::bail!(\n            \"openai/plugins marketplace download is too large: {} bytes\",\n            bytes.len()\n        );\n    }\n    Ok(bytes.to_vec())\n}\n\nfn install_openai_plugins_zip(home: &Path, bytes: &[u8]) -> anyhow::Result<()> {\n    let destination = home.join(\".tmp\").join(\"plugins\");\n    let staging_parent = home.join(\".tmp\");\n    std::fs::create_dir_all(&staging_parent)\n        .with_context(|| format!(\"failed to create {}\", staging_parent.display()))?;\n    let staging = staging_parent.join(format!(\n        \"plugins-download-{}\",\n        std::time::SystemTime::now()\n            .duration_since(std::time::UNIX_EPOCH)\n            .unwrap_or_default()\n            .as_millis()","sourceCodeStart":293,"sourceCodeEnd":329,"githubUrl":"https://github.com/BigPizzaV3/CodexPlusPlus/blob/b1ed92e5e4a2d74095d4b8db5af43cef7acba9c6/crates/codex-plus-core/src/plugin_marketplace.rs#L293-L329","documentation":"download_openai_plugins_zip fetches the openai/plugins marketplace archive over HTTP and enforces a hard size ceiling (OPENAI_PLUGINS_DOWNLOAD_LIMIT_BYTES). If the downloaded body exceeds that limit it aborts with this error instead of unzipping an oversized archive, protecting memory and disk from an unexpectedly huge or malicious download.","triggerScenarios":"initialize_openai_curated_marketplace_from_github calls download_openai_plugins_zip and the GitHub zip response body's byte length exceeds OPENAI_PLUGINS_DOWNLOAD_LIMIT_BYTES — e.g. the upstream repo added many more plugins, a release includes large assets, or the limit constant is set too low for the current marketplace size.","commonSituations":"Upstream openai/plugins grew beyond the baked-in limit; a proxy/mirror returns an unexpected large file; operator pinned an old CodexPlusPlus version whose limit predates the marketplace's growth.","solutions":["Check OPENAI_PLUGINS_DOWNLOAD_LIMIT_BYTES in plugin_marketplace.rs and raise it to accommodate the current openai/plugins archive size","Verify what is actually served at the download URL (curl -sI) — confirm it is the expected zip and not a bloated mirror artifact","Update CodexPlusPlus to a version with an up-to-date limit constant","If the URL is a proxy, bypass it or point directly at the canonical GitHub archive"],"exampleFix":"// before\nif bytes.len() > OPENAI_PLUGINS_DOWNLOAD_LIMIT_BYTES {\n    anyhow::bail!(\"openai/plugins marketplace download is too large: {} bytes\", bytes.len());\n}\n// after\nconst OPENAI_PLUGINS_DOWNLOAD_LIMIT_BYTES: u64 = 256 * 1024 * 1024; // raised from old limit","handlingStrategy":"validation","validationCode":"let resp = reqwest::get(url).await?;\nlet bytes = resp.bytes().await?;\nif bytes.len() > OPENAI_PLUGINS_DOWNLOAD_LIMIT_BYTES {\n    return Err(anyhow!(\"download too large: {} bytes\", bytes.len()));\n}","typeGuard":null,"tryCatchPattern":"match download_openai_plugins_zip().await {\n    Ok(bytes) => install(bytes),\n    Err(e) if e.to_string().contains(\"too large\") => warn_user_and_suggest_manual_download(e),\n    Err(e) => return Err(e),\n}","preventionTips":["Keep OPENAI_PLUGINS_DOWNLOAD_LIMIT_BYTES in sync with upstream marketplace growth","Check Content-Length header before downloading the body","Log the download URL and size for diagnosis"],"tags":["network","download","file-size-limit","marketplace"],"backgroundTag":"file-size-limit-exceeded","analyzedSha":"b1ed92e5e4a2d74095d4b8db5af43cef7acba9c6","analyzedAt":"2026-09-19T23:35:21.129Z","contentChangedAt":"2026-09-19T23:35:21.129Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}