I have added support to cancel long running transaction with asynchronous connection support. Attached is the modified patch, please review it and if looks good then please commit the code.
I have added logic to support asynchronous connection in psycopg2. This functionality will be required for the Debugger module, so sending the patch. Attached is the patch file, please review it and let me know the comments if any. If it looks good then please commit the code.