djspiewak/ensime-sidekick — Issue #10: "ENSIME Server Error: Broken pipe" at server start up
Author: benqua
Created: 2011-11-10 22:02:18+00:00
State: open

Hi,

I get an "ENSIME Server Error: Broken pipe" at server start up. Works well on emacs/ENSIME.

I checked again my jEdit configuration and reread the README, but didn't find anything wrong.

ben$ cat /tmp/ensime*log
java -classpath lib/ant-1.6.5.jar:lib/wagon-http-lightweight-1.0-beta-6.jar:lib/asm-3.2.jar:lib/plexus-utils-1.5.15.jar:lib/wagon-provider-api-1.0-beta-6.jar:lib/ant-launcher-1.8.1.jar:lib/asm-tree-3.2.jar:lib/plexus-container-default-1.0-alpha-9-stable-1.jar:lib/maven-repository-metadata-2.2.1.jar:lib/asm-commons-3.2.jar:lib/plexus-interpolation-1.11.jar:lib/maven-artifact-manager-2.2.1.jar:lib/maven-error-diagnostics-2.2.1.jar:lib/critbit-0.0.4.jar:lib/nekohtml-1.9.6.2.jar:lib/maven-ant-tasks-2.1.0.jar:lib/scala-compiler.jar:lib/maven-artifact-2.2.1.jar:lib/ivy-2.1.0.jar:lib/org.eclipse.jdt.core-3.6.0.v_A58.jar:lib/classworlds-1.1-alpha-2.jar:lib/wagon-file-1.0-beta-6.jar:lib/maven-settings-2.2.1.jar:lib/ant-1.8.1.jar:lib/expectj-2.0.1.jar:lib/ensime_2.9.2-SNAPSHOT-0.7.6.RC1.jar:lib/maven-profile-2.2.1.jar:lib/org.scala-refactoring_2.9.2-0.3.0-SNAPSHOT.jar:lib/xercesMinimal-1.9.6.2.jar:lib/wagon-http-shared-1.0-beta-6.jar:lib/scala-library.jar:lib/maven-model-2.2.1.jar:lib/backport-util-concurrent-3.1.jar:lib/commons-logging-1.1.1.jar:lib/maven-plugin-registry-2.2.1.jar:lib/scalariform_2.9.1-0.1.1.jar:lib/maven-project-2.2.1.jar -XX:+DoEscapeAnalysis -Xms256M -Xmx1512M -XX:PermSize=128m -Xss1M -Dfile.encoding=UTF-8 org.ensime.server.Server /private/tmp/ensime2096556717549206314.port
Project waiting for init...
Server listening on 49477..
Wrote port 49477 to /private/tmp/ensime2096556717549206314.port.
Got connection, creating handler...

Handling RPC: (swank:init-project (:root-dir /Users/ben/Dropbox/geoscript.scala :sbt-active-subproject examples :use-sbt t :sbt-subprojects ((:name geocss :deps ()) (:name geoscript :deps (geocss)) (:name examples :deps (geoscript)))))
Using project root: /Users/ben/Dropbox/geoscript.scala
Using sbt at /Users/ben/Dropbox/Scala/ensime/dist/bin/sbt-launch-0.11.0.jar
Exception in thread "main" java.lang.NoClassDefFoundError:
Caused by: java.lang.ClassNotFoundException:
at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
java.io.IOException: Broken pipe
at java.io.FileOutputStream.writeBytes(Native Method)
at java.io.FileOutputStream.write(FileOutputStream.java:282)
at java.io.BufferedOutputStream.flushBuffer(BufferedOutputStream.java:65)
at java.io.BufferedOutputStream.flush(BufferedOutputStream.java:123)
at sun.nio.cs.StreamEncoder.implFlush(StreamEncoder.java:278)
at sun.nio.cs.StreamEncoder.flush(StreamEncoder.java:122)
at java.io.OutputStreamWriter.flush(OutputStreamWriter.java:212)
at java.io.BufferedWriter.flush(BufferedWriter.java:236)
at expectj.Spawn.send(Spawn.java:403)
at org.ensime.config.Sbt$Sbt10Style.evalUnit(Sbt.scala:271)
at org.ensime.config.Sbt$Sbt10Style.getConfig(Sbt.scala:189)
at org.ensime.config.Sbt$.getConfig(Sbt.scala:333)
at org.ensime.config.ProjectConfig$$anonfun$load$1.apply(ProjectConfig.scala:197)
at org.ensime.config.ProjectConfig$$anonfun$load$1.apply(ProjectConfig.scala:196)
at scala.Option.foreach(Option.scala:197)
at org.ensime.config.ProjectConfig$.load(ProjectConfig.scala:196)
at org.ensime.config.ProjectConfig$.fromSExp(ProjectConfig.scala:172)
at org.ensime.protocol.SwankProtocol$class.handleRPCRequest(SwankProtocol.scala:467)
at org.ensime.protocol.SwankProtocol$class.handleEmacsRex(SwankProtocol.scala:133)
at org.ensime.protocol.SwankProtocol$class.handleMessageForm(SwankProtocol.scala:121)
at org.ensime.protocol.SwankProtocol$class.handleIncomingMessage(SwankProtocol.scala:113)
at org.ensime.protocol.SwankProtocol$.handleIncomingMessage(SwankProtocol.scala:42)
at org.ensime.server.Project$$anonfun$act$1$$anonfun$apply$mcV$sp$1.apply(Project.scala:101)
at org.ensime.server.Project$$anonfun$act$1$$anonfun$apply$mcV$sp$1.apply(Project.scala:96)
Writing: 000026(:return (:abort 201 "Broken pipe") 1)
at scala.actors.Actor$class.receive(Actor.scala:547)
at org.ensime.server.Project.receive(Project.scala:77)
at org.ensime.server.Project$$anonfun$act$1.apply$mcV$sp(Project.scala:96)
at org.ensime.server.Project$$anonfun$act$1.apply(Project.scala:95)
at org.ensime.server.Project$$anonfun$act$1.apply(Project.scala:95)
at scala.actors.Reactor$class.seq(Reactor.scala:280)
at org.ensime.server.Project.seq(Project.scala:77)
at scala.actors.Reactor$$anon$3.andThen(Reactor.scala:258)
at scala.actors.Combinators$class.loop(Combinators.scala:26)
at org.ensime.server.Project.loop(Project.scala:77)
at org.ensime.server.Project.act(Project.scala:94)
at scala.actors.Reactor$$anonfun$dostart$1.apply(Reactor.scala:222)
at scala.actors.Reactor$$anonfun$dostart$1.apply(Reactor.scala:222)
at scala.actors.ReactorTask.run(ReactorTask.scala:33)
at scala.concurrent.forkjoin.ForkJoinPool$AdaptedRunnable.exec(ForkJoinPool.java:611)
at scala.concurrent.forkjoin.ForkJoinTask.quietlyExec(ForkJoinTask.java:422)
at scala.concurrent.forkjoin.ForkJoinWorkerThread.mainLoop(ForkJoinWorkerThread.java:340)
at scala.concurrent.forkjoin.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:325)

I think it can be reproduce with the project https://github.com/dwins/geoscript.scala and a .ensime file like:
(
:use-sbt t
:sbt-subprojects (
(:name "geocss" :deps ())
(:name "geoscript" :deps ("geocss"))
(:name "examples" :deps ("geoscript"))
)
)