【发布时间】:2021-06-02 16:47:52
【问题描述】:
我想使用 BeautifulSoup 从 Google 专利搜索中抓取专利链接,但我不确定 Google 是否将他们的 html 转换为无法通过 BeautifulSoup 解析的 javascript,或者问题是什么。
下面是一些简单的代码:
url = 'https://patents.google.com/?assignee=Roche&after=priority:20110602&type=PATENT&num=100'
soup = BeautifulSoup(requests.get(url).content, 'html.parser')
links = []
for link in soup.find_all('a', href=True):
print(link['href'])
我还想将链接附加到列表中,但没有打印任何内容,因为汤中没有“a”标签。 有什么方法可以获取所有专利的链接?
【问题讨论】:
标签: python beautifulsoup google-patent-search