Skip to main content

Module subprocess

Module subprocess 

Source
Expand description

Interactive subprocess I/O (spawn + piped stdin/stdout).

Windjammer std::subprocess maps here. Uses opaque handles so backends can swap implementation without changing the WJ API.

Structs§

SubprocessHandle
Opaque handle returned to Windjammer (Subprocess.handle).

Functions§

close
frames_in_agent_command
Parse frames=N from an agent CMD payload (default 1).
invalid_handle
is_valid
kill
read_agent_obs_n
Read N @AGENT OBS lines; returns the payload of the last one (no prefix).
read_line
read_line_until_prefix
Read lines until one starts with prefix (e.g. @AGENT OBS).
spawn
Spawn a program with piped stdin/stdout (stderr inherits to host). A background thread drains stdout so game init logs cannot deadlock the pipe.
wait
write_line