MCPcopy Create free account
hub / github.com/ScrapeGraphAI/Scrapegraph-ai / delayed_scraper

Function delayed_scraper

tests/test_chromium.py:951–957  ·  view source on GitHub ↗
(url)

Source from the content-addressed store, hash-verified

949 loader = ChromiumLoader(urls, backend="playwright")
950
951 async def delayed_scraper(url):
952 # Delay inversely proportional to a function of the url to scramble finish order
953 import asyncio
954
955 delay = 0.3 - 0.1 * (len(url) % 3)
956 await asyncio.sleep(delay)
957 return f"<html>Content for {url}</html>"
958
959 monkeypatch.setattr(loader, "ascrape_playwright", delayed_scraper)
960

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected