code: def check_applied(result):
      
      try:
          applied = result.was_applied
      except Exception:
          applied = True  # result was not LWT form
      if not applied:
          raise LWTException(result.one())
docs: Raises LWTException if it looks like a failed LWT request. A LWTException
      won't be raised in the special case in which there are several failed LWT
      in a  :class:`~cqlengine.query.BatchQuery`.