SandboxProcessInfo

class baseten.sandbox.SandboxProcessInfo(*, pid, name, command, status, exit_code, stdout, stderr, logs, working_dir, started_at, completed_at, keep_alive, max_restarts, restart_count, restart_on_failure, stdin)

Bases: object

A process in a sandbox.

Parameters:
  • pid (str)

  • name (str)

  • command (str)

  • status (Literal['failed', 'killed', 'stopped', 'running', 'completed'] | str)

  • exit_code (int)

  • stdout (str)

  • stderr (str)

  • logs (str)

  • working_dir (str)

  • started_at (datetime)

  • completed_at (datetime | None)

  • keep_alive (bool | None)

  • max_restarts (int | None)

  • restart_count (int | None)

  • restart_on_failure (bool | None)

  • stdin (bool | None)

completed_at: datetime | None

When the process exited. None while it runs.

keep_alive: bool | None

Whether scale-to-zero is disabled for this process.

logs: str

Standard output and standard error, interleaved.

max_restarts: int | None

Maximum number of restarts on failure. Negative means unlimited.

pid: str

Process identifier, usable wherever a process name is.

restart_count: int | None

Number of times the process has been restarted.

restart_on_failure: bool | None

Whether the process is restarted when it fails.

stdin: bool | None

Whether the process was started with a writable stdin pipe.