MCPcopy Create free account
hub / github.com/apify/crawlee-python / is_empty

Method is_empty

src/crawlee/storages/_request_queue.py:316–326  ·  view source on GitHub ↗

Check if the request queue is empty. An empty queue means that there are no requests currently available to fetch. However, this does not necessarily mean that the crawling operation is finished, as there still might be requests being processed or tasks that could add additi

(self)

Source from the content-addressed store, hash-verified

314 return await self._client.reclaim_request(request, forefront=forefront)
315
316 async def is_empty(self) -> bool:
317 """Check if the request queue is empty.
318
319 An empty queue means that there are no requests currently available to fetch. However, this does not
320 necessarily mean that the crawling operation is finished, as there still might be requests being processed
321 or tasks that could add additional requests to the queue.
322
323 Returns:
324 True if the request queue is empty, False otherwise.
325 """
326 return await self._client.is_empty()
327
328 async def is_finished(self) -> bool:
329 """Check if the request queue is finished.

Calls

no outgoing calls