Reputation: 15
Getting below error while playing sample song spotify:track:2TpxZ7JUBn3uw46aR7qd6V
I/SpotifySDK﹕ Got notification: Became active playing device
I/SpotifySdkDemo﹕ Player event: became active
**E/SpotifySDK﹕ Got error 8**
Sample Code
Spotify spotify = new Spotify(access_token);
mPlayer = spotify.getPlayer(this, "My Company Name", this,
new Player.InitializationObserver() {
@Override
public void onInitialized() {
mPlayer.addConnectionStateCallback(SpotifyAuthActivityDemo.this);
mPlayer.addPlayerNotificationCallback(SpotifyAuthActivityDemo.this);
mPlayer.play("spotify:track:2TpxZ7JUBn3uw46aR7qd6V");
}
@Override
public void onError(Throwable throwable) {
Log.e("MainActivity", "Could not initialize player: " + throwable.getMessage());
}
});
Upvotes: 0
Views: 152
Reputation: 18776
Error 8 is "Login failed: Bad credentials". Check your login credentials and handle the appropriate login events in the SDK accordingly.
Upvotes: 1