播放时出现以下错误 样本歌曲spotify:track:2TpxZ7JUBn3uw46aR7qd6V
I/SpotifySDK﹕ Got notification: Became active playing device
I/SpotifySdkDemo﹕ Player event: became active
**E/SpotifySDK﹕ Got error 8**
示例代码
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());
}
});
答案 0 :(得分:1)
错误8是"登录失败:凭据错误"。检查您的登录凭据并相应地处理SDK中的相应登录事件。