Throw an exception if task completion callback fails.