Status Update
Comments
il...@google.com <il...@google.com>
se...@google.com <se...@google.com> #2
You need to temporarily add following to your build.gradle
:
tasks.withType(KotlinCompile).configureEach {
kotlinOptions {
freeCompilerArgs += [
"-Xjvm-default=all",
]
}
}
Note that in certain circumstances you may want to use all-compatibility
instead of all
, learn more about that in
Starting with kotlin 1.6.20 you won't need touch build.gradle
for more information see
ba...@gmail.com <ba...@gmail.com> #3
pi...@gmail.com <pi...@gmail.com> #4
te...@gmail.com <te...@gmail.com> #5
I have tried adding the code in various places in my Module level build.gradle
but keep receiving the error
Caused by: groovy.lang.MissingPropertyException: Could not get unknown property 'KotlinCompile' for extension 'android' of type com.android.build.gradle.internal.dsl.BaseAppModuleExtension.
at org.gradle.internal.metaobject.AbstractDynamicObject.getMissingProperty(AbstractDynamicObject.java:85)
at org.gradle.internal.metaobject.ConfigureDelegate.getProperty(ConfigureDelegate.java:130)
Can you please provide a more detailed example of how to use the temporary code within a Module level build.gradle
file?
da...@gmail.com <da...@gmail.com> #6
This is what worked for me. Try adding the code to app level build.gradle
file:
android {
...
kotlinOptions {
...
freeCompilerArgs += [
"-Xjvm-default=all",
]
}
}
ar...@gmail.com <ar...@gmail.com> #7
ml...@gmail.com <ml...@gmail.com> #8
ml...@gmail.com <ml...@gmail.com> #9
ms...@hssoft.com <ms...@hssoft.com> #10
This solution is help me.
ad...@gmail.com <ad...@gmail.com> #11
Upgrading Kotlin to version 1.6.20 – as mentioned in build.gradle
file.
Description
Component used: lifecycle-viewmodel:2.5.0-alpha01 Version used: 2.5.0-alpha01 Devices/Android versions reproduced on: All
When I want to implement ViewModelProvider.Factory I got an error: