I am looking for a python based solution to compare two xml's ignoring a particular attribute value. For example, the below xml's should be treated as identical though the Ref and ID values are different as these would be different in each xml. One of the solution could be to substitue these with empty strings first and then compare xml's. Is there any library available in python which can do this while comparing the xmls.
#XML1:
<Objects>
<Object Name="Object1" Ref="12345">
<Item Name="Item1" value="Value1"/>
</Object>
</Objects>
<RefTable>
<Refitem ID="12345" Name="Item1"/>
</RefTable>
#XML2:
<Objects>
<Object Name="Object1" Ref="54321">
<Item Name="Item1" value="Value1"/>
</Object>
</Objects>
<RefTable>
<Refitem ID="54321" Name="Item1"/>
</RefTable>
difflib