MCPcopy
hub / github.com/scrapy/scrapy / crawl

Method crawl

scrapy/core/engine.py:433–438  ·  view source on GitHub ↗

Inject the request into the spider <-> downloader pipeline

(self, request: Request)

Source from the content-addressed store, hash-verified

431 return not self._slot.scheduler.has_pending_requests()
432
433 def crawl(self, request: Request) -> None:
434 """Inject the request into the spider <-> downloader pipeline"""
435 if self.spider is None:
436 raise RuntimeError(f"No open spider to crawl: {request}")
437 self._schedule_request(request)
438 self._slot.nextcall.schedule() # type: ignore[union-attr]
439
440 def _schedule_request(self, request: Request) -> None:
441 request_scheduled_result = self.signals.send_catch_log(

Callers 9

_process_start_nextMethod · 0.95
runMethod · 0.45
runMethod · 0.45
start_parsingMethod · 0.45
runMethod · 0.45
runMethod · 0.45
runMethod · 0.45

Calls 2

_schedule_requestMethod · 0.95
scheduleMethod · 0.80

Tested by

no test coverage detected