supertokens-python icon indicating copy to clipboard operation
supertokens-python copied to clipboard

Asyncio issue with flask when run with eventlet or greenlet

Open sattvikc opened this issue 1 year ago • 0 comments

Steps to reproduce:

  • Create a supertokens app using python flask framework.
  • run the generated backend using gunicorn + eventlet gunicorn app:app -k eventlet --timeout 1000 -w 1 --bind 0.0.0.0:3001
  • Update Call API to make multiple requests in parallel

Some of the requests will fail with 500 error stating Event loop is already running

We might need to implement a separate middleware for flask to support asyncio.

sattvikc avatar Oct 07 '24 10:10 sattvikc