Open jrief opened 9 years ago
if haystack is used in conjunction with Elasticsearch, the shown configuration settings
HAYSTACK_CONNECTIONS = { 'en': { 'ENGINE': 'haystack.backends.elasticsearch_backend.ElasticsearchSearchEngine', 'URL': 'http://localhost:9200/', 'INDEX_NAME': 'haystack-en', }, 'fr': { 'ENGINE': 'haystack.backends.elasticsearch_backend.ElasticsearchSearchEngine', 'URL': 'http://localhost:9200/', 'INDEX_NAME': 'haystack-fr', }, }
will give a very weird error:
File "lib/python2.7/site-packages/haystack/__init__.py", line 6, in <module> from haystack import signals ImportError: cannot import name signals
Instead declare one of the search-indices as default, say
HAYSTACK_CONNECTIONS = { 'default': { 'ENGINE': 'haystack.backends.elasticsearch_backend.ElasticsearchSearchEngine', 'URL': 'http://localhost:9200/', 'INDEX_NAME': 'haystack-en', }, ... }
@jrief the need for a default connection is documented in haystack, we can extend our example in the readme to include the default connection.
default
if haystack is used in conjunction with Elasticsearch, the shown configuration settings
will give a very weird error:
Instead declare one of the search-indices as default, say