UnicodeEncodeError: 'ascii' codec can't encode character u'\xef' in position 0: ordinal not in range(128)

前端 未结 7 1587
旧巷少年郎
旧巷少年郎 2020-11-28 04:24

I want to parse my XML document. So I have stored my XML document as below

class XMLdocs(db.Expando):  
   id = db.IntegerProperty()    
   name=db.StringPro         


        
7条回答
  •  旧时难觅i
    2020-11-28 04:55

    Just putting .encode('utf-8') at the end of object will do the job in recent versions of Python.

提交回复
热议问题