-
Notifications
You must be signed in to change notification settings - Fork 152
Closed
Description
Describe the bug
Running :app:getDependencies
task on our Android project (with 26 gradle modules) takes minutes and prints an enormous amount of AmbiguousVariantSelectionException for each of our library modules, resulting in 150+ MB of text logs.
Using AGP 7.0.2
Expected behavior
Correctly handle local library modules
Example log
Failed to process <app id>:<module name>:1.0.0-SNAPSHOT
org.gradle.internal.component.AmbiguousVariantSelectionException: The consumer was configured to find an API of a component, preferably optimized for Android, as well as attribute 'com.android.build.api.attributes.BuildTypeAttr' with value 'release', attribute 'store' with value 'playstore', attribute 'brand' with value 'suunto', attribute 'org.jetbrains.kotlin.platform.type' with value 'androidJvm'. However we cannot choose between the following variants of project :<module name>:
Configuration ':<module name>:releaseApiElements' variant android-aidl declares an API of a component, as well as attribute 'com.android.build.api.attributes.BuildTypeAttr' with value 'release', attribute 'org.jetbrains.kotlin.platform.type' with value 'androidJvm':
- Unmatched attributes:
- Provides attribute 'artifactType' with value 'android-aidl' but the consumer didn't ask for it
- Doesn't say anything about brand (required 'suunto')
- Provides attribute 'com.android.build.gradle.internal.attributes.VariantAttr' with value 'release' but the consumer didn't ask for it
- Doesn't say anything about its target Java environment (preferred optimized for Android)
- Doesn't say anything about store (required 'playstore')
Desktop
- Gradle version: 7.0.2
- AGP: 7.0.2
- Android Studio version: Android Studio Arctic Fox | 2020.3.1 Patch 2
- Plugin name and version: plugin 0.10.4, oss lib 17.0.0
sayedtenkanen, ibevilinc, mrmike, kuuuurt, bartek-wesolowski and 14 more
Metadata
Metadata
Assignees
Labels
No labels