Android Jenkins构建因崩溃而失败

前端之家收集整理的这篇文章主要介绍了Android Jenkins构建因崩溃而失败前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。
每次我尝试使用Jenkins构建时,都会出现以下错误

Failed to apply plugin [id ‘io.fabric’]
Could not create plugin of type ‘CrashlyticsPlugin’.

从Gradle中删除Crashlytics可以解决此问题

解决方法

这些是您需要遵循的最终命令:
sudo mkdir -p /Users/Shared/Jenkins/Library/Caches/com.crashlytics
sudo chown -R jenkins:jenkins /Users/Shared/Jenkins/Library

以下是此案例的相关调试日志:

13:33:45.133 [ERROR] [org.gradle.BuildExceptionReporter]    at com.crashlytics.tools.gradle.CrashlyticsPlugin.<clinit>(CrashlyticsPlugin.groovy:13)
13:33:45.135 [ERROR] [org.gradle.BuildExceptionReporter]    at org.gradle.api.internal.DependencyInjectingInstantiator.newInstance(DependencyInjectingInstantiator.java:48)
13:33:45.136 [ERROR] [org.gradle.BuildExceptionReporter]    at org.gradle.api.internal.plugins.DefaultPluginRegistry.loadPlugin(DefaultPluginRegistry.java:69)
13:33:45.136 [ERROR] [org.gradle.BuildExceptionReporter]    ... 55 more
13:33:45.141 [ERROR] [org.gradle.BuildExceptionReporter] Caused by: java.lang.RuntimeException: Crashlytics data directory at /Users/Shared/Jenkins/Library/Caches/com.crashlytics could not be created.
13:33:45.142 [ERROR] [org.gradle.BuildExceptionReporter]    at com.crashlytics.tools.android.DeveloperTools.<clinit>(DeveloperTools.java:116)
13:33:45.143 [ERROR] [org.gradle.BuildExceptionReporter]    ... 60 more
13:33:45.143 [ERROR] [org.gradle.BuildExceptionReporter] 
13:33:45.144 [LIFECYCLE] [org.gradle.BuildResultLogger] 
13:33:45.145 [LIFECYCLE] [org.gradle.BuildResultLogger] BUILD Failed
13:33:45.146 [LIFECYCLE] [org.gradle.BuildResultLogger] 
13:33:45.147 [LIFECYCLE] [org.gradle.BuildResultLogger] Total time: 8.362 secs

猜你在找的Android相关文章