{"record":{"id":"fca7d1f23201625a","repo":"Yeachan-Heo/oh-my-codex","slug":"native-assets-manifest-version-mismatch-expecte","errorCode":null,"errorMessage":"[native-assets] manifest version mismatch: expected ${version}, received ${manifest.version}","messagePattern":"\\[native-assets\\] manifest version mismatch: expected (.+?), received (.+?)","errorType":"validation","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"src/cli/native-assets.ts","lineNumber":247,"sourceCode":"}\n\nexport function isRepositoryCheckout(packageRoot = getPackageRoot()): boolean {\n  return existsSync(join(packageRoot, '.git'));\n}\n\nexport async function loadNativeReleaseManifest(\n  packageRoot = getPackageRoot(),\n  version?: string,\n  env: NodeJS.ProcessEnv = process.env,\n): Promise<NativeReleaseManifest> {\n  const url = await resolveNativeManifestUrl(packageRoot, version, env);\n  const response = await fetch(url);\n  if (!response.ok) {\n    throw new Error(`[native-assets] failed to fetch native release manifest (${response.status} ${response.statusText}) from ${url}`);\n  }\n  const manifest = await response.json() as NativeReleaseManifest;\n  validateNativeReleaseManifest(manifest as never);\n  if (version && manifest.version !== version) throw new Error(`[native-assets] manifest version mismatch: expected ${version}, received ${manifest.version}`);\n  return manifest;\n}\n\nfunction isUnavailableManifestError(error: unknown): boolean {\n  if (!(error instanceof Error)) return false;\n  return /\\[native-assets\\] failed to fetch native release manifest/i.test(error.message)\n    || /fetch failed/i.test(error.message);\n}\n\nfunction isUnavailableArchiveError(error: unknown): boolean {\n  if (!(error instanceof Error)) return false;\n  return /\\[native-assets\\] failed to download /i.test(error.message)\n    || /fetch failed/i.test(error.message);\n}\n\nasync function downloadFile(url: string, destinationPath: string): Promise<void> {\n  const response = await fetch(url);\n  if (!response.ok || !response.body) {","sourceCodeStart":229,"sourceCodeEnd":265,"githubUrl":"https://github.com/Yeachan-Heo/oh-my-codex/blob/3ad79a8a6fe6e95fdbb8c00e40716fffe4011ce2/src/cli/native-assets.ts#L229-L265","documentation":"The manifest was downloaded successfully but its embedded version field does not match the requested package version. This is a consistency check: the manifest at the URL for vX claims a different version, indicating a stale or mis-uploaded release asset.","triggerScenarios":"Calling loadNativeReleaseManifest with an explicit version argument when the manifest asset under releases/download/vX contains \"version\": \"Y\" — typically a release that was drafted from the wrong build, or a manually patched manifest.","commonSituations":"Release automation that uploads the manifest built from a different commit than the npm package; manual asset re-uploads; NATIVE_RELEASE_BASE_URL pointed at a mirror whose manifest is a different version.","solutions":["Re-download and inspect the manifest at the printed URL; confirm its version field.","Re-publish the correct manifest asset for the v<version> release.","If mirroring, fix the mirror so each version directory serves the matching manifest."],"exampleFix":null,"handlingStrategy":"try-catch","validationCode":null,"typeGuard":null,"tryCatchPattern":"try { await loadNativeReleaseManifest(root, version); } catch (e) { if (/manifest version mismatch/.test(String(e))) { /* release asset is stale; report to publisher, pin a good version */ } throw e; }","preventionTips":["Pin versions known to have consistent releases","Automate publishing npm package and GitHub release from the same CI job","Validate manifest.version against the tag in release CI before upload"],"tags":["native-assets","version-mismatch","manifest","release-integrity"],"backgroundTag":"version-mismatch","analyzedSha":"3ad79a8a6fe6e95fdbb8c00e40716fffe4011ce2","analyzedAt":"2026-08-27T22:18:39.783Z","schemaVersion":2},"datasetVersion":"2026-08-28T00:17:15.603Z"}