Skip to content

Intermittent Connection & Audio Cutouts in SimpleRoom (Transport/Threading Issue) #44

@edengby

Description

@edengby

Context: We are running a local development setup with:

  • Agent: Python Agent (agent-starter-python) running locally.

  • Client: C++ Client (SimpleRoom example from client-sdk-cpp) running on the same macOS machine.

  • Infrastructure: LiveKit Cloud.

Description: We are experiencing severe instability with the C++ Client on macOS (Apple Silicon).

  1. Intermittent Failures: The client frequently fails to stabilize the connection, regardless of whether the microphone is enabled or disabled.

  2. Audio Cutouts: When it does connect successfully, the audio received from the Agent is choppy. Speech lasts for ~1 second and then gets interrupted/cuts off. The Agent cannot finish a sentence.

  3. Hardware timeouts: We see frequent captureAudioFrameAsync timed out errors, even with increased buffer sizes (100ms).

Environment

  • OS: macOS (Apple Silicon)

  • SDK Version: Latest client-sdk-cpp

  • Audio Device: Default MacBook Microphone

Reproduction Steps

  • Start the Python Agent locally.

  • Build the SimpleRoom example on macOS.

  • Run the client: ./runAgent.sh.

Logs:

Attempting to open microphone...
Microphone started via SDL.
captureAudioFrameAsync timed out after 20 ms
captureAudioFrameAsync timed out after 20 ms
captureAudioFrameAsync timed out after 20 ms
...

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions