Я попробовал новую версию студии Android, но она не меняется.
Моя программа работает так же хорошо, как и раньше, я удалил обналиченную и перезапустил студию Android, но ничего не изменилось, это мой код в build.gradle
Код: Выделить всё
Execution failed for task ':persiandatepicker:compileDebugLibraryResources'.
> A failure occurred while executing
com.android.build.gradle.tasks.CompileLibraryResourcesTask$CompileLibraryResourcesAction
> Could not isolate value
com.android.build.gradle.tasks.CompileLibraryResourcesTask$CompileLibraryResourcesParams_Decorated@3558d1e5 of type CompileLibraryResourcesTask.CompileLibraryResourcesParams
> Could not resolve all files for configuration ':persiandatepicker:detachedConfiguration2'.
> Failed to transform aapt2-7.3.1-8691043-windows.jar (com.android.tools.build:aapt2:7.3.1-8691043) to match attributes {artifactType=_internal-android-aapt2-binary, org.gradle.libraryelements=jar, org.gradle.status=release, org.gradle.usage=java-runtime}.
> Could not find aapt2-7.3.1-8691043-windows.jar (com.android.tools.build:aapt2:7.3.1-8691043).
Searched in the following locations:
https://dl.google.com/dl/android/maven2/com/android/tools/build/aapt2/7.3.1-8691043/aapt2-7.3.1-8691043-windows.jar
Possible solution:
- Declare repository providing the artifact, see the documentation at https://docs.gradle.org/current/userguide/declaring_repositories.html
Код: Выделить всё
and this is what I have in build.gradle:
```
// Top-level build file where you can add configuration options common to all sub-projects/modules.
buildscript {
repositories {
google()
mavenCentral()
maven {url "https://maven.google.com" }
}
dependencies {
classpath 'com.android.tools.build:gradle:7.3.1'
classpath 'com.google.gms:google-services:4.4.0'
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
}
}
allprojects {
configurations {
compile.exclude group: "junit", module: "junit"
}
configurations.configureEach {
resolutionStrategy.dependencySubstitution {
substitute module('org.hamcrest:hamcrest-core:1.1') with module('junit:junit:4.10')
}
}
gradle.projectsEvaluated {
tasks.withType(JavaCompile).tap {
configureEach {
options.compilerArgs
Подробнее здесь: [url]https://stackoverflow.com/questions/79889637/execution-failed-for-task-persiandatepickercompiledebuglibraryresources[/url]
Мобильная версия