Opened 4 years ago

Closed 3 years ago

#786 closed defect (worksforme)

MS Annotation Editor - Cannot save changes in "MS Properties" tab

Reported by: sena Owned by: dbrentw
Priority: normal Milestone: GRITS - 1.2 SR1
Component: MS annotation management Version: GRITS 1.1.x
Severity: major Keywords:
Cc: dbrentw

Description

I tried to modify the description in MS properties (first page) in MS Annotation Editor (open a GELATO annotation entry) and got the following exception in the log:

[ERROR] 2016-11-04 13:01:16,803 [org.grits.toolbox.entry.ms.views.tabbed.MassSpecPropertyView updateProjectProperty 513] - org.grits.toolbox.entry.ms.annotation.glycan.property.MSGlycanAnnotationProperty cannot be cast to org.grits.toolbox.entry.ms.property.MassSpecProperty
java.lang.ClassCastException: org.grits.toolbox.entry.ms.annotation.glycan.property.MSGlycanAnnotationProperty cannot be cast to org.grits.toolbox.entry.ms.property.MassSpecProperty

at org.grits.toolbox.entry.ms.views.tabbed.MassSpecPropertyView.updateProjectProperty(MassSpecPropertyView.java:477)
at org.grits.toolbox.core.editor.EntryEditorPart.doSave(EntryEditorPart.java:47)
at org.grits.toolbox.entry.ms.annotation.views.tabbed.MSAnnotationMultiPageViewer.doSave(MSAnnotationMultiPageViewer.java:550)
at org.eclipse.ui.internal.DefaultSaveable.doSave(DefaultSaveable.java:51)
at org.eclipse.ui.Saveable.doSave(Saveable.java:216)
at org.eclipse.ui.internal.SaveableHelper.doSaveModel(SaveableHelper.java:357)
at org.eclipse.ui.internal.SaveablesList$3.run(SaveablesList.java:665)
at org.eclipse.ui.internal.SaveableHelper$5.run(SaveableHelper.java:285)
at org.eclipse.ui.internal.WorkbenchWindow.run(WorkbenchWindow.java:2123)
at org.eclipse.ui.internal.SaveableHelper.runProgressMonitorOperation(SaveableHelper.java:293)
at org.eclipse.ui.internal.SaveablesList.saveModels(SaveablesList.java:675)
at org.eclipse.ui.internal.SaveablesList.saveModels(SaveablesList.java:632)
at org.eclipse.ui.internal.SaveablesList.promptForSaving(SaveablesList.java:617)
at org.eclipse.ui.internal.SaveablesList.promptForSavingIfNecessary(SaveablesList.java:449)
at org.eclipse.ui.internal.SaveablesList.preCloseParts(SaveablesList.java:405)
at org.eclipse.ui.internal.SaveablesList.preCloseParts(SaveablesList.java:355)
at org.eclipse.ui.internal.SaveablesList.preCloseParts(SaveablesList.java:350)
at org.eclipse.ui.internal.WorkbenchWindow$7.save(WorkbenchWindow.java:591)
at org.eclipse.e4.ui.internal.workbench.PartServiceImpl.savePart(PartServiceImpl.java:1342)
at org.grits.toolbox.core.handler.SaveHandler.execute(SaveHandler.java:17)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.eclipse.e4.core.internal.di.MethodRequestor.execute(MethodRequestor.java:56)
at org.eclipse.e4.core.internal.di.InjectorImpl.invokeUsingClass(InjectorImpl.java:252)
at org.eclipse.e4.core.internal.di.InjectorImpl.invoke(InjectorImpl.java:234)
at org.eclipse.e4.core.contexts.ContextInjectionFactory.invoke(ContextInjectionFactory.java:132)
at org.eclipse.e4.core.commands.internal.HandlerServiceHandler.execute(HandlerServiceHandler.java:152)
at org.eclipse.core.commands.Command.executeWithChecks(Command.java:493)
at org.eclipse.core.commands.ParameterizedCommand.executeWithChecks(ParameterizedCommand.java:486)
at org.eclipse.e4.core.commands.internal.HandlerServiceImpl.executeHandler(HandlerServiceImpl.java:210)
at org.eclipse.e4.ui.workbench.renderers.swt.HandledContributionItem.executeItem(HandledContributionItem.java:799)
at org.eclipse.e4.ui.workbench.renderers.swt.HandledContributionItem.handleWidgetSelection(HandledContributionItem.java:675)
at org.eclipse.e4.ui.workbench.renderers.swt.HandledContributionItem.access$7(HandledContributionItem.java:659)
at org.eclipse.e4.ui.workbench.renderers.swt.HandledContributionItem$4.handleEvent(HandledContributionItem.java:592)
at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
at org.eclipse.swt.widgets.Display.sendEvent(Display.java:4362)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1113)
at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:4180)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3769)
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:694)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:337)
at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:606)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:150)
at org.grits.toolbox.core.Application.start(Application.java:29)
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(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
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)

[INFO ] 2016-11-04 13:01:20,985 [org.grits.toolbox.core.preference.GritsPreferenceStore savePreference 125] - Saving preference : org.grits.toolbox.entry.ms.all

Change History (6)

comment:1 Changed 4 years ago by sena

It looks like there are two fields with the same name (one defined in the parent) in MSAnnoationEntityProperty. The one defined in the subclass, MSAnnoationEntityProperty overrides the parent's parentProperty field. The subclass sets it to MSGlycanAnnotationProperty and it is expected to be of type "MassSpecProperty" in MassSpecPropertyView's save method.

comment:2 Changed 4 years ago by sena

Owner: set to dbrentw
Status: newassigned

comment:3 Changed 3 years ago by dbrentw

Milestone: GRITS - 1.2GRITS - 1.2 SR1

comment:4 Changed 3 years ago by sena

Severity: minormajor
Summary: MS Annotation Editor - Cannat save changes in "MS Properties" tabMS Annotation Editor - Cannot save changes in "MS Properties" tab

comment:5 Changed 3 years ago by sena

Resolution: worksforme
Status: assignedreview

This is not a valid problem anymore since the user is not allowed to change anything in MS properties tab with the new MS redesign.

comment:6 Changed 3 years ago by sena

Status: reviewclosed
Note: See TracTickets for help on using tickets.