{"record":{"id":"1aa6d4e5fd0feb71","repo":"astrid-runtime/astrid","slug":"wasm-binary-not-found-at","errorCode":null,"errorMessage":"WASM binary not found at {}","messagePattern":"WASM binary not found at (.+?)","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"crates/astrid-build/src/archiver.rs","lineNumber":111,"sourceCode":"    // security measure and we want this invariant to survive upstream default changes).\n    tar.follow_symlinks(true);\n\n    // 1. Write the synthesized Capsule.toml directly from memory\n    let mut header = deterministic_header(\n        manifest_content.len() as u64,\n        0o644,\n        tar::EntryType::Regular,\n    );\n    tar.append_data(&mut header, \"Capsule.toml\", manifest_content.as_bytes())\n        .context(\"Failed to write Capsule.toml to archive\")?;\n\n    // 2. Append the WASM binary (if present)\n    if let Some(wasm) = wasm_path {\n        if wasm.exists() {\n            let file_name = wasm.file_name().unwrap_or_default();\n            append_file(&mut tar, Path::new(file_name), wasm)?;\n        } else {\n            anyhow::bail!(\"WASM binary not found at {}\", wasm.display());\n        }\n    }\n\n    // 3. Append additional contextual and opaque asset files.\n    // Use a cycle-safe recursive walk instead of tar's append_dir_all, because\n    // follow_symlinks(true) + append_dir_all has no cycle detection — a symlink\n    // pointing to an ancestor directory would cause infinite recursion and OOM.\n    let mut ordered_files: Vec<(&Path, PathBuf)> = additional_files\n        .iter()\n        .filter(|path| path.exists())\n        .map(|path| {\n            let relative = path\n                .strip_prefix(base_dir)\n                .unwrap_or(Path::new(path.file_name().unwrap_or_default()))\n                .to_path_buf();\n            (*path, relative)\n        })\n        .collect();","sourceCodeStart":93,"sourceCodeEnd":129,"githubUrl":"https://github.com/astrid-runtime/astrid/blob/affd8760f44190dbdfbec23403f4c4b642c33112/crates/astrid-build/src/archiver.rs#L93-L129","documentation":"Like error 1120, the signed channel pointer's release.metadata_asset must equal format!(\"astrid-{version}-release.toml\"). This instance is the same ensure! reached for any channel (stable/dev/nightly) whenever the asset name string does not match the canonical pattern derived from the pointer's canonical version.","triggerScenarios":"validate_pointer (via parse_channel or enforce_continuity) is given a ChannelPointer where pointer.release.metadata_asset != format!(\"astrid-{version}-release.toml\").","commonSituations":"Signed pointer generated by a script using an old asset naming scheme; manual edit of the channel file; asset renamed during a re-release but pointer not regenerated.","solutions":["Rewrite release.metadata_asset as \"astrid-<canonical-version>-release.toml\".","Regenerate and re-sign the channel pointer with the current release tooling.","Re-run parse_channel to confirm the pointer validates."],"exampleFix":"# before\nmetadata_asset = \"astrid-1.2.3-release.toml.bak\"\n# after\nmetadata_asset = \"astrid-1.2.3-release.toml\"","handlingStrategy":"validation","validationCode":"fn asset_name_matches(version: &str, asset: &str) -> bool {\n    asset == format!(\"astrid-{version}-release.toml\")\n}","typeGuard":null,"tryCatchPattern":"if let Err(e) = parse_channel(&bytes, channel, now) {\n    if e.to_string().contains(\"metadata asset is invalid\") { eprintln!(\"fix metadata_asset naming\"); }\n    return Err(e.into());\n}","preventionTips":["Single source of truth for derived pointer fields","Validate pointers in CI pre-publication","Avoid manual edits to signed files"],"tags":["validation","signing","naming"],"backgroundTag":"invalid-argument-value","analyzedSha":"affd8760f44190dbdfbec23403f4c4b642c33112","analyzedAt":"2026-09-09T21:28:12.402Z","contentChangedAt":"2026-09-09T21:28:12.402Z","schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}