Consistent output — replace bare print macros with output system#23
Merged
Merged
Conversation
Bare println!/eprintln! calls in exit.rs, entry.rs, and relay.rs bypassed the output system, causing inconsistent formatting, incorrect stream routing, and messages that ignored colour and format config. Replace all ad-hoc print calls with crate::info!, crate::warn!, and crate::error!. Auth warnings (the most visible case) are now routed through crate::warn! with consistent formatting. Connection retry messages go through crate::info!. Non-retryable failures use anyhow context so they surface once through the error chain rather than being printed separately and then re-displayed by main. The redundant println! in relay.rs that duplicated an existing crate::info! call is removed. REPL printer fallbacks (println! in the rustyline output thread) are unchanged — they are part of the Printer mechanism, not ad-hoc status output. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
The .dockerignore was missing a target/ exclusion rule, causing the entire 30 GB target directory to be sent as build context on every docker compose build. The exception path was also stale — pointing at the pre-CARGO_TARGET_DIR path instead of target/musl/. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Commits scoped to internal modules (e.g. feat(server):, feat(tls):) only touch crates/wallhack and were silently excluded from the cli changelog. Since all user-facing changes flow through wallhack before reaching the cli binary, tracking it ensures no feat or fix is missed. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Zero-config is a first-class feature. The per-connection auth warning on exit and relay nodes was noise — removed entirely. The --insecure flag existed only to suppress that warning so it is removed too. The entry node retains a single startup warning when no PSK is configured, which is the right place for it (once, at listen time, not on every incoming connection). Introduce route_info! and route_warn! macros in output.rs to route status messages through the Printer when in interactive/REPL mode, or the output system (stderr) when headless. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- gitignore: add AI agent instruction files (CLAUDE.md, GEMINI.md, copilot-instructions.md) and AI-generated docs patterns so they stay local without showing as untracked - TODO: remove completed zero-config auth warning item (done by previous commit), remove stale ANALYSIS.md reference Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
maxholman
added a commit
that referenced
this pull request
Mar 15, 2026
- #23: debug-level TCP relay connect/close logs with byte counts on exit node - #25: PskFailTracker deduplicates PSK failure logs per source IP (x1, x2, x4…) - #27: log "PSK authentication configured" on startup when PSK is set - #17: startup banner shows CLI binary version + build timestamp/git hash + dirty flag - Remove double-warn on PSK failure (validate_handshake + caller) Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Consistent output — replace bare print macros with output system
Scope
crates/cli/src/— exit.rs, entry.rs, relay.rsOut of scope
build.rs, version.rs, cli.rs, subscriber.rs, output.rs — these are all legitimate
uses of print macros and must not be changed.
Why
Some status and warning messages bypass the output system (the
info!,warn!,error!macros and thePrintertype in session.rs) and write directly viabare
println!oreprintln!. This causes inconsistent formatting, incorrectstream routing, and messages that ignore output configuration (colour, format).
The most visible symptom is the auth warning — "WARNING: Connecting without
authentication..." — which has its own ad-hoc format instead of going through
warn!.Notes
info!,warn!,error!,verbose!) are inoutput.rsand write to stderr via the global OUTPUT_CONFIG
Printerinsession.rsis for REPL/connection handler output and writesto stdout with styling
a one-to-one replacement of every call site