0

当我添加 @With (SecureSocial.class) 以保护控制器类之一时,我收到以下错误。不知道为什么,因为我确实让它在另一个有更多类的项目中工作。

Oops: VerifyError
An unexpected error occured caused by exception VerifyError: Bad return type in method controllers.securesocial.SecureSocial.loadCurrentUser()Lsecuresocial/provider/SocialUser; at offset 53
    play.exceptions.UnexpectedException: Unexpected Error
            at play.Invoker$Invocation.onException(Invoker.java:232)
            at play.Invoker$Invocation.run(Invoker.java:273)
            at Invocation.HTTP Request(Play!)
    Caused by: java.lang.VerifyError: Bad return type in method controllers.securesocial.SecureSocial.lo
    adCurrentUser()Lsecuresocial/provider/SocialUser; at offset 53
            at java.lang.Class.getDeclaredMethods0(Native Method)
            at java.lang.Class.privateGetDeclaredMethods(Class.java:2442)
            at java.lang.Class.getDeclaredMethods(Class.java:1808)
            at play.utils.JavaWithCaching.findAllAnnotatedMethods(Java.java:500)
            at play.utils.JavaWithCaching.findAllAnnotatedMethods(Java.java:507)
            at play.utils.JavaWithCaching.findAllAnnotatedMethods(Java.java:470)
            at play.utils.Java.findAllAnnotatedMethods(Java.java:255)
            at play.mvc.ActionInvoker.handleFinallies(ActionInvoker.java:382)
            at play.mvc.ActionInvoker.invoke(ActionInvoker.java:255)
            ... 1 more
4

1 回答 1

0

当您运行的代码针对与 JVM 在执行代码时加载的版本不同的版本进行编译时,就会发生 VerifyError。

您的 dependencies.yml 看起来如何?你在这台机器上运行过 play deps 吗?

于 2012-02-24T18:01:36.620 回答