Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    Debugging Javascript exception

    Hi There,

    Today, I've suddenly received an exception when my application first starts up. I've been raking my brain around this for few a few hours.

    The exception stack trace I'm receiving in Development Mode is:
    Code:
    23:41:19.507 [ERROR] [myappdesigner] Uncaught exception escaped
    com.google.gwt.core.client.JavaScriptException: (null) @com.smartgwt.client.widgets.layout.HLayout::create()([]): null
        at com.google.gwt.dev.shell.BrowserChannelServer.invokeJavascript(BrowserChannelServer.java:249)
        at com.google.gwt.dev.shell.ModuleSpaceOOPHM.doInvoke(ModuleSpaceOOPHM.java:136)
        at com.google.gwt.dev.shell.ModuleSpace.invokeNative(ModuleSpace.java:571)
        at com.google.gwt.dev.shell.ModuleSpace.invokeNativeObject(ModuleSpace.java:279)
        at com.google.gwt.dev.shell.JavaScriptHost.invokeNativeObject(JavaScriptHost.java:91)
        at com.smartgwt.client.widgets.layout.HLayout.create(HLayout.java)
        at com.smartgwt.client.widgets.BaseWidget.getOrCreateJsObj(BaseWidget.java:404)
        at com.smartgwt.client.widgets.layout.Layout.addMember(Layout.java:1229)
        at MyApp.designer.client.ui.HeaderArea.<init>(HeaderArea.java:218)
        at MyApp.designer.client.MyAppDesigner$9.onSuccess(MyAppDesigner.java:544)
        at com.google.gwt.core.client.GWT.runAsync(GWT.java:255)
        at MyApp.designer.client.MyAppDesigner.drawInterface(MyAppDesigner.java:522)
        at MyApp.designer.client.MyAppDesigner.access$12(MyAppDesigner.java:520)
        at MyApp.designer.client.MyAppDesigner$6.execute(MyAppDesigner.java:463)
        at com.google.gwt.core.client.impl.SchedulerImpl$Task$.executeScheduled$(SchedulerImpl.java:50)
        at com.google.gwt.core.client.impl.SchedulerImpl.runScheduledTasks(SchedulerImpl.java:180)
        at com.google.gwt.core.client.impl.SchedulerImpl.flushPostEventPumpCommands(SchedulerImpl.java:347)
        at com.google.gwt.core.client.impl.SchedulerImpl$Flusher.execute(SchedulerImpl.java:78)
        at com.google.gwt.core.client.impl.SchedulerImpl.execute(SchedulerImpl.java:138)
        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:601)
        at com.google.gwt.dev.shell.MethodAdaptor.invoke(MethodAdaptor.java:103)
        at com.google.gwt.dev.shell.MethodDispatch.invoke(MethodDispatch.java:71)
        at com.google.gwt.dev.shell.OophmSessionHandler.invoke(OophmSessionHandler.java:172)
        at com.google.gwt.dev.shell.BrowserChannelServer.reactToMessagesWhileWaitingForReturn(BrowserChannelServer.java:338)
        at com.google.gwt.dev.shell.BrowserChannelServer.invokeJavascript(BrowserChannelServer.java:219)
        at com.google.gwt.dev.shell.ModuleSpaceOOPHM.doInvoke(ModuleSpaceOOPHM.java:136)
        at com.google.gwt.dev.shell.ModuleSpace.invokeNative(ModuleSpace.java:571)
        at com.google.gwt.dev.shell.ModuleSpace.invokeNativeObject(ModuleSpace.java:279)
        at com.google.gwt.dev.shell.JavaScriptHost.invokeNativeObject(JavaScriptHost.java:91)
        at com.google.gwt.core.client.impl.Impl.apply(Impl.java)
        at com.google.gwt.core.client.impl.Impl.entry0(Impl.java:242)
        at sun.reflect.GeneratedMethodAccessor39.invoke(Unknown Source)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:601)
        at com.google.gwt.dev.shell.MethodAdaptor.invoke(MethodAdaptor.java:103)
        at com.google.gwt.dev.shell.MethodDispatch.invoke(MethodDispatch.java:71)
        at com.google.gwt.dev.shell.OophmSessionHandler.invoke(OophmSessionHandler.java:172)
        at com.google.gwt.dev.shell.BrowserChannelServer.reactToMessages(BrowserChannelServer.java:293)
        at com.google.gwt.dev.shell.BrowserChannelServer.processConnection(BrowserChannelServer.java:547)
        at com.google.gwt.dev.shell.BrowserChannelServer.run(BrowserChannelServer.java:364)
        at java.lang.Thread.run(Thread.java:722)
    The "HeaderArea.java" file hasn't been touched in a very long time, and is actually rather simple. It makes no sense why an error would occur there. Commenting out the offending line just shifts the error elsewhere.

    I've upgraded to the latest nightly build of SmartGWT 3.1, and upgraded GWT 2.5.1 (from GWT 2.4.0) but this error continues to persist.

    Any help understanding or debugging it would be appreciated.

    UPDATE: I've just tried in Chrome, and it works perfectly. This error is only affecting Firefox. :-(
    Last edited by nwilton; 30 May 2013, 06:27. Reason: Additional information.

    #2
    Solution!

    I ended up "Clearing Recent History" in Firefox, and selecting everything; All Checkboxes.

    Previously I was just clearing the cache and active logons; not the cookies, etc. This is obviously not sufficient; you must clear everything.

    It's funny how the biggest bugs, often have most simple solutions.

    Thanks anyway.

    BTW; I absolutely love SmartGWT... and will definitely buy a license when I'm a bit further along my development path. :-)

    Comment

    Working...
    X