contrib-drivers icon indicating copy to clipboard operation
contrib-drivers copied to clipboard

Gradle not resolving after compiling rainbow hat

Open soorajshankar opened this issue 7 years ago • 5 comments

Error:Execution failed for task ':app:preDebugAndroidTestBuild'.

Conflict with dependency 'com.android.support:support-annotations' in project ':app'. Resolved versions for app (24.2.0) and test app (25.4.0) differ. See https://d.android.com/r/tools/test-apk-dependency-conflicts.html for details.

soorajshankar avatar Dec 17 '17 11:12 soorajshankar

Can you post the line in your gradle file you're using to import the rainbow hat?

On Sun, Dec 17, 2017, 3:10 AM soorajshankar [email protected] wrote:

Error:Execution failed for task ':app:preDebugAndroidTestBuild'.

Conflict with dependency 'com.android.support:support-annotations' in project ':app'. Resolved versions for app (24.2.0) and test app (25.4.0) differ. See https://d.android.com/r/tools/test-apk-dependency-conflicts.html for details.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/androidthings/contrib-drivers/issues/85, or mute the thread https://github.com/notifications/unsubscribe-auth/ADI58_LG4rCxBB0LEdrNqRRXtmUA-iehks5tBPa2gaJpZM4REns5 .

Fleker avatar Dec 17 '17 17:12 Fleker

I fixed that by removing expresso from dependency . But seems some version mismatching is there. BTW this was the way I imported rainbowhat

compile 'com.google.android.things.contrib:driver-rainbowhat:+'

also tried with older version 0.7 and all

Min SDK version 26 target SDK version 26 (tried with 24 as min also then things was not compatible)

soorajshankar avatar Dec 17 '17 18:12 soorajshankar

Looks like Rainbow Hat uses 24.2.0 of Android Support Annotations, but only for testing. I don't know why it would conflict with your version.

Fleker avatar Dec 17 '17 19:12 Fleker

I think Android Support Annotations are defined as Implementation but not Test Implementation

I doubt that could be a problem if I use another support library with different version

soorajshankar avatar Dec 18 '17 11:12 soorajshankar

Yes you're right it isn't defined as testImplementation, but I do wonder why this library is using it. It probably should be updated or perhaps removed.

But implementation shouldn't pass the dependencies through AFAIK.

Fleker avatar Dec 18 '17 18:12 Fleker