#16682: KeyboardInterrupt not handled properly in transaction aborting
-------------------------------------+-------------------------------------
     Reporter:  mtredinnick          |                    Owner:  nobody
         Type:  Bug                  |                   Status:  new
    Milestone:                       |                Component:  Database
      Version:  1.3                  |  layer (models, ORM)
     Keywords:                       |                 Severity:  Normal
    Has patch:  0                    |             Triage Stage:
  Needs tests:  0                    |  Unreviewed
Easy pickings:  0                    |      Needs documentation:  0
                                     |  Patch needs improvement:  0
                                     |                    UI/UX:  0
-------------------------------------+-------------------------------------
 Ticket #6928 was reopened to report this, so I (Malcolm) am moving it to a
 new ticket, since it's a separate issue. Following text is from comment:7
 on that ticket:

 ---

 After [14288] transaction.commit_on_success does not handle
 `KeyboardInterrupt`.

 Problem in `django.db.transaction.Transaction.__exit__` and default
 `exiting` function.

 {{{#!python
     def __exit__(self, exc_type, exc_value, traceback):
         self.exiting(exc_value, self.using)
 }}}

 `exc_value` is None after `KeyboardInterrupt` has been throwed, only
 `exc_type` and `traceback` has value.
 But if raise `KeyboardInterrupt` manualy from code it's work ok.

 Possible solution: use `exc_type` and `exc_value` in `exiting` function

 I use python 2.6.6

-- 
Ticket URL: <https://code.djangoproject.com/ticket/16682>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

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

Reply via email to