Somehow Scala support in my idea got corrupted...

Yesterday everything worked fine, I installed the updated plugin with imporved FSC and it worked great.

Today, not so much ;). When I try to run anything with or without FSC, I get: scala.tools.nsc.MissingRequirementError: object scala not found. Moreover, some random types are not "seen" by the editor, e.g. Option and Seq (they are highighted as red and auto-import suggest some Option from java). However, I can open Option by using "go to class". I tried recreating the project (using SBT), removing all the caches, removing the plugin and installing it again, but nothing helps.

Any suggestions? :)

Thanks,
Adam

4 comments
Comment actions Permalink

Please check project configuration guide. It's likely that you have no scala standard library in the dependencies.

0
Comment actions Permalink

Hmm, the idea project is auto-generated using the idea sbt plugin, plus it worked without problems up until yesterday (I only updated the scala plugin, and that worked for several hours as well).

I looked at the deps, and each module is dependent on a project library which has scala-library inside, plus all of the facets are set to use a library with scala-library and scala-compiler jars.

Adam

0
Comment actions Permalink

Hm, after careful re-examintaion it turned out one of my modules didn't have the scala lib in dependencies. Weird ... I'll try to reproduce and issue a bug in the sbt-idea plugin.

Meanwhile, thanks a lot for the help! :)

Adam

0
Comment actions Permalink

The same problem happened to me.  Adam, thanks for pointing to the source of the problem and the solution.  In the dependencies tab for my module, the scala library was listed but the font was red and the icon was a globe instead of a bunch of books.  I deleted that entry and added it again, after which it started working again.

0

Please sign in to leave a comment.