docs: def parseXMLString(xml):
      """
      Parse XML string, return root
      :param str: Passed in XML
      """
  
      # Remove BOM if it exists (different requests seem to have different BOMs)
      unichr_captured = ""
  
      if not xml.strip():
          return u""
  
      while xml[0] != u"<":
          unichr_captured += xml[0]
          xml = xml[1:]
      parser = etree.XMLParser(ns_clean=True, collect_ids=False, huge_tree=True)
      try:
          return etree.fromstring(xml.encode("utf-8"), parser=parser)
      except etree.XMLSyntaxError:
          raise Exception(xml)