Final version
This commit is contained in:
parent
d7fd3dd578
commit
63e275fa2f
30 changed files with 2918 additions and 5 deletions
17
code/pyconus2024-css.py
Normal file
17
code/pyconus2024-css.py
Normal file
|
@ -0,0 +1,17 @@
|
|||
import scrapy
|
||||
|
||||
|
||||
class PyConUS2024Spider(scrapy.Spider):
|
||||
name = "pyconus"
|
||||
|
||||
start_urls = [
|
||||
"https://us.pycon.org/2024/schedule/tutorials/",
|
||||
]
|
||||
|
||||
def parse(self, response):
|
||||
for tutorial in response.css(".presentation"):
|
||||
yield {
|
||||
"speaker": tutorial.css(".speaker::text").get().strip(),
|
||||
"url": response.urljoin(tutorial.css(".title a::attr(href)").get()),
|
||||
"title": tutorial.css(".title a::text").get(),
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue