{"record":{"id":"a06b57dca5029b2c","repo":"tauri-apps/tauri","slug":"does-not-exist","errorCode":null,"errorMessage":"{:?} does not exist","messagePattern":"(.+?) does not exist","errorType":"exception","errorClass":"anyhow::Error","httpStatus":null,"severity":"error","filePath":"crates/tauri-build/src/lib.rs","lineNumber":47,"sourceCode":"\nmod acl;\n#[cfg(feature = \"codegen\")]\nmod codegen;\nmod manifest;\nmod mobile;\nmod static_vcruntime;\n\n#[cfg(feature = \"codegen\")]\n#[cfg_attr(docsrs, doc(cfg(feature = \"codegen\")))]\npub use codegen::context::CodegenContext;\n\npub use acl::{AppManifest, DefaultPermissionRule, InlinedPlugin};\n\nfn copy_file(from: impl AsRef<Path>, to: impl AsRef<Path>) -> Result<()> {\n  let from = from.as_ref();\n  let to = to.as_ref();\n  if !from.exists() {\n    return Err(anyhow::anyhow!(\"{:?} does not exist\", from));\n  }\n  if !from.is_file() {\n    return Err(anyhow::anyhow!(\"{:?} is not a file\", from));\n  }\n  let dest_dir = to.parent().expect(\"No data in parent\");\n  fs::create_dir_all(dest_dir)?;\n  fs::copy(from, to)?;\n  Ok(())\n}\n\nfn copy_binaries(\n  binaries: ResourcePaths,\n  target_triple: &str,\n  path: &Path,\n  package_name: Option<&str>,\n) -> Result<()> {\n  for src in binaries {\n    let src = src?;","sourceCodeStart":29,"sourceCodeEnd":65,"githubUrl":"https://github.com/tauri-apps/tauri/blob/2f1cd75b0f3fb72e6870d719bbfeadedcf8ca884/crates/tauri-build/src/lib.rs#L29-L65","documentation":"tauri-build copies configured files (bundle resources, external binaries/sidecars, macOS .dylib frameworks) through copy_file, which first asserts the source path exists. This error fires when a configured path does not resolve to anything on disk at build time, with the offending path printed via Debug formatting.","triggerScenarios":"Running tauri build / tauri dev when a bundle.resources, bundle.externalBin, or frameworks entry points at a missing file - a glob or map key that matched nothing, a generated asset directory (e.g. frontend dist/) that was never built, or a path resolved relative to the wrong base directory.","commonSituations":"Frontend build not run before tauri build so the resource path is absent; typo'd paths in tauri.conf.json; sidecar binaries not compiled before bundling; case-sensitivity differences between macOS dev machines and Linux/Windows CI.","solutions":["Check the exact path printed in the error and either create the file or fix the path in tauri.conf.json","Ensure generation steps run before bundling (beforeBuildCommand building the frontend, sidecar compilation scripts)","Remember resource paths resolve relative to the tauri.conf.json directory; adjust relative paths accordingly","On case-sensitive filesystems verify exact casing of every path segment"],"exampleFix":"// before: tauri.conf.json\n\"resources\": [\"asets/logo.png\"]\n\n// after\n\"resources\": [\"assets/logo.png\"]","handlingStrategy":"validation","validationCode":"// prebuild check: every resource path must exist\nconst { readFileSync, existsSync } = require('fs')\nconst cfg = readFileSync('src-tauri/tauri.conf.json', 'utf8')\n// simple case for literal string entries under bundle.resources\nfor (const m of cfg.matchAll(/\"([^\"*]+)\"/g)) {\n  if (m[1].includes('.') && !existsSync(`src-tauri/${m[1]}`)) {\n    console.warn(`missing path: ${m[1]}`)\n  }\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Run frontend and sidecar builds before tauri build (wire them into beforeBuildCommand)","Add a CI step asserting every bundle.resources path exists","Keep resources in stable, committed directories instead of generated ad-hoc paths","Watch path casing - develop on case-insensitive macOS, fail on case-sensitive Linux CI"],"tags":["tauri-build","resources","filesystem","config"],"backgroundTag":null,"analyzedSha":"2f1cd75b0f3fb72e6870d719bbfeadedcf8ca884","analyzedAt":"2026-08-16T04:18:42.486Z","schemaVersion":2},"datasetVersion":"2026-08-16T08:17:34.114Z"}