【问题标题】:How to get rid of random groovy error during compile task如何在编译任务期间摆脱随机的常规错误
【发布时间】:2019-02-25 10:56:59
【问题描述】:

在编译任务期间,我偶尔会遇到这个 groovy 错误。

FAILURE: Build failed with an exception.

* Where:
Build file '/home/willem/projects/someproj/projects/someproj/build.gradle' line: 95

* What went wrong:
A problem occurred evaluating root project 'someproj'.
> Expecting a stackmap frame at branch target 14
  Exception Details:
    Location:
      build_wxobn4rxsir22ywxygzua0ka.$getStaticMetaClass()Lgroovy/lang/MetaClass; @6: if_acmpeq
    Reason:
      Expected stackmap frame at this location.
    Bytecode:
      0x0000000: 2ab6 0048 1202 a500 082a b800 4cb0 b200
      0x0000010: 4e4c 2bc7 000f 2ab6 0048 b800 5459 4cb3
      0x0000020: 004e 2bb6 0057 b0                      


* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.

BUILD FAILED

到目前为止,我发现的唯一解决方法是清除 gradle 缓存,然后再次下载所有依赖项。好像是intershop的东西。发现这个用户也有同样的问题: https://pastebin.com/vzc8RRAa

有人知道这是什么吗?

【问题讨论】:

    标签: groovy intershop


    【解决方案1】:

    我自己也偶尔会遇到此错误。我的灵丹妙药是

    rm -rf $GRADLE_USER_HOME/gradle/caches/2.11/scripts
    

    从源代码(即gradle_environment 脚本被执行)gradle 开发者 shell 中执行。至于原因,老实说,我对此一无所知。

    【讨论】:

    • 我刚刚看到您找到了解决方法。所以我唯一的贡献是你现在知道删除完整的 gradle 缓存是不必要的。
    • 我在 Studio 中更新 gradle 依赖项后看到了这个错误。
    • 是的,我在通过工作室运行 gradlew 发布后得到了这个,可能与最新的工作室相关
    猜你喜欢
    • 2021-01-13
    • 1970-01-01
    • 1970-01-01
    • 2012-05-08
    • 1970-01-01
    • 2015-11-11
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多