diff --git a/aider/voice.py b/aider/voice.py index 5f6086cf5..f0879b319 100644 --- a/aider/voice.py +++ b/aider/voice.py @@ -46,6 +46,12 @@ class Voice: return f"Recording, press ENTER when done... {dur:.1f}sec {bar}" def record_and_transcribe(self): + try: + return self.raw_record_and_transcribe() + except KeyboardInterrupt: + return + + def raw_record_and_transcribe(self): self.q = queue.Queue() filename = tempfile.mktemp(suffix=".wav")