Describe the problem/error/question
When I use the CLI to import all or a workflow, I get this error
What is the error message (if any)?
~ $ n8n import:workflow --input=/files/n8n-workflows/CpDs6GApbWob6kud.json
User settings loaded from: /home/node/.n8n/config
2024-07-03T22:56:52.654Z | debug | Lazy Loading credentials and nodes from n8n-nodes-base "{\n credentials: 356,\n nodes: 453,\n file: 'LoggerProxy.js',\n function: 'exports.debug'\n}"
2024-07-03T22:56:52.669Z | debug | Lazy Loading credentials and nodes from @n8n/n8n-nodes-langchain "{\n credentials: 15,\n nodes: 74,\n file: 'LoggerProxy.js',\n function: 'exports.debug'\n}"
2024-07-03T22:56:52.810Z | debug | [Concurrency Control] Service disabled "{ file: 'concurrency-control.service.js', function: 'log' }"
2024-07-03T22:56:52.892Z | error | An error occurred while importing workflows. See log messages for details. "{ file: 'workflow.js', function: 'catch' }"
2024-07-03T22:56:52.893Z | error | workflows.map is not a function "{ file: 'workflow.js', function: 'catch' }"
~ $ n8n import:workflow --separate --input=/files/n8n-workflows/
User settings loaded from: /home/node/.n8n/config
2024-07-03T22:59:18.830Z | debug | Lazy Loading credentials and nodes from n8n-nodes-base "{\n credentials: 356,\n nodes: 453,\n file: 'LoggerProxy.js',\n function: 'exports.debug'\n}"
2024-07-03T22:59:18.844Z | debug | Lazy Loading credentials and nodes from @n8n/n8n-nodes-langchain "{\n credentials: 15,\n nodes: 74,\n file: 'LoggerProxy.js',\n function: 'exports.debug'\n}"
2024-07-03T22:59:18.976Z | debug | [Concurrency Control] Service disabled "{ file: 'concurrency-control.service.js', function: 'log' }"
2024-07-03T22:59:19.127Z | info | Importing 151 workflows... "{ file: 'workflow.js', function: 'run' }"
2024-07-03T22:59:19.378Z | info | Deactivating workflow "Text To Speech". Remember to activate later. "{ file: 'import.service.js' }"
2024-07-03T22:59:19.394Z | error | An error occurred while importing workflows. See log messages for details. "{ file: 'workflow.js', function: 'catch' }"
2024-07-03T22:59:19.395Z | error | duplicate key value violates unique constraint "idx_812eb05f7451ca757fb98444ce" "{ file: 'workflow.js', function: 'catch' }"
The Credential imports works:
~ $ n8n import:credentials --separate --input=/files/n8n-credentials/
User settings loaded from: /home/node/.n8n/config
2024-07-03T22:55:32.672Z | debug | Lazy Loading credentials and nodes from n8n-nodes-base "{\n credentials: 356,\n nodes: 453,\n file: 'LoggerProxy.js',\n function: 'exports.debug'\n}"
2024-07-03T22:55:32.690Z | debug | Lazy Loading credentials and nodes from @n8n/n8n-nodes-langchain "{\n credentials: 15,\n nodes: 74,\n file: 'LoggerProxy.js',\n function: 'exports.debug'\n}"
2024-07-03T22:55:32.846Z | debug | [Concurrency Control] Service disabled "{ file: 'concurrency-control.service.js', function: 'log' }"
2024-07-03T22:55:33.077Z | info | Successfully imported 26 credentials. "{ file: 'credentials.js', function: 'reportSuccess' }"
Information on your n8n setup
- n8n version: 1.48.2
- Database (default: SQLite): Postgres
- n8n EXECUTIONS_PROCESS setting (default: own, main): own
- Running n8n via (Docker, npm, n8n cloud, desktop app): Docker
- Operating system: Linux