#36942: SimpleTestCase._remove_databases_failures() is not idempotent and 
crashes
on complex MRO.
-----------------------------------+---------------------------------------
     Reporter:  Michele Fiori      |                    Owner:  michele0303
         Type:  Bug                |                   Status:  closed
    Component:  Testing framework  |                  Version:  6.0
     Severity:  Normal             |               Resolution:  needsinfo
     Keywords:                     |             Triage Stage:  Unreviewed
    Has patch:  1                  |      Needs documentation:  0
  Needs tests:  1                  |  Patch needs improvement:  0
Easy pickings:  0                  |                    UI/UX:  0
-----------------------------------+---------------------------------------
Comment (by Rio Weber):

 Filed #37064 with diff + tests , should cover the needsinfo close.

 Minimal pytest-django run against a 2-DB SQLite settings triggers it:
 SQLite recycles the connection between setUpClass and tearDownClass, so
 teardown hits a plain function instead of the _DatabaseFailure setup
 installed. Verified on 6.0.3 and main.

 Patch uses isinstance(method, _DatabaseFailure) rather than the hasattr
 check in #20758
 Won't chase third-party .wrapped attrs
-- 
Ticket URL: <https://code.djangoproject.com/ticket/36942#comment:3>
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/0107019dc0f788d5-66555be1-9825-432b-ae9b-b2683ac1d484-000000%40eu-central-1.amazonses.com.

Reply via email to