def get_sequence(self):
    try:
        if (self._seq is not None):
            return self._seq
    except AttributeError:
        pass
    seq = []
    cursor = self
    while cursor.previous:
        cursor = cursor.previous
    seq.append(cursor)
    while True:
        try:
            cursor = cursor.next
            seq.append(cursor)
        except SessionBlockTweet.DoesNotExist:
            break
    self._seq = seq
    return self.get_sequence()
def get_sequence(self):
    try:
        if (self._seq is not None):
            return self._seq
    except AttributeError:
        pass
    seq = []
    cursor = self
    while cursor.previous:
        cursor = cursor.previous
    seq.append(cursor)
    while True:
        try:
            cursor = cursor.next
            seq.append(cursor)
        except SessionBlockTweet.DoesNotExist:
            break
    self._seq = seq
    return self.get_sequence()