-
Notifications
You must be signed in to change notification settings - Fork 66
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
helpers.scan doesn't work #11
Comments
Same here and I come to the same conclusion. Would you consider a PR in this direction? |
Sorry guys, but I do not have too much time to maintain this library. But you can always send a PR with this improvement :) |
You can mock the elastic search scan something like the below code
|
from elasticmock.fake_elasticsearch import FakeElasticsearch
def _mock_clear_scroll(client: FakeElasticsearch, *args, **kwargs):
# pylint: disable=unused-argument
pass
FakeElasticsearch.clear_scroll = _mock_clear_scroll |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I'm trying to use elasticsearch.helpers.scan with the mocked ES. It apparently doesn't work because the results don't include a
_scroll_id
: https://github.com/elastic/elasticsearch-py/blob/9fe0763670633848b521ff9df6350bc811f4f110/elasticsearch/helpers/__init__.py#L367. Is it insane to think about adding this functionality, or does that get way complicated?The text was updated successfully, but these errors were encountered: