| Summary: | Confluence coloring code causing WikiText Editor crash | ||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| Product: | z_Archived | Reporter: | David Carver <d_a_carver> | ||||||||
| Component: | Mylyn | Assignee: | David Green <greensopinion> | ||||||||
| Status: | RESOLVED FIXED | QA Contact: | |||||||||
| Severity: | normal | ||||||||||
| Priority: | P3 | ||||||||||
| Version: | 1.3 | ||||||||||
| Target Milestone: | 1.4.0 | ||||||||||
| Hardware: | PC | ||||||||||
| OS: | Linux | ||||||||||
| Whiteboard: | |||||||||||
| Attachments: |
|
||||||||||
Created attachment 179417 [details]
candidate fix and unit tests
Implemented a candidate fix for this problem. It appears as if the MarkupLanguage wasn't correctly setting the character offset for nested blocks.
Created attachment 179418 [details]
mylyn/context/zip
Patch looks good to me. I won't have time to manually test it (neck deep in other projects now). Fixed in HEAD. Created attachment 181216 [details]
mylyn/context/zip
|
Given the following bit of the confluence wikitext: views to help SOA development. These includes [SOA Services Explorer](in green) for the list of all available SOA services, [Types Explorer](in {color:#0000ff}blue{color}) for searching and browsing all available In a file will generate the following stacktrace when trying to open a text file with the confluence wikitext above. If you remove the coloring the editor opens fine.: java.lang.IllegalArgumentException at org.eclipse.mylyn.internal.wikitext.ui.editor.syntax.Segments.add(Segments.java:30) at org.eclipse.mylyn.internal.wikitext.ui.editor.syntax.Segment.add(Segment.java:96) at org.eclipse.mylyn.internal.wikitext.ui.editor.syntax.FastMarkupPartitioner$PartitionBuilder.beginBlock(FastMarkupPartitioner.java:316) at org.eclipse.mylyn.internal.wikitext.confluence.core.block.ParagraphBlock.processLineContent(ParagraphBlock.java:40) at org.eclipse.mylyn.wikitext.core.parser.markup.MarkupLanguage.processContent(MarkupLanguage.java:174) at org.eclipse.mylyn.wikitext.core.parser.MarkupParser.parse(MarkupParser.java:92) at org.eclipse.mylyn.wikitext.core.parser.MarkupParser.parse(MarkupParser.java:82) at org.eclipse.mylyn.internal.wikitext.ui.editor.syntax.FastMarkupPartitioner$PartitionTokenScanner.computeOlp(FastMarkupPartitioner.java:171) at org.eclipse.mylyn.internal.wikitext.ui.editor.syntax.FastMarkupPartitioner$PartitionTokenScanner.setPartialRange(FastMarkupPartitioner.java:133) at org.eclipse.mylyn.internal.wikitext.ui.editor.syntax.FastMarkupPartitioner$PartitionTokenScanner.setRange(FastMarkupPartitioner.java:222) at org.eclipse.jface.text.rules.FastPartitioner.initialize(FastPartitioner.java:163) at org.eclipse.mylyn.internal.wikitext.ui.editor.syntax.FastMarkupPartitioner.resetPartitions(FastMarkupPartitioner.java:75) at org.eclipse.mylyn.internal.wikitext.ui.editor.syntax.FastMarkupPartitioner.setMarkupLanguage(FastMarkupPartitioner.java:65) at org.eclipse.mylyn.internal.wikitext.ui.editor.MarkupEditor.setMarkupLanguage(MarkupEditor.java:999) at org.eclipse.mylyn.internal.wikitext.ui.editor.MarkupEditor.initializeMarkupLanguage(MarkupEditor.java:986) at org.eclipse.mylyn.internal.wikitext.ui.editor.MarkupEditor.doSetInput(MarkupEditor.java:470) at org.eclipse.ui.texteditor.AbstractTextEditor$19.run(AbstractTextEditor.java:3037) at org.eclipse.jface.operation.ModalContext.runInCurrentThread(ModalContext.java:464) at org.eclipse.jface.operation.ModalContext.run(ModalContext.java:372) at org.eclipse.jface.window.ApplicationWindow$1.run(ApplicationWindow.java:759) at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:70) at org.eclipse.jface.window.ApplicationWindow.run(ApplicationWindow.java:756) at org.eclipse.ui.internal.WorkbenchWindow.run(WorkbenchWindow.java:2600) at org.eclipse.ui.texteditor.AbstractTextEditor.internalInit(AbstractTextEditor.java:3055) at org.eclipse.ui.texteditor.AbstractTextEditor.init(AbstractTextEditor.java:3082) at org.eclipse.mylyn.internal.wikitext.ui.editor.MarkupEditor.init(MarkupEditor.java:965) at org.eclipse.ui.internal.EditorManager.createSite(EditorManager.java:798) at org.eclipse.ui.internal.EditorReference.createPartHelper(EditorReference.java:647) at org.eclipse.ui.internal.EditorReference.createPart(EditorReference.java:465) at org.eclipse.ui.internal.WorkbenchPartReference.getPart(WorkbenchPartReference.java:595) at org.eclipse.ui.internal.EditorReference.getEditor(EditorReference.java:289) at org.eclipse.ui.internal.WorkbenchPage.busyOpenEditorBatched(WorkbenchPage.java:2863) at org.eclipse.ui.internal.WorkbenchPage.busyOpenEditor(WorkbenchPage.java:2768) at org.eclipse.ui.internal.WorkbenchPage.access$11(WorkbenchPage.java:2760) at org.eclipse.ui.internal.WorkbenchPage$10.run(WorkbenchPage.java:2711) at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:70) at org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPage.java:2707) at org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPage.java:2691) at org.eclipse.ui.actions.OpenWithMenu.openEditor(OpenWithMenu.java:331) at org.eclipse.ui.actions.OpenWithMenu$2.handleEvent(OpenWithMenu.java:179) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1258) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3552) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3171) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2629) at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2593) at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2427) at org.eclipse.ui.internal.Workbench$7.run(Workbench.java:670) at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332) at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:663) at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149) at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:115) 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(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:619) at org.eclipse.equinox.launcher.Main.basicRun(Main.java:574) at org.eclipse.equinox.launcher.Main.run(Main.java:1407)