Can SQLAlchemy be configured to be non-blocking?

You can use SQLA in a non-blocking style using gevent. Here’s an example using psycopg2, using psycopg2’s coroutine support:

https://bitbucket.org/zzzeek/green_sqla/

I’ve also heard folks use the same idea with pymysql. As pymysql is in pure Python and uses the sockets library, gevent patches the socket library to be asynchronous.

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)