Ok If I understand you correctly, I should only instantiate one Scheduler in the App and the Tasks should be defined in the models of the plugins. ( I was instantiating a Scheduler() in each plugin)
If I define taskA() in a model called plugin_A.py and taskB() in a model plugin_B.py then I try to instantiate the scheduler in the App using : from gluon.scheduler import Scheduler Scheduler(db,dict(A=taskA,B=taskB)) I get an error in the App Model 'TaskA is not defined' Thanks for your help. On Wednesday, December 16, 2015 at 3:00:15 PM UTC-5, Niphlod wrote: > > This is definitely weird. > Unless you're plugins that carry themselves the instantiation of the > Scheduler AND the definition of tasks: there should be only ONE scheduler > instance (because it's thought as a singleton) and tasks definitions should > be available on models .... so they'd be available to the app and will be > executed without issues. > > On Wednesday, December 16, 2015 at 11:33:51 AM UTC+1, > mi...@thesmartcone.com wrote: >> >> I have 2 different plugins that currently use Web2Py Scheduler. They both >> work when they are installed in an App separately. If they are both >> isnstalled in the same App only one of the plugins scheduled tasks get run. >> (The one with the last loaded model alphabetically). Can someone point me >> in the right direction to get this working? >> >> Thanks, >> >> Mike >> > -- 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 web2py+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.