- Some problems were found with the configuration of task ':app:generateSafeArgsDebug' (type 'ArgumentsGenerationTask').
Type 'androidx.navigation.safeargs.gradle.ArgumentsGenerationTask' property 'applicationId' is missing an input or output annotation.
Solution: Yes Because the version of the navigation-safe-args-gradle-plugin plugin is too low, just modify the version number, for example
classpath "androidx.navigation:navigation-safe-args-gradle-plugin:1.0.0"
change into
classpath "androidx.navigation:navigation-safe-args-gradle-plugin:2.3.0"
- Using insecure protocols with repositories, without explicit opt-in, is unsupported. Switch Maven repository 'maven(http://maven.aliyun.com/nexus/content/groups/public)' to redirect to a secure protocol (like HTTPS) or allow insecure protocols. See ...
Solution: Set the allowInsecureProtocol property setting of the corresponding maven library
to
maven {
allowInsecureProtocol = true
url 'http://maven.aliyun.com/nexus/content/groups/public/'
}
- this.activity?.let{…}
kotlin-related keywords such as let and also are marked in red and need to be added to the project's build.gradle file
dependencies {
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:1.6.10"
}
Add in the app's build.gradle file
dependencies {
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:1.6.10"
}