Ensure task result processing is idempotent