spotify / android-sdk

Spotify SDK for Android
https://developer.spotify.com/documentation/android/
Apache License 2.0
462 stars 119 forks source link

Spotify App Remote does not connect on most Android 14 devices (Upside Down Cake) #361

Open Virock opened 6 months ago

Virock commented 6 months ago

Thanks for your interest in the Spotify App Remote SDK! If you're submitting a bug, please use the following template. If your issue is a feature request, please include your use-case so that we have all the necessary info.

Issue found on DATE. 3/20/2024

SDK Version:

Spotify Android SDK v0.8.0

OS Version:

Android Version 14 (Upside Down Cake)

Scope(s):

playlist-read-private playlist-modify-private playlist-read-collaborative playlist-modify-public user-library-read user-read-private user-library-modify user-top-read user-read-playback-state user-read-email

Steps to reproduce:

  1. Connect the app remote:

    SpotifyAppRemote.connect(this, connectionParams, new Connector.ConnectionListener() {
        @Override
        public void onConnected(SpotifyAppRemote spotifyAppRemote) {
    
        }
    
        @Override
        public void onFailure(Throwable throwable) {
    
        }
    });

    Expected behaviour:

    onConnected or onFailure should be called

    Actual behaviour:

    On most Android 14 devices, neither is called. It doesn't even time out. It just never connects and never gives an error message.

aniketTCodes commented 4 months ago

I am also facing the same issue

tim-ebner-exxeta commented 3 months ago

I had the same issue. This worked out for me: https://github.com/spotify/android-sdk/issues/273#issuecomment-706176433

duytq2dsv commented 2 months ago

I got the same issue With the same source code Android 11: able to open auth screen and then connected success Android 14: didn't do anything

Virock commented 1 week ago

@tim-ebner-exxeta Hi. I read the code in the link you posted but there is no way to get a reference to the SpotifyAppRemote instance in that code.