From ba8772a66f9a16db26198baa50213c8e3fbe0dae Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Honza=20Kr=C3=A1l?= Date: Sat, 22 Jul 2017 13:13:53 -0400 Subject: [PATCH] When retrying we get deserialized data This is just a hotfix until a better solution with proper tests come along --- elasticsearch/helpers/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/elasticsearch/helpers/__init__.py b/elasticsearch/helpers/__init__.py index c899a892..41639bbe 100644 --- a/elasticsearch/helpers/__init__.py +++ b/elasticsearch/helpers/__init__.py @@ -92,7 +92,7 @@ def _process_bulk_chunk(client, bulk_actions, bulk_data, raise_on_exception=True try: # send the actual request - resp = client.bulk('\n'.join(bulk_actions) + '\n', **kwargs) + resp = client.bulk('\n'.join(map(client.transport.serializer.dumps, bulk_actions)) + '\n', **kwargs) except TransportError as e: # default behavior - just propagate exception if raise_on_exception: