

def run(self, parent, blocks):
    block = blocks.pop(0)
    m = self.RE.search(block)
    if m:
        before = block[:m.start()]
        self.parser.parseBlocks(parent, [before])
        block = '\n'.join([self.clean(line) for line in block[m.start():].split('\n')])
    sibling = self.lastChild(parent)
    if (sibling and (sibling.tag == 'blockquote')):
        quote = sibling
    else:
        quote = util.etree.SubElement(parent, 'blockquote')
    self.parser.state.set('blockquote')
    self.parser.parseChunk(quote, block)
    self.parser.state.reset()

dataset/ETHPy150Open darcyliu/storyboard/markdown/blockprocessors.py BlockQuoteProcessor.run/original