commit_user_turn() resolves after scheduling the end-of-turn bounce, which sleeps the endpointing delay before delivering the turn. With turn_detection="manual", a VAD START_OF_SPEECH inside that window cancels the pending task unconditionally (audio_recognition.py, SOS handler). Audio tail around a push-to-talk release (last syllable, breath, button noise) is enough to raise it.
Two problems compound:
- The cancel is silent. No reply is generated and nothing is logged. In manual mode the eou task always belongs to a turn the application already committed, so the VAD is overriding an explicit commit.
- The cancelled bounce skips its turn-scoped cleanup, so
_user_turn_committed stays set and _on_stt_event discards every later transcript until the next commit flushes the stale buffer.
Observed in production (push-to-talk voice app, default injected Silero VAD): a user asked a question, got silence, repeated it; the repeat's audio was also discarded, and the eventual reply was generated from the stale buffer of the first attempt.
Repro: manual mode, commit a turn, deliver a VAD START_OF_SPEECH during the endpointing sleep. The turn never delivers and later finals are dropped. A failing test is included in the linked PR.
Same cancellation-poisoning class as #6913 and #6897. PR with fix and regression tests: #7011.
commit_user_turn()resolves after scheduling the end-of-turn bounce, which sleeps the endpointing delay before delivering the turn. Withturn_detection="manual", a VADSTART_OF_SPEECHinside that window cancels the pending task unconditionally (audio_recognition.py, SOS handler). Audio tail around a push-to-talk release (last syllable, breath, button noise) is enough to raise it.Two problems compound:
_user_turn_committedstays set and_on_stt_eventdiscards every later transcript until the next commit flushes the stale buffer.Observed in production (push-to-talk voice app, default injected Silero VAD): a user asked a question, got silence, repeated it; the repeat's audio was also discarded, and the eventual reply was generated from the stale buffer of the first attempt.
Repro: manual mode, commit a turn, deliver a VAD
START_OF_SPEECHduring the endpointing sleep. The turn never delivers and later finals are dropped. A failing test is included in the linked PR.Same cancellation-poisoning class as #6913 and #6897. PR with fix and regression tests: #7011.