Is it possible to get the task id of the current task from within the task?
for example:
def task_add(a,b):
task_id = scheduler.my_id() # get current task id
return a+b
scheduler = Scheduler(db, tasks=dict(demo1=task_add))
scheduler.queue_task('demo1', pvars=dict(a=1,b=2),
riable. So, to get the task id,
task_id = W2P_TASK.id
On Thursday, 29 August 2013 19:14:25 UTC+5:30, Manoj Kumar M wrote:
>
> Is it possible to get the task id of the current task from within the task?
>
> for example:
> def task_add(a,b):
> task_id = scheduler.my_id() # get current ta
2 matches
Mail list logo