Don't reread file on unicode decode error

Once the file descriptor has been read you can't do it again!
Remove unused error var
Encode the xml on python 2

Can't quite work out what python 2 is doing here but it needs the xml to
be encoded to unicode.