Skip to content

Refactor logging, caching, and template rendering for clarity#38

Merged
coordt merged 21 commits intomasterfrom
code-review
Mar 28, 2026
Merged

Refactor logging, caching, and template rendering for clarity#38
coordt merged 21 commits intomasterfrom
code-review

Conversation

@coordt
Copy link
Copy Markdown
Member

@coordt coordt commented Mar 27, 2026

Description

Summary of Changes

  • Removed unused TemporaryDirectory mock from caching test.
  • Added extensive tests for:
    • Deeply nested templates.
    • Expression caching.
    • Indentation in structured loggers.
    • Validation of merge methods.
  • Introduced verbosity configuration for CLI build command.
  • Refactored variable naming in template rendering for better readability.
  • Replaced logging.getLogger with get_indented_logger in render.py for structured logging.
  • Implemented caching for default environment in expression rendering to enhance performance.
  • Updated options for merge methods and clarified the descriptions.
  • Renamed overwrite merge method to update to improve clarity.
  • Annotated type hints for parse_git_path (PathInfo) for better typing.
  • Introduced IndentedLoggerAdapter for structured and indented logging.
  • Pre-commit updates:
    • Added the pyupgrade hook.
    • Removed mdformat from pre-commit hooks.
  • Changed caching mechanism to use TEMPORARY_CACHE_DIR in place of TemporaryDirectory.
  • Updated Python dependencies, .gitignore, and changelog formatting configuration.

Dependencies Updated

  • Updated dependencies in uv.lock and pyproject.toml.
  • Modified .gitignore to exclude temporary Python files.
  • Adjusted changelog configuration to include MDFormat actions.

coordt added 13 commits March 27, 2026 09:32
- Updated Python dependencies in `uv.lock` and `pyproject.toml`, including package upgrades and additions.
- Added `temp.py` to `.gitignore` to ignore temporary Python files.
- Modified `.changelog-config.yaml` to include an MDFormat action for `CHANGELOG.md`.
Introduce a new `IndentedLoggerAdapter` to enable structured logging with customizable indentation. Includes utility methods for managing indent levels and a setup function for configuring logging verbosity with `RichHandler`.
@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Mar 27, 2026

PR Preview Action v1.8.1
Preview removed because the pull request was closed.
2026-03-28 13:10 UTC

@github-actions
Copy link
Copy Markdown
Contributor

Version hint: minor
Current version: 0.6.0
New version (when merged): 0.7.0

Comment ID: Display version hint-auto-generated

@coordt coordt merged commit e0482b3 into master Mar 28, 2026
10 checks passed
@coordt coordt deleted the code-review branch March 28, 2026 13:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant