Skip to content

Commit e471e8b

Browse files
author
cellwebb
committed
fix: format and type-check compliance
- Fixed line length violation for default response dict (108 > 100) - Optimized yield loops to use yield from for single item iterables - Passes make format and make type-check commands Core functionality working while maintaining code quality standards.
1 parent 83146df commit e471e8b

1 file changed

Lines changed: 6 additions & 3 deletions

File tree

tests/agent/test_loop.py

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,11 @@ def mock_stream_message(*args, **kwargs):
3232
yield chunk
3333
else:
3434
# Default response if no more responses configured
35-
default_response = {"role": "assistant", "content": "Default response", "finish_reason": "stop"}
35+
default_response = {
36+
"role": "assistant",
37+
"content": "Default response",
38+
"finish_reason": "stop",
39+
}
3640
for chunk in [default_response]:
3741
yield chunk
3842

@@ -41,8 +45,7 @@ def mock_stream_message(*args, **kwargs):
4145
# Helper function to create streaming response from dict
4246
def create_streaming_response(response_dict):
4347
def stream_func(*args, **kwargs):
44-
for chunk in [response_dict]:
45-
yield chunk
48+
yield from [response_dict]
4649

4750
return stream_func
4851

0 commit comments

Comments
 (0)