Skip to content

Commit 71ef584

Browse files
authored
feat(runner): add debug log in run_async (#310)
* feat(runner): add debug log in run_async * feat(runner): fix typo
1 parent 43044eb commit 71ef584

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

veadk/runner.py

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -138,6 +138,17 @@ async def wrapper(
138138
**kwargs,
139139
):
140140
yield event
141+
if event.get_function_calls():
142+
for function_call in event.get_function_calls():
143+
logger.debug(f"Function call: {function_call}")
144+
elif (
145+
event.content is not None
146+
and event.content.parts
147+
and event.content.parts[0].text is not None
148+
and len(event.content.parts[0].text.strip()) > 0
149+
):
150+
final_output = event.content.parts[0].text
151+
logger.debug(f"Event output: {final_output}")
141152

142153
post_run_process(self)
143154

0 commit comments

Comments
 (0)