Expand description
Lines a tool prints to say it is waiting on a lock (ADR-0009,
hooks.liveness): the vocabulary, the framing that finds them in a
stream of bytes, and nothing that touches a clock.
Two tiers, deliberately. A marker is a line the real binary prints,
matched exactly, and it pauses the silence clock: the tool has said what
it is doing and the clock would otherwise call that stuck. A line that
merely looks like a wait earns one retry after a silence kill and
nothing more, because a loose match on lock would also pause the clock
for a test suite whose test ids contain the word.
Structs§
- Line
Framer - Turns a stream of byte chunks into complete lines, one chunk at a time.
What the stderr reader hands to
marker.
Enums§
- Cargo
Lock What - Which cargo lock a
Blocking waiting for file lock on …line names. - Wait
Kind - A declared wait: the tool and, where it says, the lock.
Constants§
- MAX_
LINE - The longest line the framer keeps while waiting for its newline. A tool that writes more than this without a newline is not printing status lines; the fragment is dropped rather than grown.
Functions§
- looks_
like_ wait - Whether a line reads like a wait, loosely: whole phrases only, so a test
id such as
test_lock.py::xor a file namedlock.rsis not one. The second tier — what earns one retry after a silence kill, never a pause. - marker
- The exact line a tool prints while it waits on a lock, or
None. - strip_
csi linewithout its CSI escape sequences (ESC [ … mand the rest of the family), so a tool toldCARGO_TERM_COLOR=alwaysstill matches. Only theESC [form: that is what colour is, and a stray loneESCis kept as text rather than guessed at.