Samsung - alarm_stream notifications still silent
See original GitHub issueHome Assistant Android version: beta-637-94e1f15
Android version: 11
Phone model: SM-G991U
Home Assistant version: 2021.3.4
Last working Home Assistant release (if known):
Description of problem: alarm_stream notifications still silent installing latest beta and fresh start. Configuration below:
type: button
tap_action:
confirmation:
text: Find Phone?
action: call-service
service: notify.mobile_app_s21r8
service_data:
title: Finding Phone
message: Ringing phone
data:
ttl: 0
importance: high
priority: high
tag: Find
channel: alarm_stream
name: Find S21
icon: 'mdi:cellphone-wireless'
Traceback (if applicable, to get the logs you may refer to: https://companion.home-assistant.io/docs/troubleshooting/faqs/#android-crash-logs):
[03-29 15:55:48.322 21235:31640 D/MessagingService]
From: 331041709873
[03-29 15:55:48.323 21235:31640 D/MessagingService]
Message data payload: {tag=Find, title=Finding Phone, channel=alarm_stream, message=Ringing phone, importance=high}
[03-29 15:55:48.325 1740:4671 D/SamsungAlarmManager]
Cancel Alarm calling from uid:10245 pid :3068 / OP:PendingIntent{d45bbac: PendingIntentRecord{12521f2 com.google.android.gms/com.google.android.gms.gcm broadcastIntent}}
[03-29 15:55:48.325 1740:4671 I/SamsungAlarmManager]
setLocked to kernel - T:2 / 20210329T155852, set=30546841, now=30362501
[03-29 15:55:48.326 1740:4671 I/SamsungAlarmManager]
setLocked to kernel - T:3 / 20210329T155559, set=30373189, now=30362501
[03-29 15:55:48.329 21235:21235 D/MessagingService]
Creating notification with following data: {tag=Find, title=Finding Phone, channel=alarm_stream, message=Ringing phone, importance=high}
[03-29 15:55:48.334 21235:21235 D/RingtoneManager]
getActualDefaultRingtoneUri type :4
[03-29 15:55:48.335 21235:21235 I/RingtoneManager]
Ringtone value : content://media/internal/audio/media/110?title=Homecoming&canonical=1
[03-29 15:55:48.336 21235:21235 D/RingtoneManager]
getActualDefaultRingtoneUri type :4
[03-29 15:55:48.336 21235:21235 I/RingtoneManager]
Ringtone value : content://media/internal/audio/media/110?title=Homecoming&canonical=1
[03-29 15:55:48.342 4325:4325 D/BoundBrokerSvc]
onBind: Intent { act=com.google.android.gms.measurement.START pkg=com.google.android.gms }
[03-29 15:55:48.342 4325:4325 D/BoundBrokerSvc]
Loading bound service for intent: Intent { act=com.google.android.gms.measurement.START pkg=com.google.android.gms }
[03-29 15:55:48.342 21235:21235 D/MessagingService]
Show notification with tag "Find" and id "2189785"
[03-29 15:55:48.345 1740:2484 D/ApplicationPolicy]
isStatusBarNotificationAllowedAsUser: packageName = io.homeassistant.companion.android,userId = 0
[03-29 15:55:48.345 1740:2484 D/PersonaManagerAdapter]
ContainerOnlyMode - EOS
[03-29 15:55:48.345 1740:1794 D/SettingsProvider]
isChangeAllowed() : name = enabled_notification_listeners
[03-29 15:55:48.345 1740:1794 D/SettingsProvider]
isChangeAllowed() : name = enabled_notification_assistant
[03-29 15:55:48.345 1740:1794 D/SettingsProvider]
isChangeAllowed() : name = enabled_notification_policy_access_packages
[03-29 15:55:48.346 1740:2484 D/ApplicationPolicy]
isStatusBarNotificationAllowedAsUser: packageName = io.homeassistant.companion.android,userId = 0
[03-29 15:55:48.346 1740:2484 D/PersonaManagerAdapter]
ContainerOnlyMode - EOS
[03-29 15:55:48.383 1740:4671 D/SamsungAlarmManager]
Cancel Alarm calling from uid:10245 pid :4325 / OP:PendingIntent{71a70e5: PendingIntentRecord{b070f9c com.google.android.gms/com.google.android.gms.measurement broadcastIntent}}
[03-29 15:55:48.457 2394:2511 D/NetworkController.SecMobileSignalController(0/1)]
onDataActivity: direction=3
[03-29 15:55:48.459 2394:2511 D/MobileSignalIconsSelector]
getDataIconGroup(): connected=true,enabled=true,level=5,inetCondition=1,dataIconGroup=DataIconGroup(5G_TMO),activityIn=true,activityOut=true,lastModified=03-29 15:55:48.458,dataSim=true,networkName=T-Mobile,networkNameData=T-Mobile,dataConnected=true,roaming=false,isDefault=true,isEmergency=false,airplaneMode=false,carrierNetworkChangeMode=false,userSetup=true,defaultDataOff=false,cdmaEriIconIndex=-1,cdmaEriIconMode=-1,callState=0,voWifiConnected=false,shouldShowDisabledDataIcon=false,bluetoothTethered=false,isLTEFemtoCell=false,cardOperator=OTHERS,optionalRadioTech=0,isCAIndicator=false,isLimitedStateForCTCSlaveVoLTE=false,isSWRoaming=false,isMobileDataSettingEnabled=false,nwBoosterRilEnabled=false,nwBoosterSettingEnabled=false,emergencyModeActivated=false,ismmW5G=false, iconSet = null
[03-29 15:55:48.459 2394:2394 D/StatusbarSignalPolicy]
setMobileDataIndicators state = MobileIconState(subId=1, strengthId=2131233570, roaming=false, typeId=2131233374, visible=true, activityId=0, roamingId=0, slotId=0)
[03-29 15:55:48.490 1012:27998 I/sensors-hal]
handle_sns_client_event:182, auto_rotation_event: mode:255, type:1:0/0.010,0.065,9.882
[03-29 15:55:48.517 1028:1120 I/vendor.qti.hardware.perf@2.2-service]
drmIOCTLLib connectorId: 55
[03-29 15:55:48.518 1028:1120 I/vendor.qti.hardware.perf@2.2-service]
drmIOCTLLib ret: 0
[03-29 15:55:48.518 886:886 E/audit]
type=1400 audit(1617051348.513:28926): avc: denied { sys_admin } for pid=1028 comm="perf@2.2-servic" capability=21 scontext=u:r:vendor_hal_perf_default:s0 tcontext=u:r:vendor_hal_perf_default:s0 tclass=capability permissive=0 SEPF_SM-G991U_11_0007 audit_filtered
[03-29 15:55:48.518 1028:1120 I/vendor.qti.hardware.perf@2.2-service]
drmIOCTLLib close return 0
[03-29 15:55:48.548 1740:1740 I/NotificationService]
RuneStone mIsRuneStoneSupported = true, mIsRuneStoneEnabled = false
[03-29 15:55:48.552 1740:1740 I/AccessibilityManager]
semStartFlashNotification notitype = alarm
[03-29 15:55:48.552 1740:1740 D/AccessibilityManagerService]
semStartFlashNotification
[03-29 15:55:48.552 1740:1740 I/AccessibilityManagerService]
semStartFlashNotificationInner() type=Default, pkgName=android, token=android.os.Binder@226e1c6
[03-29 15:55:48.552 1740:1740 D/AccessibilityManagerService]
Can not use light notification
[03-29 15:55:48.555 1740:1740 D/EdgeLightingManager]
isCallingUserSupported : callingUserId=0, mUserId=0, isDualAppId=false, isKnoxId=false
[03-29 15:55:48.555 1740:1740 D/EdgeLightingManager]
showForNotification : isInteractive=true, isHeadUp=true, color=0, canBypassDnd=false, sbn = StatusBarNotification(pkg=io.homeassistant.companion.android user=UserHandle{0} id=2189785 tag=Find key=0|io.homeassistant.companion.android|2189785|Find|10291: Notification(channel=alarm_stream shortcut=null contentView=null vibrate=null sound=null defaults=0x0 flags=0x10 color=0xff03a9f4 category=alarm vis=PRIVATE semFlags=0x0 semPriority=0 semMissedCount=0))
[03-29 15:55:48.555 1740:1740 D/EdgeLightingClientManager]
isAvailableEdgeLighting: condition=1 mCondition=3 mIsConnected=false0
[03-29 15:55:48.555 1740:1740 D/EdgeLightingManager]
showForNotificationScreenOn : return false by isAvailableEdgeLighting.
[03-29 15:55:48.567 2736:2736 I/Launcher.NotificationListener]
onNotificationPosted : io.homeassistant.companion.android number : 0
[03-29 15:55:48.567 2736:2852 I/Launcher.NotificationListener]
notificationIsValidForUI : io.homeassistant.companion.android missingTitleAndText : false isGroupHeader : false
[03-29 15:55:48.576 2394:2394 D/InterruptionStateProvider]
No bubble up: not allowed to bubble: 0|io.homeassistant.companion.android|2189785|Find|10291
[03-29 15:55:48.577 2394:2394 W/NotifBindPipeline]
Row is not set so pipeline will not run. notif = 0|io.homeassistant.companion.android|2189785|Find|10291
Screenshot of problem:
Additional information:
Issue Analytics
- State:
- Created 2 years ago
- Reactions:1
- Comments:22 (14 by maintainers)
Top Results From Across the Web
Alarm issues when phone is on silent. - Samsung Community
If you put your phone on silent when you go to bed then your alarm will only vibrate. I found the problem and...
Read more >What to do if the alarm, media volume, and ... - Samsung
If your Galaxy watch doesn't make any notification sounds, or if you don't hear any sound from the speaker, the device may be...
Read more >Sometimes the alarm on my Samsung Galaxy device doesn't ...
If the alarm you set through the Clock app on your Samsung Android device is unreliable a software bug is likely the cause...
Read more >What to do if the alarm, media volume, and ... - Samsung
If your Galaxy watch doesn't make any notification sounds, or if you don't hear any sound from the speaker, the device may be...
Read more >Fix for Galaxy watch muted alarm, volume, and ringtone
When your Galaxy watch is set to the Vibrate or Mute mode, the device will not make any sound. Follow the steps below...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I suppose we could add some more debug logs but based on what I see in the logs above the ringtone URI is successfully retrieved but the notification call strips it out for some reason. I dont know if its something samsung has done to the actual notification API or not but I know resorting to media player/ringtone player is not desireable as the audio wont stop naturally like it does on my pixel. Honestly not really sure where to start with it, everything about hte code suggests it should work. Based on the logs above I know my assumption was correct in that the default alarm ringtone was null but not sure why the ringtone itself wont work when its not null.
https://github.com/home-assistant/android/blob/master/app/src/full/java/io/homeassistant/companion/android/notifications/MessagingService.kt#L1032
Can you reproduce it on the tablet?
Thanks for the update. Disabling DND before sending TTS is an alternative that never failed in my case. Posting the actions for anyone interested.