Error (one-off) when creating new model (5.4.3)

Started by Xiaoqi, November 05, 2024, 00:59:00 AM

Previous topic - Next topic

Xiaoqi

Hello all,

Upgraded to Archi 5.4.3 recent days, no issues found, just this morning when I opened Archi (with coArchi 0.9.2 in Windows 11) and I click to creating new model, I got attached error dialog pop up.

Error message:
Cannot invoke "org.eclipse.gef.GraphicalViewer.getControl()" because the return value of "com.archimatetool.editor.diagram.AbstractDiagramEditor.getGreaphicalViewre()" is null.

After click OK, the new model is created and looks no strange of using.

While, I tried multiple times again for creating new models, but this error hasn't pop up again.

So far, I can keep working in Archi, however, would like to report to forum here in case this is something need to be noticed which due to the latest version? (p.s. it's first time I see this error message).

Thanks,
Xiaoqi

Phil Beauvoir

Hi Xiaoqi,

Attach the error trace in the error log if possible. This can be accessed in Archi by selecting the "About Archi" menu item. In the dialog box press the "Installation Details" button, then select the "Configuration" tab and press the "View Error Log" button.

Phil
If you value and use Archi, please consider making a donation!
Ask your ArchiMate related questions to the ArchiMate Community's Discussion Board.

Xiaoqi

Hi Phil,

Below I extract the detail from that timestamp:

!ENTRY org.eclipse.jface 4 2 2024-11-05 08:50:32.637
!MESSAGE Problems occurred when invoking code from plug-in: "org.eclipse.jface".
!STACK 0
java.lang.NullPointerException: Cannot invoke "org.eclipse.gef.GraphicalViewer.getControl()" because the return value of "com.archimatetool.editor.diagram.AbstractDiagramEditor.getGraphicalViewer()" is null
at com.archimatetool.editor.diagram.AbstractDiagramEditor.selectObjects(AbstractDiagramEditor.java:969)
at com.archimatetool.editor.diagram.ArchimateDiagramEditor.selectObjects(ArchimateDiagramEditor.java:155)
at com.archimatetool.editor.views.tree.TreeSelectionSynchroniser.selectionChanged(TreeSelectionSynchroniser.java:188)
at org.eclipse.jface.viewers.Viewer$1.run(Viewer.java:151)
at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:47)
at org.eclipse.jface.util.SafeRunnable.run(SafeRunnable.java:174)
at org.eclipse.jface.viewers.Viewer.fireSelectionChanged(Viewer.java:148)
at org.eclipse.jface.viewers.StructuredViewer.updateSelection(StructuredViewer.java:2132)
at org.eclipse.jface.viewers.ColumnViewer.updateSelection(ColumnViewer.java:1055)
at org.eclipse.jface.viewers.StructuredViewer.setSelection(StructuredViewer.java:1664)
at org.eclipse.jface.viewers.TreeViewer.setSelection(TreeViewer.java:1091)
at com.archimatetool.editor.views.tree.TreeModelView.propertyChange(TreeModelView.java:758)
at java.desktop/java.beans.PropertyChangeSupport.fire(Unknown Source)
at java.desktop/java.beans.PropertyChangeSupport.firePropertyChange(Unknown Source)
at com.archimatetool.editor.model.impl.EditorModelManager.firePropertyChange(EditorModelManager.java:755)
at com.archimatetool.editor.model.impl.EditorModelManager.registerModel(EditorModelManager.java:184)
at com.archimatetool.editor.model.impl.EditorModelManager.createNewModel(EditorModelManager.java:162)
at com.archimatetool.editor.actions.NewArchimateModelAction.run(NewArchimateModelAction.java:40)
at org.eclipse.jface.action.Action.runWithEvent(Action.java:474)
at org.eclipse.jface.commands.ActionHandler.execute(ActionHandler.java:124)
at org.eclipse.ui.internal.handlers.E4HandlerProxy.execute(E4HandlerProxy.java:98)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.base/java.lang.reflect.Method.invoke(Unknown Source)
at org.eclipse.e4.core.internal.di.MethodRequestor.execute(MethodRequestor.java:58)
at org.eclipse.e4.core.internal.di.InjectorImpl.invokeUsingClass(InjectorImpl.java:299)
at org.eclipse.e4.core.internal.di.InjectorImpl.invoke(InjectorImpl.java:233)
at org.eclipse.e4.core.contexts.ContextInjectionFactory.invoke(ContextInjectionFactory.java:174)
at org.eclipse.e4.core.commands.internal.HandlerServiceHandler.execute(HandlerServiceHandler.java:165)
at org.eclipse.core.commands.Command.executeWithChecks(Command.java:488)
at org.eclipse.core.commands.ParameterizedCommand.executeWithChecks(ParameterizedCommand.java:485)
at org.eclipse.e4.core.commands.internal.HandlerServiceImpl.executeHandler(HandlerServiceImpl.java:204)
at org.eclipse.e4.ui.workbench.renderers.swt.HandledContributionItem.executeItem(HandledContributionItem.java:444)
at org.eclipse.e4.ui.workbench.renderers.swt.AbstractContributionItem.handleWidgetSelection(AbstractContributionItem.java:442)
at org.eclipse.e4.ui.workbench.renderers.swt.AbstractContributionItem.lambda$2(AbstractContributionItem.java:464)
at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:91)
at org.eclipse.swt.widgets.Display.sendEvent(Display.java:4285)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1160)
at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:4083)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3673)
at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$5.run(PartRenderingEngine.java:1151)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:339)
at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.run(PartRenderingEngine.java:1042)
at org.eclipse.e4.ui.internal.workbench.E4Workbench.createAndRunUI(E4Workbench.java:152)
at org.eclipse.ui.internal.Workbench.lambda$3(Workbench.java:639)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:339)
at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:546)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:173)
at com.archimatetool.editor.Application.start(Application.java:85)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:208)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:143)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:109)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:439)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:271)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.base/java.lang.reflect.Method.invoke(Unknown Source)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:668)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:605)
at org.eclipse.equinox.launcher.Main.run(Main.java:1481)

For your checking, thanks.
Xiaoqi

Phil Beauvoir

Thanks, Xiaoqi. Looks like some asynchronous issue. I'll put a null check guard in at that point for the next version.

Phil
If you value and use Archi, please consider making a donation!
Ask your ArchiMate related questions to the ArchiMate Community's Discussion Board.

Xiaoqi

Good to provide some hint, actually I haven't seen same error until now, one full day, along with my using Archi.