code: def buckets(self, start, end):
      '''
      Calculate the buckets within a starting and ending timestamp.
      '''
      rval = [ self.to_bucket(start) ]
      step = 1
  
      # In theory there's already been a check that end>start
      # TODO: Not a fan of an unbound while loop here
      while True:
        bucket = self.to_bucket(start, step)
        bucket_time = self.from_bucket( bucket )
        if bucket_time >= end:
          if bucket_time==end:
            rval.append( bucket )
          break
        rval.append( bucket )
        step += 1
  
      return rvaf buckets(self, start, end):
      '''
      Calculate the buckets within a starting and ending timestamp.
      '''
      rval = [ self.to_bucket(start) ]
      step = 1
  
      # In theory there's already been a check that end>start
      # TODO: Not a fan of an unbound while loop here
      while True:
        bucket = self.to_bucket(start, step)
        bucket_time = self.from_bucket( bucket )
        if bucket_time >= end:
          if bucket_time==end:
            rval.append( bucket )
          break
        rval.append( bucket )
        step += 1
  
      return rval
docs: Calculate the buckets within a starting and ending timestamp.