Skip to content

Instantly share code, notes, and snippets.

@rafikahmed
Last active September 29, 2018 10:01
Show Gist options
  • Save rafikahmed/a836b258d544db4762c236889bd572c5 to your computer and use it in GitHub Desktop.
Save rafikahmed/a836b258d544db4762c236889bd572c5 to your computer and use it in GitHub Desktop.
def parse(self, response):
for joke in response.xpath("//div[@class='jokes']"):
yield {
'joke_text': joke.xpath(".//div[@class='joke-text']/p").extract_first()
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment