MCPcopy Create free account
hub / github.com/ScaleML/AgentSPEX / _make_screenshot

Function _make_screenshot

tests/tool_tests/test_som_annotator.py:49–54  ·  view source on GitHub ↗

Create a temporary PNG screenshot and return its path.

(width=200, height=150)

Source from the content-addressed store, hash-verified

47
48
49def _make_screenshot(width=200, height=150) -> str:
50 """Create a temporary PNG screenshot and return its path."""
51 img = Image.new("RGB", (width, height), color=(255, 255, 255))
52 tmp = tempfile.NamedTemporaryFile(suffix=".png", delete=False)
53 img.save(tmp.name)
54 return tmp.name
55
56
57def _elem(

Calls

no outgoing calls

Tested by

no test coverage detected