Project: aptanastudio
Issue APSTUD-4385: Hide errant "Cannot Recover From Syntax Error" exceptions in log file
While following the steps for APSTUD-2564, I saw this in my log file when I started typing "body": {code} (Build 3.0.3.qualifier) [ERROR] Cannot recover from the syntax error beaver.Parser$Exception: Cannot recover from the syntax error beaver.Parser.recoverFromError(Parser.java:590) beaver.Parser.parse(Parser.java:487) beaver.Parser.parse(Parser.java:428) com.aptana.editor.css.parsing.CSSParser.parse(CSSParser.java:131) com.aptana.parsing.ParserPoolFactory.doParse(ParserPoolFactory.java:286) com.aptana.parsing.ParserPoolFactory.parse(ParserPoolFactory.java:244) com.aptana.parsing.ParserPoolFactory.parse(ParserPoolFactory.java:231) com.aptana.parsing.ParserPoolFactory.parse(ParserPoolFactory.java:213) com.aptana.editor.common.AbstractThemeableEditor.getAST(AbstractThemeableEditor.java:1084) com.aptana.editor.common.text.reconciler.CommonReconcilingStrategy$2.run(CommonReconcilingStrategy.java:253) org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:35) org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:135) org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:3935) org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3612) org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2696) org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2660) org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2494) org.eclipse.ui.internal.Workbench$7.run(Workbench.java:674) org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332) org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:667) org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149) com.appcelerator.titanium.rcp.IDEApplication.start(IDEApplication.java:125) org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196) org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110) org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79) org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:344) org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179) sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) java.lang.reflect.Method.invoke(Method.java:597) org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:622) org.eclipse.equinox.launcher.Main.basicRun(Main.java:577) org.eclipse.equinox.launcher.Main.run(Main.java:1410) org.eclipse.equinox.launcher.Main.main(Main.java:1386) (Build 3.0.3.qualifier) [ERROR] Cannot recover from the syntax error org.eclipse.core.runtime.CoreException: Cannot recover from the syntax error com.aptana.index.core.build.BuildContext.getAST(BuildContext.java:126) com.aptana.index.core.build.BuildContext.getAST(BuildContext.java:83) com.aptana.editor.css.contentassist.index.CSSFileIndexingParticipant.index(CSSFileIndexingParticipant.java:42) com.aptana.core.internal.build.IndexBuildParticipant.buildFile(IndexBuildParticipant.java:83) com.aptana.editor.common.text.reconciler.CommonReconcilingStrategy.runParticipants(CommonReconcilingStrategy.java:306) com.aptana.editor.common.text.reconciler.CommonReconcilingStrategy.reconcile(CommonReconcilingStrategy.java:238) com.aptana.editor.common.text.reconciler.CommonReconcilingStrategy.reconcile(CommonReconcilingStrategy.java:208) com.aptana.editor.common.text.reconciler.CommonReconcilingStrategy.fullReconcile(CommonReconcilingStrategy.java:396) com.aptana.editor.common.text.reconciler.CompositeReconcilingStrategy.fullReconcile(CompositeReconcilingStrategy.java:125) com.aptana.editor.common.text.reconciler.CommonReconciler.process(CommonReconciler.java:162) org.eclipse.jface.text.reconciler.AbstractReconciler$BackgroundThread.run(AbstractReconciler.java:206) Caused by: beaver.Parser$Exception: Cannot recover from the syntax error beaver.Parser.recoverFromError(Parser.java:590) beaver.Parser.parse(Parser.java:487) beaver.Parser.parse(Parser.java:428) com.aptana.editor.css.parsing.CSSParser.parse(CSSParser.java:131) com.aptana.parsing.ParserPoolFactory.doParse(ParserPoolFactory.java:286) com.aptana.parsing.ParserPoolFactory.parse(ParserPoolFactory.java:244) com.aptana.index.core.build.BuildContext.getAST(BuildContext.java:117)	... 10 more ckgroundThread.run(AbstractReconciler.java:206) {code} Those error messages aren't necessary.
Story points: 5