Thank you.
Add options: method=‘c14n2’, strip_text=TrueWhen you serialize the output.( pretty_print should also be the default False )
>>> print(etree.tostring(etree.fromstring(ss),method='c14n2', strip_text=True))b'<wpt lat="46.98520" lon="6.8831"><name>blah</name></wpt>'