{"record":{"id":"f0b0a63a95f407d7","repo":"n8n-io/n8n","slug":"node-type-nodetype-not-found","errorCode":null,"errorMessage":"Node type ${nodeType} not found","messagePattern":"Node type (.+?) not found","errorType":"exception","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"packages/@n8n/instance-ai/evaluations/harness/stub-services.ts","lineNumber":175,"sourceCode":"\t\t\t\t\t// version to the agent.\n\t\t\t\t\tversion: Array.isArray(node.version)\n\t\t\t\t\t\t? (node.version[node.version.length - 1] ?? 1)\n\t\t\t\t\t\t: node.version,\n\t\t\t\t};\n\t\t\t});\n\t\t\tif (!opts?.query) return all;\n\t\t\tconst q = opts.query.toLowerCase();\n\t\t\treturn all.filter(\n\t\t\t\t(n) =>\n\t\t\t\t\tn.displayName.toLowerCase().includes(q) ||\n\t\t\t\t\tn.name.toLowerCase().includes(q) ||\n\t\t\t\t\tn.description.toLowerCase().includes(q),\n\t\t\t);\n\t\t},\n\t\tasync getDescription(nodeType: string) {\n\t\t\tconst desc = descriptionsByName.get(nodeType);\n\t\t\tif (!desc) {\n\t\t\t\tthrow new Error(`Node type ${nodeType} not found`);\n\t\t\t}\n\t\t\treturn desc;\n\t\t},\n\t\tasync listSearchable() {\n\t\t\treturn searchableNodes;\n\t\t},\n\t\t// Real type-definition source from `dist/node-definitions/`. Falls back\n\t\t// to a clear message when the nodes packages haven't been built yet\n\t\t// (`pnpm build` from the repo root produces them) — matches production's\n\t\t// behavior when node-definition dirs are missing.\n\t\tgetNodeTypeDefinition: async (nodeType, opts) => {\n\t\t\tif (nodeDefinitionDirs.length === 0) {\n\t\t\t\treturn {\n\t\t\t\t\tcontent: '',\n\t\t\t\t\terror:\n\t\t\t\t\t\t'Node type definitions are not available in this eval run. ' +\n\t\t\t\t\t\t'Run `pnpm build` in packages/nodes-base and packages/@n8n/nodes-langchain ' +\n\t\t\t\t\t\t'to generate dist/node-definitions/.',","sourceCodeStart":157,"sourceCodeEnd":193,"githubUrl":"https://github.com/n8n-io/n8n/blob/5ac6606e81f67bb9534255570cd4e86fd8101eee/packages/@n8n/instance-ai/evaluations/harness/stub-services.ts#L157-L193","documentation":"Thrown by the stub node-catalogue's getDescription when asked for a nodeType that has no entry in the descriptionsByName map built from the loaded catalogue file. The stub mirrors production's NodeDescription lookup; an unknown type cannot be described.","triggerScenarios":"The agent/tool requests a nodeType string that was not present in the catalogue JSON used to build the stub; the nodeType uses a different versioned name (e.g. with a version suffix); the catalogue was generated from a build that did not include the node.","commonSituations":"Running evals with a stale catalogue after a new node was added to nodes-base; requesting a node by its display name instead of its internal `name`; a typo in the nodeType string.","solutions":["Regenerate the node catalogue (run `pnpm export:nodes` in packages/@n8n/ai-workflow-builder.ee) so it includes the missing node.","Pass the correct internal node `name`, not the displayName.","Verify the catalogue file the harness loaded actually contains an entry for the requested nodeType."],"exampleFix":"// before — requesting a displayName not in the catalogue\nclient.getDescription('Schedule Trigger'); // displayName\n\n// after — use the internal name and regenerate the catalogue if missing\nclient.getDescription('n8n-nodes-base.scheduleTrigger');","handlingStrategy":"validation","validationCode":"function nodeTypeKnown(nodeType: string, descriptionsByName: Map<string, unknown>): boolean {\n  return descriptionsByName.has(nodeType);\n}\n\nif (!nodeTypeKnown(nodeType, descriptionsByName)) {\n  throw new Error(`nodeType ${nodeType} not in catalogue; regenerate with pnpm export:nodes`);\n}","typeGuard":"function isKnownNodeType(nodeType: string, names: Set<string>): boolean {\n  return names.has(nodeType);\n}","tryCatchPattern":"try {\n  await client.getDescription(nodeType);\n} catch (e) {\n  if (e instanceof Error && /Node type .* not found/.test(e.message)) {\n    // regenerate catalogue or use the internal node name, then retry\n  }\n  throw e;\n}","preventionTips":["Regenerate the catalogue whenever nodes-base changes.","Always pass the internal node `name`, not displayName.","Ship the catalogue as a build artefact in CI."],"tags":["eval-harness","stub-services","node-catalogue","configuration"],"backgroundTag":null,"analyzedSha":"5ac6606e81f67bb9534255570cd4e86fd8101eee","analyzedAt":"2026-08-12T05:26:35.080Z","schemaVersion":2},"datasetVersion":"2026-08-12T13:17:24.610Z"}