{"record":{"id":"f83e92559c71ddfe","repo":"Foundry376/Mailspring","slug":"could-not-find-a-file-at-path","errorCode":null,"errorMessage":"Could not find a file at path '%@'","messagePattern":"Could not find a file at path '%@'","errorType":"exception","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"app/src/theme-manager.ts","lineNumber":276,"sourceCode":"    if (this._systemAccentDisposable) {\n      this._systemAccentDisposable.dispose();\n      this._systemAccentDisposable = null;\n    }\n    if (color) {\n      this._systemAccentDisposable = AppEnv.styles.addStyleSheet(buildSystemAccentCSS(color), {\n        sourcePath: SYSTEM_ACCENT_SOURCE_PATH,\n        priority: 2,\n      });\n    }\n  }\n\n  // Section: Private\n  // ------\n\n  requireStylesheet(stylesheetPath) {\n    const sourcePath = this.resolveStylesheetPath(stylesheetPath);\n    if (!sourcePath) {\n      throw new Error(localized(`Could not find a file at path '%@'`, stylesheetPath));\n    }\n    const content = this.cssContentsOfStylesheet(sourcePath);\n    this.styleSheetDisposablesBySourcePath[sourcePath] = AppEnv.styles.addStyleSheet(content, {\n      priority: -1,\n      sourcePath,\n    });\n  }\n\n  loadStaticStylesheets() {\n    this.requireStylesheet('../static/style/index');\n    this.requireStylesheet('../static/style/email-frame');\n  }\n\n  resolveStylesheetPath(stylesheetPath) {\n    if (path.extname(stylesheetPath).length > 0) {\n      const p = path.resolve(__dirname, stylesheetPath);\n      return fs.existsSync(p) ? p : null;\n    }","sourceCodeStart":258,"sourceCodeEnd":294,"githubUrl":"https://github.com/Foundry376/Mailspring/blob/648c685d602ece6bb00c22534b8734de6ac644b3/app/src/theme-manager.ts#L258-L294","documentation":"ThemeManager.requireStylesheet could not resolve the given stylesheet path to an existing .css or .less file via resolveStylesheetPath. Raised when a theme or core code loads a stylesheet whose path is wrong, the theme is missing files, or the theme's package manifest references a nonexistent file.","triggerScenarios":"Thrown at app/src/theme-manager.ts:276 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Fix the stylesheet path passed to requireStylesheet (relative paths resolve against the theme/package directory)","Check the active theme's package.json lists files that actually exist","Switch back to the default theme to isolate whether the theme package is broken or incomplete"],"exampleFix":null,"handlingStrategy":"fallback","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"648c685d602ece6bb00c22534b8734de6ac644b3","analyzedAt":"2026-09-03T02:00:24.311Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-10T07:17:11.731Z"}