I have Intellij-IDEA 13.1.2. [edited, previously 13.0.2] I use the scala-plugin. I'm trying to use worksheets to evaluate code.
But all I got are two errors :
bad macro impl binding: versionFormat is supposed to be there
Unable to read an event from: rO0ABXNyADVvcmcuamV0YnJhaW5zLmpwcy5pbmNyZW1lbnRhbC...
I can run the scala console normally and execute my code in it, but the worksheet doesn't function. If my code is incorrect, it outputs an error indicating the interpreter failed to parse my code. I got the "bad macro impl binding" error only if my code is correct.
I tried creating a new project, but it didn't work. I followed tutorial to configure scala in intellij but it didn't help either.
Is there an important configuration step I may have missed ? What does that error mean ?
EDIT : I tried the simplest thing in my worksheet like 1 or var x = 1 or println("Hello World!")
EDIT2: I'm not sure what I changed but now I have another error : Error:error while loading MacroPrinter, class file needed by MacroPrinter is missing. reference value macros of package reflect refers to nonexisting symbol.
UPDATE: Now it works fine under Intellij 13.1.5, Scala plugin 0.41.2 with both scala-2.10 and 2.11
Right-click your project and select New|Scala Worksheet. We recommend that you create an . sc file in the src directory to avoid problems with code highlighting. In the New Scala Worksheet window, type the name of the file and click OK.
tip. To install Scala plugin, press Ctrl+Alt+S , open the Plugins page, browse repositories to locate the Scala plugin, click Install and restart IntelliJ IDEA. Now you can successfully check out from VCS, create, or import Scala projects.
A worksheet is a Scala file that is evaluated on save, and the result of each expression is shown in a column to the right of your program. Worksheets are like a REPL session on steroids, and enjoy 1st class editor support: completion, hyperlinking, interactive errors-as-you-type, etc. Worksheet use the extension .
I had the "Unable to read an event from" issue and switching from Scala 2.11.0 to Scala 2.10.4 fixed it for me.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With