Reputation: 21
I believe the project has been set up exactly as the documentation outlines, but I still am getting this error.
Gradle project sync failed. Basic functionality (e.g. editing, debugging) will not work properly.
Error: Failed to resolve: com.spotify-player-24-noconnect-2.20b: Open File
Any suggestions to correct this?
Upvotes: 2
Views: 1287
Reputation: 1191
I had this same issue. The code in the tutorial is correct, and that compile line is indeed
compile 'com.spotify.sdk:spotify-player-24-noconnect-2.20b@aar'
with a dash between player and 24, contrary to Charlie's answer. The problem I had was earlier in the process- the instructions for installing the auth and player libraries are different. For auth you copy the whole auth library into app/libs whereas for player you just copy the .aar file itself from within the player folder. It's easy to not notice that and just copy both folders.
Given this might be found after the keyword "compile" ceases to be valid, the lines should actually now be:
// This library handles authentication and authorization
api 'com.spotify.android:auth:1.0.0-alpha'
// This library handles music playback
api 'com.spotify.sdk:spotify-player-24-noconnect-2.20b@aar'
Upvotes: 1