Hi there,

Django's TransactionMiddleware only rolls back the transaction if an exception 
is raised in a view. If a view doesn't raise an exception, but returns (say) a 
500 response directly, the transaction goes ahead and commits.

I noticed this while using Piston, and there's a thread about it here:

  
http://groups.google.com/group/django-piston/browse_thread/thread/2958a12d74a323fa/f4a0192943e7cddd

Is Django's behaviour here a design decision - that views should not return 500 
responses directly, but raise exceptions - or is this an omission in the 
TransactionMiddleware?

Cheers,
Dan
--
Dan Fairs <d...@fezconsulting.com> | http://www.fezconsulting.com/

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.

Reply via email to