#9409: "OperationalError: database is locked" with Python 2.6 multiprocessing
and
SQLite backend
------------------------------------+---------------------------------------
Reporter: mrts | Owner: nobody
Status: reopened | Milestone:
Component: Documentation | Version: 1.0
Resolution: | Keywords:
Stage: Unreviewed | Has_patch: 0
Needs_docs: 0 | Needs_tests: 0
Needs_better_patch: 0 |
------------------------------------+---------------------------------------
Changes (by mrts):
* status: closed => reopened
* resolution: invalid =>
* component: Database layer (models, ORM) => Documentation
Comment:
`OperationalError: database is locked` seems to imply the code is thread-
aware (assuming ''locked'' denotes ''locked by a thread-aware lock''). I'm
not aware of the internals, but setting `DATABASE_OPTIONS = {'timeout':
30}` as suggested by Brian Beck in http://groups.google.com/group/django-
developers/browse_thread/thread/d320de970c2a4016 solved the problem. So
''connections cannot be shared between threads'' seems to be incorrect --
Django ORM seems to do it's job quite well when timeout is larger with the
sample code.
I'd say this should be documented and I'm willing to do it (unfortunately
I'm currently dead busy).
--
Ticket URL: <http://code.djangoproject.com/ticket/9409#comment:6>
Django <http://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 post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/django-updates?hl=en
-~----------~----~----~----~------~----~------~--~---