Skip to content
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

Duplicate media player notitications #443

Closed
cadecomposer opened this issue May 12, 2021 · 24 comments
Closed

Duplicate media player notitications #443

cadecomposer opened this issue May 12, 2021 · 24 comments

Comments

@cadecomposer
Copy link

cadecomposer commented May 12, 2021

Description
Sometimes I am getting duplicates of the media player notification, and the old ones can't be cleared. It looks like I have different queues from different apps, but only one of them correctly shows what's playing. This is not a problem with the classic notification, only the modern one.

To Reproduce
Steps to reproduce the behavior:

  1. Open Vinyl and start playing music
  2. Check to make sure the player notification is there
  3. Pause the music
  4. Go to the app switcher
  5. Close Vinyl
  6. Reopen Vinyl
  7. Start playing music again
  8. Check notifications, it should have created a duplicate

Expected behavior
I would have expected the older media player notifications to be cleared out, or at least clearable.

Screenshots
Screenshot_20210512-142903_Niagara Launcher
Screenshot_20210512-142914_Niagara Launcher
Screenshot_20210512-142918_Niagara Launcher

Smartphone:

  • Device: Samsung Galaxy S20+ 5G
  • Android Version: 11
  • ROM: One UI 3.1
  • Vinyl Music Player Version: 1.2.0

Additional context
In order to clear the duplicates, I've found that rebooting my device helps; attempting to remove them by long pressing or swiping doesn't do anything. Also, I have a feeling that this is specifically an issue with some/all Android 11 devices due to the changes they made to the media player notifications.

@soncaokim
Copy link
Collaborator

That's curious.

  • is this happening only with Vinyl or with other app/media player as well?
  • do you have any history of using Vinyl before - i.e it starts acting like this just recently or it was the case with previous versions as well?

@cadecomposer
Copy link
Author

  • I've used various other media playing apps on this version of Android (e.g. Musicolet, Pulse, VLC) and not seen this before, I've only seen it happen with Vinyl.
  • I only just started using Vinyl very recently (a couple of days ago), so I can't comment on previous versions of Vinyl or One UI. However I can test previous releases of Vinyl if you think that might help troubleshoot the issue.

@soncaokim
Copy link
Collaborator

Frankly I dont even recognize the notification popup in your screenshots. The OS skin is probably overriding the notification here (the 4 dots, side by side widgets, rounded play button, etc)

There is high probability that rollback to previous versions wont help. If you are comfortable with installing custom APK not vetted by G Playstore, given by a stranger on the internet, then we can think of going down this road.

@cadecomposer
Copy link
Author

Those dots at the bottom are only there because of the duplicates, and it seems that (at least from what I can find) it looks similar on Pixel devices running A11, although I don't have any to test on.
2021-05-12_15-49
I'm not sure what the rounded play button is about though. In any case, I'm certainly willing to test out custom APKs to try and troubleshoot this issue.

@soncaokim
Copy link
Collaborator

similar on Pixel devices running A11,

Yup, looks like we are talking about a new Android feature here: https://android-developers.googleblog.com/2020/08/playing-nicely-with-media-controls.html?m=1

In any case, I'm certainly willing to test out custom APKs to try and troubleshoot this issue.

Here a build of version 1.1.2, before I've made some innocent change to the notification code: https://608-115534318-gh.circle-artifacts.com/0/outputs/circleci/release/vinyl_master_4a7107cd_210512-2020-circleci-release.apk

Please uninstall and reinstall, and telle how it goes.

@cadecomposer
Copy link
Author

Hm, that seems to have fixed it. I went through the same procedure I mentioned earlier a few times on this version and haven't gotten any duplicate players. I wonder what changed?
I'm kind of noob to github so I'll let you close this thread once you deem it fixed. Thanks for being so responsive and helpful, I appreciate it.

@soncaokim
Copy link
Collaborator

Now that's troubling!
I might still need your help in the future to further isolate the issue.

@soncaokim
Copy link
Collaborator

soncaokim commented May 12, 2021

I'm kind of noob to github...

Bug report with precise steps that help reproducing the issue right away - I dont expect that on noob level 👍

--

Can you please check if this build is any better? https://609-115534318-gh.circle-artifacts.com/0/outputs/circleci/release/vinyl_android-11-notification_070ffed7_210512-2246-circleci-release.apk

It should contain the fix, or at least a work around for now. More details in #444

@cadecomposer
Copy link
Author

Now the duplicates are back again...
I restarted to make sure it wasn't a fluke somehow, but nope they came back again
Also I forgot to mention that I always get a "shuffle all" notification on startup, I'm not sure if that's intentional or not
Should I make a recording of all of this to show you what I mean? Maybe it'll help pinpoint what the issue is

@soncaokim
Copy link
Collaborator

Now the duplicates are back again...

Even with the apk containing the fix?

@cadecomposer
Copy link
Author

Yes, the version is 1.2.0-android-11-notification_070ffed7_210512-2246CI
I reinstalled the version of 1.1.2 that you sent me to check, and that one is still working fine

Some other things that might be helpful:

  • Here's that "Shuffle all" thing, I didn't see this on 1.1.2
    Screenshot_20210512-193554_Niagara Launcher
  • If I press "play" on the notification after closing the app from the app switcher but without starting Vinyl again, the interface changes from the circular play button back to the regular interface, and the music plays for a split second and cuts out, but it doesn't make a duplicate notif (it seems like the app is trying to start up again after closing it? I think I'll make a recording in a second so you can see what I mean)

I suppose a solution for my problem would be to just use 1.1.2? However I would like to figure out what's going on here

@cadecomposer
Copy link
Author

Hopefully this can help give some insight
https://youtu.be/SVU9J3-SNcc

@soncaokim
Copy link
Collaborator

Will get in touch with you via this thread. Thanks for the feedback!

@cadecomposer
Copy link
Author

Not a problem, thanks so much for maintaining this app, it's quite wonderful

@soncaokim
Copy link
Collaborator

The "shuffle all" item is intended for Android Auto only (and it can be other item, depending on your library section order) - I guess these are items that are shown with the rounded button in your case.

I've made a new attempt to disable them if they are being requested from the system - can you please have a look?
https://611-115534318-gh.circle-artifacts.com/0/outputs/circleci/release/vinyl_android-11-notification_ae29fc10_210513-1659-circleci-release.apk

@cadecomposer
Copy link
Author

That seems to have fixed the duplication issue
Now if I close the app the music player notification dismisses itself instead of sticking around like it was
Also the shuffle all did not appear on reboot this time
Just to verify the version is 1.2.0-android-11-notification_ae29fc10_210513-1659CI

@soncaokim
Copy link
Collaborator

Now if I close the app the music player notification dismisses itself instead of sticking around like it was

I might revisit that behavior, but if you killed the app explicitly, that's what to be expected, no?

@cadecomposer
Copy link
Author

cadecomposer commented May 13, 2021

I might revisit that behavior, but if you killed the app explicitly, that's what to be expected, no?

Sorry I didn't specify, I meant to say that it was the behavior I was expecting. Before if I closed the app (even if I force stopped the app in settings) the duplicates would still be there, but on this new version you sent me it no longer does that, ergo it's fixed. I haven't seen any issues with the media player in this new version, so I think it's fixed now.

@soncaokim
Copy link
Collaborator

@littlelamp100 I have a question: Have you noticed the following behaviour? I have it on my emulator device, just wonder if this is the case on a real one.

After launch, the now-playing notification is not shown on the first play (must pause/play for it to show up in the notif dropdown)

@cadecomposer
Copy link
Author

I haven't noticed anything like that on my device
To check I closed it, force stopped it and reopened it
Once I started playing music, the notif popped up and I didn't have to pause/play it or anything
I wonder if this behavior is different on stock Android devices though? Perhaps Samsung has done something weird with their implementation of this new media player feature

@cadecomposer
Copy link
Author

Just checking - you meant on the latest build you sent in this thread, correct?

@soncaokim
Copy link
Collaborator

Yes sir

@soncaokim
Copy link
Collaborator

Once I started playing music, the notif popped up and I didn't have to pause/play it or anything

OK, so I will pretend that I dont see this weird behaviour, or it is linked with my slow emulation setup :-)
I'm wrapping this now, dont hesitate to go back and report further findings.

The official release will come later, there are other issues still to be tackled.

@soncaokim
Copy link
Collaborator

Should be fixed now

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants