Announcement

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

    JavaScript exception on Button Click in current 5.1d

    Hi Isomorphic,

    I'm getting this Developer Console exception in 5.1d (SNAPSHOT_v10.1d_2015-07-21) I'm not getting in 5.0p (v10.0p_2015-07-15).
    It happens on button click but is most likely related to your request/RPC code.

    Developer Console GC43 (removed server name in logs):
    Code:
    11:55:58.991:MUP2:WARN:Log:com.google.gwt.core.client.JavaScriptException: (TypeError) : Cannot read property 'length' of undefined
        at RF(lms-0.js)
        at cd(lms-0.js)
        at Xc(lms-0.js)
        at SH(lms-0.js)
        at YH(lms-0.js)
        at eval(lms-0.js)
        at Pb(lms-0.js)
        at Sb(lms-0.js)
        at eval(lms-0.js)
        at MM.d.click(lms-0.js)
        at isc_StatefulCanvas_handleActivate(https://myserver.com/project/sc/modules/ISC_Foundation.js?isc_version=v10.1d_2015-07-21-SNAPSHOT.js)
        at isc_StatefulCanvas_handleClick(https://myserver.com/project/sc/modules/ISC_Foundation.js?isc_version=v10.1d_2015-07-21-SNAPSHOT.js)
        at isc_c_EventHandler_bubbleEvent(https://myserver.com/project/sc/modules/ISC_Core.js?isc_version=v10.1d_2015-07-21-SNAPSHOT.js)
        at isc_c_EventHandler_handleClick(https://myserver.com/project/sc/modules/ISC_Core.js?isc_version=v10.1d_2015-07-21-SNAPSHOT.js)
        at isc_c_EventHandler__handleMouseUp(https://myserver.com/project/sc/modules/ISC_Core.js?isc_version=v10.1d_2015-07-21-SNAPSHOT.js)
        at isc_c_EventHandler_handleMouseUp(https://myserver.com/project/sc/modules/ISC_Core.js?isc_version=v10.1d_2015-07-21-SNAPSHOT.js)
        at isc_c_EventHandler_dispatch(https://myserver.com/project/sc/modules/ISC_Core.js?isc_version=v10.1d_2015-07-21-SNAPSHOT.js)
        at eval(eval at isc__makeFunction (https://myserver.com/project/sc/modules/ISC_Core.js?isc_version=v10.1d_2015-07-21-SNAPSHOT.js)
    Developer Console FF26 (different, less details, no change to logs, especially nothing removed behind "https"):
    Code:
    11:59:35.670:MUP6:WARN:Log:com.google.gwt.core.client.JavaScriptException: (TypeError) : _4 is undefined
        at tF(https)
        at dd(https)
        at Yc(https)
        at xH(https)
        at DH(https)
        at qM/g<(https)
        at Pb(https)
        at Sb(https)
        at Rb/<(https)
        at click(https)
        at isc_StatefulCanvas_handleActivate(https)
        at isc_StatefulCanvas_handleClick(https)
        at isc_c_EventHandler_bubbleEvent(https)
        at isc_c_EventHandler_handleClick(https)
        at isc_c_EventHandler__handleMouseUp(https)
        at isc_c_EventHandler_handleMouseUp(https)
        at isc_c_EventHandler_dispatch(https)
        at anonymous(https)
        at anonymous()
    My code:
    Code:
    reloadButton.addClickHandler(new ClickHandler() {
    	@Override
    	public void onClick(ClickEvent event) {
    
    		// resultGrid.fetchData(combinedAC);
    
    		FilterSectionStack.this.parent.fetchData(computeCriteria());
    	}
    });
    
    //...
    //This is the fetchData called above:
    
    public void fetchData(AdvancedCriteria combinedAC) {
    	RPCManager.startQueue();
    	funnelDS.fetchData(combinedAC, new DSCallback() {
    		@Override
    		public void execute(DSResponse dsResponse, Object data, DSRequest dsRequest) {
    			if (dsResponse.getStatus() == DSResponse.STATUS_SUCCESS)
    				funnelSectionStack.getFunnel().setData(dsResponse);
    		}
    	}, new DSRequest() {
    		{
    			setOperationId("countLeads");
    		}
    	});
    	leadListReporting.fetchData(combinedAC);
    	RPCManager.sendQueue();
    }
    Please also note the difference in the sent RPC requests in the attached screenshot. Therefore I think this might be related to the RPC code, not the button click.

    This is pretty important for me, so if you need more details, let me know.

    Best regards
    Blama
    Attached Files
    Last edited by Blama; 23 Jul 2015, 02:10.

    #2
    For completeness:

    IE 11 Developer Console entry:
    Code:
    12:12:28.487:pointerup5:WARN:Log:com.google.gwt.core.client.JavaScriptException: (TypeError) : Die Eigenschaft "length" eines undefinierten oder Nullverweises kann nicht abgerufen werden.
        at tF(Unknown script code)
        at dd(Unknown script code)
        at Yc(Unknown script code)
        at xH(Unknown script code)
        at DH(Unknown script code)
        at anonymous(Unknown script code)
        at Pb(Unknown script code)
        at Sb(Unknown script code)
        at anonymous(Unknown script code)
        at click(Unknown script code)
        at isc_StatefulCanvas_handleActivate(https://myserver.com/project/sc/modules/ISC_Foundation.js?isc_version=v10.1d_2015-07-21-SNAPSHOT.js)
        at isc_StatefulCanvas_handleClick(https://myserver.com/project/sc/modules/ISC_Foundation.js?isc_version=v10.1d_2015-07-21-SNAPSHOT.js)
        at isc_c_EventHandler_bubbleEvent(https://myserver.com/project/sc/modules/ISC_Core.js?isc_version=v10.1d_2015-07-21-SNAPSHOT.js)
        at isc_c_EventHandler_handleClick(https://myserver.com/project/sc/modules/ISC_Core.js?isc_version=v10.1d_2015-07-21-SNAPSHOT.js)
        at isc_c_EventHandler__handleMouseUp(https://myserver.com/project/sc/modules/ISC_Core.js?isc_version=v10.1d_2015-07-21-SNAPSHOT.js)
        at isc_c_EventHandler__handlePointerUp(https://myserver.com/project/sc/modules/ISC_Core.js?isc_version=v10.1d_2015-07-21-SNAPSHOT.js)
        at isc_c_EventHandler_dispatch(https://myserver.com/project/sc/modules/ISC_Core.js?isc_version=v10.1d_2015-07-21-SNAPSHOT.js)
        at Function code(Function code)
    The RPC tab here looks like the one in the FF26-screenshot.

    Best regards
    Blama

    Comment


      #3
      One other thing: It worked with previous versions of 5.1d, but I don't know when it stopped working.

      Comment


        #4
        Also tested with SNAPSHOT_v10.1d_2015-07-23/PowerEdition Deployment (built 2015-07-23), same error.

        Comment


          #5
          This looks like a crash inside GWT Java application code being called from a click event. Is there any reason you think this crash is inside framework code?

          Perhaps using less obfuscation you'd be able to see where in the code this is occurring.

          Comment


            #6
            Hi Isomorphic,

            yes, please see the Development Mode Error message:
            Code:
            [B]12:32:14.672 [ERROR] [lms] Uncaught exception escaped
            
            com.google.gwt.event.shared.UmbrellaException: Exception caught: (TypeError) @com.smartgwt.client.widgets.grid.ListGrid::fetchData(Lcom/smartgwt/client/data/Criteria;)([Java object: com.smartgwt.client.data.AdvancedCriteria@788949635]): _4 is undefined
            [/B]    at com.google.gwt.event.shared.HandlerManager.fireEvent(HandlerManager.java:129)
                at com.google.gwt.user.client.ui.Widget.fireEvent(Widget.java:129)
                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 com.google.gwt.dev.shell.MethodAdaptor.invoke(MethodAdaptor.java:103)
                at com.google.gwt.dev.shell.MethodDispatch.invoke(MethodDispatch.java:72)
                at com.google.gwt.dev.shell.OophmSessionHandler.invoke(OophmSessionHandler.java:172)
                at com.google.gwt.dev.shell.BrowserChannelServer.reactToMessagesWhileWaitingForReturn(BrowserChannelServer.java:341)
                at com.google.gwt.dev.shell.BrowserChannelServer.invokeJavascript(BrowserChannelServer.java:222)
                at com.google.gwt.dev.shell.ModuleSpaceOOPHM.doInvoke(ModuleSpaceOOPHM.java:137)
                at com.google.gwt.dev.shell.ModuleSpace.invokeNative(ModuleSpace.java:589)
                at com.google.gwt.dev.shell.ModuleSpace.invokeNativeObject(ModuleSpace.java:293)
                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:299)
                at sun.reflect.GeneratedMethodAccessor56.invoke(Unknown Source)
                at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
                at java.lang.reflect.Method.invoke(Unknown Source)
                at com.google.gwt.dev.shell.MethodAdaptor.invoke(MethodAdaptor.java:103)
                at com.google.gwt.dev.shell.MethodDispatch.invoke(MethodDispatch.java:72)
                at com.google.gwt.dev.shell.OophmSessionHandler.invoke(OophmSessionHandler.java:172)
                at com.google.gwt.dev.shell.BrowserChannelServer.reactToMessages(BrowserChannelServer.java:296)
                at com.google.gwt.dev.shell.BrowserChannelServer.processConnection(BrowserChannelServer.java:551)
                at com.google.gwt.dev.shell.BrowserChannelServer.run(BrowserChannelServer.java:368)
                at java.lang.Thread.run(Unknown Source)
            Caused by: com.google.gwt.core.client.JavaScriptException: (TypeError) @com.smartgwt.client.widgets.grid.ListGrid::fetchData(Lcom/smartgwt/client/data/Criteria;)([Java object: com.smartgwt.client.data.AdvancedCriteria@788949635]): _4 is undefined
                at com.google.gwt.dev.shell.BrowserChannelServer.invokeJavascript(BrowserChannelServer.java:252)
                at com.google.gwt.dev.shell.ModuleSpaceOOPHM.doInvoke(ModuleSpaceOOPHM.java:137)
                at com.google.gwt.dev.shell.ModuleSpace.invokeNative(ModuleSpace.java:589)
                at com.google.gwt.dev.shell.ModuleSpace.invokeNativeVoid(ModuleSpace.java:315)
                at com.google.gwt.dev.shell.JavaScriptHost.invokeNativeVoid(JavaScriptHost.java:107)
                at com.smartgwt.client.widgets.grid.ListGrid.fetchData(ListGrid.java)
                at com.lmscompany.lms.client.ui.reporting.ReportingHLayout.fetchData(ReportingHLayout.java:66)
                at com.lmscompany.lms.client.ui.reporting.FilterSectionStack$6.onClick(FilterSectionStack.java:202)
                at com.smartgwt.client.widgets.events.ClickEvent.dispatch(ClickEvent.java:112)
                at com.smartgwt.client.widgets.events.ClickEvent.dispatch(ClickEvent.java:1)
                at com.google.gwt.event.shared.GwtEvent.dispatch(GwtEvent.java:1)
                at com.google.web.bindery.event.shared.EventBus.dispatchEvent(EventBus.java:40)
                at com.google.web.bindery.event.shared.SimpleEventBus.doFire(SimpleEventBus.java:193)
                at com.google.web.bindery.event.shared.SimpleEventBus.fireEvent(SimpleEventBus.java:88)
                at com.google.gwt.event.shared.HandlerManager.fireEvent(HandlerManager.java:127)
                at com.google.gwt.user.client.ui.Widget.fireEvent(Widget.java:129)
                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 com.google.gwt.dev.shell.MethodAdaptor.invoke(MethodAdaptor.java:103)
                at com.google.gwt.dev.shell.MethodDispatch.invoke(MethodDispatch.java:72)
                at com.google.gwt.dev.shell.OophmSessionHandler.invoke(OophmSessionHandler.java:172)
                at com.google.gwt.dev.shell.BrowserChannelServer.reactToMessagesWhileWaitingForReturn(BrowserChannelServer.java:341)
                at com.google.gwt.dev.shell.BrowserChannelServer.invokeJavascript(BrowserChannelServer.java:222)
                at com.google.gwt.dev.shell.ModuleSpaceOOPHM.doInvoke(ModuleSpaceOOPHM.java:137)
                at com.google.gwt.dev.shell.ModuleSpace.invokeNative(ModuleSpace.java:589)
                at com.google.gwt.dev.shell.ModuleSpace.invokeNativeObject(ModuleSpace.java:293)
                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:299)
                at sun.reflect.GeneratedMethodAccessor56.invoke(Unknown Source)
                at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
                at java.lang.reflect.Method.invoke(Unknown Source)
                at com.google.gwt.dev.shell.MethodAdaptor.invoke(MethodAdaptor.java:103)
                at com.google.gwt.dev.shell.MethodDispatch.invoke(MethodDispatch.java:72)
                at com.google.gwt.dev.shell.OophmSessionHandler.invoke(OophmSessionHandler.java:172)
                at com.google.gwt.dev.shell.BrowserChannelServer.reactToMessages(BrowserChannelServer.java:296)
                at com.google.gwt.dev.shell.BrowserChannelServer.processConnection(BrowserChannelServer.java:551)
                at com.google.gwt.dev.shell.BrowserChannelServer.run(BrowserChannelServer.java:368)
                at java.lang.Thread.run(Unknown Source)
            combinedAC.asString() in the debugger:
            Code:
            {
                "operator":"and", 
                "_constructor":"AdvancedCriteria", 
                "$H":10
            }
            I have no idea what "$H" is. This computes the criteria:
            Code:
            private AdvancedCriteria computeCriteria() {
            
            	AdvancedCriteria masterdataAC = leadMasterdataForm.getValuesAsAdvancedCriteria();
            	AdvancedCriteria creatorAC = leadCreatordataForm.getValuesAsAdvancedCriteria();
            	AdvancedCriteria resellerAC = null;
            	AdvancedCriteria resellerUserAC = null;
            	if (User.isResellerUser())
            		resellerUserAC = resellerUserForm.getValuesAsAdvancedCriteria();
            	else
            		resellerAC = resellerForm.getValuesAsAdvancedCriteria();
            
            	AdvancedCriteria combinedAC = new AdvancedCriteria(OperatorId.AND);
            	if (masterdataAC != null)
            		combinedAC.addCriteria(masterdataAC);
            	if (creatorAC != null)
            		combinedAC.addCriteria(creatorAC);
            	// either
            	if (resellerAC != null)
            		combinedAC.addCriteria(resellerAC);
            	if (resellerUserAC != null)
            		combinedAC.addCriteria(resellerUserAC);
            	return combinedAC;
            }
            Before the return, the values of combinedAC.asString() in the debugger is:
            Code:
            {
                "operator":"and", 
                "_constructor":"AdvancedCriteria"
            }
            It changes after my 1st fetch in the Queue (that uses only SmartGWT APIs, see code above). See the attached screenshots.

            Best regards
            Blama
            Attached Files

            Comment


              #7
              Hi Isomorphic,

              also please see the 1st request (the 2nd is not visible in the RPC tab because the program crashes before:
              Code:
              {
                  dataSource:"V_REPORTING_FUNNEL", 
                  operationType:"fetch", 
                  operationId:"countLeads", 
                  data:{
                      operator:"and"
                  }, 
                  textMatchStyle:"exact", 
                  showPrompt:true, 
                  oldValues:{
                      operator:"and"
                  }, 
                  requestId:"V_REPORTING_FUNNEL$62713", 
                  fallbackToEval:false, 
                  lastClientEventThreadCode:"MUP7", 
                  bypassCache:true, 
                  dataProtocol:"getParams"
              }
              Note how operator:"and" is under data/oldValues and that there is no criteria.

              Best regards
              Blama

              Comment


                #8
                Hi Isomorphic,

                please disregard the last post. This seems to be the normal position for operator.
                One more observation: If the change the UI so that the generated criteria are not empty, everything is working as expected.

                Best regards
                Blama

                Comment


                  #9
                  We are not able to reproduce the error you are seeing. Perhaps, we are not taking into account important data that you have in your code, so, could you please post your test code to test it?

                  Regards,
                  Isomorphic Software

                  Comment


                    #10
                    Hi Isomorphic,

                    still using: SNAPSHOT_v10.1d_2015-07-23.

                    Please see this testcase:
                    .java:
                    Code:
                    package com.smartgwt.sample.client;
                    
                    import com.google.gwt.core.client.EntryPoint;
                    import com.smartgwt.client.core.KeyIdentifier;
                    import com.smartgwt.client.data.AdvancedCriteria;
                    import com.smartgwt.client.data.DSCallback;
                    import com.smartgwt.client.data.DSRequest;
                    import com.smartgwt.client.data.DSResponse;
                    import com.smartgwt.client.data.DataSource;
                    import com.smartgwt.client.rpc.RPCManager;
                    import com.smartgwt.client.types.OperatorId;
                    import com.smartgwt.client.util.PageKeyHandler;
                    import com.smartgwt.client.util.Page;
                    import com.smartgwt.client.util.SC;
                    import com.smartgwt.client.widgets.IButton;
                    import com.smartgwt.client.widgets.events.ClickEvent;
                    import com.smartgwt.client.widgets.events.ClickHandler;
                    import com.smartgwt.client.widgets.grid.ListGrid;
                    import com.smartgwt.client.widgets.layout.HLayout;
                    import com.smartgwt.client.widgets.layout.VLayout;
                    
                    public class BuiltInDS implements EntryPoint {
                    	private VLayout vL;
                    	private TestGrid tG1;
                    	private TestGrid tG2;
                    	private HLayout hL;
                    
                    	public void onModuleLoad() {
                    		KeyIdentifier debugKey = new KeyIdentifier();
                    		debugKey.setCtrlKey(true);
                    		debugKey.setKeyName("D");
                    
                    		Page.registerKey(debugKey, new PageKeyHandler() {
                    			public void execute(String keyName) {
                    				SC.showConsole();
                    			}
                    		});
                    
                    		vL = new VLayout(5);
                    		vL.setPadding(20);
                    		vL.setWidth100();
                    		vL.setHeight100();
                    		tG1 = new TestGrid("animals");
                    		tG2 = new TestGrid("employees");
                    
                    		hL = new HLayout(5);
                    		hL.setHeight(40);
                    		IButton reloadBtn = new IButton("Reload");
                    		reloadBtn.setWidth(150);
                    		reloadBtn.addClickHandler(new ClickHandler() {
                    			@Override
                    			public void onClick(ClickEvent event) {
                    				vL.removeChild(tG1);
                    				vL.removeChild(tG2);
                    				tG1.markForDestroy();
                    				tG2.markForDestroy();
                    				tG1 = new TestGrid("animals");
                    				tG2 = new TestGrid("employees");
                    				vL.addMember(tG1, 0);
                    				vL.addMember(tG2, 1);
                    			}
                    		});
                    
                    		hL.addMembers(reloadBtn);
                    		vL.addMembers(tG1, tG2, hL);
                    		vL.draw();
                    		fetchData(computeCriteria());
                    	}
                    
                    	private class TestGrid extends ListGrid {
                    		public TestGrid(String mode) {
                    			super();
                    			setShowFilterEditor(true);
                    			setDataSource(DataSource.get(mode));
                    			setAutoFetchData(false);
                    		}
                    	}
                    
                    	private AdvancedCriteria computeCriteria() {
                    		AdvancedCriteria combinedAC = new AdvancedCriteria(OperatorId.AND);
                    		return combinedAC;
                    	}
                    
                    	public void fetchData(AdvancedCriteria combinedAC) {
                    		AdvancedCriteria combinedAC2 = new AdvancedCriteria(combinedAC);
                    		RPCManager.startQueue();
                    		tG1.fetchData(combinedAC, new DSCallback() {
                    			@Override
                    			public void execute(DSResponse dsResponse, Object data, DSRequest dsRequest) {
                    				if (dsResponse.getStatus() == DSResponse.STATUS_SUCCESS)
                    					SC.say("Yay!");
                    			}
                    		}, new DSRequest() {
                    			{
                    				setOperationId("countLeads");
                    			}
                    		});
                    		tG2.fetchData(combinedAC2);
                    		RPCManager.sendQueue();
                    	}
                    }
                    .html:
                    Code:
                    <!DOCTYPE html>
                    <html>
                    <head>
                    <meta http-equiv="content-type" content="text/html; charset=UTF-8">
                    <title>BuiltInDS</title>
                    <script>
                    	var isomorphicDir = "builtinds/sc/";
                    </script>
                    <script type="text/javascript" src="builtinds/sc/modules/ISC_Core.js"></script>
                    <script type="text/javascript" src="builtinds/sc/modules/ISC_Foundation.js"></script>
                    <script type="text/javascript" src="builtinds/sc/modules/ISC_Containers.js"></script>
                    <script type="text/javascript" src="builtinds/sc/modules/ISC_Grids.js"></script>
                    <script type="text/javascript" src="builtinds/sc/modules/ISC_Forms.js"></script>
                    <script type="text/javascript" src="builtinds/sc/modules/ISC_DataBinding.js"></script>
                    <script type="text/javascript" src="builtinds/sc/skins/Simplicity/load_skin.js"></script>
                    <script type="text/javascript" src="builtinds/builtinds.nocache.js"></script>
                    </head>
                    <body>
                    	<script src="builtinds/sc/DataSourceLoader?dataSource=supplyItem,animals,employees"></script>
                    	<iframe src="javascript:''" id="__gwt_historyFrame" tabIndex='-1'
                    		style="position: absolute; width: 0; height: 0; border: 0"></iframe>
                    </body>
                    </html>
                    FF26 Dev Mode exception on load
                    Code:
                    15:44:16.008 [ERROR] [builtinds] Unable to load module entry point class com.smartgwt.sample.client.BuiltInDS (see associated exception for details)
                    
                    com.google.gwt.core.client.JavaScriptException: (TypeError) @com.smartgwt.client.widgets.grid.ListGrid::fetchData(Lcom/smartgwt/client/data/Criteria;Lcom/smartgwt/client/data/DSCallback;Lcom/smartgwt/client/data/DSRequest;)([Java object: com.smartgwt.client.data.AdvancedCriteria@1225410362, Java object: com.smartgwt.sample.client.BuiltInDS$3@1103779404, Java object: com.smartgwt.sample.client.BuiltInDS$4@1256700242]): _15 is undefined
                        at com.google.gwt.dev.shell.BrowserChannelServer.invokeJavascript(BrowserChannelServer.java:252)
                        at com.google.gwt.dev.shell.ModuleSpaceOOPHM.doInvoke(ModuleSpaceOOPHM.java:137)
                        at com.google.gwt.dev.shell.ModuleSpace.invokeNative(ModuleSpace.java:589)
                        at com.google.gwt.dev.shell.ModuleSpace.invokeNativeVoid(ModuleSpace.java:315)
                        at com.google.gwt.dev.shell.JavaScriptHost.invokeNativeVoid(JavaScriptHost.java:107)
                        at com.smartgwt.client.widgets.grid.ListGrid.fetchData(ListGrid.java)
                        at com.smartgwt.sample.client.BuiltInDS.fetchData(BuiltInDS.java:87)
                        at com.smartgwt.sample.client.BuiltInDS.onModuleLoad(BuiltInDS.java:67)
                        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 com.google.gwt.dev.shell.ModuleSpace.onLoad(ModuleSpace.java:423)
                        at com.google.gwt.dev.shell.OophmSessionHandler.loadModule(OophmSessionHandler.java:200)
                        at com.google.gwt.dev.shell.BrowserChannelServer.processConnection(BrowserChannelServer.java:530)
                        at com.google.gwt.dev.shell.BrowserChannelServer.run(BrowserChannelServer.java:368)
                        at java.lang.Thread.run(Unknown Source)
                    FF26 Developer Console Exception on load (deployed):
                    Code:
                    15:54:20.861:INFO:Log:initialized
                    15:54:21.745:INFO:Log:isc.Page is loaded
                    [B]15:54:22.701:WARN:Log:Uncaught JavaScript exception: TypeError: _15 is undefined in http://localhost:8080/BuiltInDS/builtinds/sc/modules/ISC_Forms.js, line 317
                    [/B]Messaging endpoint not responding - remote debugging unavailable.  To fix, make sure you have correctly registered the Messaging servlet in your web.xml
                    This does not show the exact error I saw, but also clearly an exception that should not happen.

                    Best regards
                    Blama

                    Comment


                      #11
                      FYI: Removing the empty AdvancedCriteria from the ListGrid-fetches fixes the problem - so it seems to be a problem with empty criteria.

                      Best regards
                      Blama

                      Comment


                        #12
                        The fix for the latest reported issue will be in nightly builds on 5.1d branch as of tomorrow, July 28. Please, check whether this fix solves your previous issue.

                        Regards,
                        Isomorphic Software

                        Comment


                          #13
                          Hi Isomorphic,

                          SNAPSHOT_v10.1d_2015-07-29 seems to fix the bug in the sample as well as in my application.

                          Best regards
                          Blama

                          Comment


                            #14
                            Hi,

                            I know this is an old post but it's the first that popped up when searching for $H.

                            Some reason $H is getting shoved into criteria making queries fail as a result.

                            We are using:
                            GWT Version : 2.8.2
                            SmartGWT Version : 5.1p
                            SmartGWT Build Date : 10/01/2018 09:08
                            SmartGWT Edition : Pro Edition
                            Best regards,
                            Luke

                            Comment


                              #15
                              Hi,

                              I also have been struggling with "$H" in criteria for some time. Although it is ignored by grid's fetch and seems to be working fine I recently noticed that it somehow stops grid's caches from working. Another words, once "$H" occurs in grid's criteria, then grid does not update its records even though you add a criteria valid record through datasource.

                              Here a good example of producing "$H" into grid's criteria:

                              Code:
                              package pl.com.tech4.client;
                              
                              import com.google.gwt.core.client.EntryPoint;
                              import com.smartgwt.client.data.AdvancedCriteria;
                              import com.smartgwt.client.data.DataSource;
                              import com.smartgwt.client.data.DataSourceField;
                              import com.smartgwt.client.data.OperationBinding;
                              import com.smartgwt.client.data.RestDataSource;
                              import com.smartgwt.client.data.fields.DataSourceDateTimeField;
                              import com.smartgwt.client.data.fields.DataSourceTextField;
                              import com.smartgwt.client.types.DSDataFormat;
                              import com.smartgwt.client.types.DSOperationType;
                              import com.smartgwt.client.types.DSProtocol;
                              import com.smartgwt.client.types.FieldType;
                              import com.smartgwt.client.types.OperatorId;
                              import com.smartgwt.client.util.JSON;
                              import com.smartgwt.client.util.SC;
                              import com.smartgwt.client.widgets.form.FilterBuilder;
                              import com.smartgwt.client.widgets.grid.ListGrid;
                              import com.smartgwt.client.widgets.layout.VLayout;
                              
                              public class MainEntryPoint implements EntryPoint {
                              
                                  public void onModuleLoad() {
                              
                                      layout();
                                      SC.showConsole();
                                  }
                              
                                  private void layout() {
                              
                                      DataSource projectDS = new RestDataSource();
                                      OperationBinding fetchBinding = new OperationBinding();
                                      fetchBinding.setOperationType(DSOperationType.FETCH);
                                      fetchBinding.setDataFormat(DSDataFormat.XML);
                                      fetchBinding.setDataProtocol(DSProtocol.POSTXML);
                                      projectDS.setOperationBindings(fetchBinding);
                              
                                      DataSourceField idField = new DataSourceField();
                                      idField.setType(FieldType.SEQUENCE);
                                      idField.setName("id");
                                      idField.setPrimaryKey(true);
                                      idField.setHidden(true);
                                      DataSourceTextField codeField = new DataSourceTextField();
                                      codeField.setName("code");
                                      DataSourceDateTimeField validFromField = new DataSourceDateTimeField();
                                      validFromField.setName("validFrom");
                                      DataSourceDateTimeField validToField = new DataSourceDateTimeField();
                                      validToField.setName("validTo");
                              
                                      projectDS.setFields(idField, codeField, validFromField, validToField);
                              
                                      FilterBuilder fb = new FilterBuilder();
                                      fb.setDataSource(projectDS);
                                      AdvancedCriteria criteria = new AdvancedCriteria();
                                      criteria.addCriteria("code", OperatorId.ICONTAINS, "test");
                                      fb.setCriteria(criteria);
                              
                                      ListGrid lg = new ListGrid();
                                      lg.setAutoFetchData(false);
                                      lg.setShowFilterEditor(true);
                                      lg.setDataSource(projectDS);
                              
                                      VLayout main = new VLayout();
                                      main.setHeight100();
                                      main.setWidth100();
                                      main.addMembers(fb, lg);
                                      main.draw();
                              
                                      lg.filterData(fb.getCriteria());
                                      SC.logWarn(JSON.encode(lg.getCriteria().getJsObj()));
                                  }
                              
                              }
                              As you can see grid fetches data using criteria obtained from filterBuilder. If you run this example and look into dev console log you will see:

                              Code:
                              *15:48:56.860:WARN:Log:{
                                  "_constructor":"AdvancedCriteria",
                                  "operator":"and",
                                  "criteria":[
                                      {
                                          "fieldName":"code",
                                          "operator":"iContains",
                                          "value":"test"
                                      }
                                  ],
                                  "$H":5
                              }
                              From this point, grid does not react to updateCaches of its datasource.

                              MichalG

                              ps reproducible in all SGWT versions I tried including the last one: SNAPSHOT_v12.1d_2019-03-16/LGPL Development Only (built 2019-03-16)

                              GWT 2.8.2

                              Comment

                              Working...
                              X