flask-rq icon indicating copy to clipboard operation
flask-rq copied to clipboard

Being able to submit jobs without pushing the context around

Open Auha opened this issue 11 years ago • 3 comments
trafficstars

So I end up having to create an app context in order to do any jobs. I was wondering if it were possible to automatically include the app context.

I have to do this often

@job
def random():
    with app.app_context():
        x = 1 + 1

I would prefer to not have to type the

with app.app_context():

Auha avatar Sep 25 '14 04:09 Auha

+1

phalgun avatar Feb 26 '15 06:02 phalgun

+1

Sure, auto create app context (passing config) will be nice.

zxygentoo avatar Jan 31 '16 11:01 zxygentoo

#27

joostdevries avatar May 12 '16 20:05 joostdevries