Can you show us the model and attributes of db.team.
I suspect db.team.mDate is missing a writable=False, readable=False
which you need since it is a computed field.


On Feb 3, 10:59 am, Carl <carl.ro...@gmail.com> wrote:
> MainThread - pid4460_seq4
>         update [gql.py:696]
>         update_record [sql.py:3232]
>         <lambda> [sql.py:3109]
>         update [subscription.py:65]
>         update_team [default.py:call:68]
>         serve_jsonrpc [tools.py:2560]
>         __call__ [tools.py:2646]
>         call [default.py:call:594]
>         <lambda> [globals.py:96]
>         <module> [default.py:call:764]
>         restricted [restricted.py:173]
>         run_controller_in [compileapp.py:426]
>         serve_controller [main.py:193]
>         wsgibase [main.py:478]
>         wsgiapp [gaehandler.py:71]
>         newfun [gaehandler.py:51]
>         run [handlers.py:92]
>         main [gaehandler.py:85]
>         ExecuteOrImportScript [dev_appserver.py:2187]
>         ExecuteCGI [dev_appserver.py:2289]
>         Dispatch [dev_appserver.py:2379]
>         Dispatch [dev_appserver.py:515]
>         _Dispatch [dev_appserver.py:3120]
>         _HandleRequest [dev_appserver.py:3177]
>         do_POST [dev_appserver.py:3069]
>         handle_one_request [BaseHTTPServer.py:310]
>         handle [BaseHTTPServer.py:316]
>         __init__ [SocketServer.py:522]
>         __init__ [dev_appserver.py:3057]
>         finish_request [SocketServer.py:254]
>         process_request [SocketServer.py:241]
>         handle_request [SocketServer.py:222]
>         serve_forever [SocketServer.py:201]
>         main [dev_appserver_main.py:402]
>         <module> [dev_appserver_main.py:417]
>         run_file [dev_appserver.py:63]
>         <module> [dev_appserver.py:67]
>         run [pydevd.py:780]
>         <module> [pydevd.py:953]
>
> #from a function in default.py
> (id, name, quota, users, usage) = team.update(auth.user.id, id, name)
> # Line68
>
> # from subscription.py.
>     def update(self, ownerId, teamId, name):
>         q = (self.db.team.owner_user_id == ownerId) \
>             & (self.db.team.id == teamId)
>         rows = self.db(q).select(self.db.team.ALL)
>
>         if rows:
>             rows[0].update_record(#name=name,    # note I've commented
> out this parameter to reproduce behavior
>                                   credit_quota=quota,
>                                   mDate=now) # *** Line 65 ***
>
> On Feb 3, 3:51 pm, mdipierro <mdipie...@cs.depaul.edu> wrote:
>
> > what is the traceback?
>
> > On Feb 3, 6:59 am, Carl <carl.ro...@gmail.com> wrote:
>
> > > Given:
> > > - a define_table() with a field as "compute=lambda r:r['name'].lower
> > > ()"
> > > - that I call update_record() on a row returned from a select.
>
> > > when I test on dev_appserver I need to include name as a parameter to
> > > update_record() otherwise an exception is thrown by Set.update(self,
> > > **update_fields) in gql.py (line 696)
>
> > > I post this for the record for anyone using GAE and update_record()
> > > rather than a call to action.
>
> > > I'm using Web2py 1.74.6
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To post to this group, send email to web...@googlegroups.com.
To unsubscribe from this group, send email to 
web2py+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/web2py?hl=en.

Reply via email to