Announcement

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

    SmartGWT.mobile - Error calling method on NPObject with

    Receiving this error with smartgwt.mobile builds 2012-12-20 and 2012-12-21 ? No idea what is happening. No such error with builds 2012-12-19 and before. Any help please?

    Code:
    14:17:03.237 [ERROR] [moon_mobile] Uncaught exception escaped
    com.google.gwt.core.client.JavaScriptException: (Error): Error calling method on NPObject.
        at com.google.gwt.dev.shell.BrowserChannelServer.invokeJavascript(BrowserChannelServer.java:248)
        at com.google.gwt.dev.shell.ModuleSpaceOOPHM.doInvoke(ModuleSpaceOOPHM.java:136)
        at com.google.gwt.dev.shell.ModuleSpace.invokeNative(ModuleSpace.java:561)
        at com.google.gwt.dev.shell.ModuleSpace.invokeNativeObject(ModuleSpace.java:269)
        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:213)
        at sun.reflect.GeneratedMethodAccessor45.invoke(Unknown Source)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:597)
        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:292)
        at com.google.gwt.dev.shell.BrowserChannelServer.processConnection(BrowserChannelServer.java:546)
        at com.google.gwt.dev.shell.BrowserChannelServer.run(BrowserChannelServer.java:363)
        at java.lang.Thread.run(Thread.java:680)
    This happens after a simple fetchData on a TableView() that used to work before.
    Last edited by bda@n-side.com; 21 Dec 2012, 07:48. Reason: MORE INFO

    #2
    We really can't tell anything from this. It appears to be a JavaScript error, it may not be from SmartGWT.mobile at all. Try to gather more information, possibly by using browser tools (f12).

    Comment


      #3
      I am still blocked by this issue, was expecting "miracle" resolution with new builds but no, still there. I cannot see anything abnormal using browser tool.

      When I run with Firefox (instead of Chrome) I have a different stack trace which touches some smartgwt code this time, maybe this can provide more info:

      Code:
      14:37:23.417 [ERROR] [moon_mobile] Uncaught exception escaped
      com.google.gwt.core.client.JavaScriptException: (null): null
          at com.google.gwt.dev.shell.BrowserChannelServer.invokeJavascript(BrowserChannelServer.java:248)
          at com.google.gwt.dev.shell.ModuleSpaceOOPHM.doInvoke(ModuleSpaceOOPHM.java:136)
          at com.google.gwt.dev.shell.ModuleSpace.invokeNative(ModuleSpace.java:561)
          at com.google.gwt.dev.shell.ModuleSpace.invokeNativeObject(ModuleSpace.java:269)
          at com.google.gwt.dev.shell.JavaScriptHost.invokeNativeObject(JavaScriptHost.java:91)
          at com.smartgwt.mobile.client.util.DateUtil.parseInput(DateUtil.java)
          at com.smartgwt.mobile.client.data.SimpleType$3.parseInput(SimpleType.java:161)
          at com.smartgwt.mobile.client.data.SimpleType$3.parseInput(SimpleType.java:1)
          at com.smartgwt.mobile.client.data.SimpleType._fromVal(SimpleType.java:217)
          at com.smartgwt.mobile.client.data.DataSource.extractRecord(DataSource.java:873)
          at com.smartgwt.mobile.client.data.DataSource.extractRecordList(DataSource.java:919)
          at com.smartgwt.mobile.client.data.DataSource.extractRecordList(DataSource.java:736)
          at com.smartgwt.mobile.client.data.DataSource$1.onResponseReceived(DataSource.java:1351)
          at com.google.gwt.http.client.Request.fireOnResponseReceived(Request.java:287)
          at com.google.gwt.http.client.RequestBuilder$1.onReadyStateChange(RequestBuilder.java:395)
          at sun.reflect.GeneratedMethodAccessor63.invoke(Unknown Source)
          at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
          at java.lang.reflect.Method.invoke(Method.java:597)
          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:337)
          at com.google.gwt.dev.shell.BrowserChannelServer.invokeJavascript(BrowserChannelServer.java:218)
          at com.google.gwt.dev.shell.ModuleSpaceOOPHM.doInvoke(ModuleSpaceOOPHM.java:136)
          at com.google.gwt.dev.shell.ModuleSpace.invokeNative(ModuleSpace.java:561)
          at com.google.gwt.dev.shell.ModuleSpace.invokeNativeObject(ModuleSpace.java:269)
          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:213)
          at sun.reflect.GeneratedMethodAccessor62.invoke(Unknown Source)
          at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
          at java.lang.reflect.Method.invoke(Method.java:597)
          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:292)
          at com.google.gwt.dev.shell.BrowserChannelServer.processConnection(BrowserChannelServer.java:546)
          at com.google.gwt.dev.shell.BrowserChannelServer.run(BrowserChannelServer.java:363)
          at java.lang.Thread.run(Thread.java:680)

      Comment


        #4
        Made some more tests that confirm this problem is caused by the presence of Date type field in the .ds.xml. If I remove date field from my ds, then everything goes well.
        Note that strangely enough, this is happening only in dev mode.

        I hope this will help you to spot the root cause.

        Thanks for helping with this, I really would like to upgrade to last mobile version to incorporate other bug fixes/enhancements related to my other recent posts.

        Ben.
        Last edited by bda@n-side.com; 24 Dec 2012, 06:13.

        Comment


          #5
          I don't know if this can help, but if I change the type of the field to text, and if I look at the string that is returned in this case (while the field remains a DATE field in the DB), I get this:

          2013-02-28T23:00:00

          which looks a strange format to me, especially the 23:00:00 since the DB does not contain time for this field only date (it is a DATE not a DATETIME).

          Comment


            #6
            Leave the field as type "date". The behavior when you've got an underlying date value but you declare type "text" is undefined.

            Can you show a sample of the server response that leads to this error?

            Have you tried the latest nightly of SGWT.mobile combined with the latest SGWT desktop build? Corresponding changes were made to each to fix some edge cases in communicating dates.

            Comment


              #7
              Just tested with 2012-12-24 SWGT/SGWT.mob, still the same.

              Of course I would like to leave the type as date, but the only way at the moment to make recent builds working is to replace the "date" type in my .ds.xml by "text" and parse the string back to a Date in my Java code.

              What do you mean by a sample of the server response? How do I capture that ?

              Comment


                #8
                Use Firebug or any similar tool to see what the server is sending back.

                Comment


                  #9
                  So I have installed Firebug. Here are some logs but I don't know what server response you are expecting.

                  The RestHandler Post/Respons related to the ds containing the Date field:

                  Headers
                  Code:
                  Response Headers
                  Cache-Control	no-cache
                  Content-Type	application/json; charset=UTF-8
                  Expires	Tue, 25 Dec 2012 20:09:38 GMT
                  Pragma	no-cache
                  Server	Jetty(6.1.x)
                  Transfer-Encoding	chunked
                  X-Included-Test	true
                  X-Included-Test2	true
                  Request Headers
                  Accept	application/json,*/*
                  Accept-Encoding	gzip, deflate
                  Accept-Language	en-US,en;q=0.5
                  Connection	keep-alive
                  Content-Length	328
                  Content-Type	application/json;charset=UTF-8
                  Cookie	isc_cState=ready; JSESSIONID=1gyf1x780l67l
                  Host	127.0.0.1:8888
                  Referer	http://127.0.0.1:8888/MOON_MOBILE.html?gwt.codesvr=127.0.0.1:9997
                  User-Agent	Mozilla/5.0 (Macintosh; Intel Mac OS X 10.7; rv:17.0) Gecko/20100101 Firefox/17.0

                  Post
                  Code:
                  {"transactionNum":2,"dataSource":"ui_grid_prospects","sortBy":null,"operationType":"fetch","requestId":"2","showPrompt":null,"data":{"_constructor":"AdvancedCriteria","operator":"and","criteria":[{"fieldName":"person_samCode","operator":"equals","value":"cdr"},{"fieldName":"statusIs_final","operator":"equals","value":false}]}}
                  Response
                  Code:
                  {"response":{"data":[{"sectorGroupName":"002 - Pharma","companyName_short":"IDDI","person_samCode":"cdr","statusName":"Wait client","name_short":"CT-FAST Pilot Study","countryCode":"BE","sectorSortkey":2,"statusDate_close":"2013-03-01","statusCurrency":"€","mobileIcon":"/MOON/images/flags/16x11/BE.png","id":182,"statusIs_final":false,"statusBudget_weighted":2500.0000,"statusLikelihood":0.25,"statusBudget_total":10000.00,"mobileIconDebug":"/images/flags/16x11/BE.png","sectorName":"Pharma","_statusAge":110},{"sectorGroupName":"002 - Pharma","companyName_short":"UCB","person_samCode":"cdr","statusName":"Stretch","name_short":"CT-FAST Consulting","countryCode":"BE","sectorSortkey":2,"statusDate_close":"2013-03-01","statusCurrency":"€","mobileIcon":"/MOON/images/flags/16x11/BE.png","id":286,"statusIs_final":false,"statusBudget_weighted":60000.0000,"statusLikelihood":0.20,"statusBudget_total":300000.00,"mobileIconDebug":"/images/flags/16x11/BE.png","sectorName":"Pharma","_statusAge":88},{"sectorGroupName":"002 - Pharma","companyName_short":"Sanofi","person_samCode":"cdr","statusName":"Wait client","name_short":"CT-FAST Implementation","countryCode":"FR","sectorSortkey":2,"statusDate_close":"2013-01-01","statusCurrency":"€","mobileIcon":"/MOON/images/flags/16x11/FR.png","id":95,"statusIs_final":false,"statusBudget_weighted":105750.0000,"statusLikelihood":0.25,"statusBudget_total":423000.00,"mobileIconDebug":"/images/flags/16x11/FR.png","sectorName":"Pharma","_statusAge":81},{"sectorGroupName":"002 - Pharma","companyName_short":"AstraZeneca","person_samCode":"cdr","statusName":"Reminder","name_short":"CT-FAST Implementation","countryCode":"GB","sectorSortkey":2,"statusDate_close":"2013-01-01","statusCurrency":"€","mobileIcon":"/MOON/images/flags/16x11/GB.png","id":104,"statusIs_final":false,"statusBudget_weighted":0.0000,"statusLikelihood":0.00,"statusBudget_total":470000.00,"mobileIconDebug":"/images/flags/16x11/GB.png","sectorName":"Pharma","_statusAge":99},{"sectorGroupName":"002 - Pharma","companyName_short":"Mundi","person_samCode":"cdr","statusName":"Stretch","name_short":"CT-FAST Pilot Study","countryCode":"GB","sectorSortkey":2,"statusDate_close":"2013-06-01","statusCurrency":"€","mobileIcon":"/MOON/images/flags/16x11/GB.png","id":211,"statusIs_final":false,"statusBudget_weighted":3600.0000,"statusLikelihood":0.15,"statusBudget_total":24000.00,"mobileIconDebug":"/images/flags/16x11/GB.png","sectorName":"Pharma","_statusAge":110},{"sectorGroupName":"002 - Pharma","companyName_short":"Teva","person_samCode":"cdr","statusName":"Stretch","name_short":"CT-FAST Implementation","countryCode":"IL","sectorSortkey":2,"statusDate_close":"2013-03-01","statusCurrency":"$","mobileIcon":"/MOON/images/flags/16x11/IL.png","id":188,"statusIs_final":false,"statusBudget_weighted":58950.0000,"statusLikelihood":0.15,"statusBudget_total":393000.00,"mobileIconDebug":"/images/flags/16x11/IL.png","sectorName":"Pharma","_statusAge":53},{"sectorGroupName":"002 - Pharma","companyName_short":"Almac","person_samCode":"cdr","statusName":"Stretch","name_short":"CT-FAST Pay-per-Use","countryCode":"US","sectorSortkey":2,"statusDate_close":"2013-04-04","statusCurrency":"$","mobileIcon":"/MOON/images/flags/16x11/US.png","id":94,"statusIs_final":false,"statusBudget_weighted":22500.0000,"statusLikelihood":0.05,"statusBudget_total":450000.00,"mobileIconDebug":"/images/flags/16x11/US.png","sectorName":"Pharma","_statusAge":53},{"sectorGroupName":"002 - Pharma","companyName_short":"Astellas","person_samCode":"cdr","statusName":"Stretch","name_short":"CT-FAST Implementation","countryCode":"US","sectorSortkey":2,"statusDate_close":"2013-06-01","statusCurrency":"$","mobileIcon":"/MOON/images/flags/16x11/US.png","id":297,"statusIs_final":false,"statusBudget_weighted":66150.0000,"statusLikelihood":0.15,"statusBudget_total":441000.00,"mobileIconDebug":"/images/flags/16x11/US.png","sectorName":"Pharma","_statusAge":41},{"sectorGroupName":"002 - Pharma","companyName_short":"Dainippon","person_samCode":"cdr","statusName":"Reminder","name_short":"CT-FAST Implementation","countryCode":"US","sectorSortkey":2,"statusDate_close":"2013-01-15","statusCurrency":"$","mobileIcon":"/MOON/images/flags/16x11/US.png","id":64,"statusIs_final":false,"statusBudget_weighted":0.0000,"statusLikelihood":0.00,"statusBudget_total":290000.00,"mobileIconDebug":"/images/flags/16x11/US.png","sectorName":"Pharma","_statusAge":42},{"sectorGroupName":"002 - Pharma","companyName_short":"Fisher","person_samCode":"cdr","statusName":"Wait client","name_short":"CT-FAST Consulting","countryCode":"US","sectorSortkey":2,"statusDate_close":"2012-12-01","statusCurrency":"$","mobileIcon":"/MOON/images/flags/16x11/US.png","id":288,"_warnings":1,"statusIs_final":false,"statusBudget_weighted":56250.0000,"statusLikelihood":0.25,"statusBudget_total":225000.00,"mobileIconDebug":"/images/flags/16x11/US.png","sectorName":"Pharma","_statusAge":42},{"sectorGroupName":"002 - Pharma","companyName_short":"GSK Pharma","person_samCode":"cdr","statusName":"Stretch","name_short":"CT-FAST Implementation","countryCode":"US","sectorSortkey":2,"statusDate_close":"2013-01-01","statusCurrency":"$","mobileIcon":"/MOON/images/flags/16x11/US.png","id":287,"statusIs_final":false,"statusBudget_weighted":121800.0000,"statusLikelihood":0.20,"statusBudget_total":609000.00,"mobileIconDebug":"/images/flags/16x11/US.png","sectorName":"Pharma","_statusAge":53},{"sectorGroupName":"002 - Pharma","companyName_short":"Lilly","person_samCode":"cdr","statusName":"Wait client","name_short":"CT-FAST Enhancements","countryCode":"US","sectorSortkey":2,"statusDate_close":"2013-06-01","statusCurrency":"$","mobileIcon":"/MOON/images/flags/16x11/US.png","id":236,"statusIs_final":false,"statusBudget_weighted":62100.0000,"statusLikelihood":0.30,"statusBudget_total":207000.00,"mobileIconDebug":"/images/flags/16x11/US.png","sectorName":"Pharma","_statusAge":43},{"sectorGroupName":"002 - Pharma","companyName_short":"Otsuka","person_samCode":"cdr","statusName":"Wait client","name_short":"CT-FAST SaaS","countryCode":"US","sectorSortkey":2,"statusDate_close":"2012-12-01","statusCurrency":"$","mobileIcon":"/MOON/images/flags/16x11/US.png","id":274,"_warnings":1,"statusIs_final":false,"statusBudget_weighted":191288.0000,"statusLikelihood":0.40,"statusBudget_total":478220.00,"mobileIconDebug":"/images/flags/16x11/US.png","sectorName":"Pharma","_statusAge":53},{"sectorGroupName":"002 - Pharma","companyName_short":"Takeda","person_samCode":"cdr","statusName":"Unrated","name_short":"Study on enrollment","countryCode":"US","sectorSortkey":2,"statusDate_close":"2013-01-01","statusCurrency":"$","mobileIcon":"/MOON/images/flags/16x11/US.png","id":289,"statusIs_final":false,"statusBudget_weighted":120.0000,"statusLikelihood":0.04,"statusBudget_total":3000.00,"mobileIconDebug":"/images/flags/16x11/US.png","sectorName":"Pharma","_statusAge":53}],"endRow":14,"invalidateCache":false,"isDSResponse":true,"operationType":"fetch","queueStatus":0,"startRow":0,"status":0,"totalRows":14}}
                  The Response from the datasource load (when statusDate_close is set to text instead of date, no problem):
                  Code:
                  if (window.isc == undefined || window.isc.DataSource == undefined){  alert("Can't load DataSources - SmartClient runtime not loaded");}isc.DataSource.create({
                      allowAdvancedCriteria:true,
                      tableCode:"114a4fdae7f4c701620d878350a9ff47",
                      ID:"ui_grid_prospects",
                      fields:[
                          {
                              title:"Id",
                              hidden:true,
                              columnCode:"b80bb7740288fda1f201890375a60c8f",
                              primaryKey:true,
                              name:"id",
                              type:"sequence"
                          },
                          {
                              title:"Group name",
                              columnCode:"e498428107c1283fe7df75439b35e3e1",
                              name:"sectorGroupName",
                              type:"text"
                          },
                          {
                              title:"Short name",
                              columnCode:"35c275a815db788a3016ce2f041ed6b1",
                              name:"name_short",
                              type:"text"
                          },
                          {
                              title:"Status",
                              columnCode:"68e1d769a1b319e0dfdba9e9e6923dab",
                              name:"statusName",
                              type:"text"
                          },
                          {
                              title:"BD",
                              columnCode:"5a7ed46b08a2c49c5379482ac0465e00",
                              name:"person_samCode",
                              type:"text"
                          },
                          {
                              title:"Company",
                              columnCode:"49aaf329e9140c17202dc0f8ea875d2a",
                              name:"companyName_short",
                              type:"text"
                          },
                          {
                              title:"Flag",
                              columnCode:"ea549dee5d7749e80313058a5ea3ff96",
                              name:"countryCode",
                              type:"text"
                          },
                          {
                              title:"Lkh",
                              columnCode:"02bd520d8a0c1fe68222ec336c321650",
                              name:"statusLikelihood",
                              type:"double"
                          },
                          {
                              title:"Date",
                              columnCode:"b12006e42e86b5a04a1670979f3938d4",
                              name:"statusDate_close",
                              type:"date"
                          },
                          {
                              title:"Budget",
                              columnCode:"dee2b72575c52108179c823cdd2d7b88",
                              name:"statusBudget_total",
                              type:"double"
                          },
                          {
                              title:"Budget wgt",
                              hidden:true,
                              columnCode:"607f0d913740c9e82c545df367683a3e",
                              name:"statusBudget_weighted",
                              type:"double"
                          },
                          {
                              title:"¤",
                              columnCode:"297220eb60e963a077ef3af69382bf56",
                              name:"statusCurrency",
                              type:"text"
                          },
                          {
                              title:"Sector",
                              columnCode:"b464920f08671ac4ff89564aa75f3383",
                              name:"sectorName",
                              type:"text"
                          },
                          {
                              title:"Sector sortkey",
                              hidden:true,
                              columnCode:"1a485061102fa5e670d34324228825d6",
                              name:"sectorSortkey",
                              type:"integer"
                          },
                          {
                              title:"F",
                              columnCode:"b7f1f1990fb2f2c07c53733530873ecc",
                              name:"statusIs_final",
                              type:"boolean"
                          },
                          {
                              title:"!",
                              columnCode:"d87a01f066845994c2b073eb8a94d627",
                              name:"_warnings",
                              type:"integer"
                          },
                          {
                              title:"°",
                              columnCode:"3ef477cfa5fd71acfa8a51c690671b9c",
                              name:"_temperature",
                              type:"text"
                          },
                          {
                              title:"Age",
                              columnCode:"6627129197f3fefd371b8c6f8f5b3f74",
                              name:"_statusAge",
                              type:"integer"
                          },
                          {
                              title:"Icon",
                              columnCode:"4a9912d9eb99c29c626e86ed1f63c001",
                              name:"mobileIcon",
                              type:"text"
                          },
                          {
                              title:"Icon",
                              columnCode:"cc9795b764f2a82cad0a6810051d72d3",
                              name:"mobileIconDebug",
                              type:"text"
                          }
                      ],
                      serverType:"sql"
                  })
                  The Development Mode Log of Eclipse (where the exception appears):
                  Code:
                  21:09:38.519 [ERROR] [moon_mobile] Uncaught exception escaped
                  com.google.gwt.core.client.JavaScriptException: (null): null
                      at com.google.gwt.dev.shell.BrowserChannelServer.invokeJavascript(BrowserChannelServer.java:248)
                      at com.google.gwt.dev.shell.ModuleSpaceOOPHM.doInvoke(ModuleSpaceOOPHM.java:136)
                      at com.google.gwt.dev.shell.ModuleSpace.invokeNative(ModuleSpace.java:561)
                      at com.google.gwt.dev.shell.ModuleSpace.invokeNativeObject(ModuleSpace.java:269)
                      at com.google.gwt.dev.shell.JavaScriptHost.invokeNativeObject(JavaScriptHost.java:91)
                      at com.smartgwt.mobile.client.util.DateUtil.parseInput(DateUtil.java)
                      at com.smartgwt.mobile.client.data.SimpleType$3.parseInput(SimpleType.java:161)
                      at com.smartgwt.mobile.client.data.SimpleType$3.parseInput(SimpleType.java:1)
                      at com.smartgwt.mobile.client.data.SimpleType._fromVal(SimpleType.java:217)
                      at com.smartgwt.mobile.client.data.DataSource.extractRecord(DataSource.java:873)
                      at com.smartgwt.mobile.client.data.DataSource.extractRecordList(DataSource.java:919)
                      at com.smartgwt.mobile.client.data.DataSource.extractRecordList(DataSource.java:736)
                      at com.smartgwt.mobile.client.data.DataSource$1.onResponseReceived(DataSource.java:1351)
                      at com.google.gwt.http.client.Request.fireOnResponseReceived(Request.java:287)
                      at com.google.gwt.http.client.RequestBuilder$1.onReadyStateChange(RequestBuilder.java:395)
                      at sun.reflect.GeneratedMethodAccessor189.invoke(Unknown Source)
                      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
                      at java.lang.reflect.Method.invoke(Method.java:597)
                      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:337)
                      at com.google.gwt.dev.shell.BrowserChannelServer.invokeJavascript(BrowserChannelServer.java:218)
                      at com.google.gwt.dev.shell.ModuleSpaceOOPHM.doInvoke(ModuleSpaceOOPHM.java:136)
                      at com.google.gwt.dev.shell.ModuleSpace.invokeNative(ModuleSpace.java:561)
                      at com.google.gwt.dev.shell.ModuleSpace.invokeNativeObject(ModuleSpace.java:269)
                      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:213)
                      at sun.reflect.GeneratedMethodAccessor188.invoke(Unknown Source)
                      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
                      at java.lang.reflect.Method.invoke(Method.java:597)
                      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:292)
                      at com.google.gwt.dev.shell.BrowserChannelServer.processConnection(BrowserChannelServer.java:546)
                      at com.google.gwt.dev.shell.BrowserChannelServer.run(BrowserChannelServer.java:363)
                      at java.lang.Thread.run(Thread.java:680)

                  Appart this exception in Eclipse, there are no error in the console log of Firebug.


                  Here follow the Web Console Log
                  Code:
                  [21:35:18.819] The Web Console logging API (console.log, console.info, console.warn, console.error) has been disabled by a script on this page.
                  [21:35:08.196] Use of Mutation Events is deprecated. Use MutationObserver instead. @ chrome://firebug/content/chrome/tabContext.js:589
                  [21:35:10.365] Error in parsing value for 'display'.  Declaration dropped. @ http://127.0.0.1:8888/MOON_MOBILE.html?gwt.codesvr=127.0.0.1:9997#Prospects:17
                  [21:35:10.365] Unknown property 'box-orient'.  Declaration dropped. @ http://127.0.0.1:8888/MOON_MOBILE.html?gwt.codesvr=127.0.0.1:9997#Prospects:30
                  [21:35:10.365] Unknown property 'box-pack'.  Declaration dropped. @ http://127.0.0.1:8888/MOON_MOBILE.html?gwt.codesvr=127.0.0.1:9997#Prospects:46
                  [21:35:10.365] Unknown property 'box-flex'.  Declaration dropped. @ http://127.0.0.1:8888/MOON_MOBILE.html?gwt.codesvr=127.0.0.1:9997#Prospects:64
                  [21:35:10.365] Unknown property 'box-direction'.  Declaration dropped. @ http://127.0.0.1:8888/MOON_MOBILE.html?gwt.codesvr=127.0.0.1:9997#Prospects:69
                  [21:35:10.365] Unknown property 'box-align'.  Declaration dropped. @ http://127.0.0.1:8888/MOON_MOBILE.html?gwt.codesvr=127.0.0.1:9997#Prospects:99
                  [21:35:10.365] Unknown property 'box-sizing'.  Declaration dropped. @ http://127.0.0.1:8888/MOON_MOBILE.html?gwt.codesvr=127.0.0.1:9997#Prospects:142
                  [21:35:10.367] Error in parsing value for 'background-image'.  Declaration dropped. @ http://127.0.0.1:8888/MOON_MOBILE.html?gwt.codesvr=127.0.0.1:9997#Prospects:1
                  [21:35:10.367] Unknown property '-moz-border-radius'.  Declaration dropped. @ http://127.0.0.1:8888/MOON_MOBILE.html?gwt.codesvr=127.0.0.1:9997#Prospects:1
                  [21:35:10.367] Unknown property '-moz-box-shadow'.  Declaration dropped. @ http://127.0.0.1:8888/MOON_MOBILE.html?gwt.codesvr=127.0.0.1:9997#Prospects:1
                  [21:35:10.367] Error in parsing value for 'background'.  Declaration dropped. @ http://127.0.0.1:8888/MOON_MOBILE.html?gwt.codesvr=127.0.0.1:9997#Prospects:1
                  [21:35:10.459] Expected color but found 'top'.  Error in parsing value for 'background-image'.  Declaration dropped. @ http://127.0.0.1:8888/MOON_MOBILE.html?gwt.codesvr=127.0.0.1:9997#Prospects:24
                  [21:35:10.471] Unknown property '-moz-background-size'.  Declaration dropped. @ http://127.0.0.1:8888/MOON_MOBILE.html?gwt.codesvr=127.0.0.1:9997#Prospects:1
                  [21:35:10.471] Unknown property 'mask-position'.  Declaration dropped. @ http://127.0.0.1:8888/MOON_MOBILE.html?gwt.codesvr=127.0.0.1:9997#Prospects:1
                  [21:35:10.471] Unknown property 'mask-size'.  Declaration dropped. @ http://127.0.0.1:8888/MOON_MOBILE.html?gwt.codesvr=127.0.0.1:9997#Prospects:1
                  [21:35:10.471] Unknown property '-moz-mask-position'.  Declaration dropped. @ http://127.0.0.1:8888/MOON_MOBILE.html?gwt.codesvr=127.0.0.1:9997#Prospects:1
                  [21:35:10.471] Unknown property '-moz-mask-size'.  Declaration dropped. @ http://127.0.0.1:8888/MOON_MOBILE.html?gwt.codesvr=127.0.0.1:9997#Prospects:1
                  [21:35:10.471] Error in parsing value for 'background-clip'.  Declaration dropped. @ http://127.0.0.1:8888/MOON_MOBILE.html?gwt.codesvr=127.0.0.1:9997#Prospects:1
                  [21:35:10.471] Unknown property '-moz-background-clip'.  Declaration dropped. @ http://127.0.0.1:8888/MOON_MOBILE.html?gwt.codesvr=127.0.0.1:9997#Prospects:1
                  [21:35:10.471] Error in parsing value for '-moz-box-align'.  Declaration dropped. @ http://127.0.0.1:8888/MOON_MOBILE.html?gwt.codesvr=127.0.0.1:9997#Prospects:1
                  [21:35:10.471] Unknown property '-moz-tap-highlight-color'.  Declaration dropped. @ http://127.0.0.1:8888/MOON_MOBILE.html?gwt.codesvr=127.0.0.1:9997#Prospects:1
                  [21:35:10.471] Unknown property 'tap-highlight-color'.  Declaration dropped. @ http://127.0.0.1:8888/MOON_MOBILE.html?gwt.codesvr=127.0.0.1:9997#Prospects:1
                  [21:35:10.471] Unknown property 'user-select'.  Declaration dropped. @ http://127.0.0.1:8888/MOON_MOBILE.html?gwt.codesvr=127.0.0.1:9997#Prospects:1
                  [21:35:10.474] Unknown property 'heigth'.  Declaration dropped. @ http://127.0.0.1:8888/MOON_MOBILE.html?gwt.codesvr=127.0.0.1:9997#Prospects:1
                  [21:35:10.526] Unknown property '-moz-margin-top-collapse'.  Declaration dropped. @ http://127.0.0.1:8888/MOON_MOBILE.html?gwt.codesvr=127.0.0.1:9997#Prospects:1
                  [21:35:10.526] Unknown property '-moz-margin-bottom-collapse'.  Declaration dropped. @ http://127.0.0.1:8888/MOON_MOBILE.html?gwt.codesvr=127.0.0.1:9997#Prospects:1
                  [21:35:10.526] Unknown property 'margin-top-collapse'.  Declaration dropped. @ http://127.0.0.1:8888/MOON_MOBILE.html?gwt.codesvr=127.0.0.1:9997#Prospects:1
                  [21:35:10.526] Unknown property 'margin-bottom-collapse'.  Declaration dropped. @ http://127.0.0.1:8888/MOON_MOBILE.html?gwt.codesvr=127.0.0.1:9997#Prospects:1

                  Comment


                    #10
                    Based on the stacktrace, you should be able to narrow down the issue by setting a breakpoint at com.smartgwt.mobile.client.util.DateUtil.parseInput(..) or SimpleType.java:161 to see what input data is causing the subsequent exception.

                    Comment


                      #11
                      Ok, based on the comment of Sjivan, I have included all java files of smartgwt-mobile.jar inside my project in order to be able to set a breakpoint.

                      the exception is generated by the command (SimpleType:161):
                      return DateUtil.parseInput(text);
                      where text is "2013-03-01"

                      I cannot set a breakpoint deeper (in parseInput), but if you simply execute the command DateUtil.parseInput("2013-03-01") in any smartgwt-mobile project you should hopefully get the error.

                      Thanks.

                      Comment


                        #12
                        Since this problem was not there in version 2012-12-19 and before, I compared the DateUtil and SimpleType classes between 2012-12-19 and 2012-12-24 and there is a difference:

                        In 2012-12-19 DateUtil did not contain the method

                        Code:
                            public static native LogicalDate parseInput(String dateString) /*-{
                                if (null == dateString) return null;
                                var parts = (dateString.@java.lang.String::trim()()).split(/\s*[-. ]\s*(?:)/);
                                if (null == parts || 3 != parts.length) return null;
                                var year = parseInt(parts[0], 10),
                                    month = parseInt(parts[1], 10),
                                    date = parseInt(parts[2], 10);
                                if (isNaN(year) || isNaN(month) || isNaN(date)) return null;
                                month = Math.max(0, Math.min(month - 1, 11));
                                date = Math.max(1, Math.min(date, 31));
                                return @com.smartgwt.mobile.client.util.LogicalDate::new(III)(year, month, date);
                            }-*/;
                        And dateType in SimpleType was initialized a different way.


                        Difficult to narrow down more than that. Hope this will help.

                        In the meantime I have found another workaround than type="text". Declaring the field in the ds as type="datetime" solves the issue. Yet the field is a Date not a DATETIME in the DB.
                        Last edited by bda@n-side.com; 27 Dec 2012, 04:24.

                        Comment


                          #13
                          Any feedback on this ? Is declaring the SQL DATE field as datetime type in ds.xml the expected solution, I suppose no ?

                          Thanks, Ben.

                          Comment


                            #14
                            We can't reproduce this, but we did switch the implementation of the date parsing to pure Java (it didn't need to be in JavaScript any more as of other recent changes), so you should be able to get a more exact error message even if you're unfamiliar with JS debug tools.

                            Comment


                              #15
                              No error anymore. Thanks!

                              Comment

                              Working...
                              X