You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have the followed problem, How can i solve it that please?
/django-drf-elasticsearch$ python manage.py search_index --rebuild
/home/hala/anaconda3/envs/env/lib/python3.12/site-packages/django_elasticsearch_dsl/management/commands/search_index.py:301: ElasticsearchWarning: this request accesses system indices: [.security-7], but in a future major version, direct access to system indices will be prevented by default
for index in self.es_conn.indices.get_alias().values():
Are you sure you want to delete the 'users, articles, categories' indices? [y/N]: y
Deleting index 'users'
Deleting index 'articles'
Deleting index 'categories'
Creating index 'users'
Creating index 'articles'
Creating index 'categories'
Indexing 0 'Article' objects
Indexing 3 'User' objects
Traceback (most recent call last):
File "/home/hala/work/2024/django-drf-elasticsearch/manage.py", line 22, in
main()
File "/home/hala/work/2024/django-drf-elasticsearch/manage.py", line 18, in main
execute_from_command_line(sys.argv)
File "/home/hala/anaconda3/envs/env/lib/python3.12/site-packages/django/core/management/init.py", line 442, in execute_from_command_line
utility.execute()
File "/home/hala/anaconda3/envs/env/lib/python3.12/site-packages/django/core/management/init.py", line 436, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File "/home/hala/anaconda3/envs/env/lib/python3.12/site-packages/django/core/management/base.py", line 412, in run_from_argv
self.execute(*args, **cmd_options)
File "/home/hala/anaconda3/envs/env/lib/python3.12/site-packages/django/core/management/base.py", line 458, in execute
output = self.handle(*args, **options)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/hala/anaconda3/envs/env/lib/python3.12/site-packages/django_elasticsearch_dsl/management/commands/search_index.py", line 311, in handle
self._rebuild(models, aliases, options)
File "/home/hala/anaconda3/envs/env/lib/python3.12/site-packages/django_elasticsearch_dsl/management/commands/search_index.py", line 277, in _rebuild
self._populate(models, options)
File "/home/hala/anaconda3/envs/env/lib/python3.12/site-packages/django_elasticsearch_dsl/management/commands/search_index.py", line 153, in _populate
doc().update(qs, parallel=parallel, refresh=options['refresh'])
File "/home/hala/anaconda3/envs/env/lib/python3.12/site-packages/django_elasticsearch_dsl/documents.py", line 259, in update
return self._bulk(
^^^^^^^^^^^
File "/home/hala/anaconda3/envs/env/lib/python3.12/site-packages/django_elasticsearch_dsl/documents.py", line 236, in _bulk
return self.bulk(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/hala/anaconda3/envs/env/lib/python3.12/site-packages/django_elasticsearch_dsl/documents.py", line 178, in bulk
response = bulk(client=self._get_connection(), actions=actions, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/hala/anaconda3/envs/env/lib/python3.12/site-packages/elasticsearch/helpers/actions.py", line 521, in bulk
for ok, item in streaming_bulk(
File "/home/hala/anaconda3/envs/env/lib/python3.12/site-packages/elasticsearch/helpers/actions.py", line 436, in streaming_bulk
for data, (ok, info) in zip(
File "/home/hala/anaconda3/envs/env/lib/python3.12/site-packages/elasticsearch/helpers/actions.py", line 355, in _process_bulk_chunk
yield from gen
File "/home/hala/anaconda3/envs/env/lib/python3.12/site-packages/elasticsearch/helpers/actions.py", line 274, in _process_bulk_chunk_success
raise BulkIndexError(f"{len(errors)} document(s) failed to index.", errors)
elasticsearch.helpers.BulkIndexError: 3 document(s) failed to index.
The text was updated successfully, but these errors were encountered:
I have the followed problem, How can i solve it that please?
/django-drf-elasticsearch$ python manage.py search_index --rebuild
/home/hala/anaconda3/envs/env/lib/python3.12/site-packages/django_elasticsearch_dsl/management/commands/search_index.py:301: ElasticsearchWarning: this request accesses system indices: [.security-7], but in a future major version, direct access to system indices will be prevented by default
for index in self.es_conn.indices.get_alias().values():
Are you sure you want to delete the 'users, articles, categories' indices? [y/N]: y
Deleting index 'users'
Deleting index 'articles'
Deleting index 'categories'
Creating index 'users'
Creating index 'articles'
Creating index 'categories'
Indexing 0 'Article' objects
Indexing 3 'User' objects
Traceback (most recent call last):
File "/home/hala/work/2024/django-drf-elasticsearch/manage.py", line 22, in
main()
File "/home/hala/work/2024/django-drf-elasticsearch/manage.py", line 18, in main
execute_from_command_line(sys.argv)
File "/home/hala/anaconda3/envs/env/lib/python3.12/site-packages/django/core/management/init.py", line 442, in execute_from_command_line
utility.execute()
File "/home/hala/anaconda3/envs/env/lib/python3.12/site-packages/django/core/management/init.py", line 436, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File "/home/hala/anaconda3/envs/env/lib/python3.12/site-packages/django/core/management/base.py", line 412, in run_from_argv
self.execute(*args, **cmd_options)
File "/home/hala/anaconda3/envs/env/lib/python3.12/site-packages/django/core/management/base.py", line 458, in execute
output = self.handle(*args, **options)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/hala/anaconda3/envs/env/lib/python3.12/site-packages/django_elasticsearch_dsl/management/commands/search_index.py", line 311, in handle
self._rebuild(models, aliases, options)
File "/home/hala/anaconda3/envs/env/lib/python3.12/site-packages/django_elasticsearch_dsl/management/commands/search_index.py", line 277, in _rebuild
self._populate(models, options)
File "/home/hala/anaconda3/envs/env/lib/python3.12/site-packages/django_elasticsearch_dsl/management/commands/search_index.py", line 153, in _populate
doc().update(qs, parallel=parallel, refresh=options['refresh'])
File "/home/hala/anaconda3/envs/env/lib/python3.12/site-packages/django_elasticsearch_dsl/documents.py", line 259, in update
return self._bulk(
^^^^^^^^^^^
File "/home/hala/anaconda3/envs/env/lib/python3.12/site-packages/django_elasticsearch_dsl/documents.py", line 236, in _bulk
return self.bulk(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/hala/anaconda3/envs/env/lib/python3.12/site-packages/django_elasticsearch_dsl/documents.py", line 178, in bulk
response = bulk(client=self._get_connection(), actions=actions, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/hala/anaconda3/envs/env/lib/python3.12/site-packages/elasticsearch/helpers/actions.py", line 521, in bulk
for ok, item in streaming_bulk(
File "/home/hala/anaconda3/envs/env/lib/python3.12/site-packages/elasticsearch/helpers/actions.py", line 436, in streaming_bulk
for data, (ok, info) in zip(
File "/home/hala/anaconda3/envs/env/lib/python3.12/site-packages/elasticsearch/helpers/actions.py", line 355, in _process_bulk_chunk
yield from gen
File "/home/hala/anaconda3/envs/env/lib/python3.12/site-packages/elasticsearch/helpers/actions.py", line 274, in _process_bulk_chunk_success
raise BulkIndexError(f"{len(errors)} document(s) failed to index.", errors)
elasticsearch.helpers.BulkIndexError: 3 document(s) failed to index.
The text was updated successfully, but these errors were encountered: