You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
/Library/Python/2.7/site-packages/beautifulsoup4-4.5.3-py2.7.egg/bs4/__init__.py:181: UserWarning: Noparserwasexplicitlyspecified, soI'm using the best available HTML parser for this system ("html.parser"). This usually isn'taproblem, butifyourunthiscodeonanothersystem, orinadifferentvirtualenvironment, itmayuseadifferentparserandbehavedifferently.
Thecodethatcausedthiswarningisonline371ofthefileLianJiaSpider.py. Togetridofthiswarning, changecodethatlookslikethis:
BeautifulSoup([yourmarkup])
tothis:
BeautifulSoup([yourmarkup], "html.parser")
Traceback (mostrecentcalllast):
File"LianJiaSpider.py", line371, in<module>do_xiaoqu_spider(db_xq,region)
File"LianJiaSpider.py", line187, indo_xiaoqu_spiderd="d="+soup.find('div',{'class':'page-box house-lst-page-box'}).get('page-data')
AttributeError: 'NoneType'objecthasnoattribute'get'
The text was updated successfully, but these errors were encountered:
爬了两个城区后出现下列错误。同时网页打开后提示流量异常,要我做图片验证码,做完后网页浏览正常,但是爬取仍然如此。
此外,拿到的db是12K,是不是也是只有空文件? 另外这个文件使用sqlite查看吗?
The text was updated successfully, but these errors were encountered: