fix: stop the prepared demo failure from degrading n8n integration health
The demo seed plants exactly one failed delivery (BK-H-0020) to demonstrate retry and audit. Because derive_n8n_status() counted any failure, every fresh reset pinned the n8n integration to "degraded" -- the demo showed a warning about a prop, which tells a viewer something untrue about the automation. The seeded failure now carries its own error code, demoScenarioTimeout, rather than the generic connectionError a real timeout produces. No column and no migration: last_error_code already existed, is already surfaced to the UI and is already localizable. - integration status splits failed into unexpected_failed and demo_scenario_failed; only unexpected failures may move the state. A staged failure alone leaves n8n operational. - latest_failure_at is a health signal and now ignores the staged failure; latest_demo_scenario_at reports it separately. - /api/v1/workflows exposes is_demo_scenario. The Automation page labels the run as a prepared demo scenario, explains that it is a simulated temporary failure that does not affect automation health, and offers a distinct "retry demo scenario" action. Translated in nl-BE, en-GB and fr-BE. - the carve-out stays narrow: a real failure still degrades n8n, and a genuine later failure of the same event overwrites the demo code with the real one. - the retry itself is unchanged and real: the event goes back on the outbox and the dispatcher delivers it to n8n like any other, so 19+1 becomes 20+0 only on an actual round trip. The audit records which kind of failure was retried. Tests that assert on the seeded scenario now reseed first, since earlier test files legitimately mutate the outbox and the suite shares one database. Verified locally against a real PostgreSQL 16: 181 passed, ruff clean, mypy clean (50 files), tsc clean, frontend build clean. Not deployed and not browser-verified.
This commit is contained in:
@@ -19,7 +19,8 @@
|
||||
"mcpNoEvidence": "Registered, but no tool call has been recorded yet.",
|
||||
"mcpEvidence": "Last call: {{tool}} by {{client}} · {{count}} total calls",
|
||||
"mcpHubReachable": "Hub reachable",
|
||||
"mcpHubUnreachable": "Hub unreachable"
|
||||
"mcpHubUnreachable": "Hub unreachable",
|
||||
"n8nDemoScenario": "Plus {{count}} prepared demo scenario — a simulated temporary failure, not an integration problem."
|
||||
},
|
||||
"statusLabels": {
|
||||
"notConnected": "Not connected",
|
||||
@@ -97,7 +98,11 @@
|
||||
"malformedPayload": "The job contained incomplete data and could not be delivered. The underlying data remains safely stored.",
|
||||
"remoteReportedFailure": "The workflow service declined the delivery. The job can be retried.",
|
||||
"staleLeaseRecovered": "This job was recovered after an earlier delivery attempt stalled without a result.",
|
||||
"unknownError": "An unexpected error occurred while delivering this job."
|
||||
}
|
||||
"unknownError": "An unexpected error occurred while delivering this job.",
|
||||
"demoScenarioTimeout": "Simulated timeout towards the workflow service. This failure is part of the prepared demo scenario, not a real incident."
|
||||
},
|
||||
"demoScenarioBadge": "Prepared demo scenario",
|
||||
"demoScenarioExplanation": "Simulated temporary failure, planted by the demo data on purpose to show retry and audit. It does not affect the health of the automation.",
|
||||
"retryDemoScenario": "Retry demo scenario"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -19,7 +19,8 @@
|
||||
"mcpNoEvidence": "Enregistré, mais aucun appel d'outil n'a encore été consigné.",
|
||||
"mcpEvidence": "Dernier appel : {{tool}} par {{client}} · {{count}} appels au total",
|
||||
"mcpHubReachable": "Hub accessible",
|
||||
"mcpHubUnreachable": "Hub inaccessible"
|
||||
"mcpHubUnreachable": "Hub inaccessible",
|
||||
"n8nDemoScenario": "Plus {{count}} scénario de démonstration préparé — une panne temporaire simulée, pas un problème d'intégration."
|
||||
},
|
||||
"statusLabels": {
|
||||
"notConnected": "Non connecté",
|
||||
@@ -97,7 +98,11 @@
|
||||
"malformedPayload": "La tâche contenait des données incomplètes et n'a pas pu être livrée. Les données sous-jacentes restent enregistrées en toute sécurité.",
|
||||
"remoteReportedFailure": "Le service d'automatisation a refusé la livraison. La tâche peut être soumise à nouveau.",
|
||||
"staleLeaseRecovered": "Cette tâche a été récupérée après qu'une tentative de livraison précédente s'est arrêtée sans résultat.",
|
||||
"unknownError": "Une erreur inattendue s'est produite lors de la livraison de cette tâche."
|
||||
}
|
||||
"unknownError": "Une erreur inattendue s'est produite lors de la livraison de cette tâche.",
|
||||
"demoScenarioTimeout": "Délai d'attente simulé vers le service de workflow. Cette panne fait partie du scénario de démonstration préparé, ce n'est pas un incident réel."
|
||||
},
|
||||
"demoScenarioBadge": "Scénario de démonstration préparé",
|
||||
"demoScenarioExplanation": "Panne temporaire simulée, placée volontairement dans les données de démonstration pour montrer la relance et l'audit. Elle n'affecte pas la santé de l'automatisation.",
|
||||
"retryDemoScenario": "Relancer le scénario de démonstration"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -19,7 +19,8 @@
|
||||
"mcpNoEvidence": "Geregistreerd, maar er is nog geen tool-aanroep geregistreerd.",
|
||||
"mcpEvidence": "Laatste aanroep: {{tool}} door {{client}} · {{count}} aanroepen in totaal",
|
||||
"mcpHubReachable": "Hub bereikbaar",
|
||||
"mcpHubUnreachable": "Hub onbereikbaar"
|
||||
"mcpHubUnreachable": "Hub onbereikbaar",
|
||||
"n8nDemoScenario": "Plus {{count}} voorbereid demoscenario — een gesimuleerde tijdelijke fout, geen integratieprobleem."
|
||||
},
|
||||
"statusLabels": {
|
||||
"notConnected": "Niet gekoppeld",
|
||||
@@ -97,7 +98,11 @@
|
||||
"malformedPayload": "De opdracht bevatte onvolledige gegevens en kon niet worden afgeleverd. De onderliggende gegevens blijven veilig bewaard.",
|
||||
"remoteReportedFailure": "De workflowdienst heeft de aflevering geweigerd. De opdracht kan opnieuw worden aangeboden.",
|
||||
"staleLeaseRecovered": "Deze opdracht werd hersteld nadat een eerdere afleverpoging vastliep zonder resultaat.",
|
||||
"unknownError": "Er is een onverwachte fout opgetreden bij het afleveren van deze opdracht."
|
||||
}
|
||||
"unknownError": "Er is een onverwachte fout opgetreden bij het afleveren van deze opdracht.",
|
||||
"demoScenarioTimeout": "Gesimuleerde time-out richting de workflowdienst. Deze fout hoort bij het voorbereide demoscenario en is geen echt incident."
|
||||
},
|
||||
"demoScenarioBadge": "Voorbereid demoscenario",
|
||||
"demoScenarioExplanation": "Gesimuleerde tijdelijke fout, bewust in de demodata gezet om retry en audit te tonen. Ze heeft geen invloed op de gezondheid van de automatisering.",
|
||||
"retryDemoScenario": "Demoscenario opnieuw proberen"
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user