導入bs4時出現奇怪的錯誤。 我在其他地方找不到任何幫助。 我試過安裝html和未來。導入beautifulsoup時出錯
完整回溯:
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "C:\Python27\lib\site-packages\bs4\__init__.py", line 35, in <module>
from .builder import builder_registry, ParserRejectedMarkup
File "C:\Python27\lib\site-packages\bs4\builder\__init__.py", line 7, in <module>
from bs4.element import (
File "C:\Python27\lib\site-packages\bs4\element.py", line 10, in <module>
from bs4.dammit import EntitySubstitution
File "C:\Python27\lib\site-packages\bs4\dammit.py", line 53, in <module>
class EntitySubstitution(object):
File "C:\Python27\lib\site-packages\bs4\dammit.py", line 74, in EntitySubstitution
CHARACTER_TO_HTML_ENTITY_RE) = _populate_class_variables()
File "C:\Python27\lib\site-packages\bs4\dammit.py", line 62, in _populate_clas
s_variables
character = chr(codepoint)
ValueError: chr() arg not in range(256)
哪一行,在哪個文件? – marmeladze
我剛剛調用命令提示符並輸入import bs4 –
有什麼幫助?我完全失去了...已經嘗試了一切... –