Hi

I have an app I've been working on and upgraded my system to 1.97.1 today. Since then I'm getting the following with an AJAX call for json data:

Traceback(most recent call last):
  File"gluon/restricted.py",line192,inrestricted
  File"C:/dev/web2py/applications/InfoCenter/controllers/administration.py"  
<http://127.0.0.1:8000/admin/default/edit/InfoCenter/controllers/administration.py>,line862,in<module>
  File"gluon/globals.py",line137,in<lambda>
  File"C:/dev/web2py/applications/InfoCenter/controllers/administration.py"  
<http://127.0.0.1:8000/admin/default/edit/InfoCenter/controllers/administration.py>,line17,incall
  File"gluon/tools.py",line3918,in__call__
  File"gluon/tools.py",line3734,inserve_json
  File"gluon/tools.py",line3404,inuniversal_caller
TypeError:object of type'NoneType'has no len()


My call from my template looks like this:

jQuery(document).ready(function(){
  jQuery("#list").jqGrid({
    url:'/InfoCenter/administration/call/json/userList',
    datatype: 'json',
    postData:{'searchText':$("#searchText").val()},
    colModel :[ {
                name:'id',
                index:'id',
                label:'ID',
                hidden:true,
            },
            {
                name:'lastFirst',
                index:'lastFirst',
                width:'50%',
                label:'Name',
            },
            {
                name:'email',
                index:'email',
                width:'50%',
                label:'Email',
            },

    ],
    pager: '#pager',
    rowNum:20,
    sortname: "lastFirst",
    sortorder: 'asc',
    width: 875,
    height: "100%",
    ondblClickRow: function(){
        var row_id = $("#list").getGridParam('selrow');
        window.location.href = "/InfoCenter/administration/user/" + row_id;
        return true;
    },
    caption:'',
  });
  jQuery("#list").navGrid("#pager",
          {edit:false,add:false,del:true,search:false},
          {},
          {},
          {msg:"Delete selected row(s)",
              bSubmit:"Delete",
              bCancel:"Cancel",
              url:"/InfoCenter/administration/userDelete",
              reloadAfterSubmit:true}
      );
});

This works in the 1.96.x branches by not 1.97.1. And, it never gets to the method in the controller. Line in administration.py is the last line of the call() method:

and line 862 doesn't exist in the controller, it ends at 861:


Any thoughts?  I'm stumped (but also pretty new to web2py).

    -Jim

<<inline: dgagieea.png>>

<<inline: ghbgbjgj.png>>

Reply via email to