#24080: Sqlite segmentation fault regression when running tests (since 1.7.2)
-----------------------------------+------------------------------------
     Reporter:  stevejalim         |                    Owner:  nobody
         Type:  Bug                |                   Status:  new
    Component:  Testing framework  |                  Version:  master
     Severity:  Normal             |               Resolution:
     Keywords:  sqlite             |             Triage Stage:  Accepted
    Has patch:  0                  |      Needs documentation:  0
  Needs tests:  0                  |  Patch needs improvement:  0
Easy pickings:  0                  |                    UI/UX:  0
-----------------------------------+------------------------------------

Comment (by tricoder42):

 It's probably related only to Python 2.7.6. In Python 3.4.1 the test case
 runs fine.

 Unfortunately I haven't found the cause of segmentation fault. Here is the
 traceback (begins with the last test case):

 {{{
 SAVEPOINT "s140735267844864_x61"
 test_use_explicit_o2o_to_parent_from_abstract_model
 (model_inheritance_regress.tests.ModelInheritanceTest) ... ok
 ROLLBACK TO SAVEPOINT "s140735267844864_x61"
 Fatal Python error: Segmentation fault

 Current thread 0x00007fff7ba5b300 (most recent call first):
   File
 "/Users/tricoder/Projects/django/django/db/backends/sqlite3/base.py", line
 317 in execute
   File "/Users/tricoder/Projects/django/django/db/backends/utils.py", line
 63 in execute
   File "/Users/tricoder/Projects/django/django/db/backends/base/base.py",
 line 215 in _savepoint_rollback
   File "/Users/tricoder/Projects/django/django/db/backends/base/base.py",
 line 255 in savepoint_rollback
   File "/Users/tricoder/Projects/django/django/db/transaction.py", line
 252 in __exit__
   File "/Users/tricoder/Projects/django/django/test/testcases.py", line
 932 in _rollback_atomics
   File "/Users/tricoder/Projects/django/django/test/testcases.py", line
 988 in _fixture_teardown
   File "/Users/tricoder/Projects/django/django/test/testcases.py", line
 844 in _post_teardown
   File "/Users/tricoder/Projects/django/django/test/testcases.py", line
 184 in __call__
   File
 
"/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/unittest/suite.py",
 line 108 in run
   File
 
"/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/unittest/suite.py",
 line 70 in __call__
   File
 
"/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/unittest/runner.py",
 line 151 in run
   File "/Users/tricoder/Projects/django/django/test/runner.py", line 178
 in run_suite
   File "/Users/tricoder/Projects/django/django/test/runner.py", line 211
 in run_tests
   File "./tests/runtests.py", line 236 in django_tests
   File "./tests/runtests.py", line 414 in <module>
 [1]    38431 segmentation fault  ./tests/runtests.py -v3
 model_inheritance_regress
 }}}

 Some clues:
 - Good library for catching tracebacks on segfault is `faulthandler`
 http://faulthandler.readthedocs.org/
 - Some failing test suites are `model_inheritance_regress` (with traceback
 above) and `admin_views`
 - It always crashes on "ROLLBACK TO SAVEPOINT", even in different tests
 (admin_views for example).
 - It doesn't depend on how many savepoints is created and released
 (`admin_views` tests create about 350 savepoints, while
 `model_inheritance_regress` creates about 60 savepoints)

--
Ticket URL: <https://code.djangoproject.com/ticket/24080#comment:11>
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 post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/068.f4a64b925b7acc45f9153e4e083d164d%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to