nnmatveev / idea-plugin-protobuf

Google Protocol Buffes support for Intellij IDEA
Other
120 stars 39 forks source link

Project compilation fails in IDEA 14 #53

Closed mukhanov closed 9 years ago

mukhanov commented 10 years ago

Whole compilation workflow fails when plugin is enabled:

com.intellij.compiler.CompilerWorkspaceConfiguration.useOutOfProcessBuild()Z java.lang.NoSuchMethodError: com.intellij.compiler.CompilerWorkspaceConfiguration.useOutOfProcessBuild()Z at protobuf.compiler.PbPrecompileTask.execute(PbPrecompileTask.java:26) at com.intellij.compiler.impl.CompileDriver.a(CompileDriver.java:622) at com.intellij.compiler.impl.CompileDriver.access$400(CompileDriver.java:89) at com.intellij.compiler.impl.CompileDriver$3.run(CompileDriver.java:414) at com.intellij.compiler.progress.CompilerTask.run(CompilerTask.java:181) at com.intellij.openapi.progress.impl.ProgressManagerImpl$TaskRunnable.run(ProgressManagerImpl.java:476) at com.intellij.openapi.progress.impl.ProgressManagerImpl$2.run(ProgressManagerImpl.java:183) at com.intellij.openapi.progress.ProgressManager.executeProcessUnderProgress(ProgressManager.java:218) at com.intellij.openapi.progress.impl.ProgressManagerImpl.executeProcessUnderProgress(ProgressManagerImpl.java:217) at com.intellij.openapi.progress.impl.ProgressManagerImpl.runProcess(ProgressManagerImpl.java:170) at com.intellij.openapi.progress.impl.ProgressManagerImpl$8.run(ProgressManagerImpl.java:385) at com.intellij.openapi.application.impl.ApplicationImpl$9.run(ApplicationImpl.java:446) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:439) at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303) at java.util.concurrent.FutureTask.run(FutureTask.java:138) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:895) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:918) at java.lang.Thread.run(Thread.java:695) at com.intellij.openapi.application.impl.ApplicationImpl$1$1.run(ApplicationImpl.java:149)

java.lang.Throwable at com.intellij.openapi.diagnostic.Logger.error(Logger.java:125) at com.intellij.openapi.application.impl.ApplicationImpl.assertReadAccessAllowed(ApplicationImpl.java:1053) at com.intellij.debugger.ui.breakpoints.BreakpointWithHighlighter.reload(BreakpointWithHighlighter.java:269) at com.intellij.debugger.ui.breakpoints.BreakpointWithHighlighter.(BreakpointWithHighlighter.java:180) at com.intellij.debugger.ui.breakpoints.LineBreakpoint.(LineBreakpoint.java:79) at com.intellij.javascript.debugger.nashorn.NashornJsBreakpointHandlerFactory$NashornLineBreakpoint.(NashornJsBreakpointHandlerFactory.java:35) at com.intellij.javascript.debugger.nashorn.NashornJsBreakpointHandlerFactory$NashornLineBreakpoint.(NashornJsBreakpointHandlerFactory.java:33) at com.intellij.javascript.debugger.nashorn.NashornJsBreakpointHandlerFactory$1.createJavaBreakpoint(NashornJsBreakpointHandlerFactory.java:27) at com.intellij.debugger.engine.JavaBreakpointHandler.registerBreakpoint(JavaBreakpointHandler.java:46) at com.intellij.xdebugger.impl.XDebugSessionImpl.a(XDebugSessionImpl.java:388) at com.intellij.xdebugger.impl.XDebugSessionImpl.a(XDebugSessionImpl.java:378) at com.intellij.xdebugger.impl.XDebugSessionImpl.a(XDebugSessionImpl.java:520) at com.intellij.xdebugger.impl.XDebugSessionImpl.initBreakpoints(XDebugSessionImpl.java:298) at com.intellij.debugger.engine.DebugProcessEvents.e(DebugProcessEvents.java:327) at com.intellij.debugger.engine.DebugProcessEvents.commitVM(DebugProcessEvents.java:72) at com.intellij.debugger.engine.DebugProcessImpl$9$2$1.action(DebugProcessImpl.java:1847) at com.intellij.debugger.engine.events.DebuggerCommandImpl.run(DebuggerCommandImpl.java:45) at com.intellij.debugger.engine.DebuggerManagerThreadImpl.processEvent(DebuggerManagerThreadImpl.java:151) at com.intellij.debugger.engine.DebuggerManagerThreadImpl.processEvent(DebuggerManagerThreadImpl.java:39) at com.intellij.debugger.impl.InvokeThread.a(InvokeThread.java:146) at com.intellij.debugger.impl.InvokeThread.access$100(InvokeThread.java:28) at com.intellij.debugger.impl.InvokeThread$WorkerThreadRequest.run(InvokeThread.java:55) at com.intellij.openapi.application.impl.ApplicationImpl$9.run(ApplicationImpl.java:446) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:439) at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303) at java.util.concurrent.FutureTask.run(FutureTask.java:138) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:895) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:918) at java.lang.Thread.run(Thread.java:695) at com.intellij.openapi.application.impl.ApplicationImpl$1$1.run(ApplicationImpl.java:149)

tcripps commented 10 years ago

Sigh. It would be nice if JetBrains was better about deprecating API before removing it.

I'm uploading a 0.5.8-EAP release archive that restores function when running under IDEA 14.

mcamou commented 10 years ago

I installed the plugin to get syntax highlighting (we're using Scala and sbt-scalabuf to compile). Even when I disable protobuf compilation in the project settings I get this same error.

tcripps commented 10 years ago

mcamou,

Which version of the plugin did you install? Was it version 0.5.8-EAP (the only version of the plugin that supports IDEA 14)?

mcamou commented 10 years ago

I have the latest one that is available in the IntelliJ repositories (0.5.7). Where do I get 0.5.8-EAP?

tcripps commented 10 years ago

https://github.com/nnmatveev/idea-plugin-protobuf/releases

mcamou commented 10 years ago

Thanks! That fixed THAT exception. However, in my project I am using scalabuff (called from sbt) to compile the .proto files into Scala (I want to use the plugin just for syntax highlighting). I've gone into Project Structure -> Facets -> Protobuf Facet and disabled the "Enable compilation" checkbox. However, when trying to compile I get the following message:

19:09:59 Throwable: Cannot generate protobuf files as the path to protoc has not been set. Please set in Settins > Compiler 19:09:59 Compilation completed with 0 errors and 0 warnings in 0 sec

Setting the path to protoc in the IntelliJ settings allows me to compile the project, however, I think that should not be necessary since I have disabled compilation.

driekken commented 9 years ago

Please see https://github.com/nnmatveev/idea-plugin-protobuf/issues/48 as well.

GildedHonour commented 9 years ago

Setting the path to protoc in the IntelliJ settings allows me to compile the project, however, I think that should not be necessary since I have disabled compilation. - what did you set it to?

mcamou commented 9 years ago

@GildedHonour You have to install protobuf on your machine (outside of IntelliJ) and then put in the path to the protoc executable

ghost commented 9 years ago

How to compile using http://github.com/nnmatveev/idea-plugin-protobuf ? Is there User-Guide? Demo?

tcripps commented 9 years ago

Read https://github.com/nnmatveev/idea-plugin-protobuf/blob/master/Help.txt. It explains how to install and configure the plugin. Compilation happens "automagically" (once set up) when you build your Java module or project.