parameters: (in_path)
return_statement: return tree
docstring: Opens the xml file and turns it into an ETree
      :param in_path:
      :return:
docstring_summary: Opens the xml file and turns it into an ETree
      :param in_path:
      :return:
docstring_tokens: Opens the xml file and turns it into an ETree : param in_path : : return :
function: def parse_xml(in_path):
      """
      Opens the xml file and turns it into an ETree
      :param in_path:
      :return:
      """
  
      # print "parse : " + in_path
      tree = None
      try:
          with open(in_path, "rb") as xml_file:
              content = xml_file.read().decode("utf-8", errors="replace")
              new_content = content.encode("utf-8", errors="replace")
              parser = ET.XMLParser(encoding="utf-8")
              tree = ET.fromstring(new_content, parser)
  
      except:
          exc = sys.exc_info()[0]
          log("COULD NOT PARSE FILE: " + in_path, 2)
          log(exc, 2)
      return tree
function_tokens: def parse_xml ( in_path ) : # print "parse : " + in_path tree = None try : with open ( in_path , "rb" ) as xml_file : content = xml_file . read ( ) . decode ( "utf-8" , errors = "replace" ) new_content = content . encode ( "utf-8" , errors = "replace" ) parser = ET . XMLParser ( encoding = "utf-8" ) tree = ET . fromstring ( new_content , parser ) except : exc = sys . exc_info ( ) [ 0 ] log ( "COULD NOT PARSE FILE: " + in_path , 2 ) log ( exc , 2 ) return tree