Android无实施室2.4.2
无法安装版本室> 2.3.0。 我指定上面的版本 - 我现在确实SYNS GRADLE(不显示错误)。
编译项目时,它写道,无法找到库并显示搜索这些库的链接,请务必注意,当您单击链接时,链接是有效的,所需的存档将在浏览器。
我试图在两天前找到解决方案,但失败了。我将感谢所有回应的人。
错误:
Execution failed for task ':app:checkDebugAarMetadata'.
> Could not resolve all files for configuration ':app:debugRuntimeClasspath'.
> Failed to transform room-ktx-2.4.2.aar (androidx.room:room-ktx:2.4.2) to match attributes {artifactType=android-aar-metadata, org.gradle.category=library, org.gradle.dependency.bundling=external, org.gradle.libraryelements=aar, org.gradle.status=release, org.gradle.usage=java-runtime}.
> Could not find room-ktx-2.4.2.aar (androidx.room:room-ktx:2.4.2).
Searched in the following locations:
https://dl.google.com/dl/android/maven2/androidx/room/room-ktx/2.4.2/room-ktx-2.4.2.aar
> Failed to transform room-runtime-2.4.2.aar (androidx.room:room-runtime:2.4.2) to match attributes {artifactType=android-aar-metadata, org.gradle.category=library, org.gradle.dependency.bundling=external, org.gradle.libraryelements=aar, org.gradle.status=release, org.gradle.usage=java-runtime}.
> Could not find room-runtime-2.4.2.aar (androidx.room:room-runtime:2.4.2).
Searched in the following locations:
https://dl.google.com/dl/android/maven2/androidx/room/room-runtime/2.4.2/room-runtime-2.4.2.aar
> Failed to transform sqlite-framework-2.2.0.aar (androidx.sqlite:sqlite-framework:2.2.0) to match attributes {artifactType=android-aar-metadata, org.gradle.category=library, org.gradle.dependency.bundling=external, org.gradle.libraryelements=aar, org.gradle.status=release, org.gradle.usage=java-runtime}.
> Could not find sqlite-framework-2.2.0.aar (androidx.sqlite:sqlite-framework:2.2.0).
Searched in the following locations:
https://dl.google.com/dl/android/maven2/androidx/sqlite/sqlite-framework/2.2.0/sqlite-framework-2.2.0.aar
> Failed to transform sqlite-2.2.0.aar (androidx.sqlite:sqlite:2.2.0) to match attributes {artifactType=android-aar-metadata, org.gradle.category=library, org.gradle.dependency.bundling=external, org.gradle.libraryelements=aar, org.gradle.status=release, org.gradle.usage=java-runtime}.
> Could not find sqlite-2.2.0.aar (androidx.sqlite:sqlite:2.2.0).
Searched in the following locations:
https://dl.google.com/dl/android/maven2/androidx/sqlite/sqlite/2.2.0/sqlite-2.2.0.aar
我的gradle应用:
plugins {
id 'com.android.application'
id 'org.jetbrains.kotlin.android'
id 'kotlin-kapt'
}
android {
compileSdk 32
defaultConfig {
applicationId "com.example.roomtest"
minSdk 24
targetSdk 32
versionCode 1
versionName "1.0"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
}
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
kotlinOptions {
jvmTarget = '1.8'
}
}
dependencies {
implementation 'androidx.core:core-ktx:1.7.0'
implementation 'androidx.appcompat:appcompat:1.4.1'
implementation 'com.google.android.material:material:1.6.0'
implementation 'androidx.constraintlayout:constraintlayout:2.1.3'
testImplementation 'junit:junit:4.13.2'
androidTestImplementation 'androidx.test.ext:junit:1.1.3'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.4.0'
implementation "androidx.room:room-ktx:2.4.2"
implementation 'androidx.room:room-common:2.4.2'
kapt "androidx.room:room-compiler:2.4.2"
androidTestImplementation "androidx.room:room-testing:2.4.2"
}
我的gradle项目:
plugins {
id 'com.android.application' version '7.1.2' apply false
id 'com.android.library' version '7.1.2' apply false
id 'org.jetbrains.kotlin.android' version '1.6.21' apply false
}
task clean(type: Delete) {
delete rootProject.buildDir
}
我的设置.gradle:
pluginManagement {
repositories {
gradlePluginPortal()
google()
mavenCentral()
}
}
dependencyResolutionManagement {
repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
repositories {
google()
mavenCentral()
}
}
rootProject.name = "roomtest"
include ':app'
Unable to install version room > 2.3.0.
I specify the version above - I do syns now gradle (does not show errors).
When compiling the project, it writes that it is not possible to find libraries and shows the links by which these libraries were searched, it is important to note that when you click on the link, the link is valid and the required archive is downloaded in the browser.
I tried to find a solution two days earlier but failed. I will be grateful to all who responded.
Error:
Execution failed for task ':app:checkDebugAarMetadata'.
> Could not resolve all files for configuration ':app:debugRuntimeClasspath'.
> Failed to transform room-ktx-2.4.2.aar (androidx.room:room-ktx:2.4.2) to match attributes {artifactType=android-aar-metadata, org.gradle.category=library, org.gradle.dependency.bundling=external, org.gradle.libraryelements=aar, org.gradle.status=release, org.gradle.usage=java-runtime}.
> Could not find room-ktx-2.4.2.aar (androidx.room:room-ktx:2.4.2).
Searched in the following locations:
https://dl.google.com/dl/android/maven2/androidx/room/room-ktx/2.4.2/room-ktx-2.4.2.aar
> Failed to transform room-runtime-2.4.2.aar (androidx.room:room-runtime:2.4.2) to match attributes {artifactType=android-aar-metadata, org.gradle.category=library, org.gradle.dependency.bundling=external, org.gradle.libraryelements=aar, org.gradle.status=release, org.gradle.usage=java-runtime}.
> Could not find room-runtime-2.4.2.aar (androidx.room:room-runtime:2.4.2).
Searched in the following locations:
https://dl.google.com/dl/android/maven2/androidx/room/room-runtime/2.4.2/room-runtime-2.4.2.aar
> Failed to transform sqlite-framework-2.2.0.aar (androidx.sqlite:sqlite-framework:2.2.0) to match attributes {artifactType=android-aar-metadata, org.gradle.category=library, org.gradle.dependency.bundling=external, org.gradle.libraryelements=aar, org.gradle.status=release, org.gradle.usage=java-runtime}.
> Could not find sqlite-framework-2.2.0.aar (androidx.sqlite:sqlite-framework:2.2.0).
Searched in the following locations:
https://dl.google.com/dl/android/maven2/androidx/sqlite/sqlite-framework/2.2.0/sqlite-framework-2.2.0.aar
> Failed to transform sqlite-2.2.0.aar (androidx.sqlite:sqlite:2.2.0) to match attributes {artifactType=android-aar-metadata, org.gradle.category=library, org.gradle.dependency.bundling=external, org.gradle.libraryelements=aar, org.gradle.status=release, org.gradle.usage=java-runtime}.
> Could not find sqlite-2.2.0.aar (androidx.sqlite:sqlite:2.2.0).
Searched in the following locations:
https://dl.google.com/dl/android/maven2/androidx/sqlite/sqlite/2.2.0/sqlite-2.2.0.aar
My gradle app:
plugins {
id 'com.android.application'
id 'org.jetbrains.kotlin.android'
id 'kotlin-kapt'
}
android {
compileSdk 32
defaultConfig {
applicationId "com.example.roomtest"
minSdk 24
targetSdk 32
versionCode 1
versionName "1.0"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
}
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
kotlinOptions {
jvmTarget = '1.8'
}
}
dependencies {
implementation 'androidx.core:core-ktx:1.7.0'
implementation 'androidx.appcompat:appcompat:1.4.1'
implementation 'com.google.android.material:material:1.6.0'
implementation 'androidx.constraintlayout:constraintlayout:2.1.3'
testImplementation 'junit:junit:4.13.2'
androidTestImplementation 'androidx.test.ext:junit:1.1.3'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.4.0'
implementation "androidx.room:room-ktx:2.4.2"
implementation 'androidx.room:room-common:2.4.2'
kapt "androidx.room:room-compiler:2.4.2"
androidTestImplementation "androidx.room:room-testing:2.4.2"
}
My gradle project:
plugins {
id 'com.android.application' version '7.1.2' apply false
id 'com.android.library' version '7.1.2' apply false
id 'org.jetbrains.kotlin.android' version '1.6.21' apply false
}
task clean(type: Delete) {
delete rootProject.buildDir
}
My settings.gradle:
pluginManagement {
repositories {
gradlePluginPortal()
google()
mavenCentral()
}
}
dependencyResolutionManagement {
repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
repositories {
google()
mavenCentral()
}
}
rootProject.name = "roomtest"
include ':app'
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我遇到了同样的问题,并将VPN从德国更改为美国。
我住在伊朗,无法访问这些URL。
I had the same problem and changed my VPN from Germany to the USA.
I live in Iran and have no access to these URLs.