Case import error question

Hi John,

Unfortunately I don’t think I’ve ever seen that error. I checked our error
logs and we’ve never gotten that error before. I would double check your
database settings and ensure they are the same as the ones we use or try
googling around for that error message. This seems like an issue with the
setup you have locally, rather than a commcarehq error.


··· On Sat, Feb 4, 2017 at 5:32 PM, John Harper wrote:

I am running a local install of commcarehq…lets get that out front

during an excel import of case data I am receiving this error randomly on
the import…which crashes the server and the import. but rerunning the
remaining case records that did not post after the server is back online go
in correctly.

that being said i am fairly certain that the data is not the culprit but
perhaps something else is not working correctly.

here is the error received.

Internal Server Error: /a/kidsv2/importer/excel/commit/

Method: POST

URL: http://server:8000/a/kidsv2/importer/excel/commit/

Traceback (most recent call first):

DatabaseError: DatabaseWrapper objects created in a thread can only be used in that same thread. The object with alias ‘default’ was created in thread id 140074495502080 and this is thread id 140074668811280.

File “/home/commcarehq/local/lib/python2.7/site-packages/django/db/backends/base/”, line 421, in validate_thread_sharing
% (self.alias, self._thread_ident, thread.get_ident()))

File “/home/commcarehq/local/lib/python2.7/site-packages/django/db/backends/base/”, line 191, in close

File “/home/commcarehq/local/lib/python2.7/site-packages/django/db/”, line 261, in exit

File “/home/commcarehq/local/lib/python2.7/site-packages/django/db/models/”, line 762, in save_base
updated = self._save_table(raw, cls, force_insert, force_update, using, update_fields)

File “/home/commcarehq/local/lib/python2.7/site-packages/django/db/models/”, line 734, in save
force_update=force_update, update_fields=update_fields)

File “/home/commcarehq/commcare-hq/corehq/apps/case_importer/tracking/”, line 57, in trigger_upload

File “/home/commcarehq/commcare-hq/corehq/apps/case_importer/”, line 266, in excel_commit
case_upload.trigger_upload(domain, config)

File “/home/commcarehq/commcare-hq/corehq/apps/users/”, line 21, in _inner
return view_func(request, domain, *args, **kwargs)

File “/home/commcarehq/commcare-hq/corehq/apps/domain/”, line 103, in _inner
return view_func(req, domain_name, *args, **kwargs)

File “/home/commcarehq/local/lib/python2.7/site-packages/django/views/decorators/”, line 45, in inner
return func(request, *args, **kwargs)

File "/home/commcarehq/local/lib/python2.7/site-packages/django/core/handl

You received this message because you are subscribed to the Google Groups
"CommCare Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to
For more options, visit