SuperDove 发表于 2017-3-28 21:25:36

Error:scalac: Error: org/jetbrains/jps/incremental/ModuleLevelBuilder$ExitCode

本帖最后由 SuperDove 于 2017-3-28 21:27 编辑

换了个系统
装了个idea(装了scala插件)
装了个jdk1.7.0_79
creat a new mvn 项目
使用的scala-archetype-simple
改了一个scala.version 为2.11.8
建了一个test.scala
写了句hello world
然后就是如下错误
上图


Error:scalac: Error: org/jetbrains/jps/incremental/messages/BuildMessage$Kind
java.lang.UnsupportedClassVersionError: org/jetbrains/jps/incremental/messages/BuildMessage$Kind

      at org.jetbrains.jps.incremental.scala.local.AbstractCompiler$ClientReporter.log(AbstractCompiler.scala:91)

      at xsbt.DelegatingReporter.info0(DelegatingReporter.scala:39)

      at xsbt.DelegatingReporter.info0(DelegatingReporter.scala:17)

      at scala.reflect.internal.Reporter.warning(Reporting.scala:81)

      at scala.tools.nsc.Reporting$PerRunReporting$ConditionalWarning.summarize(Reporting.scala:40)

      at scala.tools.nsc.Reporting$PerRunReporting.summarizeErrors(Reporting.scala:95)

      at scala.tools.nsc.Global$Run.compileUnitsInternal(Global.scala:1544)

      at scala.tools.nsc.Global$Run.compileUnits(Global.scala:1486)

      at scala.tools.nsc.Global$Run.compileSources(Global.scala:1481)

      at scala.tools.nsc.Global$Run.compile(Global.scala:1582)

      at xsbt.CachedCompiler0.run(CompilerInterface.scala:115)

      at xsbt.CachedCompiler0.run(CompilerInterface.scala:94)

      at xsbt.CompilerInterface.run(CompilerInterface.scala:22)

      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)

      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

      at java.lang.reflect.Method.invoke(Method.java:606)

      at sbt.compiler.AnalyzingCompiler.call(AnalyzingCompiler.scala:101)

      at sbt.compiler.AnalyzingCompiler.compile(AnalyzingCompiler.scala:47)

      at sbt.compiler.AnalyzingCompiler.compile(AnalyzingCompiler.scala:41)

      at org.jetbrains.jps.incremental.scala.local.IdeaIncrementalCompiler.compile(IdeaIncrementalCompiler.scala:32)

      at org.jetbrains.jps.incremental.scala.local.LocalServer.compile(LocalServer.scala:26)

      at org.jetbrains.jps.incremental.scala.remote.Main$.make(Main.scala:68)

      at org.jetbrains.jps.incremental.scala.remote.Main$.nailMain(Main.scala:25)

      at org.jetbrains.jps.incremental.scala.remote.Main.nailMain(Main.scala)

      at sun.reflect.GeneratedMethodAccessor2.invoke(Unknown Source)

      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

      at java.lang.reflect.Method.invoke(Method.java:606)

      at com.martiansoftware.nailgun.NGSession.run(NGSession.java:319)




我的hello world去哪了

fylanyu 发表于 2017-3-29 08:59:32

楼主换成jdk1.8

SuperDove 发表于 2017-3-29 10:29:58

fylanyu 发表于 2017-3-29 08:59
楼主换成jdk1.8

跟jdk没关系吧,我查了scala2.10最低jdk是1.6以上的都行,spark的要求scala2.10以上的都行,我在另一台机器上也用的1.7我goole查了,说跟sbt有关系,可是我压根就没建sbt项目,我用的mvn创建的,跟sbt有毛关系,不懂,懵了~~

qcbb001 发表于 2017-3-29 20:38:42

下面资料楼主可以参考,建议还是试下jdk
org.jetbrains.jps.incremental.messages包
是Java不支持org.jetbrains.jps.incremental.messages包

org/jetbrains/jps/incremental/messages/BuildMessage$Kind


public abstract class More ...BuildMessage {
   public static enum More ...Kind {
   ERROR, WARNING, INFO, PROGRESS
}

private final String myMessageText;
private final Kind myKind;

protected More ...BuildMessage(String messageText, Kind kind) {
    myMessageText = messageText;
    myKind = kind;
}

public Kind More ...getKind() {
    return myKind;
}

public String More ...getMessageText() {
    return myMessageText;
}

public String More ...toString() {
    return getMessageText();
}
}




SuperDove 发表于 2017-3-29 21:23:15

qcbb001 发表于 2017-3-29 20:38
下面资料楼主可以参考,建议还是试下jdk
org.jetbrains.jps.incremental.messages包
是Java不支持org.jet ...

好吧,见了鬼了,我重新换了jdk1.8.0_101的版本,把项目的jdk换成这个之后hello world出来了,真是jdk的问题.....谢谢了,结贴
页: [1]
查看完整版本: Error:scalac: Error: org/jetbrains/jps/incremental/ModuleLevelBuilder$ExitCode