#37000: cursor_iter relies on GC for server-side cursor cleanup, causing
transaction abort after savepoint rollback
-------------------------------------+-------------------------------------
     Reporter:  Ratskó László        |                    Owner:  Vidhi
                                     |  Singh
         Type:  Bug                  |                   Status:  assigned
    Component:  Database layer       |                  Version:  4.2
  (models, ORM)                      |
     Severity:  Normal               |               Resolution:
     Keywords:  iterator, server-    |             Triage Stage:  Accepted
  side-cursor, savepoint, psycopg3   |
    Has patch:  0                    |      Needs documentation:  0
  Needs tests:  0                    |  Patch needs improvement:  0
Easy pickings:  0                    |                    UI/UX:  0
-------------------------------------+-------------------------------------
Comment (by Vidhi Singh):

 I’ve worked on this issue and opened a PR to make server-side cursor
 closing more
 resilient when iterator() is interrupted inside transaction.atomic().

 The fix ensures that delayed cursor.close() calls do not raise
 InvalidCursorName
 and break the transaction.

 PR: https://github.com/django/django/pull/XXXX
-- 
Ticket URL: <https://code.djangoproject.com/ticket/37000#comment:8>
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 unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion visit 
https://groups.google.com/d/msgid/django-updates/0107019d2592e44a-39de1fb6-211a-4f0e-92fa-401712ce4b65-000000%40eu-central-1.amazonses.com.

Reply via email to