[Django] #30016: Test regressions with sqlite3 3.26.0 (vs 3.25.3)

4 views
Skip to first unread message

Django

unread,
Dec 6, 2018, 11:02:41 AM12/6/18
to django-...@googlegroups.com
#30016: Test regressions with sqlite3 3.26.0 (vs 3.25.3)
-------------------------------------+-------------------------------------
Reporter: Chris | Owner: nobody
Lamb |
Type: Bug | Status: new
Component: Database | Version: 2.1
layer (models, ORM) |
Severity: Normal | Keywords: sqlite3 tests
Triage Stage: | Has patch: 0
Unreviewed |
Needs documentation: 0 | Needs tests: 0
Patch needs improvement: 0 | Easy pickings: 0
UI/UX: 0 |
-------------------------------------+-------------------------------------
Hi,

In Debian, I am seeing the following test failure since upgrading
`libsqlite3-0` from `3.25.3` (currently in buster) to `3.26.0`.

With `libsqlite3-0 (3.26.0-1)`:

{{{
$ cd tests
$ PYTHONPATH=.. python3 ./runtests.py --parallel=1 --failfast
[…]
Testing against Django installed in '/home/lamby/git/debian/python-
team/modules/python-django/django'
Creating test database for alias 'default'...
Creating test database for alias 'other'...
System check identified no issues (14 silenced).
.................sss..s............................sss..............................................................................................s..................................s..................................................s............................................................s................s.........................................................................................................................................................................................................................................s........................E
======================================================================
ERROR: test_dumpdata_with_excludes (fixtures.tests.FixtureLoadingTests)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/home/lamby/git/debian/python-team/modules/python-
django/django/db/backends/utils.py", line 85, in _execute
return self.cursor.execute(sql, params)
File "/home/lamby/git/debian/python-team/modules/python-
django/django/db/backends/sqlite3/base.py", line 296, in execute
return Database.Cursor.execute(self, query, params)
sqlite3.OperationalError: no such table: main.django_site__old

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
File "/home/lamby/git/debian/python-team/modules/python-
django/tests/fixtures/tests.py", line 330, in test_dumpdata_with_excludes
Site.objects.all().delete()
File "/home/lamby/git/debian/python-team/modules/python-
django/django/db/models/query.py", line 663, in delete
deleted, _rows_count = collector.delete()
File "/home/lamby/git/debian/python-team/modules/python-
django/django/db/models/deletion.py", line 282, in delete
count = qs._raw_delete(using=self.using)
File "/home/lamby/git/debian/python-team/modules/python-
django/django/db/models/query.py", line 677, in _raw_delete
return sql.DeleteQuery(self.model).delete_qs(self, using)
File "/home/lamby/git/debian/python-team/modules/python-
django/django/db/models/sql/subqueries.py", line 75, in delete_qs
cursor = self.get_compiler(using).execute_sql(CURSOR)
File "/home/lamby/git/debian/python-team/modules/python-
django/django/db/models/sql/compiler.py", line 1065, in execute_sql
cursor.execute(sql, params)
File "/home/lamby/git/debian/python-team/modules/python-
django/django/db/backends/utils.py", line 68, in execute
return self._execute_with_wrappers(sql, params, many=False,
executor=self._execute)
File "/home/lamby/git/debian/python-team/modules/python-
django/django/db/backends/utils.py", line 77, in _execute_with_wrappers
return executor(sql, params, many, context)
File "/home/lamby/git/debian/python-team/modules/python-
django/django/db/backends/utils.py", line 85, in _execute
return self.cursor.execute(sql, params)
File "/home/lamby/git/debian/python-team/modules/python-
django/django/db/utils.py", line 89, in __exit__
raise dj_exc_value.with_traceback(traceback) from exc_value
File "/home/lamby/git/debian/python-team/modules/python-
django/django/db/backends/utils.py", line 85, in _execute
return self.cursor.execute(sql, params)
File "/home/lamby/git/debian/python-team/modules/python-
django/django/db/backends/sqlite3/base.py", line 296, in execute
return Database.Cursor.execute(self, query, params)
django.db.utils.OperationalError: no such table: main.django_site__old

----------------------------------------------------------------------
Ran 572 tests in 3.948s

FAILED (errors=1, skipped=13)
}}}

Curiously, just running just this test does not result in a failure:

{{{
$ cd tests
$ PYTHONPATH=.. python3 ./runtests.py --parallel=1 --failfast
fixtures.tests.FixtureLoadingTests.test_dumpdata_with_excludes
Testing against Django installed in '/home/lamby/git/debian/python-
team/modules/python-django/django'
Creating test database for alias 'default'...
Creating test database for alias 'other'...
System check identified no issues (0 silenced).
.
----------------------------------------------------------------------
Ran 1 test in 0.020s

OK
}}}

Two caveats:

* This looks somewhat similar to
https://code.djangoproject.com/ticket/29182 but that bug was opened some
time ago so I am unsure at this point whether it is the same.

* This may be a bug in `sqlite3` itself.

This was filed in Debian as https://bugs.debian.org/915626

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

Django

unread,
Dec 6, 2018, 11:20:07 AM12/6/18
to django-...@googlegroups.com
#30016: Test regressions with sqlite3 3.26.0 (vs 3.25.3)
-------------------------------------+-------------------------------------
Reporter: Chris Lamb | Owner: nobody
Type: Bug | Status: closed
Component: Database layer | Version: 2.1
(models, ORM) |
Severity: Normal | Resolution: duplicate

Keywords: sqlite3 tests | Triage Stage:
| Unreviewed
Has patch: 0 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by Simon Charette):

* status: new => closed
* resolution: => duplicate


Comment:

Duplicate of #29182.

--
Ticket URL: <https://code.djangoproject.com/ticket/30016#comment:1>

Reply all
Reply to author
Forward
0 new messages