MCPcopy Create free account
hub / github.com/vercel/examples / _timer

Function _timer

python/vibe-coding-ide/backend/src/agent/tools/sandbox.py:504–519  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

502 stop_event.set()
503
504 async def _timer() -> None:
505 nonlocal timed_out
506 if ready_deadline is None:
507 return
508 try:
509 now = time.time()
510 remaining = max(0.0, ready_deadline - now)
511 await asyncio.sleep(remaining)
512 if not stop_event.is_set():
513 timed_out = True
514 stop_event.set()
515 except Exception:
516 # best-effort timeout
517 if not stop_event.is_set():
518 timed_out = True
519 stop_event.set()
520
521 # After command start/finish, optionally compute a filesystem snapshot for auto-resync
522 if detached:

Callers 1

sandbox_runFunction · 0.85

Calls 1

setMethod · 0.80

Tested by

no test coverage detected