Commit 0797736e authored by 段英荣's avatar 段英荣

增加搜索爬取功能

parent 21612b5f
...@@ -248,6 +248,7 @@ class ZhihuAccount(object): ...@@ -248,6 +248,7 @@ class ZhihuAccount(object):
if "data" in raw_content_dict: if "data" in raw_content_dict:
for data_item in raw_content_dict["data"]: for data_item in raw_content_dict["data"]:
if data_item["type"] == "search_result":
data_type = data_item["object"]["type"] data_type = data_item["object"]["type"]
content = data_item["object"]["content"] content = data_item["object"]["content"]
platform_id = data_item["object"]["id"] platform_id = data_item["object"]["id"]
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment