{"record":{"id":"927a4ea192ca1b83","repo":"n8n-io/n8n","slug":"csv-file-not-found-at-resolvedpath","errorCode":null,"errorMessage":"CSV file not found at ${resolvedPath}","messagePattern":"CSV file not found at (.+?)","errorType":"exception","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"packages/@n8n/ai-workflow-builder.ee/evaluations/cli/csv-prompt-loader.ts","lineNumber":46,"sourceCode":"\t\tconst rows = parse(content.replace(/^\\ufeff/, ''), {\n\t\t\tcolumns: false,\n\t\t\tskip_empty_lines: true,\n\t\t\ttrim: true,\n\t\t\trelax_column_count: true,\n\t\t}) as ParsedCsvRow[];\n\n\t\treturn rows.map((row) => row.map((cell) => cell ?? ''));\n\t} catch (error) {\n\t\tconst message = error instanceof Error ? error.message : 'Unknown parsing error';\n\t\tthrow new Error(`Failed to parse CSV file: ${message}`);\n\t}\n}\n\nexport function loadTestCasesFromCsv(csvPath: string): TestCase[] {\n\tconst resolvedPath = isAbsolute(csvPath) ? csvPath : resolve(process.cwd(), csvPath);\n\n\tif (!existsSync(resolvedPath)) {\n\t\tthrow new Error(`CSV file not found at ${resolvedPath}`);\n\t}\n\n\tconst rows = parseCsv(readFileSync(resolvedPath, 'utf8'));\n\n\tif (rows.length === 0) {\n\t\tthrow new Error('The provided CSV file is empty');\n\t}\n\n\tconst hasHeader = isHeaderRow(rows[0]);\n\tconst header = hasHeader ? rows[0] : undefined;\n\tconst dataRows = hasHeader ? rows.slice(1) : rows;\n\n\tif (dataRows.length === 0) {\n\t\tthrow new Error('No prompt rows found in the provided CSV file');\n\t}\n\n\t// Find column index by name(s), returns undefined if no header\n\tconst findColumn = (...names: string[]): number | undefined => {","sourceCodeStart":28,"sourceCodeEnd":64,"githubUrl":"https://github.com/n8n-io/n8n/blob/5ac6606e81f67bb9534255570cd4e86fd8101eee/packages/@n8n/ai-workflow-builder.ee/evaluations/cli/csv-prompt-loader.ts#L28-L64","documentation":"Error \"CSV file not found at ${resolvedPath}\" thrown in n8n-io/n8n.","triggerScenarios":"Thrown at packages/@n8n/ai-workflow-builder.ee/evaluations/cli/csv-prompt-loader.ts:46 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"5ac6606e81f67bb9534255570cd4e86fd8101eee","analyzedAt":"2026-08-12T05:26:35.080Z","schemaVersion":2},"datasetVersion":"2026-08-12T13:17:24.610Z"}