Skip to content

fix: macOS Bluetooth input fallback to prevent media pause during recording#1146

Open
3manu31 wants to merge 1 commit intocjpais:mainfrom
3manu31:fix/macos-bluetooth-input-fallback
Open

fix: macOS Bluetooth input fallback to prevent media pause during recording#1146
3manu31 wants to merge 1 commit intocjpais:mainfrom
3manu31:fix/macos-bluetooth-input-fallback

Conversation

@3manu31
Copy link
Copy Markdown

@3manu31 3manu31 commented Mar 25, 2026

Prevents audio pause/glitches during recording with any Bluetooth input device as the default microphone by prioritizing non-Bluetooth alternatives to avoid CoreAudio profile switches that some media apps interpret as route changes.

Before Submitting This PR

Please confirm you have done the following:

If this is a feature or change that was previously closed/rejected:

  • I have explained in the description below why this should be reconsidered
  • I have gathered community feedback (link to discussion below)

Human Written Description

Recently started using Handy, however, I kept finding myself not using much as I wear airpods all day, and when I do wear airpods my experience with Handy has been far from perfect. 2 issues: 1st: when listening to music (on airpods) and then start recording with Handy, then the music becomes muffled and too loud, because a switch to CoreAudio profile occurs as if I am in a call, and the moment I stop recording (when the mic is not in use anymore), then it goes back to normal. 2nd: I use an app for white noise that auto pauses when CoreAudio profile switching occurs (e.g. when switching output sources, or start/end a call), and so each time I would trigger Handy, then the white noise would completely pause).

I fixed it by adding a fallback to non-bluetooth input devices on macOS when the default input is Bluetooth, preventing those switches that cause the problem.
I think it would be good to implement the fix on the official version of Handy. P.s. if necessary, I would be willing to also add it as a setting on the advanced settings page, for users to optionally opt for it or not, I know I personally would because I keep finding myself having to choose between using my airpods and using Handy, and I don't want to have to choose.

Related Issues/Discussions

Fixes the unwanted behavior described in #646, where AirPods handoff is triggered by the use of Handy. Additionally, it addresses another issue reported in a comment of #646 (#646 (comment)), where Airpods as mac audio output cause the sound volume to get too loud (and the quality to become muffled).

Community Feedback

I haven’t gathered community feedback yet. This fix is based on my own reproducible issue.

Testing

MacOS 26.3.1 (and also MacOS 26.4), Handy version: v0.8.0.
I repeated the same tests that I initially did to pinpoint the point where the issue was:

  • Used handy with Airpods and music playing on Apple Music on my mac, with and without "Mute while recording" on.
  • used handy with Airpods and my white noise app, with and without "mute while recording" on.
  • did the same thing but without airpods (system audio) this time.

After that I did another test to confirm the issue #646 is fixed:

  • on Handy version v0.8.0 I managed to replicate the issue reported, by playing music on my iphone with output to my Airpods, and then triggered Handy on Mac. Handoff got triggered and the music on the iphone stopped playing, in favor of the Handy recording on Mac.
  • Then tested it on my fixed version: played music on my iphone with output to my airpods, and then triggered Handy on my Mac. The music kept playing on the AirPods connected to the iPhone, while Handy handled the recording with the system's microphone.

In case it matters, the white noise app I use is called "Ooooo" on the mac app store, and it is what helped me pinpoint the source of the issue.

Screenshots/Videos (if applicable)

AI Assistance

  • No AI was used in this PR
  • AI was used (please describe below)

If AI was used:

  • Tools used: Github copilot
  • How extensively: helped me in finding the file where the issue was and in debugging

…ording

Prevents audio pause/glitches during recording with any Bluetooth input device
as the default microphone by prioritizing non-Bluetooth alternatives to avoid
CoreAudio profile switches that some media apps interpret as route changes.
@cjpais
Copy link
Copy Markdown
Owner

cjpais commented Mar 26, 2026

@VirenMohindra curious what you think

I haven't reviewed in depth. Feels a bit like a hack, but also maybe worth it for AirPods devices which are super common?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants