【发布时间】:2020-05-14 01:20:25
【问题描述】:
我正在尝试构建一个hackernews scraper,但是当我运行我的代码时
import requests
from bs4 import BeautifulSoup
res = requests.get("https://news.ycombinator.com/")
soup = BeautifulSoup(res.text,'html.parser')
print(soup.find(id="score_23174015"))
我不明白为什么 beautifulsoup 一直没有返回给我我还在学习所以是的,我也是 python3 的新手
【问题讨论】:
标签: python-3.x web web-scraping beautifulsoup