Skip to content

Live Session API

Tier: Stable Core

Commands sent to a running debug session, as the pyrung live CLI sends them.

pyrung.live.send_command

send_command(
    session_name: str,
    command: str,
    *,
    on_progress: Any = None,
) -> tuple[bool, str]

Connect, send command, return (ok, text).

If on_progress is provided it is called with each progress line (str) the server emits during long-running commands like how.

pyrung.live.list_sessions

list_sessions() -> list[str]

Return names of sessions whose servers are still reachable.

Stale port files (left by crashed or exited processes) are removed automatically.

pyrung.live.command_grammar

command_grammar() -> dict[str, CommandGrammar]

Return the grammar of every registered console command, keyed by verb.

Importing this module is not enough to see every verb — the console commands live in several modules that register on import, so this imports them all before reading the registry.