include rollback exception in closed transaction context manager error message
Improved the error message raised when a Session is used inside a context
manager after the transaction has been rolled back due to an exception.
The InvalidRequestError now includes the original exception that triggered
the rollback, making it clearer why the transaction is no longer active.
Pull request courtesy Ilan Keshet.
Closes: #11297
Pull-request: https://github.com/sqlalchemy/sqlalchemy/pull/11297
Pull-request-sha:
9feb9658078e1acfbeed29a119c9765cf684f677
Change-Id: If4ee3e9f673adfec533726b9b4d5c125dfcf2b9c