code: def get(self):
          '''Get the number of tokens in bucket'''
          now = time.time()
          if self.bucket >= self.burst:
              self.last_update = now
              return self.bucket
          bucket = self.rate * (now - self.last_update)
          self.mutex.acquire()
          if bucket > 1:
              self.bucket += bucket
              if self.bucket > self.burst:
                  self.bucket = self.burst
              self.last_update = now
          self.mutex.release()
          return self.buckef get(self):
          '''Get the number of tokens in bucket'''
          now = time.time()
          if self.bucket >= self.burst:
              self.last_update = now
              return self.bucket
          bucket = self.rate * (now - self.last_update)
          self.mutex.acquire()
          if bucket > 1:
              self.bucket += bucket
              if self.bucket > self.burst:
                  self.bucket = self.burst
              self.last_update = now
          self.mutex.release()
          return self.bucket
docs: Get the number of tokens in bucket