2016-10-11 18 views
5

我的构建最近停止了为开源gradle/android项目工作。直到今天(2016年10月10日),他们一直工作得很好。我在gradle和gradle android插件的多个版本(在travis上)运行构建矩阵。从本质上讲,它现在在gradle 3.0和3上都失败了,都是用gradle android 2.2.0插件。其他版本使用不同的android插件是可以的。这只是2.2.0插件失败。Android aar's已停止使用extractDebugAnnotations com/intellij/psi/PsiJavaFile构建Android

是令我感到困惑的部分是错误信息

:hello-world-aar:preBuild UP-TO-DATE 
:hello-world-aar:preDebugBuild UP-TO-DATE 
:hello-world-aar:checkDebugManifest 
:hello-world-aar:preDebugAndroidTestBuild UP-TO-DATE 
:hello-world-aar:preDebugUnitTestBuild UP-TO-DATE 
:hello-world-aar:preReleaseBuild UP-TO-DATE 
:hello-world-aar:preReleaseUnitTestBuild UP-TO-DATE 
:hello-world-aar:prepareOrgOsmdroidOsmdroidAndroid541ReleaseLibrary 
:hello-world-aar:prepareDebugDependencies 
:hello-world-aar:compileDebugAidl 
:hello-world-aar:compileDebugNdk UP-TO-DATE 
:hello-world-aar:compileLint 
:hello-world-aar:copyDebugLint SKIPPED 
:hello-world-aar:compileDebugRenderscript 
:hello-world-aar:generateDebugBuildConfig 
:hello-world-aar:generateDebugResValues 
:hello-world-aar:generateDebugResources 
:hello-world-aar:mergeDebugResources 
:hello-world-aar:processDebugManifest 
:hello-world-aar:processDebugResources 
:hello-world-aar:generateDebugSources 
:hello-world-aar:incrementalDebugJavaCompilationSafeguard 
:hello-world-aar:compileDebugJavaWithJavac 
:hello-world-aar:compileDebugJavaWithJavac - is not incremental (e.g. outputs have changed, no previous execution, etc.). 
:hello-world-aar:extractDebugAnnotations FAILED 

FAILURE: Build failed with an exception. 
* What went wrong: 
Execution failed for task ':hello-world-aar:extractDebugAnnotations'. 

> com/intellij/psi/PsiJavaFile 

再次,这是在Android档案(AAR)项目。我已经搜索过,并且无法在该课堂上找到太多内容。它在我的代码中没有被引用。我最好的猜测是,谷歌改变了一个支持库或一些打破了一些东西。我也通过travis从命令行构建。我不知道intellij的东西来自哪里。

+0

我开始看到这个今天还一个我詹金斯建立了几个不同的AAR项目中。 – sparkym3

+0

我从使用AIDE for Android的Gradle构建中看到它。问题刚刚开始不久前... – jb15613

+0

https://bintray.com/android/android-tools/com.android.tools.build.gradle看起来像一个新版本被推出中心,2.2.1 – spy

回答

2

通过与清除缓存固定:

rm -rf ~/.gradle/caches/ 
1

我刚刚面临同样的问题。 我的项目中的问题是一个空的IntDef。 如果清除gradle缓存不起作用,请检查您的代码中是否没有空Def,然后将其删除。

@IntDef({})@StringDef({}) ...