frontend.util.Microphone does not clean its queue of data objects to be output when (re)starting recording.
When using that Microphone with endpointing, recognition may stop after SpeechEndSignal and some data objects are left in the queue when I then call stopRecording(). In particular, the old DataEndSignal is still there (before a new DataStartSignal appears followed by the new audio once I call startRecording() again). The old DataEndSignal breaks recognition (or maybe already VAD?)
The fix is to add a
audioList.clear();
somewhere around line 444 (i.e., before creating the new recordingThread or before starting it).