mirror of
https://github.com/chidiwilliams/buzz.git
synced 2026-03-14 14:45:46 +01:00
Fix for errors in test
This commit is contained in:
parent
069da6c662
commit
dbff054772
1 changed files with 1 additions and 2 deletions
|
|
@ -22,7 +22,7 @@ class RecordingAmplitudeListener(QObject):
|
|||
self.input_device_index = input_device_index
|
||||
self.buffer = np.ndarray([], dtype=np.float32)
|
||||
self.accumulation_size = 0
|
||||
self._active = False
|
||||
self._active = True
|
||||
|
||||
def start_recording(self):
|
||||
try:
|
||||
|
|
@ -34,7 +34,6 @@ class RecordingAmplitudeListener(QObject):
|
|||
)
|
||||
self.stream.start()
|
||||
self.accumulation_size = int(self.stream.samplerate * self.ACCUMULATION_SECONDS)
|
||||
self._active = True
|
||||
except Exception as e:
|
||||
self.stop_recording()
|
||||
logging.exception("Failed to start audio stream on device %s: %s", self.input_device_index, e)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue