def getPlural():
plural = soup.find("span", class_="form-of lang-de plural-form-of")
if plural == None:
return None
else:
return plural.get_text()
问题似乎在于我的代码的这一部分。Pyscripter 能够很好地处理它,Python.exe 返回Error: 'charmap' codec can't encode character \xe4 in position 9: character maps to undefined.
PyScripter 和 Python.exe 运行相同的版本 (3.3)。为什么是这样?我该如何解决这个问题?