Skip to content

Commit 3d05b71

Browse files
committed
lint
1 parent 18a1272 commit 3d05b71

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

src/agents/run.py

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1138,12 +1138,11 @@ async def _start_streaming(
11381138

11391139
streamed_result.is_complete = True
11401140
finally:
1141-
if streamed_result._input_guardrails_task:
1141+
if task := streamed_result._input_guardrails_task:
11421142
try:
1143-
streamed_result.input_guardrail_results = await streamed_result._input_guardrails_task
1143+
streamed_result.input_guardrail_results = await task
11441144
except Exception:
1145-
# Exceptions will be checked in the stream_events loop
1146-
output_guardrail_results = []
1145+
streamed_result.input_guardrail_results = []
11471146
if current_span:
11481147
current_span.finish(reset_current=True)
11491148
if streamed_result.trace:

0 commit comments

Comments
 (0)