Community
Participate
Working Groups
Build Identifier: M20100909-0800 If you install just the latest liblttngtrace format and then try to import an older-format trace into an LTTng project, the application sort of crashes without any obvious feedback (no alert reporting the problem) and becomes unusable. The host eclipse application captures the error: Contributor org.eclipse.ui.navigator.ProjectExplorer cannot be created. Plug-in org.eclipse.ui.navigator.resources was unable to instantiate class org.eclipse.ui.internal.navigator.resources.workbench.TabbedPropertySheetTitleProvider Upon double-clicking the imported trace (yes, it did appear in the explorer, contrary to what should have happened), the host eclipse application's console captures: org.eclipse.linuxtools.lttng.trace.LTTngTraceException: Failed to initialize library! Is the trace version supported? Make sure you have the correct LTTv library compiled. (openTrace) at org.eclipse.linuxtools.lttng.trace.LTTngTrace.<init>(LTTngTrace.java:152) at org.eclipse.linuxtools.lttng.trace.LTTngTrace.<init>(LTTngTrace.java:125) at org.eclipse.linuxtools.lttng.ui.views.project.ProjectView.selectTrace(ProjectView.java:182) at org.eclipse.linuxtools.lttng.ui.views.project.ProjectView.access$2(ProjectView.java:173) at org.eclipse.linuxtools.lttng.ui.views.project.ProjectView$3.mouseDoubleClick(ProjectView.java:166) at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:189) 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:3540) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3161) 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.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:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:616) 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) at org.eclipse.equinox.launcher.Main.main(Main.java:1383) WARNING : Failed to initialize library handle from liblttvtraceread-2.5.so! Obviously, the trace import should FAIL if the proper format library is not found, it should report this to the user through a dialog, and the trace should not appear in the project. The exception should not escape. Reproducible: Always Steps to Reproduce: 1. Install just the latest liblttngtrace format (e.g. 2.6). 2. Launch org.eclipse.linuxtools.lttng.ui as an Eclipse application. 3. Create an LTTng project. 4. Import an older-format trace.
Created attachment 201426 [details] patch to display error dialog when native trace library fails to load instead of displaying stack trace in console This patch needs to be applied after the patches for bug 354541 are applied.
Created attachment 201427 [details] screenshot of the new error dialog
Legal Message: I, Yufen Kuo, declare that I developed attached code from scratch, without referencing any 3rd party materials except material licensed under the EPL. {I am authorized by my employer to make this contribution under the EPL.}
The patch works very well. Thanks!
Created attachment 202192 [details] Alternative error dialog I would like to improve the error description a little bit. Anything you would like to see?
(In reply to comment #5) > Created attachment 202192 [details] > Alternative error dialog > > I would like to improve the error description a little bit. Anything you would > like to see? I like the improved one also.
Comment on attachment 201426 [details] patch to display error dialog when native trace library fails to load instead of displaying stack trace in console Patch committed to stable-0.8 branch (with minor changes)
Still need to commit changes on HEAD.
Committed on HEAD.
Delivered with 0.8.1