gpt4 book ai didi

android - Jenkins:Gradle 构建:AAPT2 问题:AAPT2 aapt2-3.4.0-5326820-windows 守护进程 #0:守护进程启动失败

转载 作者:行者123 更新时间:2023-11-29 02:20:31 25 4
gpt4 key购买 nike

我正在尝试从 Jenkins 进行持续集成。我在构建部分提到了命令“清理”和“组装”。但由于 AAPT2 问题,构建失败。Gradle 版本:'com.android.tools.build:gradle:3.4.1'注意:同一项目的相同“assemble”命令在 Android Studio 和命令行中运行得非常好。

I have tried: 
1. Downgraded gradle version.
2. Downgrading compiledSDKversion to 26
3. Making AAPT2 indicator in gralde.properties file = False
4. Tried searching on google and stackoverflow, but still issue exists.

Jenkins 日志:

14:52:16 > Task :app:mergeCobraDebugResources FAILED
14:52:16
14:52:16 FAILURE: Build failed with an exception.
14:52:16
14:52:16 * What went wrong:
14:52:16 Execution failed for task ':app:mergeCobraDebugResources'.
14:52:16 > 8 exceptions were raised by workers:
14:52:16 com.android.builder.internal.aapt.v2.Aapt2InternalException: AAPT2 aapt2-3.4.0-5326820-windows Daemon #0: Daemon startup failed
14:52:16 This should not happen under normal circumstances, please file an issue if it does.
14:52:16 com.android.builder.internal.aapt.v2.Aapt2InternalException: AAPT2 aapt2-3.4.0-5326820-windows Daemon #1: Daemon startup failed
14:52:16 This should not happen under normal circumstances, please file an issue if it does.
14:52:16 com.android.builder.internal.aapt.v2.Aapt2InternalException: AAPT2 aapt2-3.4.0-5326820-windows Daemon #2: Daemon startup failed
14:52:16 This should not happen under normal circumstances, please file an issue if it does.
14:52:16 com.android.builder.internal.aapt.v2.Aapt2InternalException: AAPT2 aapt2-3.4.0-5326820-windows Daemon #3: Daemon startup failed
14:52:16 This should not happen under normal circumstances, please file an issue if it does.
14:52:16 com.android.builder.internal.aapt.v2.Aapt2InternalException: AAPT2 aapt2-3.4.0-5326820-windows Daemon #4: Daemon startup failed
14:52:16 This should not happen under normal circumstances, please file an issue if it does.
14:52:16 com.android.builder.internal.aapt.v2.Aapt2InternalException: AAPT2 aapt2-3.4.0-5326820-windows Daemon #5: Daemon startup failed
14:52:16 This should not happen under normal circumstances, please file an issue if it does.
14:52:16 com.android.builder.internal.aapt.v2.Aapt2InternalException: AAPT2 aapt2-3.4.0-5326820-windows Daemon #6: Daemon startup failed
14:52:16 This should not happen under normal circumstances, please file an issue if it does.
14:52:16 com.android.builder.internal.aapt.v2.Aapt2InternalException: AAPT2 aapt2-3.4.0-5326820-windows Daemon #7: Daemon startup failed
14:52:16 This should not happen under normal circumstances, please file an issue if it does.
14:52:16
14:52:16
14:52:16 * Try:
14:52:16 Run with --info or --debug option to get more log output. Run with --scan to get full insights.
14:52:16

GRADLE 文件(项目级别)

import org.apache.tools.ant.taskdefs.condition.Os

apply plugin: 'com.android.application'

android {
signingConfigs {
lookitRelease {
keyAlias LOOKIT_RELEASE_KEY_ALIAS
keyPassword LOOKIT_RELEASE_KEY_PASSWORD
if (Os.isFamily(Os.FAMILY_WINDOWS)) {
storeFile file(LOOKIT_RELEASE_STORE_FILE)
} else if (Os.isFamily(Os.FAMILY_MAC)) {
storeFile file(LOOKIT_RELEASE_STORE_FILE_MAC)
}
storePassword LOOKIT_RELEASE_KEY_PASSWORD
}
}
Properties versionProps = new Properties()
def versionPropsFile = file('version.properties')
if (versionPropsFile.exists())
versionProps.load(new FileInputStream(versionPropsFile))
def code = (versionProps['VERSION_CODE'] ?: "0").toInteger() + 1
versionProps['VERSION_CODE'] = code.toString()
versionProps.store(versionPropsFile.newWriter(), null)
compileSdkVersion 28
defaultConfig {
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"

applicationId "com.lightwave.lwRvCam"
minSdkVersion 21
targetSdkVersion 27
versionCode code
versionName "2.25.7." + code
}
flavorDimensions "default"
productFlavors {

}
sourceSets {

}
buildTypes {
release {
minifyEnabled true
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
debug {
debuggable true
}
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}

}

dependencies {
implementation 'com.android.support.constraint:constraint-layout:1.1.0'
implementation fileTree(include: ['*.jar'], dir: 'libs')
implementation project(':LwRvcLib-release')
androidTestImplementation 'androidx.test.espresso:espresso-core:3.1.0'
//noinspection GradleCompatible
implementation 'com.android.support:appcompat-v7:27.1.1'
implementation 'com.android.support:support-media-compat:28.0.0'
implementation 'com.android.support:support-v4:28.0.0'



implementation 'com.android.support:design:28.0.0'
implementation 'com.android.support:percent:28.0.0'
implementation 'com.github.johnpersano:supertoasts:1.3.4@aar'
implementation 'com.google.code.gson:gson:2.8.5'
implementation 'com.google.android.gms:play-services-analytics:15.0.0'
implementation 'com.google.android.gms:play-services-measurement-base:15.0.0'
implementation 'com.github.castorflex.verticalviewpager:library:19.0.1'
implementation 'com.google.firebase:firebase-core:15.0.0'
implementation 'com.google.android.gms:play-services-maps:15.0.0'
implementation 'com.cleveroad:slidingtutorial:1.0.9'
implementation 'com.daimajia.swipelayout:library:1.2.0@aar'
//androidTestImplementation 'com.android.support:support-annotations:27.1.1'
// androidTestImplementation 'com.android.support.test:runner:1.0.1'
// androidTestImplementation 'com.android.support.test:rules:1.0.1'
androidTestImplementation 'org.hamcrest:hamcrest-library:2.1'
// androidTestImplementation 'com.android.support.test.uiautomator:uiautomator-v18:2.1.3'
// androidTestImplementation('com.android.support.test.espresso:espresso-core:2.2.2') {
// exclude group: 'javax.inject'
// }
///////////////////////////////////////Androidx Dependencies/////////////////////////
// Core library
androidTestImplementation 'androidx.test:core:1.0.0'
// AndroidJUnitRunner and JUnit Rules
androidTestImplementation 'androidx.test:runner:1.1.0'
androidTestImplementation 'androidx.test:rules:1.1.0'
// Assertions
androidTestImplementation 'androidx.test.ext:junit:1.0.0'
androidTestImplementation 'androidx.test.ext:truth:1.0.0'
androidTestImplementation 'com.google.truth:truth:0.44'
// Espresso dependencies
androidTestImplementation 'androidx.test.espresso:espresso-core:3.1.0'
androidTestImplementation 'androidx.test.espresso:espresso-contrib:3.1.0'
androidTestImplementation 'androidx.test.espresso:espresso-intents:3.1.0'
androidTestImplementation 'androidx.test.espresso:espresso-accessibility:3.1.0'
androidTestImplementation 'androidx.test.espresso:espresso-web:3.1.0'
androidTestImplementation 'androidx.test.espresso.idling:idling-concurrent:3.1.0'
androidTestImplementation 'androidx.test.espresso:espresso-web:3.1.0'
androidTestImplementation 'androidx.test.uiautomator:uiautomator:2.2.0'
// The following Espresso dependency can be either "implementation"
// or "androidTestImplementation", depending on whether you want the
// dependency to appear on your APK's compile classpath or the test APK
// classpath.
androidTestImplementation 'androidx.test.espresso:espresso-idling-resource:3.1.0'
/////////////////////////////////////////////////////////////////////////////////////////////////////
androidTestImplementation 'junit:junit:4.13-beta-2'
testImplementation 'junit:junit:4.13-beta-2'
allprojects {
repositories {
jcenter()
google()
}
}
}

if (hasProperty('buildScan')) {
buildScan {
termsOfServiceUrl = 'https://gradle.com/terms-of-service'
termsOfServiceAgree = 'yes'
}
}

apply plugin: 'com.google.gms.google-services'

GRADLE 文件(应用级别):

ext {
var = '28.0.3'
var1 = '28.0.3'
var2 = '26.1.1-alpha1'
}
buildscript{
repositories {
maven { url 'https://maven.google.com' }
jcenter()
google()
}
dependencies {
classpath 'com.android.tools.build:gradle:3.4.1'
classpath 'com.google.gms:google-services:3.2.0'

// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
}
}



allprojects {
repositories {
maven { url 'https://maven.google.com' }
jcenter()
}

}


if (hasProperty('buildScan')) {
buildScan {
termsOfServiceUrl = 'https://gradle.com/terms-of-service'
termsOfServiceAgree = 'yes'
}
}

task clean(type: Delete) {
delete rootProject.buildDir
}

GRADLE 问题日志:

Have raised issue in gradle with text: AAPT2 issues: Daemon startup failed

谷歌问题追踪器:

https://issuetracker.google.com/132686257 AAPT2 issues. Gradle version : 3.4.0 Android studio version : 3.4. Android SDK tools: 26.1.1

最佳答案

关于android - Jenkins:Gradle 构建:AAPT2 问题:AAPT2 aapt2-3.4.0-5326820-windows 守护进程 #0:守护进程启动失败,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/56156392/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com