Code completion not working inside pom.xml

Hello,

I am using IntelliJ 13.1.5 on Mac OSX Mavericks.
Since today I have problems with the return and tab keys in pom.xml files (they are not functioning any more).
When I try to do auto-completion (via ctrl-space) it shows a small blue box for a second, which instantly disappears again.
It seems to be empty, too.

Even live templates are not functioning anymore.

What can I do to get it running again?

Regards

Florian

4 comments
Comment actions Permalink

I have found the following in the log file:

WARN - pi.vfs.impl.jar.JarHandlerBase - error in opening zip file: <...>/pom.xml
java.util.zip.ZipException: error in opening zip file
        at java.util.zip.ZipFile.open(Native Method)
        at java.util.zip.ZipFile.(ZipFile.java:128)
        at java.util.zip.ZipFile.(ZipFile.java:145)
        at com.intellij.openapi.vfs.impl.jar.JarHandlerBase.createJarFile(JarHandlerBase.java:102)
        at com.intellij.openapi.vfs.impl.jar.JarHandlerBase.getJar(JarHandlerBase.java:88)
        at com.intellij.openapi.vfs.impl.jar.JarHandlerBase.getEntriesMap(JarHandlerBase.java:248)
        at com.intellij.openapi.vfs.impl.jar.JarHandlerBase.getEntryInfo(JarHandlerBase.java:239)
        at com.intellij.openapi.vfs.impl.jar.JarHandlerBase.getEntryInfo(JarHandlerBase.java:234)
        at com.intellij.openapi.vfs.impl.jar.JarHandlerBase.list(JarHandlerBase.java:218)
        at com.intellij.openapi.vfs.impl.jar.JarFileSystemImpl.list(JarFileSystemImpl.java:271)
        at com.intellij.openapi.vfs.newvfs.persistent.RefreshWorker.a(RefreshWorker.java:132)
        at com.intellij.openapi.vfs.newvfs.persistent.RefreshWorker.scan(RefreshWorker.java:95)
        at com.intellij.openapi.vfs.newvfs.RefreshSessionImpl.scan(RefreshSessionImpl.java:136)
        at com.intellij.openapi.vfs.newvfs.RefreshQueueImpl.a(RefreshQueueImpl.java:102)
        at com.intellij.openapi.vfs.newvfs.RefreshQueueImpl.access$100(RefreshQueueImpl.java:40)
        at com.intellij.openapi.vfs.newvfs.RefreshQueueImpl$1.run(RefreshQueueImpl.java:79)
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:439)
        at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
        at java.util.concurrent.FutureTask.run(FutureTask.java:138)
        at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:895)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:918)
        at java.lang.Thread.run(Thread.java:695)



The error is disappearing, when I deactivate a profile which includes a subproject of the parent pom.
The profile definition is as follows:

<profile>
     <id>long-running-module</id>
     <modules>
           <module>long-running-module</module>
     </modules>
</profile>

The subproject is normally included as ready built jar because it needs long time to build.

Regards

Florian

0
Comment actions Permalink

Hello.

Can you attach your project here to let me find the problem?

If you cannot, then you can try the following hint on your side:
https://youtrack.jetbrains.com/issue/IDEA-120069#comment=27-667885

If the reference is not clear, one has to do the following:
1. Turn on the profile to include the problematic module. Probably get the error.
2. Select the module in the Project tool window.
3. F4 to open the module definition in Project Structure dialog.
4. Open Dependencies tab. See the list of "Maven: *" library entries.
5. One (or more) of these libraries contains a reference to pom.xml instead of jar in its definition. (You have to open every definition.)
You can try to remove that reference and reimport the module.

_If_ my supposition is correct (I do not see the actual project), this may help.

Regards,
Alexander.

0
Comment actions Permalink

Hello Alexander,

since the project is closed source, giving you the code is not an option :(.

I have searched with your hints and found the following:

  1. There were no libraries referencing a pom, but some errors in the artifact building process. => I've fixed them, enter is still not working in pom.xml files.
  2. After that idea.log showed me the following stack trace:
    java.lang.AssertionError
            at com.intellij.psi.impl.file.impl.ResolveScopeManagerImpl.getDefaultResolveScope(ResolveScopeManagerImpl.java:177)
            at com.intellij.lang.javascript.index.JavaScriptIndex.isMinified(JavaScriptIndex.java:301)
            at com.intellij.lang.javascript.index.MyJSNamedItem.isNavigatable(MyJSNamedItem.java:445)
            at com.intellij.lang.javascript.index.MyJSNamedItem.getNavigatable(MyJSNamedItem.java:439)
            at com.intellij.lang.javascript.index.MyJSNamedItem.canNavigate(MyJSNamedItem.java:431)
            at org.angularjs.index.AngularIndexUtil.resolve(AngularIndexUtil.java:43)
            at org.angularjs.index.AngularIndexUtil$2.compute(AngularIndexUtil.java:69)
            at com.intellij.psi.impl.PsiCachedValueImpl.doCompute(PsiCachedValueImpl.java:49)
            at com.intellij.util.CachedValueBase.getValueWithLock(CachedValueBase.java:199)
            at com.intellij.psi.impl.PsiCachedValueImpl.getValue(PsiCachedValueImpl.java:38)
            at com.intellij.util.CachedValuesManagerImpl.getCachedValue(CachedValuesManagerImpl.java:81)
            at com.intellij.psi.util.CachedValuesManager.getCachedValue(CachedValuesManager.java:95)
            at org.angularjs.index.AngularIndexUtil.hasAngularJS(AngularIndexUtil.java:65)
            at org.angularjs.editor.AngularJSInjector.getLanguagesToInject(AngularJSInjector.java:31)
            at com.intellij.psi.impl.source.tree.injected.InjectedPsiCachedValueProvider$MyInjProcessor.process(InjectedPsiCachedValueProvider.java:82)
            at com.intellij.psi.impl.source.tree.injected.InjectedLanguageManagerImpl.processInPlaceInjectorsFor(InjectedLanguageManagerImpl.java:448)
            at com.intellij.psi.impl.source.tree.injected.InjectedPsiCachedValueProvider.doCompute(InjectedPsiCachedValueProvider.java:62)
            at com.intellij.psi.impl.source.tree.injected.InjectedLanguageUtil.a(InjectedLanguageUtil.java:217)
            at com.intellij.psi.impl.source.tree.injected.InjectedLanguageUtil.enumerate(InjectedLanguageUtil.java:121)
            at com.intellij.psi.impl.source.tree.injected.InjectedLanguageUtil.a(InjectedLanguageUtil.java:306)
            at com.intellij.psi.impl.source.tree.injected.InjectedLanguageUtil.a(InjectedLanguageUtil.java:288)
            at com.intellij.psi.impl.source.tree.injected.InjectedLanguageUtil.findInjectedElementNoCommit(InjectedLanguageUtil.java:269)
            at com.intellij.psi.impl.source.tree.injected.InjectedLanguageUtil.findInjectedPsiNoCommit(InjectedLanguageUtil.java:176)
            at com.intellij.psi.impl.source.tree.injected.InjectedLanguageUtil.getEditorForInjectedLanguageNoCommit(InjectedLanguageUtil.java:147)
            at com.intellij.psi.impl.source.tree.injected.InjectedLanguageUtil.getEditorForInjectedLanguageNoCommit(InjectedLanguageUtil.java:142)
            at com.intellij.openapi.fileEditor.impl.text.TextEditorPsiDataProvider.getData(TextEditorPsiDataProvider.java:53)
            at com.intellij.openapi.fileEditor.ex.FileEditorManagerEx.getData(FileEditorManagerEx.java:163)
            at com.intellij.openapi.fileEditor.impl.text.TextEditorComponent.getData(TextEditorComponent.java:269)
            at com.intellij.openapi.fileEditor.impl.text.PsiAwareTextEditorImpl$PsiAwareTextEditorComponent.getData(PsiAwareTextEditorImpl.java:92)
            at com.intellij.ide.impl.DataManagerImpl.a(DataManagerImpl.java:85)
            at com.intellij.ide.impl.DataManagerImpl.a(DataManagerImpl.java:73)
            at com.intellij.ide.impl.DataManagerImpl.access$300(DataManagerImpl.java:51)
            at com.intellij.ide.impl.DataManagerImpl$MyDataContext.a(DataManagerImpl.java:381)
            at com.intellij.ide.impl.DataManagerImpl$MyDataContext.getData(DataManagerImpl.java:358)
            at com.intellij.openapi.actionSystem.AnActionEvent$1.getData(AnActionEvent.java:131)
            at com.intellij.openapi.actionSystem.DataKey.getData(DataKey.java:75)
            at com.intellij.openapi.editor.actionSystem.EditorAction.getEditor(EditorAction.java:73)
            at com.intellij.openapi.editor.actionSystem.EditorAction.update(EditorAction.java:114)
            at com.intellij.openapi.actionSystem.AnAction.beforeActionPerformedUpdate(AnAction.java:244)
            at com.intellij.openapi.actionSystem.ex.ActionUtil.performDumbAwareUpdate(ActionUtil.java:110)
            at com.intellij.openapi.keymap.impl.IdeKeyEventDispatcher.processAction(IdeKeyEventDispatcher.java:589)
            at com.intellij.openapi.keymap.impl.IdeKeyEventDispatcher.d(IdeKeyEventDispatcher.java:463)
            at com.intellij.openapi.keymap.impl.IdeKeyEventDispatcher.dispatchKeyEvent(IdeKeyEventDispatcher.java:206)
            at com.intellij.ide.IdeEventQueue._dispatchEvent(IdeEventQueue.java:493)
            at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:335)
            at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:296)
            at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:211)
            at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:201)
            at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:196)
            at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:188)
            at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)
    
  3. I deactivated the AngularJS plugin, now everything is working again.

Maybe this can help you to search the error in the AngularJS plugin?
0
Comment actions Permalink

This looks very similar to https://youtrack.jetbrains.com/issue/WEB-12339
I've added the reference to this thread. Welcome to comment or add any information to that issue, if you like.

Regards,
Alexander.

0

Please sign in to leave a comment.