From aa6f51ba326a72ed93bc3e20bc14bc1a52f4d078 Mon Sep 17 00:00:00 2001 From: ksemchh Date: Wed, 28 May 2025 11:57:41 +0500 Subject: [PATCH 1/2] fix: fixed 'Access denied' problem --- src/stactools/threedep/utils.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/stactools/threedep/utils.py b/src/stactools/threedep/utils.py index da0acf5..9036738 100644 --- a/src/stactools/threedep/utils.py +++ b/src/stactools/threedep/utils.py @@ -3,6 +3,8 @@ from typing import List, Optional import boto3 +from botocore import UNSIGNED +from botocore.config import Config from stactools.threedep import utils from stactools.threedep.constants import AWS_BUCKET, AWS_PREFIX, USGS_FTP_SERVER @@ -32,7 +34,7 @@ def _fetch_ids_from_usgs_ftp(product: str) -> List[str]: def _fetch_ids_from_aws(product: str) -> List[str]: path = os.path.dirname(utils.path(product, "")) prefix = os.path.join(AWS_PREFIX, path) - client = boto3.client("s3") + client = boto3.client("s3", config=Config(signature_version=UNSIGNED)) paginator = client.get_paginator("list_objects_v2") page_iterator = paginator.paginate(Bucket=AWS_BUCKET, Prefix=prefix) filtered_iterator = page_iterator.search("Contents[?ends_with(Key, `.xml`)].Key") From b8e9634202ddf3c9f9fa887d31894b6b49a41398 Mon Sep 17 00:00:00 2001 From: ksemchh Date: Wed, 28 May 2025 12:17:59 +0500 Subject: [PATCH 2/2] docs: updated CHANGELOG.md --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 11f2007..8428605 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -23,6 +23,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/). - Proj extension, license, asset paths ([#12](https://github.com/stactools-packages/threedep/pull/12)) - GPKG path ([#13](https://github.com/stactools-packages/threedep/pull/13)) +- AWS access to the sources ([#17](https://github.com/stactools-packages/threedep/pull/17)) ## v0.2.0