AssertionFailedException because of IUndoContext
Oxygen general issues.
AssertionFailedException because of IUndoContext
Hello,
Precondition: we are using Eclipse 3.6 and Oxygen 13.2
Now I´ve been looking at the debugger and searching with google for 2 hours and could not figure out why the IUndoContext becomes null und then throws this Exception.
The Error occurs, when I have opened a couple of Oxygen Editors and switch between them and afterwards close one of them.
I would guess that you´re using an own IUndoContext for your XML editor.
Could it be that the IUndoContext is disposed too early, when an editor is closed?
Here is the Stacktrace of the Error:
Thanks in advance for any hint.
Regards,
Simon
Precondition: we are using Eclipse 3.6 and Oxygen 13.2
Now I´ve been looking at the debugger and searching with google for 2 hours and could not figure out why the IUndoContext becomes null und then throws this Exception.
The Error occurs, when I have opened a couple of Oxygen Editors and switch between them and afterwards close one of them.
I would guess that you´re using an own IUndoContext for your XML editor.
Could it be that the IUndoContext is disposed too early, when an editor is closed?
Here is the Stacktrace of the Error:
Code: Select all
!ENTRY org.eclipse.core.commands 4 2 2012-04-17 15:18:16.010
!MESSAGE Beim Aufrufen des Codes vom Plug-in sind Fehler aufgetreten: "org.eclipse.core.commands".
!STACK 0
org.eclipse.core.runtime.AssertionFailedException: null argument:
at org.eclipse.core.runtime.Assert.isNotNull(Assert.java:85)
at org.eclipse.core.runtime.Assert.isNotNull(Assert.java:73)
at org.eclipse.core.commands.operations.AbstractOperation.hasContext(AbstractOperation.java:153)
at org.eclipse.ui.operations.OperationHistoryActionHandler$HistoryListener.historyNotification(OperationHistoryActionHandler.java:141)
at org.eclipse.core.commands.operations.DefaultOperationHistory$2.run(DefaultOperationHistory.java:939)
at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)
at org.eclipse.core.commands.operations.DefaultOperationHistory.notifyListeners(DefaultOperationHistory.java:928)
at org.eclipse.core.commands.operations.DefaultOperationHistory.notifyRemoved(DefaultOperationHistory.java:1052)
at org.eclipse.core.commands.operations.DefaultOperationHistory.internalRemove(DefaultOperationHistory.java:900)
at org.eclipse.core.commands.operations.DefaultOperationHistory.flushUndo(DefaultOperationHistory.java:629)
at org.eclipse.core.commands.operations.DefaultOperationHistory.dispose(DefaultOperationHistory.java:328)
at org.eclipse.text.undo.DocumentUndoManager.disposeUndoHistory(DocumentUndoManager.java:969)
at org.eclipse.text.undo.DocumentUndoManager.shutdown(DocumentUndoManager.java:1225)
at org.eclipse.text.undo.DocumentUndoManager.disconnect(DocumentUndoManager.java:881)
at org.eclipse.jface.text.TextViewerUndoManager.disconnectDocumentUndoManager(TextViewerUndoManager.java:436)
at org.eclipse.jface.text.TextViewerUndoManager.disconnect(TextViewerUndoManager.java:338)
at org.eclipse.jface.text.source.SourceViewer.unconfigure(SourceViewer.java:740)
at org.eclipse.jface.text.source.SourceViewer.handleDispose(SourceViewer.java:751)
at org.eclipse.jface.text.TextViewer$2.widgetDisposed(TextViewer.java:1798)
at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:123)
at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1053)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1077)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1062)
at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java:774)
at org.eclipse.swt.custom.StyledText.handleDispose(StyledText.java:5829)
at org.eclipse.swt.custom.StyledText$7.handleEvent(StyledText.java:5655)
at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1053)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1077)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1058)
at org.eclipse.swt.widgets.Widget.release(Widget.java:808)
at org.eclipse.swt.widgets.Composite.releaseChildren(Composite.java:872)
at org.eclipse.swt.widgets.Widget.release(Widget.java:811)
at org.eclipse.swt.widgets.Composite.releaseChildren(Composite.java:872)
at org.eclipse.swt.widgets.Widget.release(Widget.java:811)
at org.eclipse.swt.widgets.Composite.releaseChildren(Composite.java:872)
at org.eclipse.swt.widgets.Widget.release(Widget.java:811)
at org.eclipse.swt.widgets.Widget.dispose(Widget.java:446)
at org.eclipse.ui.part.PageBookView.removePage(PageBookView.java:853)
at org.eclipse.ui.part.PageBookView.partClosed(PageBookView.java:784)
at org.eclipse.ui.part.PageBookView$4.partClosed(PageBookView.java:1022)
at org.eclipse.ui.internal.PartListenerList2$3.run(PartListenerList2.java:100)
at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)
at org.eclipse.core.runtime.Platform.run(Platform.java:888)
at org.eclipse.ui.internal.PartListenerList2.fireEvent(PartListenerList2.java:55)
at org.eclipse.ui.internal.PartListenerList2.firePartClosed(PartListenerList2.java:98)
at org.eclipse.ui.internal.PartService.firePartClosed(PartService.java:227)
at org.eclipse.ui.internal.WorkbenchPagePartList.firePartClosed(WorkbenchPagePartList.java:39)
at org.eclipse.ui.internal.PartList.partClosed(PartList.java:274)
at org.eclipse.ui.internal.PartList.removePart(PartList.java:186)
at org.eclipse.ui.internal.WorkbenchPage.disposePart(WorkbenchPage.java:1720)
at org.eclipse.ui.internal.WorkbenchPage.handleDeferredEvents(WorkbenchPage.java:1426)
at org.eclipse.ui.internal.WorkbenchPage.deferUpdates(WorkbenchPage.java:1410)
at org.eclipse.ui.internal.WorkbenchPage.closeEditors(WorkbenchPage.java:1384)
at org.eclipse.ui.internal.WorkbenchPage.closeEditor(WorkbenchPage.java:1439)
at org.eclipse.ui.internal.EditorPane.doHide(EditorPane.java:61)
at org.eclipse.ui.internal.PartStack.close(PartStack.java:541)
at org.eclipse.ui.internal.EditorStack.close(EditorStack.java:206)
at org.eclipse.ui.internal.PartStack$1.close(PartStack.java:120)
at org.eclipse.ui.internal.presentations.util.TabbedStackPresentation$1.handleEvent(TabbedStackPresentation.java:83)
at org.eclipse.ui.internal.presentations.util.AbstractTabFolder.fireEvent(AbstractTabFolder.java:269)
at org.eclipse.ui.internal.presentations.util.AbstractTabFolder.fireEvent(AbstractTabFolder.java:278)
at org.eclipse.ui.internal.presentations.defaultpresentation.DefaultTabFolder.access$1(DefaultTabFolder.java:1)
at org.eclipse.ui.internal.presentations.defaultpresentation.DefaultTabFolder$1.closeButtonPressed(DefaultTabFolder.java:71)
at org.eclipse.ui.internal.presentations.PaneFolder.notifyCloseListeners(PaneFolder.java:631)
at org.eclipse.ui.internal.presentations.PaneFolder$3.close(PaneFolder.java:206)
at org.eclipse.swt.custom.CTabFolder.onMouse(CTabFolder.java:1595)
at org.eclipse.swt.custom.CTabFolder$1.handleEvent(CTabFolder.java:261)
at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1053)
at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:4066)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3657)
at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2640)
at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2604)
at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2438)
at org.eclipse.ui.internal.Workbench$7.run(Workbench.java:671)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:664)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)
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:369)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179)
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:620)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:575)
at org.eclipse.equinox.launcher.Main.run(Main.java:1408)
at org.eclipse.equinox.launcher.Main.main(Main.java:1384)
Regards,
Simon
Simon Scholz
vogella GmbH
http://www.vogella.com
vogella GmbH
http://www.vogella.com
Re: AssertionFailedException because of IUndoContext
Hello Simon,
Thank you for the feedback.
I cannot see anything obvious in the code. When setting the IUndoContext, the code always checks for null values. Maybe it's because the IUndoContext is not set in some particular scenario.
Can you reproduce this problem consistently?
If affirmative, can you please provide more details about your Eclipse setup and step by step instructions?
What distribution of Eclipse 3.6 are you using (Classic, IDE for Java Developers, etc)? Do you have other Eclipse plugins installed?
If you want to keep this discussion private, please write to:
support AT oxygenxml DOT com
Regards,
Adrian
Thank you for the feedback.
I cannot see anything obvious in the code. When setting the IUndoContext, the code always checks for null values. Maybe it's because the IUndoContext is not set in some particular scenario.
Can you reproduce this problem consistently?
If affirmative, can you please provide more details about your Eclipse setup and step by step instructions?
What distribution of Eclipse 3.6 are you using (Classic, IDE for Java Developers, etc)? Do you have other Eclipse plugins installed?
If you want to keep this discussion private, please write to:
support AT oxygenxml DOT com
Regards,
Adrian
Adrian Buza
<oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com
<oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com
Re: AssertionFailedException because of IUndoContext
Hello Adrian,
we are using the Eclipse 3.6 Classic version.
Steps to reproduce the Exception:
1. Open a Document with the Oxygen XML editor
2. Maximize the editor
3. Then minimize the editor again
4. Close the editor
In order to find a solution I observed the "private IUndoContext undoContext" variable of the org.eclipse.ui.operations.OperationHistoryActionHandler and found out that a new OperationHistoryActionHandler is instanciated with null for the IUndoContext in the constructor, when the Editor is minimized.
Maybe it is an Eclipse bug. Or do you have some actions, which are done when minimizing the Editor?
Best regards,
Simon
we are using the Eclipse 3.6 Classic version.
Steps to reproduce the Exception:
1. Open a Document with the Oxygen XML editor
2. Maximize the editor
3. Then minimize the editor again
4. Close the editor
In order to find a solution I observed the "private IUndoContext undoContext" variable of the org.eclipse.ui.operations.OperationHistoryActionHandler and found out that a new OperationHistoryActionHandler is instanciated with null for the IUndoContext in the constructor, when the Editor is minimized.
Maybe it is an Eclipse bug. Or do you have some actions, which are done when minimizing the Editor?
Best regards,
Simon
Simon Scholz
vogella GmbH
http://www.vogella.com
vogella GmbH
http://www.vogella.com
Re: AssertionFailedException because of IUndoContext
Hi,
Thank you for the instructions.
Unfortunately, we could not reproduce this problem using the steps you provided. There was some confusion regarding step 3. Do you actually refer to the Minimize action or are you referring to Restore. If you actually minimized it, how did you close it while minimized? Or did you restore it before that?
We've tried various combinations of Maximize/Minimize/Restore but could not reproduce the problem.
We have tested with Eclipse Classic 3.6.2 (M20110210-1200) and Eclipse 3.7.2 (M20120208-0800) and used the latest build of Oxygen v13.2, 2012040515.
Are there other peculiarities about your Eclipse setup? Did you change some specific option from Oxygen or Eclipse?
Could you please try the same scenario with a fresh deployment of Eclipse+Oxygen and also a fresh workspace? Create a new Sample XML Project (Oxygen) in this workspace and test this situation on one of the Oxygen samples. Does it still happen in this context?
If it persists, please let me know what operating system (including version) and the exact versions and build numbers of Eclipse and Oxygen plugin.
Regards,
Adrian
Thank you for the instructions.
Unfortunately, we could not reproduce this problem using the steps you provided. There was some confusion regarding step 3. Do you actually refer to the Minimize action or are you referring to Restore. If you actually minimized it, how did you close it while minimized? Or did you restore it before that?
We've tried various combinations of Maximize/Minimize/Restore but could not reproduce the problem.
We have tested with Eclipse Classic 3.6.2 (M20110210-1200) and Eclipse 3.7.2 (M20120208-0800) and used the latest build of Oxygen v13.2, 2012040515.
Are there other peculiarities about your Eclipse setup? Did you change some specific option from Oxygen or Eclipse?
Could you please try the same scenario with a fresh deployment of Eclipse+Oxygen and also a fresh workspace? Create a new Sample XML Project (Oxygen) in this workspace and test this situation on one of the Oxygen samples. Does it still happen in this context?
If it persists, please let me know what operating system (including version) and the exact versions and build numbers of Eclipse and Oxygen plugin.
Regards,
Adrian
Adrian Buza
<oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com
<oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com
Jump to
- Oxygen XML Editor/Author/Developer
- ↳ Feature Request
- ↳ Common Problems
- ↳ DITA (Editing and Publishing DITA Content)
- ↳ SDK-API, Frameworks - Document Types
- ↳ DocBook
- ↳ TEI
- ↳ XHTML
- ↳ Other Issues
- Oxygen XML Web Author
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Content Fusion
- ↳ Feature Request
- ↳ Common Problems
- Oxygen JSON Editor
- ↳ Feature Request
- ↳ Common Problems
- Oxygen PDF Chemistry
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Feedback
- ↳ Feature Request
- ↳ Common Problems
- Oxygen XML WebHelp
- ↳ Feature Request
- ↳ Common Problems
- XML
- ↳ General XML Questions
- ↳ XSLT and FOP
- ↳ XML Schemas
- ↳ XQuery
- NVDL
- ↳ General NVDL Issues
- ↳ oNVDL Related Issues
- XML Services Market
- ↳ Offer a Service