From 1ad2c6f6d24e024706d598c52ce04e96208b0433 Mon Sep 17 00:00:00 2001 From: czlonkowski <56956555+czlonkowski@users.noreply.github.com> Date: Tue, 7 Oct 2025 10:12:44 +0200 Subject: [PATCH] fix: skip ALL node repository validation for langchain nodes (correct placement) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The previous fix placed the skip inside the `if (!nodeInfo)` block, but the database HAS langchain nodes loaded from @n8n/n8n-nodes-langchain, so nodeInfo was NOT null. This meant the skip never executed and parameter validation via EnhancedConfigValidator was running and failing. Moving the skip BEFORE the nodeInfo lookup ensures ALL node repository validation is bypassed for langchain nodes: - No nodeInfo lookup - No typeVersion validation - No EnhancedConfigValidator parameter validation Langchain nodes are fully validated by dedicated AI-specific validators in validateAISpecificNodes(). Resolves #265 (AI validation Phase 2 - critical fix) 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude --- src/services/workflow-validator.ts | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/src/services/workflow-validator.ts b/src/services/workflow-validator.ts index f6d6552..fc78036 100644 --- a/src/services/workflow-validator.ts +++ b/src/services/workflow-validator.ts @@ -395,16 +395,17 @@ export class WorkflowValidator { node.type = normalizedType; } + // Skip ALL node repository validation for langchain nodes + // They have dedicated AI-specific validators in validateAISpecificNodes() + // This prevents parameter validation conflicts and ensures proper AI validation + if (normalizedType.startsWith('nodes-langchain.')) { + continue; + } + // Get node definition using normalized type const nodeInfo = this.nodeRepository.getNode(normalizedType); if (!nodeInfo) { - // Skip validation for langchain nodes - they're validated by AI-specific validators - // This prevents database dependency issues while still ensuring proper validation - if (normalizedType.startsWith('nodes-langchain.')) { - // Langchain nodes are validated separately by validateAISpecificNodes() - continue; - } // Use NodeSimilarityService to find suggestions const suggestions = await this.similarityService.findSimilarNodes(node.type, 3);