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
With django now supporting async, should we be trying to import asgiref.local.Local if available, which is a drop-in async replacement for threading.local?
Perhaps replacing:
from threading import local
With:
try:
from asgiref.local import Local as local
except ImportError:
from threading import local
Would be happy to make a PR for this, but not sure how to approach the situation where asgiref package is available vs when it is not.
The text was updated successfully, but these errors were encountered:
With django now supporting async, should we be trying to import asgiref.local.Local if available, which is a drop-in async replacement for threading.local?
Perhaps replacing:
from threading import local
With:
try:
from asgiref.local import Local as local
except ImportError:
from threading import local
Would be happy to make a PR for this, but not sure how to approach the situation where asgiref package is available vs when it is not.
The text was updated successfully, but these errors were encountered: