From 9b3f9642a4f32b1f85460fc7d2def08914e6c60c Mon Sep 17 00:00:00 2001 From: "tim.reichard" Date: Fri, 3 Feb 2023 10:35:14 -0600 Subject: [PATCH] Remove results from callback when error in LongRunningJobs --- HISTORY.rst | 5 +++++ aioradio/long_running_jobs.py | 1 + setup.py | 2 +- 3 files changed, 7 insertions(+), 1 deletion(-) diff --git a/HISTORY.rst b/HISTORY.rst index be2eebf..4681c6c 100644 --- a/HISTORY.rst +++ b/HISTORY.rst @@ -3,6 +3,11 @@ History ======= +v0.17.31 (2023-02-03) + +* Remove results from callback when error in LongRunningJobs. + + v0.17.30 (2023-02-03) * Update LongRunningJobs to gracefully deal with exceptions during narwhal execution. diff --git a/aioradio/long_running_jobs.py b/aioradio/long_running_jobs.py index b6af875..6258b9d 100644 --- a/aioradio/long_running_jobs.py +++ b/aioradio/long_running_jobs.py @@ -207,6 +207,7 @@ async def __sqs_pull_messages_and_run_jobs__(self): json = {'results': data, 'uuid': body['uuid']} if error: json['error'] = error + del json['results'] create_task(self.httpx_client.post(callback_url, json=json, timeout=30)) # Update the hashed UUID with processing results diff --git a/setup.py b/setup.py index 5d68093..f3eaa2c 100644 --- a/setup.py +++ b/setup.py @@ -7,7 +7,7 @@ long_description = fileobj.read() setup(name='aioradio', - version='0.17.30', + version='0.17.31', description='Generic asynchronous i/o python utilities for AWS services (SQS, S3, DynamoDB, Secrets Manager), Redis, MSSQL (pyodbc), JIRA and more', long_description=long_description, long_description_content_type="text/markdown",