code: def promote(self):
          
          with self.mutex:
              self.rwlock -= 1
              while self.rwlock != 0:
                  self._writer_wait()
              self.rwlock = -1
docs: Promote an already acquired read lock to a write lock
          notice: this function can easily cause a deadlock!!!!!!!!!