BeautifulSoup(response.text, "lxml") # 解析页面
出现以下错误:
bs4.FeatureNotFound: Couldn't find a tree builder with the features you requested: lxml. Do you need to install a parser library?
因为没有安装‘lxml’库,
1.使用”pip install lxml“安装即可以。
2.使用PyCharm-->File-->Settings-->Project:xxxProjextName-->project Interpreter-->+-->(找到要添加的库)-->Install Package
版权声明:本文为asd237241291原创文章,遵循CC 4.0 BY-SA版权协议,转载请附上原文出处链接和本声明。