ERROR - .roots.impl.DirectoryIndexImpl - Directory index is not initialized yet.

I'm getting this weird error when running an Inspection configuration with TeamCity 4.0.1

I can't find any previous reference in the forum.

Thanks in advance!

Stacktrace I'm getting:

[  10743]  ERROR - .roots.impl.DirectoryIndexImpl - Directory index is not initialized yet.
[07:59:19]: java.lang.Throwable
[07:59:19]: at com.intellij.openapi.diagnostic.Logger.error(Logger.java:48)
[07:59:19]: at com.intellij.openapi.roots.impl.DirectoryIndexImpl.e(DirectoryIndexImpl.java:448)
[07:59:19]: at com.intellij.openapi.roots.impl.DirectoryIndexImpl.getInfoForDirectory(DirectoryIndexImpl.java:382)
[07:59:19]: at com.intellij.openapi.roots.impl.ProjectFileIndexImpl.isInContent(ProjectFileIndexImpl.java:106)
[07:59:19]: at com.intellij.openapi.roots.impl.ProjectFileIndexImpl.isInContent(ProjectFileIndexImpl.java:90)
[07:59:19]: at com.intellij.util.ui.tree.AbstractFileTreeTable$FileNode.appendChildrenTo(AbstractFileTreeTable.java:10)
[07:59:19]: at com.intellij.util.ui.tree.AbstractFileTreeTable$ConvenientNode.a(AbstractFileTreeTable.java:16)
[07:59:19]: at com.intellij.util.ui.tree.AbstractFileTreeTable$ConvenientNode.getChildCount(AbstractFileTreeTable.java:25)
[07:59:19]: at javax.swing.tree.DefaultMutableTreeNode.isLeaf(DefaultMutableTreeNode.java:1072)
[07:59:19]: at javax.swing.tree.DefaultTreeModel.isLeaf(DefaultTreeModel.java:185)
[07:59:19]: at javax.swing.plaf.basic.BasicTreeUI$NodeDimensionsHandler.getNodeDimensions(BasicTreeUI.java:2717)
[07:59:19]: at javax.swing.tree.AbstractLayoutCache.getNodeDimensions(AbstractLayoutCache.java:475)
[07:59:19]: at javax.swing.tree.VariableHeightLayoutCache$TreeStateNode.updatePreferredSize(VariableHeightLayoutCache.java:1342)
[07:59:19]: at javax.swing.tree.VariableHeightLayoutCache$TreeStateNode.expand(VariableHeightLayoutCache.java:1478)
[07:59:19]: at javax.swing.tree.VariableHeightLayoutCache$TreeStateNode.expand(VariableHeightLayoutCache.java:1270)
[07:59:19]: at javax.swing.tree.VariableHeightLayoutCache.rebuild(VariableHeightLayoutCache.java:725)
[07:59:19]: at javax.swing.tree.VariableHeightLayoutCache.setModel(VariableHeightLayoutCache.java:91)
[07:59:19]: at javax.swing.plaf.basic.BasicTreeUI.setModel(BasicTreeUI.java:398)
[07:59:19]: at javax.swing.plaf.basic.BasicTreeUI$Handler.propertyChange(BasicTreeUI.java:3330)
[07:59:19]: at java.beans.PropertyChangeSupport.firePropertyChange(PropertyChangeSupport.java:339)
[07:59:19]: at java.beans.PropertyChangeSupport.firePropertyChange(PropertyChangeSupport.java:276)
[07:59:19]: at java.awt.Component.firePropertyChange(Component.java:7961)
[07:59:19]: at javax.swing.JTree.setModel(JTree.java:863)
[07:59:19]: at javax.swing.JTree.<init>(JTree.java:650)
[07:59:19]: at com.intellij.util.ui.Tree.<init>(Tree.java:45)
[07:59:19]: at com.intellij.util.ui.treetable.TreeTableTree.<init>(TreeTableTree.java:40)
[07:59:19]: at com.intellij.util.ui.treetable.TreeTable.setModel(TreeTable.java:63)
[07:59:19]: at com.intellij.util.ui.treetable.TreeTable.<init>(TreeTable.java:54)
[07:59:19]: at com.intellij.util.ui.tree.AbstractFileTreeTable.<init>(AbstractFileTreeTable.java:69)
[07:59:19]: at com.intellij.util.ui.tree.LanguagePerFileConfigurable$MyTreeTable.<init>(LanguagePerFileConfigurable.java:5)
[07:59:19]: at com.intellij.util.ui.tree.LanguagePerFileConfigurable.<init>(LanguagePerFileConfigurable.java:4)
[07:59:19]: at com.intellij.psi.templateLanguages.TemplateDataLanguageConfigurable.<init>(TemplateDataLanguageConfigurable.java:5)
[07:59:19]: at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
[07:59:19]: at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
[07:59:19]: at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
[07:59:19]: at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
[07:59:19]: at org.picocontainer.defaults.InstantiatingComponentAdapter.newInstance(InstantiatingComponentAdapter.java:193)
[07:59:19]: at org.picocontainer.defaults.ConstructorInjectionComponentAdapter$1.run(ConstructorInjectionComponentAdapter.java:220)
[07:59:19]: at org.picocontainer.defaults.ThreadLocalCyclicDependencyGuard.observe(ThreadLocalCyclicDependencyGuard.java:53)
[07:59:19]: at org.picocontainer.defaults.ConstructorInjectionComponentAdapter.getComponentInstance(ConstructorInjectionComponentAdapter.java:248)
[07:59:19]: at org.picocontainer.defaults.DecoratingComponentAdapter.getComponentInstance(DecoratingComponentAdapter.java:60)
[07:59:19]: at org.picocontainer.defaults.CachingComponentAdapter.getComponentInstance(CachingComponentAdapter.java:58)
[07:59:19]: at com.intellij.openapi.extensions.impl.ExtensionComponentAdapter.getComponentInstance(ExtensionComponentAdapter.java:71)
[07:59:19]: at com.intellij.openapi.extensions.impl.ExtensionComponentAdapter.getExtension(ExtensionComponentAdapter.java:106)
[07:59:19]: at com.intellij.openapi.extensions.impl.ExtensionPointImpl.processAdapters(ExtensionPointImpl.java:202)
[07:59:19]: at com.intellij.openapi.extensions.impl.ExtensionPointImpl.getExtensions(ExtensionPointImpl.java:151)
[07:59:19]: at com.intellij.openapi.project.impl.ProjectImpl.getExtensions(ProjectImpl.java:48)
[07:59:19]: at com.intellij.ide.actions.ShowSettingsUtilImpl.findProjectConfigurable(ShowSettingsUtilImpl.java:39)
[07:59:19]: at com.intellij.openapi.roots.ui.configuration.projectRoot.ProjectLibrariesConfigurable.getInstance(ProjectLibrariesConfigurable.java:6)
[07:59:19]: at org.jetbrains.idea.maven.project.MavenModuleConfigurator.<init>(MavenModuleConfigurator.java:42)
[07:59:19]: at org.jetbrains.idea.maven.project.MavenProjectConfigurator.createModuleConfigurator(MavenProjectConfigurator.java:202)
[07:59:19]: at org.jetbrains.idea.maven.project.MavenProjectConfigurator.configModules(MavenProjectConfigurator.java:151)
[07:59:19]: at org.jetbrains.idea.maven.project.MavenProjectConfigurator.config(MavenProjectConfigurator.java:55)
[07:59:19]: at org.jetbrains.idea.maven.project.MavenProjectsManager$10.run(MavenProjectsManager.java:327)
[07:59:19]: at com.intellij.openapi.application.impl.ApplicationImpl.runWriteAction(ApplicationImpl.java:392)
[07:59:19]: at org.jetbrains.idea.maven.project.MavenProjectsManager.commit(MavenProjectsManager.java:325)
[07:59:19]: at org.jetbrains.idea.maven.wizards.MavenProjectBuilder.commit(MavenProjectBuilder.java:90)
[07:59:19]: at com.intellij.projectImport.ProjectOpenProcessorBase.doOpenProject(ProjectOpenProcessorBase.java:0)
[07:59:19]: at com.intellij.ide.impl.ProjectUtil.openOrImport(ProjectUtil.java:86)
[07:59:19]: at com.intellij.codeInspection.InspectionApplication.run(InspectionApplication.java:49)
[07:59:19]: at com.intellij.codeInspection.InspectionApplication$1.run(InspectionApplication.java:11)
[07:59:19]: at com.intellij.openapi.application.impl.ApplicationImpl.runReadAction(ApplicationImpl.java:165)
[07:59:19]: at com.intellij.codeInspection.InspectionApplication.startup(InspectionApplication.java:102)
[07:59:19]: at com.intellij.codeInspection.InspectionMain.main(InspectionMain.java:38)
[07:59:19]: at com.intellij.idea.IdeaApplication.run(IdeaApplication.java:14)
[07:59:19]: at com.intellij.idea.MainImpl$3.run(MainImpl.java:1)
[07:59:19]: at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209)
[07:59:19]: at java.awt.EventQueue.dispatchEvent(EventQueue.java:597)
[07:59:19]: at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:269)
[07:59:19]: at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:184)
[07:59:19]: at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:174)
[07:59:19]: at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:169)
[07:59:19]: at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:161)
[07:59:19]: at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)
[07:59:19]: [  10746]  ERROR - .roots.impl.DirectoryIndexImpl - IntelliJ IDEA 8.0.1  Build #9179
[07:59:19]: [  10746]  ERROR - .roots.impl.DirectoryIndexImpl - JDK: 1.6.0_10
[07:59:19]: [  10746]  ERROR - .roots.impl.DirectoryIndexImpl - VM: Java HotSpot(TM) Server VM
[07:59:19]: [  10746]  ERROR - .roots.impl.DirectoryIndexImpl - Vendor: Sun Microsystems Inc.
[07:59:19]: [  10746]  ERROR - .roots.impl.DirectoryIndexImpl - OS: Linux
[07:59:19]: [  10746]  ERROR - .roots.impl.DirectoryIndexImpl - Last Action:
[07:59:19]: [  10747]  ERROR - .roots.impl.DirectoryIndexImpl - Directory index is not initialized yet.


8 comments
Comment actions Permalink

WIll be fixed in next IDEA 8.1 EAP, thank you

0
Comment actions Permalink

nodje,

It means it will probably be fixed in TeamCity 4.1

0
Comment actions Permalink

nodje,

BTW, does the error reproduce every time? Is it fatal for the inspections build or the results are still gathered?

0
Comment actions Permalink

you're right Yegor, it's not fatal for the inspection build. But it does reproduce systematically, it seems. Here's the rest of the stacktrace (after the errors mentione before):

Initializing project...done.
[03:05:56]: The JDK is not configured properly for this project. Inspection cannot proceed.
[03:05:56]: DefaultTeamCityJDK not found
[03:05:57]: extractDescriptions: /usr/local/buildAgent/temp/buildTmp/inspection60720result/.descriptions.xml not found
[03:05:57]: Total: 0 (+0 -0) Errors: 0 (+0 -0)
[03:05:57]: Inspection output: at com.intellij.openapi.application.impl.ApplicationImpl.runWriteAction(ApplicationImpl.java:392) at org.jetbrains.idea.maven.project.MavenProjectsManager.commit(MavenProjectsManager.java:325) at org.jetbrains.idea.maven.wizards.MavenProjectBuilder.commit(MavenProjectBuilder.java:90) at com.intellij.projectImport.ProjectOpenProcessorBase.doOpenProject(ProjectOpenProcessorBase.java:0) at com.intellij.ide.impl.ProjectUtil.openOrImport(ProjectUtil.java:86) at com.intellij.codeInspection.InspectionApplication.run(InspectionApplication.java:49) at com.intellij.codeInspection.InspectionApplication$1.run(InspectionApplication.java:11) at com.intellij.openapi.application.impl.ApplicationImpl.runReadAction(ApplicationImpl.java:165) at com.intellij.codeInspection.InspectionApplication.startup(InspectionApplication.java:102) at com.intellij.codeInspection.InspectionMain.main(InspectionMain.java:38) at com.intellij.idea.IdeaApplication.run(IdeaApplication.java:14) at com.intellij.idea.MainImpl$3.run(MainImpl.java:1) at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209) at java.awt.EventQueue.dispatchEvent(EventQueue.java:597) at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:269) at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:184) at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:174) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:169) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:161) at java.awt.EventDispatchThread.run(EventDispatchThread.java:122) [   9207]  ERROR - .roots.impl.DirectoryIndexImpl - IntelliJ IDEA 8.0.1  Build #9179  [   9207]  ERROR - .roots.impl.DirectoryIndexImpl - JDK: 1.6.0_10  [   9207]  ERROR - .roots.impl.DirectoryIndexImpl - VM: Java HotSpot(TM) Server VM  [   9207]  ERROR - .roots.impl.DirectoryIndexImpl - Vendor: Sun Microsystems Inc.  [   9207]  ERROR - .roots.impl.DirectoryIndexImpl - OS: Linux  [   9207]  ERROR - .roots.impl.DirectoryIndexImpl - Last Action:   done. Initializing project...done. The JDK is not configured properly for this project. Inspection cannot proceed. DefaultTeamCityJDK not found
[03:05:57]: Process exit code: 1
[03:05:57]: Build finished

Other Maven builds run fine. How can I fix "The JDK is not configured properly for this project"?

cheers


0
Comment actions Permalink

nodje,

"DefaultTeamCityJDK" is a JDK definition TeamCity uses if no other JDK definitions are found. How do you have the "DefaultTeamCityJDK" configured on the Inspectinos runner settings?
What JDKs do you have defined on the Inspections runner settings? Have you clicked "Check/Reparse Project" button there?

0
Comment actions Permalink

I recreated the configuration from scratch and it now works on this particular project.
I haven't seen any "Check/Reparse Project" button yet.

I still have Inspection and Duplicate configuration that fail with the following error:

Total: 0 (+0 -0) Errors: 0 (+0 -0)
[08:11:40]: Inspection output: at com.intellij.codeInspection.deadCode.DeadCodeInspection.exportResults(DeadCodeInspection.java:117) at com.intellij.codeInspection.ex.GlobalInspectionContextImpl$4.run(GlobalInspectionContextImpl.java:4) at com.intellij.openapi.application.impl.ApplicationImpl.runReadAction(ApplicationImpl.java:165) at com.intellij.codeInspection.ex.GlobalInspectionContextImpl.launchInspectionsOffline(GlobalInspectionContextImpl.java:116) at com.intellij.codeInspection.InspectionApplication$3.run(InspectionApplication.java:2) at com.intellij.openapi.progress.impl.ProgressManagerImpl$2.run(ProgressManagerImpl.java:5) at com.intellij.openapi.progress.impl.ProgressManagerImpl.executeProcessUnderProgress(ProgressManagerImpl.java:13) at com.intellij.openapi.progress.impl.ProgressManagerImpl.runProcess(ProgressManagerImpl.java:101) at com.intellij.codeInspection.InspectionApplication.run(InspectionApplication.java:33) at com.intellij.codeInspection.InspectionApplication$1.run(InspectionApplication.java:11) at com.intellij.openapi.application.impl.ApplicationImpl.runReadAction(ApplicationImpl.java:165) at com.intellij.codeInspection.InspectionApplication.startup(InspectionApplication.java:102) at com.intellij.codeInspection.InspectionMain.main(InspectionMain.java:38) at com.intellij.idea.IdeaApplication.run(IdeaApplication.java:14) at com.intellij.idea.MainImpl$3.run(MainImpl.java:1) at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209) at java.awt.EventQueue.dispatchEvent(EventQueue.java:597) at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:269) at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:184) at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:174) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:169) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:161) at java.awt.EventDispatchThread.run(EventDispatchThread.java:122) [  56004]  ERROR - spection.InspectionApplication - IntelliJ IDEA 8.0.1  Build #9179  [  56004]  ERROR - spection.InspectionApplication - JDK: 1.6.0_10  [  56005]  ERROR - spection.InspectionApplication - VM: Java HotSpot(TM) Server VM  [  56005]  ERROR - spection.InspectionApplication - Vendor: Sun Microsystems Inc.  [  56005]  ERROR - spection.InspectionApplication - OS: Linux  [  56005]  ERROR - spection.InspectionApplication - Last Action:   @NotNull method com/intellij/extapi/psi/StubBasedPsiElementBase.getRequiredStubOrPsiChild must not return null
[08:11:40]: Process exit code: 1
[08:11:40]: Build finished

Oddly enough, this appears on the simplest project.

It does work for most of our projects, even with the error mentioned originally in this post.

cheers


0
Comment actions Permalink

Could you please send us this sample project? Thank you

0
Comment actions Permalink

Hi,
sorry I've been off for some time.

The project is quite big, it's not easy to send.
If still needed, I can try to reproduce it with a smaller test case project.
But that's going to be difficult.

0

Please sign in to leave a comment.