1. Jesper Noehr
  2. django-piston
  3. Issues
Issue #216 new

transaction handling

Marco De Paoli
created an issue

In the case where an exception is thrown in a method of "create", Piston returns (correctly) 500 status_code, but Django (via the TransactionMiddleware) commits erroneous and potentially inconsistent data.

The problem arises because Piston catches any exception so that TransactionMiddleware's process_exception (which executes the rollback) is not called

The problem is documented also here: http://groups.google.com/group/django-piston/browse_thread/thread/2958a12d74a323fa/a936daec07c01dba?lnk=gst&q=transaction#a936daec07c01dba

Comments (0)

  1. Log in to comment