Without cua-spacesd
Run commands, take screenshots and open the display of a local Lume sandbox that has no cua-spacesd.
Run commands, take screenshots and open the display of a local Lume sandbox that has no cua-spacesd.
The macOS 15 image ships no cua-spacesd, so sandbox.spacesd() fails for it (macOS 26 runs cua-spacesd). A local Lume sandbox is still reachable: commands over lume ssh, screenshots and the display over the VM's VNC endpoint. cua sb exec, cua sb screenshot and cua sb view use the same calls. Other sandboxes fail with Unsupported.
Python programs usually use the high-level API instead: cua_sandbox shell and screen.
Methods of Sandbox.
Sandbox.lacks_spacesd#Whether this sandbox has no cua-spacesd: it declares no env
service, or its image says it does not carry one. spacesd() fails
for these; guest_sh, guest_screenshot and guest_display reach a
local Lume sandbox without it.
def lacks_spacesd(self) -> boolReturns bool
Sandbox.guest_sh#Runs line with /bin/sh -c in the guest without cua-spacesd, to
completion (default timeout 120 s). Local macOS Lume sandboxes only:
over lume ssh, stdout and stderr kept apart, no stdin. Others fail
with Unsupported.
async def guest_sh(self, line: str, timeout_ms: Optional[int] = None) -> ProcessOutput| Parameter | Type | Default |
|---|---|---|
line | String | required |
timeout_ms | Option<u32> | None |
Returns ProcessOutput · Async · Raises CuaError (Unsupported)
Sandbox.guest_screenshot#Captures the guest framebuffer as PNG without cua-spacesd. Local Lume sandboxes only: over the VM's VNC endpoint.
async def guest_screenshot(self) -> ScreenshotReturns Screenshot · Async · Raises CuaError
Sandbox.guest_display#The guest display without cua-spacesd: the VM's VNC endpoint and a
host command that opens it (lume attach). Local Lume sandboxes
only.
async def guest_display(self) -> GuestDisplayReturns GuestDisplay · Async · Raises CuaError
GuestDisplay#The guest display of a sandbox without cua-spacesd
(Sandbox.guest_display). An object, not a record, so no binding's
default string form (repr, str, description, toString, Debug) can show
the VNC password: url() is masked, and only the explicit
url_with_password() returns it.
Returned by Sandbox.guest_display.
| Accessor | Returns | Description |
|---|---|---|
open_command() | Vec<String> | A host command that opens a viewer on it (lume attach <vm>); empty when there is none. It handles the password itself. |
url() | String | The display URL (vnc://HOST:PORT) with any password masked as ****. Safe to print and log. |
url_with_password() | String | SENSITIVE: the display URL with the VNC password (vnc://:PASSWORD@HOST:PORT), for handing to a VNC client. Never print or log it. |
via() | String | How the display is reached (vnc). |