Skip to content

AI junk#2201

Closed
mturac wants to merge 1 commit into
pallets:mainfrom
mturac:izon/fix-2176-indent-empty-first-line
Closed

AI junk#2201
mturac wants to merge 1 commit into
pallets:mainfrom
mturac:izon/fix-2176-indent-empty-first-line

Conversation

@mturac

@mturac mturac commented Jun 29, 2026

Copy link
Copy Markdown

Fixes #2176

The indent filter now respects blank=False for an empty first line even when first=True. Non-empty first lines and blank=True behavior stay unchanged.

Tests:

  • PYTHONPATH=src uv run --frozen pytest tests/test_filters.py -q -k indent
  • PYTHONPATH=src uv run --frozen pytest tests/test_filters.py -q
  • uv run --frozen ruff check src/jinja2/filters.py tests/test_filters.py
  • git diff --check

@davidism davidism closed this Jun 29, 2026
@davidism davidism changed the title Fix indent filter empty first line handling AI junk Jun 29, 2026
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.

indent filter ignores blank=False when first=True on first line

2 participants