Seems I spoke too fast, it doesn't just work.

The problem is if a transaction fails, in my case for IntegrityError. I catch the transaction and act accordingly, even using savepoints (transaction.savepoint()) to rollback only the innermost changes that caused the failure, start new transaction but it fails with:


TransactionFailedError: An operation previously failed, with traceback




.oO V Oo.


On 11/13/2011 01:37 PM, Vlad K. wrote:

How dumb of me for not trying that... thanks! It seems it also works for transaction.abort(), except that invalidates previous session altogether.


.oO V Oo.


On 11/13/2011 08:44 AM, Malthe Borch wrote:
On 12 November 2011 01:07, Vlad K.<[email protected]>  wrote:
Is it possible to have multiple transactions within a request, and how to
start new one after transaction.commit() is manually invoked?
A new one is always started after a call to commit(). In other words:
it just works.

\malthe



--
You received this message because you are subscribed to the Google Groups 
"pylons-discuss" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/pylons-discuss?hl=en.

Reply via email to