i can't understand why this scheduled task always fails.
*It sems something related to the command commit().*
But without it no changes are saved in the db.
The same function without the commit command works fine in a controller
The code is the following:

db.py
db.define_table('test',
    Field('tempo','datetime',default=request.now),
    Field('nome','string')
               )

scheduler,py
def func1():
    db.test.insert(nome='func1')
    db.commint()

from gluon.scheduler import Scheduler
import datetime
scheduler= Scheduler(db,tasks=dict(test1=func1))

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to