def __init__(self, upstream):
    self._upstream = upstream
    self._condition = threading.Condition()
    self._paused = False
def __init__(self, upstream):
    self._upstream = upstream
    self._condition = threading.Condition()
    self._paused = False