org.eclipse.swt.SWTException: Failed to execute runnable (java.lang.ClassCastException: org.eclipse.jst.j2ee.webapplication.internal.impl.WebAppImpl cannot be cast to org.eclipse.core.resources.IResource)

pydev | *anonymous | 9 years ago
  1. 0

    PyDev plugin conflicts with "Dynamic Web Project" (Java)

    pydev | 9 years ago | *anonymous
    org.eclipse.swt.SWTException: Failed to execute runnable (java.lang.ClassCastException: org.eclipse.jst.j2ee.webapplication.internal.impl.WebAppImpl cannot be cast to org.eclipse.core.resources.IResource)
  2. 0

    {html}<div><p>I keep seeing error dialogs popping up when working with Java code in a dev instance of Eclipse. Here's the stacktrace:</p> <pre> <code>!ENTRY org.eclipse.ui 4 0 2011-06-06 14:30:25.009 !MESSAGE Unhandled event loop exception !STACK 0 java.lang.ClassCastException: org.eclipse.jdt.internal.core.JavaProject cannot be cast to org.eclipse.core.resources.IResource at com.aptana.deploy.internal.ProjectPropertyTester.test(ProjectPropertyTester.java:33) at org.eclipse.core.internal.expressions.Property.test(Property.java:58) at org.eclipse.core.internal.expressions.TestExpression.evaluate(TestExpression.java:99) at org.eclipse.core.internal.expressions.CompositeExpression.evaluateAnd(CompositeExpression.java:53) at org.eclipse.core.internal.expressions.IterateExpression.evaluate(IterateExpression.java:150) at org.eclipse.ui.internal.services.EvaluationResultCache.evaluate(EvaluationResultCache.java:74) at org.eclipse.ui.internal.services.ExpressionAuthority.evaluate(ExpressionAuthority.java:165) at org.eclipse.ui.internal.services.EvaluationAuthority.refsWithSameExpression(EvaluationAuthority.java:153) at org.eclipse.ui.internal.services.EvaluationAuthority.sourceChanged(EvaluationAuthority.java:129) at org.eclipse.ui.internal.services.ExpressionAuthority.sourceChanged(ExpressionAuthority.java:311) at org.eclipse.ui.internal.services.ExpressionAuthority.sourceChanged(ExpressionAuthority.java:290) at org.eclipse.ui.AbstractSourceProvider.fireSourceChanged(AbstractSourceProvider.java:99) at org.eclipse.ui.internal.services.WorkbenchSourceProvider.checkActivePart(WorkbenchSourceProvider.java:401) at org.eclipse.ui.internal.ShowInMenu.fillMenu(ShowInMenu.java:175) at org.eclipse.ui.internal.ShowInMenu.fill(ShowInMenu.java:125) at org.eclipse.jface.action.MenuManager.doItemFill(MenuManager.java:741) at org.eclipse.jface.action.MenuManager.update(MenuManager.java:822) at org.eclipse.jface.action.MenuManager.handleAboutToShow(MenuManager.java:474) at org.eclipse.jface.action.MenuManager.access$1(MenuManager.java:469) at org.eclipse.jface.action.MenuManager$2.menuShown(MenuManager.java:495) at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:247) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84) at org.eclipse.swt.widgets.Display.sendEvent(Display.java:4125) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1457) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1480) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1461) at org.eclipse.swt.widgets.Menu.menuWillOpen(Menu.java:805) at org.eclipse.swt.widgets.Display.windowProc(Display.java:5522) at org.eclipse.swt.internal.cocoa.OS.objc_msgSendSuper(Native Method) at org.eclipse.swt.widgets.Display.applicationNextEventMatchingMask(Display.java:4876) at org.eclipse.swt.widgets.Display.applicationProc(Display.java:5223) at org.eclipse.swt.internal.cocoa.OS.objc_msgSend(Native Method) at org.eclipse.swt.internal.cocoa.NSApplication.nextEventMatchingMask(NSApplication.java:94) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3604) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2696) at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2660) at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2494) at org.eclipse.ui.internal.Workbench$7.run(Workbench.java:674) at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332) at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:667) at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149) at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:123) at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196) at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110) at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:344) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:622) at org.eclipse.equinox.launcher.Main.basicRun(Main.java:577) at org.eclipse.equinox.launcher.Main.run(Main.java:1410)</code> </pre></div>{html}

    Appcelerator JIRA | 5 years ago | Chris Williams
    java.lang.ClassCastException: org.eclipse.jdt.internal.core.JavaProject cannot be cast to org.eclipse.core.resources.IResource
  3. 0

    JS: ClassCastException if project has the Java Nature

    GitHub | 5 years ago | vtst
    java.lang.ClassCastException: org.eclipse.jdt.internal.core.JavaProject cannot be cast to org.eclipse.core.resources.IResource
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    ClassCastException in HybridProjectLaunchShortcut.launch (49)

    Eclipse Bugzilla | 1 year ago | error-reports-inbox
    java.lang.ClassCastException: org.eclipse.jdt.internal.core.JavaProject cannot be cast to org.eclipse.core.resources.IResource
  6. 0

    {html}<div><p>I keep seeing error dialogs popping up when working with Java code in a dev instance of Eclipse. Here's the stacktrace:</p> <pre> <code>!ENTRY org.eclipse.ui 4 0 2011-06-06 14:30:25.009 !MESSAGE Unhandled event loop exception !STACK 0 java.lang.ClassCastException: org.eclipse.jdt.internal.core.JavaProject cannot be cast to org.eclipse.core.resources.IResource at com.aptana.deploy.internal.ProjectPropertyTester.test(ProjectPropertyTester.java:33) at org.eclipse.core.internal.expressions.Property.test(Property.java:58) at org.eclipse.core.internal.expressions.TestExpression.evaluate(TestExpression.java:99) at org.eclipse.core.internal.expressions.CompositeExpression.evaluateAnd(CompositeExpression.java:53) at org.eclipse.core.internal.expressions.IterateExpression.evaluate(IterateExpression.java:150) at org.eclipse.ui.internal.services.EvaluationResultCache.evaluate(EvaluationResultCache.java:74) at org.eclipse.ui.internal.services.ExpressionAuthority.evaluate(ExpressionAuthority.java:165) at org.eclipse.ui.internal.services.EvaluationAuthority.refsWithSameExpression(EvaluationAuthority.java:153) at org.eclipse.ui.internal.services.EvaluationAuthority.sourceChanged(EvaluationAuthority.java:129) at org.eclipse.ui.internal.services.ExpressionAuthority.sourceChanged(ExpressionAuthority.java:311) at org.eclipse.ui.internal.services.ExpressionAuthority.sourceChanged(ExpressionAuthority.java:290) at org.eclipse.ui.AbstractSourceProvider.fireSourceChanged(AbstractSourceProvider.java:99) at org.eclipse.ui.internal.services.WorkbenchSourceProvider.checkActivePart(WorkbenchSourceProvider.java:401) at org.eclipse.ui.internal.ShowInMenu.fillMenu(ShowInMenu.java:175) at org.eclipse.ui.internal.ShowInMenu.fill(ShowInMenu.java:125) at org.eclipse.jface.action.MenuManager.doItemFill(MenuManager.java:741) at org.eclipse.jface.action.MenuManager.update(MenuManager.java:822) at org.eclipse.jface.action.MenuManager.handleAboutToShow(MenuManager.java:474) at org.eclipse.jface.action.MenuManager.access$1(MenuManager.java:469) at org.eclipse.jface.action.MenuManager$2.menuShown(MenuManager.java:495) at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:247) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84) at org.eclipse.swt.widgets.Display.sendEvent(Display.java:4125) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1457) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1480) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1461) at org.eclipse.swt.widgets.Menu.menuWillOpen(Menu.java:805) at org.eclipse.swt.widgets.Display.windowProc(Display.java:5522) at org.eclipse.swt.internal.cocoa.OS.objc_msgSendSuper(Native Method) at org.eclipse.swt.widgets.Display.applicationNextEventMatchingMask(Display.java:4876) at org.eclipse.swt.widgets.Display.applicationProc(Display.java:5223) at org.eclipse.swt.internal.cocoa.OS.objc_msgSend(Native Method) at org.eclipse.swt.internal.cocoa.NSApplication.nextEventMatchingMask(NSApplication.java:94) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3604) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2696) at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2660) at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2494) at org.eclipse.ui.internal.Workbench$7.run(Workbench.java:674) at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332) at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:667) at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149) at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:123) at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196) at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110) at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:344) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:622) at org.eclipse.equinox.launcher.Main.basicRun(Main.java:577) at org.eclipse.equinox.launcher.Main.run(Main.java:1410)</code> </pre></div>{html}

    Appcelerator JIRA | 5 years ago | Chris Williams
    java.lang.ClassCastException: org.eclipse.jdt.internal.core.JavaProject cannot be cast to org.eclipse.core.resources.IResource

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. java.lang.ClassCastException

      org.eclipse.jst.j2ee.webapplication.internal.impl.WebAppImpl cannot be cast to org.eclipse.core.resources.IResource

      at org.python.pydev.navigator.PythonModelProvider.wrapChildren()
    2. org.python.pydev
      PythonModelProvider.interceptAdd
      1. org.python.pydev.navigator.PythonModelProvider.wrapChildren(PythonModelProvider.java:327)
      2. org.python.pydev.navigator.PythonModelProvider.convertToPythonElementsAddOrRemove(PythonModelProvider.java:250)
      3. org.python.pydev.navigator.PythonModelProvider.interceptAdd(PythonModelProvider.java:106)
      3 frames
    3. Common Navigator View
      CommonViewer.add
      1. org.eclipse.ui.internal.navigator.extensions.SafeDelegateTreeContentProvider.interceptAdd(SafeDelegateTreeContentProvider.java:224)
      2. org.eclipse.ui.internal.navigator.NavigatorPipelineService.pipelineInterceptAdd(NavigatorPipelineService.java:124)
      3. org.eclipse.ui.internal.navigator.NavigatorPipelineService.interceptAdd(NavigatorPipelineService.java:81)
      4. org.eclipse.ui.navigator.CommonViewer.add(CommonViewer.java:242)
      4 frames
    4. J2EE Extensions to Common Navigator
      ClearPlaceHolderJob.runInUIThread
      1. org.eclipse.jst.j2ee.navigator.internal.ClearPlaceHolderJob.runInUIThread(ClearPlaceHolderJob.java:41)
      1 frame
    5. Workbench
      UIJob$1.run
      1. org.eclipse.ui.progress.UIJob$1.run(UIJob.java:94)
      1 frame
    6. RWT
      Display.readAndDispatch
      1. org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:35)
      2. org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:123)
      3. org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:3659)
      4. org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3296)
      4 frames
    7. Eclipse UI
      Workbench$4.run
      1. org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2389)
      2. org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2353)
      3. org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2219)
      4. org.eclipse.ui.internal.Workbench$4.run(Workbench.java:466)
      4 frames
    8. Databinding
      Realm.runWithDefault
      1. org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:289)
      1 frame
    9. Eclipse UI
      Workbench.createAndRunWorkbench
      1. org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:461)
      1 frame
    10. Eclipse UI
      PlatformUI.createAndRunWorkbench
      1. org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)
      1 frame
    11. Eclipse IDE
      IDEApplication.start
      1. org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:106)
      1 frame
    12. Equinox Container
      EclipseAppHandle.run
      1. org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:169)
      1 frame
    13. Eclipse OSGi
      EclipseStarter.run
      1. org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:106)
      2. org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:76)
      3. org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:363)
      4. org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:176)
      4 frames
    14. Java RT
      Method.invoke
      1. sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      2. sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
      3. sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
      4. java.lang.reflect.Method.invoke(Unknown Source)
      4 frames
    15. Equinox
      Main.run
      1. org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:508)
      2. org.eclipse.equinox.launcher.Main.basicRun(Main.java:447)
      3. org.eclipse.equinox.launcher.Main.run(Main.java:1173)
      3 frames