Expand description
Line-oriented debug and warning diagnostics on standard error.
What:
Line-oriented debug and warning diagnostics on standard error,
switched like the
incumbent’s console sink.
Why:
The incumbent prints debug records only when MONOCHROMATIC_VERBOSE=true and warnings
unless MONOCHROMATIC_WARN=false (package/module/logger/src/sink/console.ts),
and its
spec requires that diagnostics never corrupt a JSONL stream:
each diagnostic is one
complete line written in one call (SPEC.md,
“Debug logging”).
In TS you’d write (pseudocode):
const l = tagged({ tag: 'cli-git' }); l.debug(message); l.warn(message);Functions§
- debug
- What:
Print a debug diagnostic when verbose diagnostics are on.
tagnames the function or module boundary, as the incumbent’s tagged loggers do. Why: Decisions such as “owner alive, skipping” are invisible otherwise. - diagnostic_
line - What:
One diagnostic line in the incumbent’s console format,
[<level>] [<ISO time>] [cli-git] [<tag>] <message>, with every control character of the message replaced by a space. Why: The incumbent’s tagged loggers print[warn] [2026-10-06T21:40:39.524Z] [cli-git] ...; one line per record keeps standard error parseable beside JSONL events. - verbose_
enabled - What:
Whether debug diagnostics are on:
MONOCHROMATIC_VERBOSEis exactlytrue. Why: The switch is shared with the TypeScript tools (decision recorded indoc/handover/cli-git-rust-implementation.md, “Adopted without a question”). - warn
- What: Print a warning unless warnings are suppressed. Why: Conditions the user should know about that do not fail the command, such as a landed-capture record that could not be written.
- warnings_
suppressed - What:
Whether warnings are suppressed:
MONOCHROMATIC_WARNis exactlyfalse. Why: Machine-protocol consumers silence warnings this way in the incumbent.