Bug Report
Environment
- livekit-agents: 1.5.2 - livekit-plugins-aws: 1.5.2
- Python: 3.12
- Model: Nova Sonic 2.0 (amazon.nova-sonic-v1:0)
- Region: us-east-1
Description
When running multiple concurrent rooms with Nova Sonic 2 and registered @function_tools, some rooms fail to execute tools and the following error appears
in the logs:
agent_turn: TypeError: string indices must be integers, not 'str'
The error is intermittent — it only affects some rooms under concurrent load, not all.
Steps to Reproduce
- Set up an AgentSession with Nova Sonic 2 and at least one @function_tool that takes a string argument.
- Simulate 10+ concurrent rooms where participants speak and trigger the tool.
- Observe that some rooms fail with the TypeError above instead of executing the tool.
Reactions are currently unavailable
Bug Report
Environment
Description
When running multiple concurrent rooms with Nova Sonic 2 and registered @function_tools, some rooms fail to execute tools and the following error appears
in the logs:
agent_turn: TypeError: string indices must be integers, not 'str'
The error is intermittent — it only affects some rooms under concurrent load, not all.
Steps to Reproduce