file.write deve ser string python

outFile = open('output.xml', 'wb')"b" for binary makes the difference.
Disgusted Duck