Hi. I am struggling with the activity indicator. I...
# compose-wear
b
Hi. I am struggling with the activity indicator. I am aware that this is not related to Wear-Compose and I apologize in advance. Currently, my app using Exoplayer and didn't include anything related to ongoing. Even in this state, if a media session and media notification were created in Wear OS 3 and 3.5, an activity indicator could be displayed at the bottom of the watch. However, I confirmed that it is no longer displayed in wear OS 4 (android13). As OS 4 changed to Android 13, notification permission was added, but according to the document, Media sessions are included in the exempt list. Therefore, I am guessing that it is not a permission issue. Looking at the system logs of the sample media player and other apps that normally show the activity indicator on OS 4, I thinks they are using onGoingActivity. Is it changed to use OnGoingActivity for showing ActivityIndicator in OS4? I searched the documentation, but couldn't find anything like this changing. Or am I missing something?
y
That project isn't actively maintained, quite old
The only thing that sounds familiar, I think pocketcasts hit a bug on Wear 4. Let me check
If it's that check log cat for system media processes.
I think this was it, does it sound similar?
If so, there was something strange with the notification artwork. The system not handling it and falling over. But I'd hope it's fixed on newer images.
I'll try to check bug history tomorrow
b
Thanks for reply. Media playback reflection works well in my case on OS4 and OS3.5 like pocket cast's issue. Only different to pocket-cast is in my case it was always occur in OS4 but not in OS3.5 and OS3. Also when I check my notification manager, media notification was activated.
By system log, I thinks big difference of my app and sample app is onNotificationPost. In OS3, when my app and sample app post media notification then system notification also posted on
<http://com.google.android.wearable.app|com.google.android.wearable.app>
. In OS4, when sample app post media notification also trigger system notification on
com.google.android.wearable.media.sessions
, but when my app post media notification not trigger system notification. I thinks this is main different of my app and sample app.
y
Yeah, you are right. That pocket casts issue was a bug in custom actions on Wear on 3.5, working on 4.
I think the other thing to check is Wear 4 notifications permissions.
I think system does that for you.
However, I confirmed that it is no longer displayed in wear OS 4 (android13). As OS 4 changed to Android 13, notification permission was added, but according to the document, Media sessions are included in the exempt list. Therefore, I am guessing that it is not a permission issue.
Our official sample is in Horologist - can you try that?
b
When I play media after grant
android.Manifest.permission._POST_NOTIFICATIONS_
, still not showing activity indicator on watch face. I will check about official sample.
👍 1
@yschimke I found the cause of this problem. The importance of the media notification channel was the problem. When I changed
NotificationManagerCompat.IMPORTANCE_DEFAULT
to
IMPORTANCE_LOW
, onGoingActivity worked normally without any separate implementation In OS 4. However, I didn’t know exactly how
IMPORTANCE_LOW
affects mediaSession in wear OS 4.
IMPORTANCE_DEFAULT
is working for ongoing activity In OS 3 and OS 3.5 and I couldn't find anything related to this in the OS 4 migration documentation. In notification document, it only says "Low: makes no sound and doesn't appear in the status bar." Do you have any clue of what
IMPORTANCE_LOW
solve the problem in OS 4?
y
Yuck. Sounds like a bug. If you can repro in the horologist sample with a simple tweak, then I can take it further. Or raise a bug.
👀 1