Simplify parse command

This commit is contained in:
Eugenio Lacuesta 2020-04-04 22:15:36 -03:00
parent 4270e0a0da
commit c887fe37ad
No known key found for this signature in database
GPG Key ID: DA3EF2D0913E9810
1 changed files with 1 additions and 2 deletions

View File

@ -146,9 +146,8 @@ class Command(ScrapyCommand):
if not self.spidercls:
logger.error('Unable to find spider for: %(url)s', {'url': url})
# Request requires callback argument as callable or None, not string
def _start_requests(spider):
yield self.prepare_request(spider, Request(url, None), opts)
yield self.prepare_request(spider, Request(url), opts)
self.spidercls.start_requests = _start_requests
def start_parsing(self, url, opts):