def add_element_with_atts_to_etree(self, etree, name, atts):
        xml_atts = {}
        for att in atts.keys():
            val = atts[att]
            if (val is not None):
                xml_atts[self._xml_att_name(att)] = str(val)
        if (len(xml_atts)>0):
            e = Element(name,xml_atts)
            if (self.pretty_xml):
                e.tail="\n"
            etree.append(e)
Add element with name and atts to etree iff there are any atts
dataset/ETHPy150Open resync/resync/resync/sitemap.py/Sitemap.add_element_with_atts_to_etree