FN-5832: surface unsupported message-role provider errors
Make unsupported provider message-role failures fail fast with actionable operator guidance. - detect provider errors that reject `messages.[n].role` values via a dedicated transient-error detector helper - classify unsupported message-role failures as operator-actionable/permanent to prevent retry loops - annotate `promptSessionAndCheck` failures with model/provider compatibility guidance for imported company-role agents - add regression tests for role-error detection, operator-actionable classification, and prompt-boundary error hinting - add a patch changeset for `@runfusion/fusion` Files changed: .changeset/fn-5832-unsupported-message-role.md | 5 +++ .../pi-prompt-session-and-check-recursion.test.ts | 24 +++++++++++++++ .../src/__tests__/transient-error-detector.test.ts | 36 ++++++++++++++++++++++ packages/engine/src/pi.ts | 8 +++++ packages/engine/src/transient-error-detector.ts | 14 ++++++++- 5 files changed, 86 insertions(+), 1 deletion(-) Fusion-Task-Id: FN-5832 Fusion-Task-Lineage: b3f78f0e-d097-4cb7-a652-dc547f46fe1d
This commit is contained in:
5
.changeset/fn-5832-unsupported-message-role.md
Normal file
5
.changeset/fn-5832-unsupported-message-role.md
Normal file
@@ -0,0 +1,5 @@
|
||||
---
|
||||
"@runfusion/fusion": patch
|
||||
---
|
||||
|
||||
Classify provider 400 errors for unsupported `messages.[n].role` values as operator-actionable agent errors, and annotate prompt-boundary failures with a clear model/provider compatibility hint. This stops invisible retry loops and makes misconfigured imported agent model/provider combinations fail fast with actionable diagnostics.
|
||||
Reference in New Issue
Block a user