Permalink
Browse files

JPS: report unexpected stdout data from compile server as warnings

  • Loading branch information...
1 parent 2661af8 commit 3152053301694dd858910d4a9bb614ba8590ca75 @pavelfatin pavelfatin committed Feb 15, 2013
Showing with 5 additions and 1 deletion.
  1. +5 −1 jps-plugin/src/org/jetbrains/jps/incremental/scala/remote/RemoteServer.scala
View
6 jps-plugin/src/org/jetbrains/jps/incremental/scala/remote/RemoteServer.scala
@@ -83,8 +83,12 @@ private object RemoteServer {
client.message(Kind.ERROR, "Unable to read an event from: " + chars)
client.trace(e)
}
+ // Main server class redirects all (unexpected) stdout data to stderr.
+ // In theory, there should be no such data at all, however, in practice,
+ // SBT "leaks" some messages into console (e.g. for "explain type errors" option).
+ // Report such output not as errors, but as warings (to continue make process).
case Chunk(NGConstants.CHUNKTYPE_STDERR, data) =>
- client.message(Kind.ERROR, fromBytes(data))
+ client.message(Kind.WARNING, fromBytes(data))
case Chunk(kind, data) =>
client.message(Kind.ERROR, "Unexpected server output: " + data)
}

0 comments on commit 3152053

Please sign in to comment.