def _remove_scripts(document_tree):
    """Removes any script tag from the tree"""
    script_elements = document_tree.xpath('//script')
    for script in script_elements:
        script.getparent().remove(script)
    return document_tree