Scheduler and pool.apply_async in frappe

Hi ,
We have a function ‘A’ calling pool.apply_async(f, args = (count, )).
It is working fine if we call directly as an API, but if we call function A from scheduler ‘pool.apply_async’ is not working.Need help to solve this.

Can you share the full code

Thank you for reply.

‘asymethod’ called from Scheduler …

def asymethod():
    pool = Pool(processes=1)
    result = pool.apply_async(testFun, args = (count, ))

def testFun():
    my_sql="update `tabSomeTable` set complete='121'"

I am not sure what are you trying to do here. If you want to push something to the background try frappe.enqueue