mirror of
https://github.com/All-Hands-AI/OpenHands.git
synced 2026-01-09 14:57:59 -05:00
fix issue where message is none (#5307)
This commit is contained in:
@@ -245,7 +245,7 @@ class LLM(RetryMixin, DebugMixin):
|
||||
with open(log_file, 'w') as f:
|
||||
f.write(json.dumps(_d))
|
||||
|
||||
message_back: str = resp['choices'][0]['message']['content']
|
||||
message_back: str = resp['choices'][0]['message']['content'] or ''
|
||||
tool_calls = resp['choices'][0]['message'].get('tool_calls', [])
|
||||
if tool_calls:
|
||||
for tool_call in tool_calls:
|
||||
|
||||
Reference in New Issue
Block a user