def METHOD_NAME(f: Future):
    if f.exception():
        exc = f.exception()
        code, user_message = get_result_error_details(exc)
        error_details = {"code": code, "user_message": user_message}
        exec_end = TaskTransition(
            timestamp=time.time_ns(),
            actor=ActorName.INTERCHANGE,
            state=TaskState.EXEC_END,
        )
        result_message = dict(
            task_id=task_id,
            data=get_error_string(exc=exc),
            exception=get_error_string(exc=exc),
            error_details=error_details,
            task_statuses=[exec_beg, exec_end],  # only transition info we have
        )
        packed = messagepack.pack(Result(**result_message))
    else:
        packed = f.result()
    self.results_passthrough.put({"task_id": task_id, "message": packed})