MCPcopy
hub / github.com/scrapy/scrapy / stop_async

Method stop_async

scrapy/crawler.py:246–255  ·  view source on GitHub ↗

Start a graceful stop of the crawler and complete when the crawler is stopped. .. versionadded:: 2.14

(self)

Source from the content-addressed store, hash-verified

244 return deferred_from_coro(self.stop_async())
245
246 async def stop_async(self) -> None:
247 """Start a graceful stop of the crawler and complete when the crawler is stopped.
248
249 .. versionadded:: 2.14
250 """
251 if self.crawling:
252 self.crawling = False
253 assert self.engine
254 if self.engine.running:
255 await self.engine.stop_async()
256
257 @staticmethod
258 def _get_component(

Callers 6

_create_engineMethod · 0.95
stopMethod · 0.95
stopMethod · 0.45
stopMethod · 0.45
create_schedulerFunction · 0.45
stopMethod · 0.45

Calls

no outgoing calls

Tested by 2

create_schedulerFunction · 0.36
stopMethod · 0.36