gpt4 book ai didi

更新到版本 0.6.0 后的 Android Studio Gradle 问题

转载 作者:塔克拉玛干 更新时间:2023-11-02 18:52:28 26 4
gpt4 key购买 nike

自从我将 Android Studio 更新到版本 0.6.0 后,我遇到了 Gradle Sync 的以下问题:

enter image description here

关于 Google+ 的讨论和 Google adt-dev group这表明新的 Manifest Merger 的自动启用导致了这个问题。两个平台上的讨论和解决方案都不清楚,尽管我确实尝试添加 android { useOldManifestMerger true; 按照 build.gradle 中的建议,但我仍然收到此错误。

P.S:我们正在使用 RoboGuice 并怀疑它可能是兼容性问题。

这是日志:

2014-06-09 11:07:35,927 [ 171888]   WARN - nal.AbstractExternalSystemTask - Cause: com.android.builder.BuilderConstants 
com.intellij.openapi.externalSystem.model.ExternalSystemException: Cause: com.android.builder.BuilderConstants
at org.jetbrains.plugins.gradle.service.project.AbstractProjectImportErrorHandler.createUserFriendlyError(AbstractProjectImportErrorHandler.java:106)
at org.jetbrains.plugins.gradle.service.project.BaseProjectImportErrorHandler.getUserFriendlyError(BaseProjectImportErrorHandler.java:153)
at org.jetbrains.plugins.gradle.service.project.BaseGradleProjectResolverExtension.getUserFriendlyError(BaseGradleProjectResolverExtension.java:352)
at com.android.tools.idea.gradle.project.AndroidGradleProjectResolver.getUserFriendlyError(AndroidGradleProjectResolver.java:334)
at org.jetbrains.plugins.gradle.service.project.GradleProjectResolver$ProjectConnectionDataNodeFunction.fun(GradleProjectResolver.java:364)
at org.jetbrains.plugins.gradle.service.project.GradleProjectResolver$ProjectConnectionDataNodeFunction.fun(GradleProjectResolver.java:330)
at org.jetbrains.plugins.gradle.service.project.GradleExecutionHelper.execute(GradleExecutionHelper.java:203)
at org.jetbrains.plugins.gradle.service.project.GradleProjectResolver.resolveProjectInfo(GradleProjectResolver.java:116)
at org.jetbrains.plugins.gradle.service.project.GradleProjectResolver.resolveProjectInfo(GradleProjectResolver.java:64)
at com.intellij.openapi.externalSystem.service.remote.RemoteExternalSystemProjectResolverImpl$1.produce(RemoteExternalSystemProjectResolverImpl.java:41)
at com.intellij.openapi.externalSystem.service.remote.RemoteExternalSystemProjectResolverImpl$1.produce(RemoteExternalSystemProjectResolverImpl.java:37)
at com.intellij.openapi.externalSystem.service.remote.AbstractRemoteExternalSystemService.execute(AbstractRemoteExternalSystemService.java:59)
at com.intellij.openapi.externalSystem.service.remote.RemoteExternalSystemProjectResolverImpl.resolveProjectInfo(RemoteExternalSystemProjectResolverImpl.java:37)
at com.intellij.openapi.externalSystem.service.remote.wrapper.ExternalSystemProjectResolverWrapper.resolveProjectInfo(ExternalSystemProjectResolverWrapper.java:49)
at com.intellij.openapi.externalSystem.service.internal.ExternalSystemResolveProjectTask.doExecute(ExternalSystemResolveProjectTask.java:48)
at com.intellij.openapi.externalSystem.service.internal.AbstractExternalSystemTask.execute(AbstractExternalSystemTask.java:137)
at com.intellij.openapi.externalSystem.service.internal.AbstractExternalSystemTask.execute(AbstractExternalSystemTask.java:123)
at com.intellij.openapi.externalSystem.util.ExternalSystemUtil$2.execute(ExternalSystemUtil.java:406)
at com.intellij.openapi.externalSystem.util.ExternalSystemUtil$3$2.run(ExternalSystemUtil.java:483)
at com.intellij.openapi.progress.impl.ProgressManagerImpl$TaskRunnable.run(ProgressManagerImpl.java:471)
at com.intellij.openapi.progress.impl.ProgressManagerImpl$2.run(ProgressManagerImpl.java:178)
at com.intellij.openapi.progress.ProgressManager.executeProcessUnderProgress(ProgressManager.java:209)
at com.intellij.openapi.progress.impl.ProgressManagerImpl.executeProcessUnderProgress(ProgressManagerImpl.java:212)
at com.intellij.openapi.progress.impl.ProgressManagerImpl.runProcess(ProgressManagerImpl.java:171)
at com.intellij.openapi.progress.impl.ProgressManagerImpl$8.run(ProgressManagerImpl.java:380)
at com.intellij.openapi.application.impl.ApplicationImpl$8.run(ApplicationImpl.java:419)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:439)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
at java.util.concurrent.FutureTask.run(FutureTask.java:138)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:895)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:918)
at java.lang.Thread.run(Thread.java:695)
at com.intellij.openapi.application.impl.ApplicationImpl$1$1.run(ApplicationImpl.java:149)

2014-06-09 11:07:35,927 [ 171888] WARN - .project.GradleProjectImporter -
2014-06-09 11:07:35,927 [ 171888] INFO - .project.GradleProjectImporter - Cause: com.android.builder.BuilderConstants

最佳答案

我遇到了同样的问题,我不得不发表评论:

apply plugin: 'android-test'

testCompile 'junit: junit: 4.10'
testCompile 'org.robolectric: robolectric: 2.3'
testCompile 'com.squareup: fest-android: 1.0 +.'

instrumentTestCompile 'junit: junit: 4.10'
instrumentTestCompile 'org.robolectric: robolectric: 2.3'
instrumentTestCompile 'com.squareup: fest-android: 1.0 +.'

我的问题是插件支持测试: https://github.com/robolectric/deckard-gradle/issues/11

我推荐你关注这篇文章: https://plus.google.com/+AndroidDevelopers/posts/Tzof6zatrJW

还有这个: https://github.com/robolectric/gradle-android-test-plugin/pull/33

关于更新到版本 0.6.0 后的 Android Studio Gradle 问题,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/24118283/

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