Commit 17adab41 authored by Victor Dosda's avatar Victor Dosda
Browse files

revert task done future result log

parent c88faac8
Pipeline #79100 failed with stages
in 30 minutes and 4 seconds
......@@ -47,12 +47,6 @@ async def _get_bulk_uris_of_versions_from_record_id(ctx: Context,
return record_bulk_uris
def task_done(future_result):
if future_result.exception():
get_ctx().logger.exception(
f"Exception on bulk versions deletion: {future_result.exception().detail}")
async def delete_record(
record_id: str,
purge: bool,
......@@ -82,6 +76,9 @@ async def delete_record(
for task in tasks:
# create_task => ensure_future
delete_result = asyncio.ensure_future(task)
task_done(delete_result)
def task_done(future_result):
if future_result.exception():
get_ctx().logger.exception(
f"Exception on bulk versions deletion: {future_result.exception().detail}")
delete_result.add_done_callback(task_done)
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment