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

Function wrapper

scrapegraphai/utils/research_web.py:108–115  ·  view source on GitHub ↗
(*args, **kwargs)

Source from the content-addressed store, hash-verified

106 def decorator(func):
107 @wraps(func)
108 def wrapper(*args, **kwargs):
109 elapsed = time.time() - last_called[0]
110 wait_time = min_interval - elapsed
111 if wait_time > 0:
112 time.sleep(wait_time)
113 result = func(*args, **kwargs)
114 last_called[0] = time.time()
115 return result
116
117 return wrapper
118

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected