Help: I can't import an sbt project

I have an sbt project. I try to import it and it goes wrong in the middle. I get an imported project that's incomplete - for example it doesn't know about the build.sbt file
What sort of things might I try to diagnose or fix it?
I just downloaded 14.1.3 today and this is the first project Ive tried to rebuild since.

10 comments
Comment actions Permalink

ok - got it working
It seems that I did not have a default java sdk set up.
could do with a more helpful error message though!

0
Comment actions Permalink

sorry to re-raise
But I've found that consistently all projects I used to be able to import no longer mport.
So if you "open" an sbt-based project it goes to the import dialog, you select the options and it starts processing the sbt file.
Then the import progress window just disappears.
You can go and open the project and it hasn't processed sbt correctly - so it is just listing the sbt file and none of the source
You can then open sbt file and do the import - which sort of works but doesn't find the sources.

This has only occured since 14.1.3 yesterday morning

0
Comment actions Permalink

I am seeing the same behavior. Sbt import works with IntelliJ IDEA 14.1.2 / Scala-plugin 1.4.15, but fails with IDEA 14.1.3 (Scala-plugin 1.4.15). Can reproduce with a simple Play Framework build.sbt.

0
Comment actions Permalink

Same issue here. Looking at ~/Library/Logs/IdeaIC14/idea.log here is the error I'm getting:

...

Reason: target module (ModuleData: module ':root:') is not found at the ide and can't be imported

2015-05-17 16:20:32,419 [ 242941]   WARN - e.LibraryDependencyDataService - Can't import library dependencies [LibraryDependencyData: dependency=library sbt-and-plugins|scope=Compile|exported=false|owner=module ':root-build:']. Reason: target module (ModuleData: module ':root-build:') is not found at the ide and can't be imported

2015-05-17 16:20:32,420 [ 242942]  ERROR - llij.ide.plugins.PluginManager - null

java.lang.NullPointerException

 at org.jetbrains.plugins.scala.project.package$ModuleExt.compilerConfiguration(package.scala:116)

 at org.jetbrains.plugins.scala.project.package$ModuleExt.configureScalaCompilerSettingsFrom(package.scala:113)

...

0
Comment actions Permalink

I'm facing the same error since updating to latest Intellij release. Getting errors like the following:

2015-05-18 17:01:42,909 [ 520221]   WARN - e.LibraryDependencyDataService - Can't import library dependencies [LibraryDependencyData: dependency=library sbt-and-plugins|scope=Compile|exported=false|owner=module ':core-build:']. Reason: target module (ModuleData: module ':core-build:') is not found at the ide and can't be imported

2015-05-18 17:01:42,909 [ 520221]   WARN - e.LibraryDependencyDataService - Can't import library dependencies [LibraryDependencyData: dependency=library sbt-and-plugins|scope=Compile|exported=false|owner=module ':scalazstream-build:']. Reason: target module (ModuleData: module ':scalazstream-build:') is not found at the ide and can't be imported

0
Comment actions Permalink

Same here exactly.

Then I tried version 1.4.189.1.EAP and it's working so far.

0
Comment actions Permalink

I also cannot import anything new after moving to IJ 14.1.3. This is a major issue for me. No SBT-based projects will import. Please address and fix this ASAP. P0.

0
Comment actions Permalink

Stack trace from log:

2015-05-18 11:34:26,749 [263423459]  ERROR - llij.ide.plugins.PluginManager - null
java.lang.NullPointerException
     at org.jetbrains.plugins.scala.project.package$ModuleExt.compilerConfiguration(package.scala:116)
     at org.jetbrains.plugins.scala.project.package$ModuleExt.configureScalaCompilerSettingsFrom(package.scala:113)
     at org.jetbrains.sbt.project.data.ScalaSdkDataService.org$jetbrains$sbt$project$data$ScalaSdkDataService$$doImport(ScalaSdkDataService.scala:30)
     at org.jetbrains.sbt.project.data.ScalaSdkDataService$$anonfun$doImportData$1.apply(ScalaSdkDataService.scala:19)
     at org.jetbrains.sbt.project.data.ScalaSdkDataService$$anonfun$doImportData$1.apply(ScalaSdkDataService.scala:19)
     at scala.collection.Iterator$class.foreach(Iterator.scala:743)
     at scala.collection.AbstractIterator.foreach(Iterator.scala:1177)
     at scala.collection.IterableLike$class.foreach(IterableLike.scala:72)
     at scala.collection.AbstractIterable.foreach(Iterable.scala:54)
     at org.jetbrains.sbt.project.data.ScalaSdkDataService.doImportData(ScalaSdkDataService.scala:19)
     at org.jetbrains.sbt.project.data.AbstractDataService$$anonfun$importData$1.apply$mcV$sp(AbstractDataService.scala:20)
     at org.jetbrains.sbt.project.data.AbstractDataService$$anon$1.execute(AbstractDataService.scala:39)
     at com.intellij.openapi.externalSystem.util.DisposeAwareProjectChange.run(DisposeAwareProjectChange.java:36)
     at com.intellij.openapi.externalSystem.util.ExternalSystemApiUtil$7$1.run(ExternalSystemApiUtil.java:462)
     at com.intellij.openapi.application.impl.ApplicationImpl.runWriteAction(ApplicationImpl.java:931)
     at com.intellij.openapi.externalSystem.util.ExternalSystemApiUtil$7.run(ExternalSystemApiUtil.java:459)
     at com.intellij.openapi.externalSystem.util.ExternalSystemApiUtil.executeOnEdt(ExternalSystemApiUtil.java:472)
     at com.intellij.openapi.externalSystem.util.ExternalSystemApiUtil.executeProjectChangeAction(ExternalSystemApiUtil.java:457)
     at org.jetbrains.sbt.project.data.AbstractDataService$.invoke(AbstractDataService.scala:37)
     at org.jetbrains.sbt.project.data.AbstractDataService.importData(AbstractDataService.scala:19)
     at com.intellij.openapi.externalSystem.service.project.manage.ProjectDataManager.importData(ProjectDataManager.java:132)
     at com.intellij.openapi.externalSystem.service.project.manage.ProjectDataManager.importData(ProjectDataManager.java:102)
     at com.intellij.openapi.externalSystem.service.project.manage.ProjectDataManager.importData(ProjectDataManager.java:141)
     at com.intellij.openapi.externalSystem.service.project.manage.ProjectDataManager.importData(ProjectDataManager.java:102)
     at com.intellij.openapi.externalSystem.service.project.manage.ProjectDataManager.importData(ProjectDataManager.java:141)
     at com.intellij.openapi.externalSystem.service.project.wizard.AbstractExternalProjectImportBuilder$2$1.run(AbstractExternalProjectImportBuilder.java:163)
     at com.intellij.openapi.roots.impl.ProjectRootManagerImpl.mergeRootsChangesDuring(ProjectRootManagerImpl.java:328)
     at com.intellij.openapi.externalSystem.service.project.wizard.AbstractExternalProjectImportBuilder$2.execute(AbstractExternalProjectImportBuilder.java:160)
     at com.intellij.openapi.externalSystem.util.DisposeAwareProjectChange.run(DisposeAwareProjectChange.java:36)
     at com.intellij.openapi.externalSystem.util.ExternalSystemApiUtil$7$1.run(ExternalSystemApiUtil.java:462)
     at com.intellij.openapi.application.impl.ApplicationImpl.runWriteAction(ApplicationImpl.java:931)
     at com.intellij.openapi.externalSystem.util.ExternalSystemApiUtil$7.run(ExternalSystemApiUtil.java:459)
     at com.intellij.util.ui.UIUtil.invokeLaterIfNeeded(UIUtil.java:2344)
     at com.intellij.openapi.externalSystem.util.ExternalSystemApiUtil.executeOnEdt(ExternalSystemApiUtil.java:479)
     at com.intellij.openapi.externalSystem.util.ExternalSystemApiUtil.executeProjectChangeAction(ExternalSystemApiUtil.java:457)
     at com.intellij.openapi.externalSystem.util.ExternalSystemApiUtil.executeProjectChangeAction(ExternalSystemApiUtil.java:453)
     at com.intellij.openapi.externalSystem.service.project.wizard.AbstractExternalProjectImportBuilder.commit(AbstractExternalProjectImportBuilder.java:157)
     at com.intellij.projectImport.ProjectImportBuilder.commit(ProjectImportBuilder.java:60)
     at com.intellij.ide.impl.NewProjectUtil.a(NewProjectUtil.java:164)
     at com.intellij.ide.impl.NewProjectUtil.createFromWizard(NewProjectUtil.java:79)
     at com.intellij.ide.actions.ImportModuleAction.createFromWizard(ImportModuleAction.java:86)
     at com.intellij.ide.actions.ImportModuleAction.doImport(ImportModuleAction.java:81)
     at com.intellij.ide.actions.ImportProjectAction.actionPerformed(ImportProjectAction.java:29)
     at com.intellij.openapi.actionSystem.ex.ActionUtil.performActionDumbAware(ActionUtil.java:182)
     at com.intellij.openapi.actionSystem.impl.ActionMenuItem$ActionTransmitter$1.run(ActionMenuItem.java:312)
     at com.intellij.openapi.wm.impl.FocusManagerImpl.runOnOwnContext(FocusManagerImpl.java:958)
     at com.intellij.openapi.wm.impl.IdeFocusManagerImpl.runOnOwnContext(IdeFocusManagerImpl.java:124)
     at com.intellij.openapi.actionSystem.impl.ActionMenuItem$ActionTransmitter.actionPerformed(ActionMenuItem.java:282)
     at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:2022)
     at com.intellij.openapi.actionSystem.impl.ActionMenuItem.fireActionPerformed(ActionMenuItem.java:109)
     at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2346)
     at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:402)
     at javax.swing.JToggleButton$ToggleButtonModel.setPressed(JToggleButton.java:308)
     at javax.swing.AbstractButton.doClick(AbstractButton.java:376)
     at com.apple.laf.ScreenMenuItemCheckbox.itemStateChanged(ScreenMenuItemCheckbox.java:193)
     at java.awt.CheckboxMenuItem.processItemEvent(CheckboxMenuItem.java:389)
     at java.awt.CheckboxMenuItem.processEvent(CheckboxMenuItem.java:357)
     at java.awt.MenuComponent.dispatchEventImpl(MenuComponent.java:351)
     at java.awt.MenuComponent.dispatchEvent(MenuComponent.java:339)
     at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:761)
     at java.awt.EventQueue.access$500(EventQueue.java:97)
     at java.awt.EventQueue$3.run(EventQueue.java:709)
     at java.awt.EventQueue$3.run(EventQueue.java:703)
     at java.security.AccessController.doPrivileged(Native Method)
     at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:75)
     at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:86)
     at java.awt.EventQueue$4.run(EventQueue.java:731)
     at java.awt.EventQueue$4.run(EventQueue.java:729)
     at java.security.AccessController.doPrivileged(Native Method)
     at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:75)
     at java.awt.EventQueue.dispatchEvent(EventQueue.java:728)
     at com.intellij.ide.IdeEventQueue.e(IdeEventQueue.java:734)
     at com.intellij.ide.IdeEventQueue._dispatchEvent(IdeEventQueue.java:569)
     at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:382)
     at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:201)
     at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:116)
     at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:105)
     at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
     at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:93)
     at java.awt.EventDispatchThread.run(EventDispatchThread.java:82)
2015-05-18 11:34:26,749 [263423459]  ERROR - llij.ide.plugins.PluginManager - IntelliJ IDEA 14.1.3  Build #IU-141.1010.3
2015-05-18 11:34:26,749 [263423459]  ERROR - llij.ide.plugins.PluginManager - JDK: 1.8.0_45
2015-05-18 11:34:26,749 [263423459]  ERROR - llij.ide.plugins.PluginManager - VM: Java HotSpot(TM) 64-Bit Server VM
2015-05-18 11:34:26,749 [263423459]  ERROR - llij.ide.plugins.PluginManager - Vendor: Oracle Corporation
2015-05-18 11:34:26,749 [263423459]  ERROR - llij.ide.plugins.PluginManager - OS: Mac OS X
2015-05-18 11:34:26,749 [263423459]  ERROR - llij.ide.plugins.PluginManager - Last Action: ImportProject
2015-05-18 11:35:26,643 [263483353]   INFO - ution.rmi.RemoteProcessSupport - Process finished with exit code 0

0
Comment actions Permalink

Resolved this for now by installing the Scala plugin EAP (https://confluence.jetbrains.com/display/SCA/Scala+plugin+EAP).

0
Comment actions Permalink

Problem has been resolved for me with with following update of the Scala plugin (1.5).

http://plugins.jetbrains.com/update/index?pr=&updateId=19817

0

Please sign in to leave a comment.