code: def release(self):
          
          if self._lock_renewal_thread is not None:
              self._stop_lock_renewer()
          logger.debug("Releasing %r.", self._name)
          error = _eval_script(self._client, UNLOCK, self._name, self._signal, args=(self._id,))
          if error == 1:
              raise NotAcquired("Lock %s is not acquired or it already expired." % self._name)
          elif error:
              raise RuntimeError("Unsupported error code %s from EXTEND script." % error)
          else:
              self._delete_signal()
docs: Releases the lock, that was acquired with the same object.
  
          .. note::
  
              If you want to release a lock that you acquired in a different place you have two choices:
  
              * Use ``Lock("name", id=id_from_other_place).release()``
              * Use ``Lock("name").reset()``