I'm writing a mixed Scala and Java program using Eclipse. Everything was working fine until about an hour ago, when it all went to hell for no apparent reason.
There are no problems (Scala or Java) reported in Eclipse, but the Scala builder appears to be failing somewhere. It is no longer producing any class files. Attempting to run "Hello World" in Scala now results in the message:
Project 'projectname' contains compilation errors (therefore, no binaries have been produced)
I'm using default settings for the Scala builder, and it worked fine earlier. I haven't changed anything.
I've tried cleaning and rebuilding the project several times, to no avail. The build progress dialog gives the appearance that both Scala and Java builds are successful. Pure-Java parts of the program compile and execute successfully. (I've temporarily commented out places where Java calls through to Scala, because the lack of Scala class files was causing 'unresolved class' import error)
Is there a Scala compiler error log somewhere that will tell me what is going wrong?? I am about to start tearing my hair out.
I don't remember exactly what I did that caused this, but it wouldn't have been anything exotic: writing a few new classes, some basic refactoring, etc.
First look on Eclipse console output during build. You can see lot of interesting things :-).
Just one possible direction to look into:
I'm not 100% sure but AFAIR Eclipse use Maven to build Java and Scala sources (at least on projects I received). If you see pom.xml file in project root, that is it and you can try to issue commands like mvn compile
and check logs. With Maven there could be lot of issues starting from ones in local JAR repository.
BTW Maven repository is located in ~/.m2. Of course most of this corresponds to Unix installations.
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