MCPcopy Create free account
hub / github.com/deepclause/agentvm / start

Method start

example/vercel_agent.py:20–39  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

18 self.process = None
19
20 def start(self):
21 print("Booting VM...", file=sys.stderr)
22 self.process = subprocess.Popen(
23 ['node', self.bridge_path],
24 stdin=subprocess.PIPE,
25 stdout=subprocess.PIPE,
26 stderr=sys.stderr, # Forward stderr (logs) to user console
27 text=True,
28 bufsize=1
29 )
30
31 # Wait for READY signal
32 while True:
33 line = self.process.stdout.readline()
34 if not line:
35 raise RuntimeError("VM process exited unexpectedly")
36 if line.strip() == "READY":
37 break
38
39 print("VM Ready.", file=sys.stderr)
40
41 def exec(self, command):
42 if not self.process:

Callers 2

run_agentFunction · 0.95
getVMFunction · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected