From 882af37d8e9ead1f273f63d365650334adee1a59 Mon Sep 17 00:00:00 2001 From: Holden Date: Fri, 12 Jun 2026 15:49:28 +0000 Subject: [PATCH] feat: VERBOSE=true enables DEBUG-level console output The log file already captures DEBUG unconditionally. This env var wires the same to the Rich console handler for troubleshooting without needing to read the log file. Co-Authored-By: Claude Sonnet 4.6 --- README.md | 1 + compose.yml | 1 + winnow/cli.py | 3 ++- 3 files changed, 4 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 9197c11..fa1386a 100644 --- a/README.md +++ b/README.md @@ -169,6 +169,7 @@ The first run after a fresh install downloads the embedding models (~1-2 GB). Su | Variable | Default | Description | | :--- | :--- | :--- | | `AUTO_MODE` | *(auto)* | Force non-interactive mode even in a terminal; auto-detected otherwise (no TTY = auto) | +| `VERBOSE` | `false` | Set to `true` to enable DEBUG-level console output | | `TRAINING_MODE` | `face` | `face` — upload crops to Frigate API; `object` — save crops to disk | | `STRATEGY` | `auto` | `auto` (adaptive), `standard` (30 images), `broad` (100 images) | | `LIMIT` | *(unset)* | Exact image count — overrides `STRATEGY` | diff --git a/compose.yml b/compose.yml index c6f367d..969a77f 100644 --- a/compose.yml +++ b/compose.yml @@ -12,6 +12,7 @@ services: # Auto mode is active by default when no TTY is present (Docker/cron). # Set AUTO_MODE=true to force auto mode in an interactive terminal. # To run interactively: docker exec -it winnow winnow + # - VERBOSE=true # Enable DEBUG-level console output # TRAINING_MODE: face = upload to Frigate face recognition API # object = save crops to output dir for manual Frigate placement - TRAINING_MODE=face diff --git a/winnow/cli.py b/winnow/cli.py index 4ea9fdb..a99983b 100644 --- a/winnow/cli.py +++ b/winnow/cli.py @@ -20,7 +20,8 @@ logger = logging.getLogger(__name__) def main() -> None: """Entry point for winnow CLI.""" try: - setup_logging(verbose=False) + verbose = os.environ.get("VERBOSE", "").lower() in ("true", "1", "yes") + setup_logging(verbose=verbose) console.print(r""" [bold blue]winnow[/bold blue]