Python Mechanize: UnicodeEncodeError when uploading UTF-8 file. 'ascii' codec?

Mechanize seems to expect the file data as raw bytes, not Unicode data. Try opening the file using the usual open() function.

Mechanize seems to expect the file data as raw bytes, not Unicode data. Try opening the file using the usual open() function: ... xmlFile = open("MyFile. Xml", "rt") ...

That was it! I cannot believe it was so simple. Thanks!

– byneri Jan 25 at 4:20.

I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.

Related Questions