Commit 4e6625d
committed
fix: handle missing input_json in tool call parsing
When a provider (e.g. MiniMax) sends a tool_use block without
incremental input_json_delta events, the accumulated input_json
key may not exist. Add an explicit else branch to fall back to
the input dict initialized at tool_use start instead of skipping
the else branch and having input remain as the raw {} init value
with a JSONDecodeError silently yielding empty tool args.1 parent 2e16281 commit 4e6625d
1 file changed
Lines changed: 3 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
421 | 421 | | |
422 | 422 | | |
423 | 423 | | |
| 424 | + | |
| 425 | + | |
424 | 426 | | |
425 | 427 | | |
426 | 428 | | |
| |||
442 | 444 | | |
443 | 445 | | |
444 | 446 | | |
445 | | - | |
| 447 | + | |
446 | 448 | | |
447 | 449 | | |
448 | 450 | | |
| |||
0 commit comments