For all the questions I read in the docs, both Django and py-sqlite3 should be fine with streaming access. (Right?) But this piece of code is not suitable for me. The work in the main thread works, but not in the threads that I create. There I get:
File "C: \ python27 \ Lib \ site-packages \ Django-1.9-py2.7.egg \ Django \ db \ engines \ sq.m lite3 \ base.py", line 323, executed by return Database.Cursor .execute (self, query, params)
OperationalError: no such table : thrtest_mymodel
What is the problem?
How can I track what is happening with the Django patch or something that is needed to fix it? Django's point of failure is quite discouraging. I canβt say how to look at which tables he sees, or what differences to look for between the main and other threads.
from django.db import models
Update: here DATABASE DATA: settings.py:
DATABASES = { 'default': { 'ENGINE': 'django.db.backends.sqlite3', 'NAME': ':memory:', # os.path.join(BASE_DIR, 'db.sqlite3'), 'TEST_NAME' : ':memory:', }, }
Update. As for Django ticket # 12118, I get the same symptoms using ':memory:' or a file on disk (for TEST_NAME ).
Django 1.9, Python 2.7.11. (The same symptoms are in Django 1.6.)
source share