MCPcopy Create free account
hub / github.com/decodecaptcha/Browser-Env / show

Method show

examples/example_httpbin_pro.py:24–32  ·  view source on GitHub ↗
(self, file_name)

Source from the content-addressed store, hash-verified

22 self.child_pid = None
23
24 def show(self, file_name):
25 shell_process = subprocess.Popen(f'{file_name}', shell=True)
26 parent = psutil.Process(shell_process.pid)
27 for _ in range(999):
28 children = parent.children(recursive=True)
29 if children:
30 break
31 time.sleep(0.1)
32 self.child_pid = children[0].pid
33
34 def close(self):
35 subprocess.check_output(f"Taskkill /PID {self.child_pid} /F")

Callers 1

__init__Method · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected