Challenge 4: Bypass the Login Form
Goal
Pages are restricted to a logged user. Add a login request to the scraper.
Email is john@doe.com and password is johnjohn.
Start
git checkout login
Instructions
  1. Open the file myscraper/spiders/myscraper.py
  2. Use a FormRequest instead of a Request in the start_requests method
  3. Use the credentials in the FormRequest
  4. Add the good URL in FormRequest
  5. Start the scraper (see Start instructions) and check the log item_scraped_count.
Soluce
git checkout .
git checkout login-soluce