def _iter_frames(initialFrame):
    '''NO-YIELD VERSION: Iterates through all the frames starting at the specified frame (which will be the first returned item)'''
    # cannot use yield
    frames = []

    while initialFrame is not None:
        frames.append(initialFrame)
        initialFrame = initialFrame.f_back

    return frames
NO-YIELD VERSION: Iterates through all the frames starting at the specified frame (which will be the first returned item)
debugger/src/_pydevd_bundle/pydevd_vars.py