-
-
Notifications
You must be signed in to change notification settings - Fork 116
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
Could not create an instance of type com.android.build.api.component.analytics.AnalyticsEnabledLayered #1112
Comments
Thanks for the issue! Hopefully the build scan will be enough, but do you have a minimal reproducer? |
Sure. Here's my same dependency copied version of my project |
I had this same issue, seems that it works fine on 1.28.0 👍 |
Yes, it seems likely this was caused by the migration to the new, non-deprecated AGP APIs in 1.29.0. |
This solved my issue of "com.android.build.api.component.analytics.AnalyticsEnabledLayered", but another error "org.jetbrains.kotlin.incremental.IncrementalJvmCompilerRunnerKt" has been occured. For anyone who using jetpack compose with this plugin,
and set app module's compose compiler version to 1.5.0 (due to kotlin version compatibility) as
this solved my issue. |
I cannot reproduce this issue with the reproducer provided, and the changes suggested in this comment. This seems like it might be a Kotlin incompatibility. This plugin currently uses Kotlin 1.9 and is only tested against Kotlin 1.9. Removing from the next milestone until I have reason to believe the problem is in this plugin itself. |
Resolved via #1132 |
Still experiencing this with the plugin
This is with AGP Here is the reproducer: https://github.com/inovait/android-architecture-playground/tree/add_dependency_analysis |
Thanks for the repro link. I note your case is not for test sources, but "production" debug sources. I can also see that the library that is failing has no res (and also no source, but this is unrelated). I'm almost certain this is a bug in AGP itself, but I think I can workaround it... probably by just try/catching the error 😞 |
Build scan link
build scan link
Plugin version
1.29.0
Gradle version
8.2
JDK version
17.0.2
(Optional) Kotlin and Kotlin Gradle Plugin (KGP) version
org.jetbrains.kotlin.android => 1.8.10
(Optional) Android Gradle Plugin (AGP) version
com.android.application => 8.2.1
Describe the bug
./gradlew buildHealth
or./gradlew app:projectHealth
makes same exceptionTo Reproduce
Steps to reproduce the behavior:
The text was updated successfully, but these errors were encountered: