使用Play 2.0.2框架,我遇到了ClassLoader冲突。看起来不同的类加载器中有两个相同类的定义。控制台运行,但是当我发出'运行'命令时,播放响应:

java.lang.LinkageError: loader constraint violation in interface itable initialization: when resolving method "play.api.PlayException.cause()Lscala/Option;" 
the class loader (instance of sbt/PlayCommands$$anonfun$61$$anonfun$63$$anon$2) of the current class, play/api/PlayException, 
and the class loader (instance of java/net/URLClassLoader) for interface
play/api/PlayException$UsefulException have different Class objects for the 
type scala/Option used in the signature
.

任何人都有一个好地方开始调试这个吗?或者一些想法为什么这是出现的?显然,类是由不同的装载机加载的,但我不熟悉播放加载程序配置。

我有scala&sbt安装port

sbt @0.11.2_0 (active)
scala2.9 @2.9.2_0 (active)
.

我的路径在港口二进制文件之前播放。

使用java

java version "1.6.0_33"
Java(TM) SE Runtime Environment (build 1.6.0_33-b03-424-10M3720)
Java HotSpot(TM) 64-Bit Server VM (build 20.8-b03-424, mixed mode)
.

运行雪豹

有帮助吗?

解决方案

拒绝端口SBT创建了一个〜/ .sbt目录,并且首选该配置。删除/移动该目录以解决问题。

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top