This is the error ticket: Error traceback 1.Traceback (most recent call last): 2. File "gluon/restricted.py", line 178, in restricted 3. File "C:/Python25/web2py/applications/Alumni/controllers/ default.py", line 55, in <module> 4. File "gluon/globals.py", line 101, in <lambda> 5. File "C:/Python25/web2py/applications/Alumni/controllers/ default.py", line 34, in user 6. File "gluon/tools.py", line 477, in __call__ 7. File "gluon/tools.py", line 827, in login 8. File "gluon/tools.py", line 642, in log_event AttributeError: 'NoneType' object has no attribute 'insert'
(The error below is part of the ticket issued:) In file: C:\Python25\web2py\applications\Alumni/controllers/default.py 1. # coding: utf8 2. 3. ######################################################################### 4. ## This is a samples controller 5. ## - index is the default action of any application . . 46. def call(): 47. """ 48. exposes services. for example: 49. http://..../[app]/default/call/jsonrpc 50. decorate with @services.jsonrpc the functions to expose 51. supports xml, json, xmlrpc, jsonrpc, amfrpc, rss, csv 52. """ 53. session.forget() 54. return service() 55. 56. response._vars=response._caller(user) In default.py source, I cannot find line 56 "response._vars=response._caller(user). It's only found in the error ticket. I'm lost with this. Is there a stable web2py version with auth_user? Thanks On Aug 20, 2:37 pm, Richard <richar...@gmail.com> wrote: > the error is thrown from default.py (line 55), so it might be > unrelated. > Richard > > On Aug 20, 4:25 pm, ed <edbi...@rocketmail.com> wrote: > > > I didn't change the gluon directory and inserted the code below in > > db.py and was able to run the app. I inserted 2 fields and tried to > > run it again but encountered the error ticket below. > > > from gluon.tools import * > > auth=Auth(globals(),db) # authentication/ > > authorization > > auth.settings.hmac_key='<your secret key>' > > #auth.define_tables() # creates all needed > > tables > > auth.settings.table_user = db.define_table("auth_user",db.Field > > ("first_name",length=128,default=""), > > db.Field("last_name", > > length=128,default=""), > > db.Field("email", > > length=128,default=""), > > db.Field > > ("password",'password',readable=False, > > writable=False,label="Password"), > > db.Field("registration_key", length=128, > > writable=False, readable=False, > > default=""), > > db.Field("birthdate", 'date', > > label="Birthdate"), > > db.Field("gender", length=6, default="", > > label="Gender")) > > db.auth_user.password.requires=[] > > ********************************************** > > I got this error ticket. > > Error traceback > > Traceback (most recent call last): > > File "gluon/restricted.py", line 178, in restricted > > File "C:/Python25/web2py/applications/Alumni/controllers/ > > default.py", line 55, in <module> > > File "gluon/globals.py", line 101, in <lambda> > > File "C:/Python25/web2py/applications/Alumni/controllers/ > > default.py", line 34, in user > > File "gluon/tools.py", line 477, in __call__ > > File "gluon/tools.py", line 827, in login > > File "gluon/tools.py", line 642, in log_event > > AttributeError: 'NoneType' object has no attribute 'insert' > > ************************************************ > > I don't know what this message is, can someone give me an idea. Thanks --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@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 -~----------~----~----~----~------~----~------~--~---