#30171: Fix DatabaseError threading error during servers tests
-------------------------------------+-------------------------------------
     Reporter:  Jon Dufresne         |                    Owner:  nobody
         Type:                       |                   Status:  closed
  Cleanup/optimization               |
    Component:  Database layer       |                  Version:  2.2
  (models, ORM)                      |
     Severity:  Normal               |               Resolution:  fixed
     Keywords:                       |             Triage Stage:  Ready for
                                     |  checkin
    Has patch:  1                    |      Needs documentation:  0
  Needs tests:  0                    |  Patch needs improvement:  0
Easy pickings:  0                    |                    UI/UX:  0
-------------------------------------+-------------------------------------

Comment (by Chris Jerdonek):

 I'm seeing in Django 2.2.17 what looks like the reappearance of #22414
 after it being fixed in 1.11. There don't seem to be a whole lot of
 changes in the LiveServerTestCase-related code between those two versions
 of Django.

 I'm wondering if it's possible this commit explains it:
 
https://github.com/django/django/commit/37cc6a9dce3354cd37f23ee972bc25b0e5cebd5c

 For example, was it intentional that this SQLite-specific condition (`if
 conn.vendor == 'sqlite' and conn.is_in_memory_db():`) was removed from
 `_tearDownClassInternal()`, even though it's still in `setUpClass()`?

 Also, for reasons of symmetry with `setUpClass()`, it doesn't seem like
 those connection restore lines should have been moved beneath the `if
 hasattr(cls, 'server_thread'):` condition. Basically, it looks like a
 couple lines were deleted, perhaps by accident.

-- 
Ticket URL: <https://code.djangoproject.com/ticket/30171#comment:6>
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 on the web visit 
https://groups.google.com/d/msgid/django-updates/067.ce7cc05deea4e641e857aac857c7b8e7%40djangoproject.com.

Reply via email to