[dotnet-port-fixes] Surface response.failed error content - #804
Conversation
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
There was a problem hiding this comment.
Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.
Note
This error may be related to your runner configuration. You can now configure runners for Copilot code review separately from Copilot cloud agent by creating a copilot-code-review.yml file with your setup steps. Read the docs for details.
Parity Review: ✅ ApprovedThis PR is a direct port of the .NET fix from microsoft/agent-framework#7497. It corrects how Scope: Only unexported helper functions in Parity: The behavior now aligns with the upstream .NET fix — failed responses produce structured error content with a message and error code. The Go-specific addition of a default fallback message/code for responses missing explicit error details is a defensive improvement consistent with the upstream intent. Verdict: No cross-repo consistency issues. No
|
Summary
Port the .NET failure-handling fix from microsoft/agent-framework#7497 into the shared Go Responses provider path so
response.failedevents surface structuredErrorContentinstead of empty updates. The Go change also applies the same fallback to failed non-streaming responses when the provider omits explicit error details, using a default message/code rather than silently dropping the failure.Ported .NET PRs
Upstream commit referenced:
d56e81357e5179b6f916b180c0cb34ea2e73c80b.Breaking Changes
No. This keeps the public Go API unchanged and only corrects how existing failed Responses API events are surfaced to callers.
Tests and Examples
go test ./provider/openaiprovidergo test ./provider/foundryproviderresponse.failedevents and failed responses without explicit provider error detailsNotes
[dotnet-port-fixes]or[dotnet-port-api]issue/PR title inmicrosoft/agent-framework-gomatched this failure-handling area.Closes #787