pb_client.stdio ¶
What a hub says while a program is running on it.
Three kinds of thing arrive on one stream, and keeping them on one stream is the point: a caller drawing a terminal has to show output and status in the order they happened, and merging two streams afterwards cannot recover an order that was thrown away. So the service sends them down one connection in order, and they are parsed here into one union.
Output is bytes and stays bytes all the way from the hub.
A chunk can end in the middle of a multi-byte character, so anything that
decodes on the way through corrupts it; only the end that owns a terminal is in
a position to decode, and it needs an incremental decoder to do it.
Classes¶
Output-- A chunk of what the program on the hub printed.State-- The hub's connection changed state.Status-- What the hub currently reports about itself.
Functions¶
events-- Parse a hub's notifications as they arrive.
Attributes¶
REPL_PROGRAM_ID-- The program id the hub reports while its interpreter is what is running.