# HG changeset patch # User Sylvain Thénault # Date 1265785673 -3600 # Node ID 85116e75f5611c7686b2e844435858d3a2805df0 # Parent 530a5997d51b82d5afc7b32667b6a6cbaaba4a41 fix auto-rollback on unauthorized error: * don't rollback if a commit is processing * don't free pool on rollback diff -r 530a5997d51b -r 85116e75f561 server/querier.py --- a/server/querier.py Wed Feb 10 08:06:02 2010 +0100 +++ b/server/querier.py Wed Feb 10 08:07:53 2010 +0100 @@ -666,7 +666,14 @@ # the session). Even though, this is done here for a better # consistency: getting an Unauthorized exception means the # transaction has been rollbacked - session.rollback() + # + # notes: + # * we should not reset the pool here, since we don't want the + # session to loose its pool during processing + # * don't rollback if we're in the commit process, will be handled + # by the session + if session.commit_state is None: + session.rollback(reset_pool=False) raise # build a description for the results if necessary descr = ()