{"record":{"id":"5fe688b4e17afb8d","repo":"gatsbyjs/gatsby","slug":"10127","errorCode":"10127","errorMessage":"Your \"${context.configName}.ts\" file failed to compile to \"${context.configName}.js\". Please run \"gatsby clean\" and try again.\n\nIf the issue persists, please open an issue with a reproduction at https://gatsby.dev/new-issue for more help.\"","messagePattern":"Your \"(.+?)\\.ts\" file failed to compile to \"(.+?)\\.js\"\\. Please run \"gatsby clean\" and try again\\.\n\nIf the issue persists, please open an issue with a reproduction at https://gatsby\\.dev/new-issue for more help\\.\"","errorType":"panic","errorClass":null,"httpStatus":null,"severity":"error","filePath":"packages/gatsby/src/bootstrap/get-config-file.ts","lineNumber":126,"sourceCode":"      })\n    }\n  }\n\n  if (uncompiledResult?.configFilePath) {\n    return uncompiledResult\n  }\n\n  const error = new Error(`Cannot find package '${uncompiledConfigPath}'`)\n\n  const { tsConfig, nearMatch } = await checkTsAndNearMatch(\n    siteDirectory,\n    configName,\n    distance\n  )\n\n  // gatsby-config.ts exists but compiled gatsby-config.js does not\n  if (tsConfig) {\n    report.panic({\n      id: `10127`,\n      error,\n      context: {\n        configName,\n      },\n    })\n  }\n\n  // gatsby-config is misnamed\n  if (nearMatch) {\n    const isTSX = nearMatch.endsWith(`.tsx`)\n    report.panic({\n      id: `10124`,\n      error,\n      context: {\n        configName,\n        nearMatch,\n        isTSX,","sourceCodeStart":108,"sourceCodeEnd":144,"githubUrl":"https://github.com/gatsbyjs/gatsby/blob/e85d62f1779e353eaac1753211629a26d123e26c/packages/gatsby/src/bootstrap/get-config-file.ts#L108-L144","documentation":"Error \"Your \"${context.configName}.ts\" file failed to compile to \"${context.configName}.js\". Please run \"gatsby clean\" and try again.\n\nIf the issue persists, please open an issue with a reproduction at https://gatsby.dev/new-issue for more help.\"\" thrown in gatsbyjs/gatsby.","triggerScenarios":"Thrown at packages/gatsby/src/bootstrap/get-config-file.ts:126 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Run `gatsby clean` to remove the stale cache so the .ts config is recompiled","If it persists, open an issue with a reproduction at https://gatsby.dev/new-issue"],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"e85d62f1779e353eaac1753211629a26d123e26c","analyzedAt":"2026-08-26T17:50:09.662Z","contentChangedAt":"2026-08-26T17:50:09.662Z","schemaVersion":2},"datasetVersion":"2026-09-14T00:17:10.932Z"}