{"record":{"id":"4abc072296a5d2a4","repo":"quasarframework/quasar","slug":"the-file-defined-in-bex-manifest-background-se","errorCode":null,"errorMessage":"The file defined in bex manifest > background > service_worker > \"${rawName}\" does NOT exist. Skipping.","messagePattern":"The file defined in bex manifest > background > service_worker > \"(.+?)\" does NOT exist\\. Skipping\\.","errorType":"console","errorClass":null,"httpStatus":null,"severity":"warning","filePath":"app-vite/lib/modes/bex/bex-utils.js","lineNumber":117,"sourceCode":"  }\n}\n\nconst scriptExtRE = /\\.[jt]sx?$/i\n\nfunction extractBexScripts(quasarConf, bexManifest) {\n  const scriptList = []\n  const scriptNameSet = new Set()\n\n  if (bexManifest.background?.service_worker) {\n    const rawName = bexManifest.background.service_worker\n    const scriptName = rawName.replace(scriptExtRE, '')\n    const inputFile = quasarConf.ctx.appPaths.resolve.bex(rawName)\n\n    bexManifest.background.service_worker = scriptName + '.js'\n\n    if (!fse.existsSync(inputFile)) {\n      warn()\n      warn(\n        `The file defined in bex manifest > background > service_worker > \"${rawName}\" does NOT exist. Skipping.`\n      )\n      warn()\n    } else {\n      const entry = getCompilationEntry(quasarConf, inputFile, scriptName)\n      if (!scriptNameSet.has(entry.name)) {\n        scriptNameSet.add(entry.name)\n        scriptList.push(entry)\n      }\n    }\n  }\n\n  bexManifest.background?.scripts?.forEach((rawName, index) => {\n    const scriptName = rawName.replace(scriptExtRE, '')\n    const inputFile = quasarConf.ctx.appPaths.resolve.bex(rawName)\n\n    bexManifest.background.scripts[index] = scriptName + '.js'\n","sourceCodeStart":99,"sourceCodeEnd":135,"githubUrl":"https://github.com/quasarframework/quasar/blob/4841521b5f635a971eb9e2710e5542efd194691b/app-vite/lib/modes/bex/bex-utils.js#L99-L135","documentation":"extractBexScripts maps the manifest's background.service_worker entry to a compiled output script. It resolves the raw name against the src-bex directory; if that input file does not exist on disk, it warns and skips the entry, leaving the service worker out of the build.","triggerScenarios":"manifest background.service_worker references a file (e.g. \"my-background.js\") that is not present in src-bex (resolve.bex(rawName) fails fse.existsSync); the script is skipped instead of being added as a compilation entry.","commonSituations":"Background file renamed or deleted but manifest not updated; wrong path (missing leading folder like \"background/index.js\"); file placed outside src-bex; case-sensitive filesystem mismatch (Linux CI vs local Windows/macOS).","solutions":["Create the missing file at the referenced path inside src-bex (e.g. src-bex/my-background.js).","Correct the background.service_worker path in src-bex/manifest.json to match an existing file.","Check filename casing exactly matches the manifest entry (Linux case sensitivity).","If the service worker is no longer needed, remove the background.service_worker field from the manifest."],"exampleFix":"// before (src-bex/manifest.json)\n\"background\": { \"service_worker\": \"backgroud.js\" }\n// after\n\"background\": { \"service_worker\": \"background.js\" } // file exists at src-bex/background.js","handlingStrategy":"validation","validationCode":"const fs = require('fs'), path = require('path')\nconst m = require('./src-bex/manifest.json')\nconst sw = m.all?.background?.service_worker\nif (sw && !fs.existsSync(path.join('src-bex', sw))) {\n  throw new Error(`background.service_worker points to missing file: src-bex/${sw}`)\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Keep manifest script paths in sync whenever renaming files (use IDE rename/refactor).","Verify on the exact CI OS — Linux is case-sensitive.","Only reference files that actually live inside src-bex."],"tags":["bex","manifest","missing-file","service-worker"],"backgroundTag":"referenced-file-not-found","analyzedSha":"4841521b5f635a971eb9e2710e5542efd194691b","analyzedAt":"2026-08-30T01:13:14.944Z","schemaVersion":2},"datasetVersion":"2026-08-30T03:17:51.788Z"}