This course dives into the process, strategies, and best practices of web scraping. Learn how to use the Python framework, Scrapy, to practice key techniques.
Instructor Ryan Mitchell teaches the practice of web scraping using the Python programming language. Ryan helps you understand how a human browsing the web is different from a web scraper. She introduces the Chrome developer tools and how to use them to examine network calls. Ryan shows you how to install Scrapy with pip and how to write some "Hello, World" code to scrape a simple web page. She covers how to use the Scrapy LinkExtractor to find internal links on a web page, then demonstrates how to configure Scrapy and the ItemPipeline to write data to various file formats. Ryan walks you through best practices for organizing your projects, writing reusable parsers, and future-proofing your spiders. She explains how APIs work and how they can be used to retrieve data directly. Ryan explores headers and cookies, then goes into browser automation and how to integrate Selenium with Scrapy. In conclusion, she offers ideas to continue your studies in computer science and think creatively about automation.
How to learn to stop worrying and love the bot
What you should know
1. Basic Web Scraping
What is web scraping?
How the internet works: A brief summary
Hello world with Scrapy
Challenge: Scraping all data on a page
Solution: Scraping all data on a page
2. Learning to Crawl
Crawling a website
Scrapy settings file
Structuring your scrapers for extensibility/reusability