We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0496c0e commit 18a1272Copy full SHA for 18a1272
src/agents/run.py
@@ -1139,7 +1139,11 @@ async def _start_streaming(
1139
streamed_result.is_complete = True
1140
finally:
1141
if streamed_result._input_guardrails_task:
1142
- await streamed_result._input_guardrails_task
+ try:
1143
+ streamed_result.input_guardrail_results = await streamed_result._input_guardrails_task
1144
+ except Exception:
1145
+ # Exceptions will be checked in the stream_events loop
1146
+ output_guardrail_results = []
1147
if current_span:
1148
current_span.finish(reset_current=True)
1149
if streamed_result.trace:
0 commit comments