调用JFace插件时的Eclipse空指针异常

时间:2017-10-31 09:35:11

标签: java eclipse java-ee centos7 jface

我已经在CentOS上消灭了火星,我无法达到" java构建路径","部署程序集","项目方面"以及我项目属性中的其他一些选项卡。 出现Problems occurred after invoking code from plug-in "org.eclipse.jface".错误窗口,因此我附上了其详细信息的屏幕截图。 我搜索并尝试了很多解决方案(包括清理项目,切换工作区,创建一个新项目,删除.classpath,.project和.settings,使用--clean启动eclipse,清理IDE安装,更改JDK),但没有一个工作如此远。有没有人打败过这个?

enter image description here

编辑:异常堆栈跟踪文本

java.lang.NullPointerException
at org.eclipse.swt.widgets.TabFolder.gtk_switch_page(TabFolder.java:490)
at org.eclipse.swt.widgets.Widget.windowProc(Widget.java:1994)
at org.eclipse.swt.widgets.Display.windowProc(Display.java:4723)
at org.eclipse.swt.internal.gtk.OS._gtk_widget_show(Native Method)
at org.eclipse.swt.internal.gtk.OS.gtk_widget_show(OS.java:14720)
at org.eclipse.swt.widgets.TabFolder.createItem(TabFolder.java:274)
at org.eclipse.swt.widgets.TabItem.createWidget(TabItem.java:123)
at org.eclipse.swt.widgets.TabItem.<init>(TabItem.java:75)
at org.eclipse.jst.servlet.ui.internal.WebModuleDependencyPageProvider.createRootControl(WebModuleDependencyPageProvider.java:77)
at org.eclipse.wst.common.componentcore.ui.propertypage.ModuleAssemblyRootPage.createContents(ModuleAssemblyRootPage.java:204)
at org.eclipse.jface.preference.PreferencePage.createControl(PreferencePage.java:241)
at org.eclipse.wst.common.componentcore.ui.propertypage.ModuleAssemblyRootPage.createControl(ModuleAssemblyRootPage.java:346)
at org.eclipse.jface.preference.PreferenceDialog.createPageControl(PreferenceDialog.java:1450)
at org.eclipse.jface.preference.PreferenceDialog$13.run(PreferenceDialog.java:1217)
at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)
at org.eclipse.ui.internal.JFaceUtil$1.run(JFaceUtil.java:50)
at org.eclipse.jface.util.SafeRunnable.run(SafeRunnable.java:173)
at org.eclipse.jface.preference.PreferenceDialog.showPage(PreferenceDialog.java:1209)
at org.eclipse.ui.internal.dialogs.FilteredPreferenceDialog.showPage(FilteredPreferenceDialog.java:608)
at org.eclipse.jface.preference.PreferenceDialog$9$1.run(PreferenceDialog.java:675)
at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:70)
at org.eclipse.jface.preference.PreferenceDialog$9.selectionChanged(PreferenceDialog.java:670)
at org.eclipse.jface.viewers.StructuredViewer$3.run(StructuredViewer.java:877)
at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)
at org.eclipse.ui.internal.JFaceUtil$1.run(JFaceUtil.java:50)
at org.eclipse.jface.util.SafeRunnable.run(SafeRunnable.java:173)
at org.eclipse.jface.viewers.StructuredViewer.firePostSelectionChanged(StructuredViewer.java:874)
at org.eclipse.jface.viewers.StructuredViewer.handlePostSelect(StructuredViewer.java:1243)
at org.eclipse.jface.viewers.StructuredViewer$5.widgetSelected(StructuredViewer.java:1269)
at org.eclipse.jface.util.OpenStrategy.firePostSelectionEvent(OpenStrategy.java:265)
at org.eclipse.jface.util.OpenStrategy.access$5(OpenStrategy.java:259)
at org.eclipse.jface.util.OpenStrategy$1$2.run(OpenStrategy.java:440)
at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:35)
at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:135)
at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:3794)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3433)
at org.eclipse.jface.window.Window.runEventLoop(Window.java:827)
at org.eclipse.jface.window.Window.open(Window.java:803)
at org.eclipse.ui.dialogs.PropertyDialogAction.run(PropertyDialogAction.java:157)
at org.eclipse.jface.action.Action.runWithEvent(Action.java:473)
at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection(ActionContributionItem.java:595)
at org.eclipse.jface.action.ActionContributionItem.access$2(ActionContributionItem.java:511)
at org.eclipse.jface.action.ActionContributionItem$5.handleEvent(ActionContributionItem.java:420)
at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
at org.eclipse.swt.widgets.Display.sendEvent(Display.java:4481)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1327)
at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3819)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3430)
at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$4.run(PartRenderingEngine.java:1127)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:337)
at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.run(PartRenderingEngine.java:1018)
at org.eclipse.e4.ui.internal.workbench.E4Workbench.createAndRunUI(E4Workbench.java:156)
at org.eclipse.ui.internal.Workbench$5.run(Workbench.java:654)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:337)
at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:598)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:150)
at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:139)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:134)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:104)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:380)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:235)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:669)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:608)
at org.eclipse.equinox.launcher.Main.run(Main.java:1515)
at org.eclipse.equinox.launcher.Main.main(Main.java:1488)

EDIT2:感谢大家的帮助。我解决这个问题的方法:像@howgler一样更新eclipse,导入到新工作区并清理每个项目。如果需要,导入到另一个工作区。不要忘记备份旧工作区,因为它可能会因版本差异而发生变化。

1 个答案:

答案 0 :(得分:2)

{0}已在Eclipse Oxygen.0(4.7.0)中修复。

不再维护Eclipse Mars(4.5)到Eclipse Oxygen (4.7)的known bug应解决您的问题。