iOS alarm badge not working

Summary
I don’t see the notification badge in the iOS app.


iOS 17.5.1

https://docs.mattermost.com/deploy/mobile-app-changelog.html

Fixed an issue on iOS where the badge number was not correct sometimes.

It’s in the patch notes, but it still doesn’t seem to fix the issue.

Steps to reproduce
iOS setting: alarm on, badge on, banner on

Banner notifications display normally
However, the badge is not displayed.

Expected behavior
show badge

Hello Eooooq,

Mattermost developer here. I have two questions to follow up.

  • When you open the app and then put it back in the background, does the notification badge properly updates?
  • Do you see any difference between having the app in the backround or completely closed?

Thank you!

  • background: same ( no badge )
  • completely close: same ( no badge )

No other clients are running (other phone, desktop)

Thank you for the response.

Would you be able to join our community server and send me through a DM the logs of the app?

The community server is https://community.mattermost.com . My handle over there is @daniel.espino-garcia . In order to get the logs of the app, hit your profile, settings, and report a problem.

Thank you!

@larkox

Please share a description of the problem:


Current User Id: 
Current Team Id: 
Server Version: 9.9.0 (Build 9307585135)
App Version: 2.17.1 (Build 529)
App Platform: ios
Device Model: iPhone14,2




2024/06/30 00:50:36:407 DEBUG Setting the badge count based on database values to 0
2024/06/30 09:00:08:435 INFO websocket closed wss://domain.com/api/v4/websocket?connection_id=rand&sequence_number=2
2024/06/30 09:00:09:052 DEBUG Not updating badge count, since we have no mentions in the database, and the number of notifications in the notification center is 1
2024/06/30 09:00:10:064 DEBUG Updating a record with pending changes in table PostsInChannel
2024/06/30 09:00:10:160 DEBUG Trying to batch a record with no prepared state on table PostsInChannel
2024/07/01 00:26:57:732 INFO websocket re-established connection to wss://domain.com/api/v4/websocket?connection_id=rand2&sequence_number=1
2024/07/01 00:26:57:773 INFO wss://domain.com/api/v4/websocket?connection_id=rand2&sequence_number=1 got connection id  randid
2024/07/01 00:26:57:773 INFO wss://domain.com/api/v4/websocket?connection_id=rand2&sequence_number=1 long timeout, or server restart, or sequence number is not found, or first connect after failure.
2024/07/01 00:26:58:355 INFO WEBSOCKET RECONNECT MODELS BATCHING TOOK 25ms
2024/07/01 00:26:59:142 DEBUG error on fetchBindings Received invalid response from the server.; JSON could not be serialized because of error:
The data cannot be read because it is not in the correct format.
2024/07/01 00:27:01:915 INFO Running "Settings
2024/07/01 00:27:03:493 INFO Running "SettingsAdvanced
2024/07/01 00:27:06:370 INFO Running "SettingsDisplay
2024/07/01 00:27:14:851 DEBUG Setting the badge count based on database values to 0
2024/07/01 00:27:41:244 INFO Launch app in Home screen
2024/07/01 00:27:41:377 INFO Running "Home
2024/07/01 00:27:42:313 DEBUG Not updating badge count, since we have no mentions in the database, and the number of notifications in the notification center is 1
2024/07/01 00:27:46:652 INFO websocket connecting to wss://domain.com/api/v4/websocket?connection_id=&sequence_number=0
2024/07/01 00:27:46:761 INFO websocket connected to wss://domain.com/api/v4/websocket?connection_id=&sequence_number=0
2024/07/01 00:27:46:773 INFO wss://domain.com/api/v4/websocket?connection_id=&sequence_number=0 got connection id  idrand
2024/07/01 00:27:46:886 INFO WEBSOCKET RECONNECT MODELS BATCHING TOOK 17ms
2024/07/01 00:27:47:053 DEBUG error on fetchBindings Received invalid response from the server.; JSON could not be serialized because of error:
The data cannot be read because it is not in the correct format.
2024/07/01 00:27:49:327 DEBUG Not updating badge count, since we have no mentions in the database, and the number of notifications in the notification center is 1
2024/07/01 00:27:52:129 INFO Running "Settings

@Eooooq According to the logs several times the database could not find any mention unread in the server.

Do the notifications you receive generate a mention badge inside the app?

Doing local tests, if I have a channel notification setting to send a notification for all messages, only the ones where I am strictly mentioned generate a badge. Is this what you are experiencing? Or does this happen for you for messages that generate a badge in app? (e.g. direct messages or explicit mentions)

@larkox

Settings - Notifications - Mentions: @channel, @all, @here [on]
If the message mentions @all , Badges display correctly

I get notifications for unmentioned messages, but my badge doesn’t increase.

I’m receiving messages from bots that don’t include mentions.
Do I have to have a mention to see the badge?
I believe the badge should show even if there are no mentions.

Same issue I am facing, I only get the badge if the message contains a mention