3

Android studio upgraded my gradle wrapper to gradle-4.1-milestone-1-all and seems to have broken the build. Getting the following error.

Gradle sync failed: java.lang.AssertionError: 'com.spotify.sdk:spotify-player-24-noconnect-2.20b:@aar' is not a valid maven coordinate. 

The dependancy is in my gradle script as an implementation and the arr is in my libs folder.

dependencies {
     implementation 'com.spotify.sdk:spotify-player-24-noconnect-2.20b@aar'
} 

Has anyone else come accross this error?

2 Answers 2

3

I am facing the same problem this morning. There's a Github issue that throws more light on the situation. It seems to be an Android Studio bug.

1
  • Its a studio issue. For me everything was working fine till last studio 3.0 canary update. seeing this issue after studio update without any change in any file
    – Anoop
    Jul 5, 2017 at 7:23
1

EDIT studio update 3.0 canary 6 has solved it.

OLD: So I was facing the same issue (could be like yours) after the canary update. I had an aar file in the libs directory added as a dependency.

this is what it was before

compile(name: 'materialbarcodescanner-release', ext: 'aar') {
    exclude group: 'com.android.support', module: 'appcompat-v7'
}

this is what solved it

 compile('com.edwardvanraak:materialbarcodescanner-release@aar') {
    exclude group: 'com.android.support', module: 'appcompat-v7'
}

basically added the '{packagename}:{filename}@arr' instead of the usual convention.

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.