Bug #2429
Index creation doesn't work if the indexes are uninitialied
100%
Description
EmptyIndexError: Index 'MAIN' does not exist in FileStorage('../var/indexes')
2019-06-08 00:43:29,629 [ERROR] django.request: Internal Server Error: /admin/reader/work/
Traceback (most recent call last):
File "/Users/lmurphey/venv/django1_11/lib/python2.7/site-packages/django/core/handlers/exception.py", line 41, in inner
response = get_response(request)
File "/Users/lmurphey/venv/django1_11/lib/python2.7/site-packages/django/core/handlers/base.py", line 249, in legacy_get_response
response = self._get_response(request)
File "/Users/lmurphey/venv/django1_11/lib/python2.7/site-packages/django/core/handlers/base.py", line 187, in _get_response
response = self.process_exception_by_middleware(e, request)
File "/Users/lmurphey/venv/django1_11/lib/python2.7/site-packages/django/core/handlers/base.py", line 185, in _get_response
response = wrapped_callback(request, *callback_args, **callback_kwargs)
File "/Users/lmurphey/venv/django1_11/lib/python2.7/site-packages/django/contrib/admin/options.py", line 552, in wrapper
return self.admin_site.admin_view(view)(*args, **kwargs)
File "/Users/lmurphey/venv/django1_11/lib/python2.7/site-packages/django/utils/decorators.py", line 149, in _wrapped_view
response = view_func(request, *args, **kwargs)
File "/Users/lmurphey/venv/django1_11/lib/python2.7/site-packages/django/views/decorators/cache.py", line 57, in _wrapped_view_func
response = view_func(request, *args, **kwargs)
File "/Users/lmurphey/venv/django1_11/lib/python2.7/site-packages/django/contrib/admin/sites.py", line 224, in inner
return view(request, *args, **kwargs)
File "/Users/lmurphey/venv/django1_11/lib/python2.7/site-packages/django/utils/decorators.py", line 67, in _wrapper
return bound_func(*args, **kwargs)
File "/Users/lmurphey/venv/django1_11/lib/python2.7/site-packages/django/utils/decorators.py", line 149, in _wrapped_view
response = view_func(request, *args, **kwargs)
File "/Users/lmurphey/venv/django1_11/lib/python2.7/site-packages/django/utils/decorators.py", line 63, in bound_func
return func._get__(self, type(self))(*args2, **kwargs2)
File "/Users/lmurphey/venv/django1_11/lib/python2.7/site-packages/django/contrib/admin/options.py", line 1590, in changelist_view
response = self.response_action(request, queryset=cl.get_queryset(request))
File "/Users/lmurphey/venv/django1_11/lib/python2.7/site-packages/django/contrib/admin/options.py", line 1287, in response_action
response = func(self, request, queryset)
File "/Users/lmurphey/git/textcritical_net/src/reader/admin.py", line 59, in make_search_indexes
WorkIndexer.index_work(work)
File "/Users/lmurphey/git/textcritical_net/src/reader/contentsearch.py", line 214, in index_work
writer = cls.get_writer()
File "/Users/lmurphey/git/textcritical_net/src/reader/contentsearch.py", line 136, in get_writer
inx = cls.get_index()
File "/Users/lmurphey/git/textcritical_net/src/reader/contentsearch.py", line 109, in get_index
inx = whoosh.index.open_dir(index_dir)
File "/Users/lmurphey/git/textcritical_net/src/whoosh/index.py", line 123, in open_dir
return FileIndex(storage, schema=schema, indexname=indexname)
File "/Users/lmurphey/git/textcritical_net/src/whoosh/index.py", line 421, in init
TOC.read(self.storage, self.indexname, schema=self._schema)
File "/Users/lmurphey/git/textcritical_net/src/whoosh/index.py", line 619, in read
% (indexname, storage))
Associated revisions
Making work indexes if they don't exist
Closes #2429
History
#1 Updated by Luke Murphey over 5 years ago
- Status changed from New to Closed
- % Done changed from 0 to 100