Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Warning logs after updating to version 10.9.1 #955

Closed
andrebcmarinho opened this issue Feb 14, 2024 · 3 comments
Closed

Warning logs after updating to version 10.9.1 #955

andrebcmarinho opened this issue Feb 14, 2024 · 3 comments

Comments

@andrebcmarinho
Copy link

After updating from v10.9.0 to v10.9.1 or any other more recent version I am seeing a lot of warning logs like this:

[18:17:14]: ▸ Found ambiguous variant - android_apps:lib-domain:1.0.1-SNAPSHOT;brandBetaApiElements
[18:17:14]: ▸ org.gradle.internal.component.AmbiguousArtifactVariantsException: The consumer was configured to find a library for use during compile-time, preferably optimized for Android, as well as attribute 'com.android.build.api.attributes.BuildTypeAttr' with value 'beta', attribute 'com.android.build.api.attributes.ProductFlavor:app' with value 'brand', attribute 'com.android.build.api.attributes.AgpVersionAttr' with value '8.2.1', attribute 'org.jetbrains.kotlin.platform.type' with value 'androidJvm'. However we cannot choose between the following variants of project :lib-domain:
[18:17:14]: ▸ - Configuration ':lib-domain:brandBetaApiElements' variant android-classes-jar declares a library for use during compile-time, preferably optimized for Android, as well as attribute 'com.android.build.api.attributes.AgpVersionAttr' with value '8.2.1', attribute 'com.android.build.api.attributes.BuildTypeAttr' with value 'beta', attribute 'com.android.build.api.attributes.ProductFlavor:app' with value 'brand', attribute 'org.jetbrains.kotlin.platform.type' with value 'androidJvm':
[18:17:14]: ▸ - Unmatched attributes:
[18:17:14]: ▸ - Provides attribute 'app' with value 'brand' but the consumer didn't ask for it
(...)
[18:17:14]: ▸ - Incompatible because this component declares a component of category 'verification' and the consumer needed a library
[18:17:14]: ▸ at org.gradle.internal.component.ResolutionFailureHandler.ambiguousArtifactVariantsFailure(ResolutionFailureHandler.java:103)
[18:17:14]: ▸ at org.gradle.api.internal.artifacts.transform.AttributeMatchingArtifactVariantSelector.doSelect(AttributeMatchingArtifactVariantSelector.java:102)
[18:17:14]: ▸ at org.gradle.api.internal.artifacts.transform.AttributeMatchingArtifactVariantSelector.select(AttributeMatchingArtifactVariantSelector.java:79)
[18:17:14]: ▸ at org.gradle.api.internal.artifacts.ivyservice.resolveengine.artifact.VariantResolvingArtifactSet.select(VariantResolvingArtifactSet.java:98)
[18:17:14]: ▸ at org.gradle.api.internal.artifacts.ivyservice.resolveengine.artifact.DefaultVisitedArtifactResults.select(DefaultVisitedArtifactResults.java:55)
[18:17:14]: ▸ at org.gradle.api.internal.artifacts.ivyservice.resolveengine.artifact.DefaultVisitedArtifactResults.selectLenient(DefaultVisitedArtifactResults.java:74)
[18:17:14]: ▸ at org.gradle.api.internal.artifacts.ivyservice.DefaultLenientConfiguration.getSelectedArtifacts(DefaultLenientConfiguration.java:121)
[18:17:14]: ▸ at org.gradle.api.internal.artifacts.ivyservice.DefaultLenientConfiguration.getAllModuleDependencies(DefaultLenientConfiguration.java:200)
[18:17:14]: ▸ at org.gradle.api.internal.artifacts.ivyservice.ErrorHandlingConfigurationResolver$ErrorHandlingLenientConfiguration.getAllModuleDependencies(ErrorHandlingConfigurationResolver.java:147)
[18:17:14]: ▸ at com.mikepenz.aboutlibraries.plugin.util.DependencyCollector.collect(DependencyCollector.kt:80)
[18:17:14]: ▸ at com.mikepenz.aboutlibraries.plugin.AboutLibrariesCollectorTask.configure(AboutLibrariesCollectorTask.kt:35)
[18:17:14]: ▸ at com.mikepenz.aboutlibraries.plugin.AboutLibrariesCollectorTask.action(AboutLibrariesCollectorTask.kt:41)
[18:17:14]: ▸ at java.base@17.0.10/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

I know this is related with a change you did on fbd5b44

My question is if you have any hint on how to fix this or if it is possible to disable these warnings?

Thank you

@mikepenz
Copy link
Owner

At this time there is no way to disable these logs, however I'll have a look to remove the stacktrace from this error message and to only output that if debug is enabled to make it less noisy.

Generally these logs may be relevant, if it may fail to include this library if some variant is not compatible.

@mikepenz
Copy link
Owner

See the latest update for lowered noise by this log

@andrebcmarinho
Copy link
Author

@mikepenz thank you so much for taking a look 👍

Repository owner deleted a comment from Renealpha Feb 18, 2024
Repository owner deleted a comment from Renealpha Feb 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants