bluebubbles-server icon indicating copy to clipboard operation
bluebubbles-server copied to clipboard

Inbound messages not being received after Mac innactivity

Open LarryRage opened this issue 6 months ago • 4 comments

After roughly ~10-15 minutes of complete inactivity on a Mac, inbound messages are received either after an ~8-15 minute delay, or not until the Messages app is brought to the foreground. This issue results in webhooks not being fired in real or near real time. Sometimes even bringing Messages to the foreground is not sufficient enough to "receive" those messages, and the user has to cycle through chats and interact with Messages.

Steps to reproduce:

-Run Bluebubbles server -Keep Messages app in the background and wait ~10-15 minutes, make sure there is no activity on the Mac. You can run caffeinate and or run amphetamine. -Send a message from another number (not from Bluebubbles, so this is an inbound message to the server) -Message will not be received instantly. It is sometimes finally received after a delay of a few minutes, or when the Messages app is brought to the foreground and interacted with, all the inbound messages finally "dump" into the Messages app. You can also "force" the messages to come in by sending a message from the server. This seemingly "wakes" the Messages app.

Setup: -Mac mini M2 -MacOS Sequoia 15.3 -Zrok proxy -Webhooks configured

I believe this issue may not be an issue with Bluebubbles itself, but an operating system related one. It could be that the operating system is idling Messages after inactivity, and incoming network requests are not being picked up on, meaning that chat.db and chat.db-wal are not being written to, so Bluebubbles does not pick up on the incoming messages. Perhaps there is another way to poll for new messages, or some script or setting in the operating system that prevents the network connection from idling?

LarryRage avatar Jun 24 '25 20:06 LarryRage

Update: The issue was not successfully recreated on an intel mac, but issue was found and still persists on M series mac. This problem is most likely an operating system related one.

LarryRage avatar Jun 26 '25 01:06 LarryRage

I appear to be having this issue as well on an Intel Mac after upgrading to Sequoia.

TheBlueMatt avatar Jun 28 '25 16:06 TheBlueMatt

I would honestly just rollback your OS to Ventura until the devs can get some sort of fix. With Ventura I have not experienced this issue.

LarryRage avatar Jun 30 '25 19:06 LarryRage

Seems to work fine if I disable screensaver entirely.

TheBlueMatt avatar Jun 30 '25 22:06 TheBlueMatt