You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Handling of RQ_ASYNC is confusing when using the application factory pattern #81
When using the application factory pattern, the RQ_ASYNC configuration is only respected if it has not already been set for the task queue being initialized.
Concrete example to show the behaviour:
rq = RQ() # rq._is_async is set to None
app = Flask(__name__)
app.config['RQ_ASYNC'] = False
rq.init_app(app) # rq._is_async is set to False
app.config['RQ_ASYNC'] = True
rq.init_app(app) # rq._is_async is unchanged
I'm not sure if this is a bug or not - from a look at the code, my guess is that the intention is that RQ_ASYNC does not override constructing the queue with the is_async argument set manually, which seems like a sensible stance. However, it does seem a bit strange - altering any of the other RQ_X options will take effect on a re-init.
Activity