Correct login request example

In the example log is not imported
and not found in the global name space
This commit is contained in:
Vicente Jimenez Aguilar 2015-05-05 10:36:02 +02:00
parent 40fbeb30e7
commit 178440a39a
1 changed files with 1 additions and 1 deletions

View File

@ -367,7 +367,7 @@ method for this job. Here's an example spider which uses it::
def after_login(self, response):
# check login succeed before going on
if "authentication failed" in response.body:
self.log("Login failed", level=log.ERROR)
self.log("Login failed", level=scrapy.log.ERROR)
return
# continue scraping with authenticated session...