-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Media/alarm audio channels reliant on notification audio channel #36
Comments
I saw a comment related to this after the implementation of #31 but this seems different enough from #22 that I felt I should create a separate GitHub issue |
I think I'm understanding this. I'll take a look at the code and see if I can see a reason for this behaviour. |
It must be this code in notifier.dart, line 213, where it checks the ringerModeStatus
I'll give this some thought, I may want to make a new option to override the phone ringer status. You'd still be able to mute via the 'mute' button on the main app screen. And yes, I believe this issue is actually the same as what @lkblkb was referring to. I didn't realize I'd put in that check for ringer mode status though - I thought from the earlier comment that this behaviour was coming from the library. Your hint about it sounding when playing from the test sound was key. Thanks for pointing that out. I'll hopefully get some time over the next few days to figure something out for this. |
Ah perfect, I'm really glad to hear it's not a limitation in Android itself and the above helped identify the culprit! It's great to hear you're looking to take this on so quickly but please don't feel time pressured. In the meantime, I've set my notifications audio channel to the lowest setting and it's honestly so quiet that I barely notice alerts outside of the much louder alarm audio.
This seems like a reasonable approach to me. My original thought was users changing the audio channel to something other than |
This is a very good point. I think I was probably misunderstanding the entire reason for issue #31. Given the above, yeah, I'm not sure I need to provide a toggle for this behaviour. To summarize, it would work as follows:
This makes sense, right? |
Yep, that makes perfect sense to me! The one remaining question I have is how the audio channels would react to do not disturb being enabled. If If, however, that call unexpectedly circumvents do not distrub, I think adding a toggle as to whether to honor do not distrub would be worthwile. In which case, the |
Do Not Disturb seems to be a bit of a challenge. It looks like it depends a lot on the Android version for the behaviour. I'm seeing in Android 10 that you can allow alarms or media sounds through, but the notification itself (i,e., the popup) is squelched. I think for now I will just put something in where, if DND is active, then there will at minimum be no sound. There may be a notification (if the app is bypassed in Android 11), but there will be no sound. This seems reasonable to me for now, and I may revisit the DND behaviour for Android 11 in the future. |
Phone mute/vibrate setting only applies to notification channel Previously the global phone mute/vibrate notification setting was applied to notification sound regardless of the selected notification channel. This kind of defeats the purpose of having separate notification channels. This commit changes the behaviour to only consider the phone mute/vibrate setting if the 'notification' channel is used. If the sound channel is set to 'media' or 'alarm' the mindful bell notifications will sound regardless of the phone mute/vibrate setting. In this case you can still mute the bell via the app 'Mute' toggle switch on the main app screen. Summary: - App mute is enabled: always mute - For notification channel: honour the phone silent/vibrate-only setting - For media and alarm channels, allow sound unless DND is enabled
Fixed in Release 1.0.19+31 Thanks very much for your input on this! |
@kmac thank you for fixing this so quickly! I have an F-Droid rookie question: is there a propogation delay between GitHub releases and F-Droid updates? Looking at f-droid/fdroiddata, I see an entry for fdroiddata/metadata/com.kmac5dev.mindfulnotifier.yml that was updated to 1.0.19 by the F-Droid checkupdates bot yesterday. I presume this was automated by F-Droid and tied to the 1.0.19+31 GitHub release that you published. What I'm a little confused on is why even after the fdroiddata update, I don't see an update available in F-Droid and the Mindful Notifier page still indicates the last release was a month ago (which aligns with the 1.0.18+30 version I have on my phone). |
I think it usually takes a few days to get a build from fdroid. It should get queued in the fdroid build after I created the v1.0.19 tag in github. I think it just hasn't built it yet. |
Makes sense, thanks again! I'll have to research a bit more on how F-Droid functions since this whole setup is very intriquing; it's awesome having open source apps tied directly to an open source app store. |
First thank you for making such a wonderful app, it's been really helpful for grounding myself in the present moment!
I've noticed the bell configuration's audio channels are not working as I expected, so I'll describe what I'm seeing below to determine whether the behavior is just a limitation of Android notifications.
If I set the audio channel, regardless of whether set to
notification
,media
, oralarm
, I am able to hear my selected bell when pressing play if that channel has it's volume above zero for my phone's respectiveSound & vibration
setting. If, however, I wait until the scheduled notification, I will only hear the bell if my phone'sSound & vibration
setting hasRing & notification volume
set above zero, in addition to the volume of the specific channel I've selected (if notnotification
).My hope by selecting the audio channel was that I would be able to continue to keep my normal notifications on vibrate with
Ring & notification volume
set to zero, while selecting thealarm
audio channel in mindfulnotifier to leverage myAlarm volume
being a non-zero value (in the same way Clock's alarm makes sound even when myRing & notification volume
is set to zero because myAlarm volume
is set above zero).Though this is my first time hearing of Dart, I tried to identify what may be causing this. After inspecting audio.dart and notifier.dart, I don't see a distinction being made in the
AndroidAudioAttributes
that would lead me to expect thatalarm
audio is reliant on thenotification
channel being non-zero.Device Info:
The text was updated successfully, but these errors were encountered: