Skip to content

v1.16.0

Choose a tag to compare

@mpangrazzi mpangrazzi released this 31 Mar 07:23
4e0b2d3

✨ CLI & Logging Overhaul

This release brings a polished, branded look to the Hayhooks CLI and unifies all log output - including uvicorn, FastAPI, and application logs - through a single, color-coded Loguru pipeline. See PR for visual examples!

Branded CLI Theme

The entire CLI now uses a consistent color palette (#4A7AFF brand blue, semantic greens/reds/yellows) powered by a new Rich theme system. Panels have been replaced with lightweight prefixed messages (✔ / ✘ / !) for a cleaner, less noisy terminal experience. Typer help screens, tables, progress bars, and all status output follow the same visual language.

Unified Logging via Loguru

All stdlib loggers (uvicorn, uvicorn.error, uvicorn.access, fastapi) are now intercepted and routed through Loguru, giving you one consistent log format regardless of whether the message comes from the framework or application code. Key details:

  • Colored log levels — each severity gets its own distinct color
  • Request ID middleware — every HTTP/WebSocket request is tagged with a short unique ID (x-request-id header), threaded through all log lines via loguru.contextualize
  • Pipeline execution logging — pipeline runs now log their name, parameters, and elapsed time automatically
  • HAYHOOKS_LOG_LEVEL — new env var (replaces the legacy LOG alias, which still works as a fallback)
  • HAYHOOKS_LOG_FORMAT — set to verbose to include module:function:line metadata in every log line
  • HAYHOOKS_INTERCEPTED_LOGGERS — configure which stdlib loggers are intercepted (defaults to uvicorn + FastAPI; add haystack or others as needed)
  • log_config=None passed to uvicorn — prevents double-formatted log output

Shared Color Palette

A new hayhooks.colors module defines the canonical palette used by both the CLI (Rich) and the server (Loguru) layers, ensuring visual consistency across the entire tool.

📚 Documentation

  • Updated Environment Variables reference with the new HAYHOOKS_LOG_LEVEL, HAYHOOKS_LOG_FORMAT, and HAYHOOKS_INTERCEPTED_LOGGERS settings
  • Expanded Logging reference with verbose vs. default format examples and intercepted-logger configuration

🔧 CI

  • Switched to trusted publishing for PyPI releases (#233)

What's Changed

Full Changelog: v1.15.0...v1.16.0

Contributors