Closed rquadling closed 7 years ago
I have the same issue with IntelliJ IDEA 2016.3.
Can we get an example where this breaks? The error happens while parsing the file, so I'm expecting that your config files are doing something unexpected.
It fails on every *.conf file, e.g.:
server {
listen 840;
server_name localhost.com;
error_page 419 = @magento;
error_page 420 = @static;
location /pub/media/ {return 420;}
location /pub/static/ {return 420;}
location / {return 419;}
location @static {
root F:/work/clients/rpcake.com/code;
access_log off;
expires max;
try_files $uri @magento;
}
location @magento {
include params_for_proxy;
proxy_redirect http://localhost.com:1840/ http://localhost.com:840/;
proxy_pass http://localhost.com:1840;
}
}
same issue in PyCharm:
2017-06-27 11:46:40,563 [ 96012] ERROR - tor.impl.FileEditorManagerImpl - java.util.concurrent.ExecutionException: java.lang.IllegalStateException: Unexpected termination offset for lexer FlexAdapter for net.ishchenko.idea.nginx.lexer._NginxLexer java.lang.RuntimeException: java.util.concurrent.ExecutionException: java.lang.IllegalStateException: Unexpected termination offset for lexer FlexAdapter for net.ishchenko.idea.nginx.lexer._NginxLexer at com.intellij.openapi.fileEditor.impl.text.AsyncEditorLoader.resultInTimeOrNull(AsyncEditorLoader.java:135) at com.intellij.openapi.fileEditor.impl.text.AsyncEditorLoader.start(AsyncEditorLoader.java:79) at com.intellij.openapi.fileEditor.impl.text.TextEditorImpl.
(TextEditorImpl.java:60) at com.intellij.openapi.fileEditor.impl.text.PsiAwareTextEditorImpl. (PsiAwareTextEditorImpl.java:44) at com.intellij.openapi.fileEditor.impl.text.PsiAwareTextEditorProvider.createEditor(PsiAwareTextEditorProvider.java:48) at com.intellij.openapi.fileEditor.impl.FileEditorManagerImpl.lambda$openFileImpl4$8(FileEditorManagerImpl.java:860) at com.intellij.util.ui.UIUtil.invokeAndWaitIfNeeded(UIUtil.java:2653) at com.intellij.openapi.fileEditor.impl.FileEditorManagerImpl.openFileImpl4(FileEditorManagerImpl.java:959) at com.intellij.openapi.fileEditor.impl.FileEditorManagerImpl.openFileImpl3(FileEditorManagerImpl.java:787) at com.intellij.openapi.fileEditor.impl.FileEditorManagerImpl.lambda$openFileImpl2$4(FileEditorManagerImpl.java:769) at com.intellij.openapi.command.impl.CoreCommandProcessor.executeCommand(CoreCommandProcessor.java:149) at com.intellij.openapi.command.impl.CoreCommandProcessor.executeCommand(CoreCommandProcessor.java:109) at com.intellij.openapi.command.impl.CoreCommandProcessor.executeCommand(CoreCommandProcessor.java:99) at com.intellij.openapi.command.impl.CoreCommandProcessor.executeCommand(CoreCommandProcessor.java:85) at com.intellij.openapi.fileEditor.impl.FileEditorManagerImpl.openFileImpl2(FileEditorManagerImpl.java:769) at com.intellij.openapi.fileEditor.impl.FileEditorManagerImpl.openFileWithProviders(FileEditorManagerImpl.java:700) at com.intellij.openapi.fileEditor.ex.FileEditorManagerEx.openFile(FileEditorManagerEx.java:154) at com.intellij.codeInsight.navigation.NavigationUtil.activatePsiElementIfOpen(NavigationUtil.java:213) at com.intellij.codeInsight.navigation.NavigationUtil.openFileWithPsiElement(NavigationUtil.java:189) at com.intellij.ide.projectView.impl.nodes.AbstractPsiBasedNode.navigate(AbstractPsiBasedNode.java:235) at com.intellij.ide.projectView.impl.nodes.AbstractPsiBasedNode.navigate(AbstractPsiBasedNode.java:245) at com.intellij.ide.projectView.impl.nodes.PsiFileNode.navigate(PsiFileNode.java:133) at com.intellij.util.OpenSourceUtil.navigate(OpenSourceUtil.java:53) at com.intellij.util.OpenSourceUtil.openSourcesFrom(OpenSourceUtil.java:31) at com.intellij.util.EditSourceOnDoubleClickHandler$TreeMouseListener.processDoubleClick(EditSourceOnDoubleClickHandler.java:130) at com.intellij.util.EditSourceOnDoubleClickHandler$TreeMouseListener.onDoubleClick(EditSourceOnDoubleClickHandler.java:122) at com.intellij.ui.DoubleClickListener.onClick(DoubleClickListener.java:30) at com.intellij.ui.ClickListener$1.mouseReleased(ClickListener.java:73) at java.awt.AWTEventMulticaster.mouseReleased(AWTEventMulticaster.java:290) at java.awt.AWTEventMulticaster.mouseReleased(AWTEventMulticaster.java:289) at java.awt.AWTEventMulticaster.mouseReleased(AWTEventMulticaster.java:289) at java.awt.AWTEventMulticaster.mouseReleased(AWTEventMulticaster.java:289) at java.awt.Component.processMouseEvent(Component.java:6541) at javax.swing.JComponent.processMouseEvent(JComponent.java:3324) at com.intellij.ui.treeStructure.Tree.processMouseEvent(Tree.java:410) at com.intellij.ide.dnd.aware.DnDAwareTree.processMouseEvent(DnDAwareTree.java:58) at java.awt.Component.processEvent(Component.java:6306) at java.awt.Container.processEvent(Container.java:2236) at java.awt.Component.dispatchEventImpl(Component.java:4897) at java.awt.Container.dispatchEventImpl(Container.java:2294) at java.awt.Component.dispatchEvent(Component.java:4719) at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4888) at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4525) at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4466) at java.awt.Container.dispatchEventImpl(Container.java:2280) at java.awt.Window.dispatchEventImpl(Window.java:2746) at java.awt.Component.dispatchEvent(Component.java:4719) at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:764) at java.awt.EventQueue.access$500(EventQueue.java:98) at java.awt.EventQueue$3.run(EventQueue.java:715) at java.awt.EventQueue$3.run(EventQueue.java:709) at java.security.AccessController.doPrivileged(Native Method) at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:80) at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:90) at java.awt.EventQueue$4.run(EventQueue.java:737) at java.awt.EventQueue$4.run(EventQueue.java:735) at java.security.AccessController.doPrivileged(Native Method) at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:80) at java.awt.EventQueue.dispatchEvent(EventQueue.java:734) at com.intellij.ide.IdeEventQueue.defaultDispatchEvent(IdeEventQueue.java:827) at com.intellij.ide.IdeEventQueue._dispatchEvent(IdeEventQueue.java:651) at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:365) 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) Caused by: java.util.concurrent.ExecutionException: java.lang.IllegalStateException: Unexpected termination offset for lexer FlexAdapter for net.ishchenko.idea.nginx.lexer._NginxLexer at java.util.concurrent.FutureTask.report(FutureTask.java:122) at java.util.concurrent.FutureTask.get(FutureTask.java:206) at com.intellij.openapi.fileEditor.impl.text.AsyncEditorLoader.resultInTimeOrNull(AsyncEditorLoader.java:131) ... 67 more Caused by: java.lang.IllegalStateException: Unexpected termination offset for lexer FlexAdapter for net.ishchenko.idea.nginx.lexer._NginxLexer at com.intellij.openapi.editor.ex.util.LexerEditorHighlighter.doSetText(LexerEditorHighlighter.java:392) at com.intellij.openapi.editor.ex.util.LexerEditorHighlighter.setText(LexerEditorHighlighter.java:358) at com.intellij.openapi.fileEditor.impl.text.TextEditorImpl.loadEditorInBackground(TextEditorImpl.java:68) at com.intellij.openapi.fileEditor.impl.text.PsiAwareTextEditorImpl.loadEditorInBackground(PsiAwareTextEditorImpl.java:50) at com.intellij.openapi.fileEditor.impl.text.AsyncEditorLoader.lambda$null$0(AsyncEditorLoader.java:98) at com.intellij.psi.impl.PsiDocumentManagerBase.lambda$commitAndRunReadAction$1(PsiDocumentManagerBase.java:478) at com.intellij.psi.impl.PsiDocumentManagerBase.lambda$commitAndRunReadAction$2(PsiDocumentManagerBase.java:503) at com.intellij.openapi.application.impl.ApplicationImpl.runReadAction(ApplicationImpl.java:946) at com.intellij.psi.impl.PsiDocumentManagerBase.commitAndRunReadAction(PsiDocumentManagerBase.java:501) at com.intellij.psi.impl.PsiDocumentManagerBase.commitAndRunReadAction(PsiDocumentManagerBase.java:478) at com.intellij.openapi.fileEditor.impl.text.AsyncEditorLoader.lambda$null$1(AsyncEditorLoader.java:97) at com.intellij.openapi.progress.util.ProgressIndicatorUtils.lambda$runWithWriteActionPriority$2(ProgressIndicatorUtils.java:146) at com.intellij.openapi.progress.impl.CoreProgressManager.lambda$runProcess$1(CoreProgressManager.java:176) at com.intellij.openapi.progress.impl.CoreProgressManager.registerIndicatorAndRun(CoreProgressManager.java:556) at com.intellij.openapi.progress.impl.CoreProgressManager.executeProcessUnderProgress(CoreProgressManager.java:501) at com.intellij.openapi.progress.impl.ProgressManagerImpl.executeProcessUnderProgress(ProgressManagerImpl.java:66) at com.intellij.openapi.progress.impl.CoreProgressManager.runProcess(CoreProgressManager.java:163) at com.intellij.openapi.progress.util.ProgressIndicatorUtils.runWithWriteActionPriority(ProgressIndicatorUtils.java:144) at com.intellij.openapi.fileEditor.impl.text.AsyncEditorLoader.lambda$scheduleLoading$4(AsyncEditorLoader.java:96) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at com.intellij.util.concurrency.BoundedTaskExecutor$2.run(BoundedTaskExecutor.java:212) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745) 2017-06-27 11:46:40,564 [ 96013] ERROR - tor.impl.FileEditorManagerImpl - PyCharm Community Edition 2017.1.4 Build #PC-171.4694.38 2017-06-27 11:46:40,564 [ 96013] ERROR - tor.impl.FileEditorManagerImpl - JDK: 1.8.0_112-release 2017-06-27 11:46:40,564 [ 96013] ERROR - tor.impl.FileEditorManagerImpl - VM: OpenJDK 64-Bit Server VM 2017-06-27 11:46:40,564 [ 96013] ERROR - tor.impl.FileEditorManagerImpl - Vendor: JetBrains s.r.o 2017-06-27 11:46:40,564 [ 96013] ERROR - tor.impl.FileEditorManagerImpl - OS: Mac OS X 2017-06-27 11:46:40,564 [ 96013] ERROR - tor.impl.FileEditorManagerImpl - Last Action:
2017-06-27 11:46:40,564 [ 96013] ERROR - tor.impl.FileEditorManagerImpl - Current Command:
2017-06-27 11:46:40,572 [ 96021] ERROR - tor.impl.FileEditorManagerImpl - java.util.concurrent.ExecutionException:
Just loading project into PHPStorm 2016.2.1