my-aws-helpers 4.9.0__tar.gz → 5.0.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of my-aws-helpers might be problematic. Click here for more details.
- {my_aws_helpers-4.9.0 → my_aws_helpers-5.0.1}/PKG-INFO +1 -1
- {my_aws_helpers-4.9.0 → my_aws_helpers-5.0.1}/my_aws_helpers/s3.py +6 -2
- {my_aws_helpers-4.9.0 → my_aws_helpers-5.0.1}/my_aws_helpers.egg-info/PKG-INFO +1 -1
- {my_aws_helpers-4.9.0 → my_aws_helpers-5.0.1}/setup.py +1 -1
- {my_aws_helpers-4.9.0 → my_aws_helpers-5.0.1}/MANIFEST.in +0 -0
- {my_aws_helpers-4.9.0 → my_aws_helpers-5.0.1}/README.md +0 -0
- {my_aws_helpers-4.9.0 → my_aws_helpers-5.0.1}/my_aws_helpers/api.py +0 -0
- {my_aws_helpers-4.9.0 → my_aws_helpers-5.0.1}/my_aws_helpers/auth.py +0 -0
- {my_aws_helpers-4.9.0 → my_aws_helpers-5.0.1}/my_aws_helpers/bedrock.py +0 -0
- {my_aws_helpers-4.9.0 → my_aws_helpers-5.0.1}/my_aws_helpers/cognito.py +0 -0
- {my_aws_helpers-4.9.0 → my_aws_helpers-5.0.1}/my_aws_helpers/dynamo.py +0 -0
- {my_aws_helpers-4.9.0 → my_aws_helpers-5.0.1}/my_aws_helpers/errors.py +0 -0
- {my_aws_helpers-4.9.0 → my_aws_helpers-5.0.1}/my_aws_helpers/event.py +0 -0
- {my_aws_helpers-4.9.0 → my_aws_helpers-5.0.1}/my_aws_helpers/logging.py +0 -0
- {my_aws_helpers-4.9.0 → my_aws_helpers-5.0.1}/my_aws_helpers/prompts/__init__.py +0 -0
- {my_aws_helpers-4.9.0 → my_aws_helpers-5.0.1}/my_aws_helpers/prompts/markdown_system_prompt.txt +0 -0
- {my_aws_helpers-4.9.0 → my_aws_helpers-5.0.1}/my_aws_helpers/prompts/transactions_headers_prompt.txt +0 -0
- {my_aws_helpers-4.9.0 → my_aws_helpers-5.0.1}/my_aws_helpers/prompts/transactions_headers_prompt_v2.txt +0 -0
- {my_aws_helpers-4.9.0 → my_aws_helpers-5.0.1}/my_aws_helpers/prompts/transactions_prompt.txt +0 -0
- {my_aws_helpers-4.9.0 → my_aws_helpers-5.0.1}/my_aws_helpers/sfn.py +0 -0
- {my_aws_helpers-4.9.0 → my_aws_helpers-5.0.1}/my_aws_helpers.egg-info/SOURCES.txt +0 -0
- {my_aws_helpers-4.9.0 → my_aws_helpers-5.0.1}/my_aws_helpers.egg-info/dependency_links.txt +0 -0
- {my_aws_helpers-4.9.0 → my_aws_helpers-5.0.1}/my_aws_helpers.egg-info/requires.txt +0 -0
- {my_aws_helpers-4.9.0 → my_aws_helpers-5.0.1}/my_aws_helpers.egg-info/top_level.txt +0 -0
- {my_aws_helpers-4.9.0 → my_aws_helpers-5.0.1}/my_aws_helpers.egg-info/zip-safe +0 -0
- {my_aws_helpers-4.9.0 → my_aws_helpers-5.0.1}/setup.cfg +0 -0
- {my_aws_helpers-4.9.0 → my_aws_helpers-5.0.1}/tests/test_cognito.py +0 -0
- {my_aws_helpers-4.9.0 → my_aws_helpers-5.0.1}/tests/test_event.py +0 -0
|
@@ -33,6 +33,8 @@ class S3Serialiser:
|
|
|
33
33
|
def _serialise(obj: Any):
|
|
34
34
|
if isinstance(obj, datetime) or isinstance(obj, date):
|
|
35
35
|
return obj.isoformat()
|
|
36
|
+
if isinstance(obj, S3Location):
|
|
37
|
+
return obj.location
|
|
36
38
|
return obj
|
|
37
39
|
|
|
38
40
|
@staticmethod
|
|
@@ -97,10 +99,12 @@ class S3:
|
|
|
97
99
|
Body=json.dumps(object), Bucket=bucket_name, Key=file_name
|
|
98
100
|
)
|
|
99
101
|
|
|
100
|
-
def list_objects_by_prefix(self, bucket_name: str, prefix: str) -> List[
|
|
102
|
+
def list_objects_by_prefix(self, bucket_name: str, prefix: str) -> List[S3Location]:
|
|
101
103
|
try:
|
|
102
104
|
response = self.client.list_objects_v2(Bucket=bucket_name, Prefix=prefix)
|
|
103
|
-
|
|
105
|
+
contents = response["Contents"]
|
|
106
|
+
locations = [S3Location(bucket = c['Bucket'], file_name = c["Key"]) for c in contents]
|
|
107
|
+
return locations
|
|
104
108
|
except Exception as e:
|
|
105
109
|
logger.exception(
|
|
106
110
|
f"Failed to get objects from s3: {bucket_name}/{prefix} due to {e}"
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{my_aws_helpers-4.9.0 → my_aws_helpers-5.0.1}/my_aws_helpers/prompts/markdown_system_prompt.txt
RENAMED
|
File without changes
|
{my_aws_helpers-4.9.0 → my_aws_helpers-5.0.1}/my_aws_helpers/prompts/transactions_headers_prompt.txt
RENAMED
|
File without changes
|
|
File without changes
|
{my_aws_helpers-4.9.0 → my_aws_helpers-5.0.1}/my_aws_helpers/prompts/transactions_prompt.txt
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|