n8n-io/n8n · error · Error
--source langtracer requires --suite <slug>
Error message
--source langtracer requires --suite <slug>
What it means
Thrown by parseCliArgs() when --source langtracer is set but no --suite <slug> is provided. The langtracer source pulls a test-case suite over MCP (requiring LANGTRACER_URL + LANGTRACER_API_KEY), and a suite slug is mandatory to identify which suite to export. Without it the provider cannot resolve any cases. The same check exists in build-mcp-manifest.ts.
Source
Thrown at packages/@n8n/instance-ai/evaluations/cli/args.ts:212
throw new Error(
'--build-via-mcp requires LangSmith experiment tracking — set LANGSMITH_API_KEY. The no-LangSmith direct loop does not support MCP builds.',
);
}
// Build knobs without --build-via-mcp would parse fine and then be silently
// ignored — the run would look like it honored them. Fail loudly instead.
if (!validated.buildViaMcp && raw.buildOnlyFlags.length > 0) {
throw new Error(
`${[...new Set(raw.buildOnlyFlags)].join(', ')} only take${raw.buildOnlyFlags.length === 1 ? 's' : ''} effect with --build-via-mcp — pass it, or drop the flag(s).`,
);
}
if (validated.deletePrebuiltWorkflows && !validated.prebuiltWorkflows) {
throw new Error('--delete-prebuilt-workflows requires --prebuilt-workflows');
}
if (validated.deletePrebuiltWorkflows && validated.keepWorkflows) {
throw new Error('--delete-prebuilt-workflows cannot be used with --keep-workflows');
}
if (validated.source === 'langtracer' && !validated.suite) {
throw new Error('--source langtracer requires --suite <slug>');
}
// In langtracer mode, default the dataset + baseline to a suite-scoped, eval-tagged
// name so runs don't pollute the shared cohort and re-runs upsert one stable dataset.
let dataset = validated.dataset;
let datasetAutoForked = false;
let baselinePrefix = validated.baselinePrefix;
if (validated.source === 'langtracer' && validated.suite) {
const suiteSlug = validated.suite
.toLowerCase()
.replace(/[^a-z0-9]+/g, '-')
.replace(/^-+|-+$/g, '');
if (!raw.datasetProvided) {
dataset = `instance-ai-langtracer-${suiteSlug}`;
datasetAutoForked = true;
}
if (!raw.baselineProvided) baselinePrefix = `instance-ai-langtracer-${suiteSlug}-baseline-`;
}View on GitHub (pinned to 5ac6606e81)
Solutions
- Add --suite <suite-slug-or-id> to the command.
- If you did not intend langtracer mode, remove --source langtracer (disk is the default).
- Verify the suite slug exists in your langtracer instance before passing it.
Example fix
// before pnpm eval:instance-ai --source langtracer --base-url http://localhost:5678 // after pnpm eval:instance-ai --source langtracer --suite my-suite-slug --base-url http://localhost:5678
Defensive patterns
Strategy: validation
Validate before calling
function validateLangtracerSuite(args: string[]): void {
const idx = args.indexOf('--source');
if (idx !== -1 && args[idx + 1] === 'langtracer' && !args.includes('--suite')) {
throw new Error('--source langtracer requires --suite <slug>');
}
} Prevention
- When switching to langtracer mode, add --suite in the same edit.
- Keep a template per source mode (disk vs langtracer) so the required companion flags are bundled.
- Validate suite existence in langtracer before the eval run.
When it happens
Trigger: Invoking the eval CLI with `--source langtracer` but omitting `--suite <slug>`. The check fires at args.ts:211. The suite value must pass the Zod min(1) constraint.
Common situations: A developer switches from the default disk source to langtracer and forgets the suite argument, or the suite slug was in a different positional form. Also occurs when LANGTRACER_URL/LANGTRACER_API_KEY env vars are set but the specific suite identifier is missing.
Related errors
- --delete-prebuilt-workflows applies to --prebuilt-workflows.
- ${[...new Set(raw.buildOnlyFlags)].join(', ')} only take${ra
- --delete-prebuilt-workflows requires --prebuilt-workflows
- --delete-prebuilt-workflows cannot be used with --keep-workf
- Unknown flag: ${flagName}
AI-assisted analysis of n8n-io/n8n@5ac6606e81 (2026-08-12).
Data as JSON: /api/errors/700d95162ec582b9.
Report an issue: GitHub.