We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 278d8f5 commit 0603547Copy full SHA for 0603547
awswrangler/opensearch/_write.py
@@ -334,12 +334,9 @@ def index_json(
334
"""
335
_logger.debug("indexing %s from %s", index, path)
336
337
- if boto3_session is None:
338
- raise ValueError("boto3_session cannot be None")
339
-
340
if path.startswith("s3://"):
341
bucket, key = parse_path(path)
342
- s3 = boto3_session.client("s3")
+ s3 = _utils.client(service_name="s3", session=boto3_session)
343
obj = s3.get_object(Bucket=bucket, Key=key)
344
body = obj["Body"].read()
345
lines = body.splitlines()
0 commit comments