{"record":{"id":"a7fc240fc02a4a67","repo":"denoland/deno","slug":"export-not-found-in-the-package","errorCode":null,"errorMessage":"Export {} not found in the package","messagePattern":"Export (.+?) not found in the package","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"cli/tools/publish/mod.rs","lineNumber":1436,"sourceCode":"      .find(|f| f.path_str == path.as_str());\n\n    if let Some(file) = file {\n      if file.hash != entry.checksum {\n        bail!(\n          \"Checksum mismatch for {}: expected {}, got {}\",\n          path,\n          entry.checksum,\n          file.hash\n        );\n      }\n    } else {\n      bail!(\"File {} not found in the tarball\", path);\n    }\n  }\n\n  for (specifier, expected) in &manifest.exports {\n    let actual = package.exports.get(specifier).ok_or_else(|| {\n      deno_core::anyhow::anyhow!(\n        \"Export {} not found in the package\",\n        specifier\n      )\n    })?;\n    if actual != expected {\n      bail!(\n        \"Export {} mismatch: expected {}, got {}\",\n        specifier,\n        expected,\n        actual\n      );\n    }\n  }\n\n  Ok(())\n}\n\nstatic SUPPORTED_LICENSE_FILE_NAMES: [&str; 12] = [","sourceCodeStart":1418,"sourceCodeEnd":1454,"githubUrl":"https://github.com/denoland/deno/blob/89f33cbef296a2b287f323d42de54c871fa69c77/cli/tools/publish/mod.rs#L1418-L1454","documentation":"After uploading a package, `deno publish` downloads the version manifest the registry produced and verifies it against the locally prepared package (`verify_version_manifest`, publish/mod.rs:1159). This error fires when the registry manifest's `exports` map contains a specifier (e.g. `./mod`) that the local `PreparedPublishPackage.exports` does not have. The server's report of the package and what the client prepared disagree.","triggerScenarios":"`deno publish` reaches post-upload verification and the manifest returned by the registry lists an export entry the client never prepared — typically client/server version skew or an unexpected registry response, since the local exports map normally mirrors deno.json `exports` exactly.","commonSituations":"Publishing with an outdated Deno version against a newer registry API; a proxy or intermediary returning a manifest for a different or previous version of the package; retrying an interrupted publish against an already-uploaded version.","solutions":["Upgrade Deno to the latest release and publish again — this path depends on exact agreement between client and registry behavior","Open the package page on jsr.io and compare the exports the uploaded version actually received against deno.json `exports`","If the version was partially published, bump the version in deno.json and publish fresh","If it reproduces on current Deno, capture the registry response with DENO_LOG=debug and open an issue"],"exampleFix":null,"handlingStrategy":"retry","validationCode":"# sanity-check that every deno.json export points at an existing file\ndeno eval 'const c = JSON.parse(Deno.readTextFileSync(\"deno.json\"));\nfor (const [k, v] of Object.entries(c.exports ?? {})) {\n  if (!Deno.statSync(v).isFile) { console.error(`export ${k} -> missing ${v}`); Deno.exit(1); }\n}'","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Keep Deno current so client-side verification matches the registry's manifest behavior","After each publish, verify the exports shown on the jsr.io package page match deno.json","Never retry a partial publish at the same version — bump and publish fresh"],"tags":["publish","jsr","registry","exports","verification"],"backgroundTag":null,"analyzedSha":"89f33cbef296a2b287f323d42de54c871fa69c77","analyzedAt":"2026-08-16T07:54:21.310Z","schemaVersion":2},"datasetVersion":"2026-08-16T08:17:34.114Z"}