From fb629de936fffe594d552e48525b9ff1a27b2bc8 Mon Sep 17 00:00:00 2001 From: Artur Shiriev Date: Mon, 27 Jul 2026 13:37:14 +0300 Subject: [PATCH] chore: adopt ruff 0.16.0 ruff 0.16.0 stabilized CPY001 (missing-copyright-notice) out of preview, so `select = ["ALL"]` now picks it up. Ignore it, matching modern-di. 0.16.0 also formats Python code blocks inside Markdown; reformat the one affected planning bundle. --- .../changes/2026-06-26.03-type-eof-action-seam.md | 11 ++++++++--- pyproject.toml | 1 + 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/planning/changes/2026-06-26.03-type-eof-action-seam.md b/planning/changes/2026-06-26.03-type-eof-action-seam.md index 7bf64d3..3e2ae76 100644 --- a/planning/changes/2026-06-26.03-type-eof-action-seam.md +++ b/planning/changes/2026-06-26.03-type-eof-action-seam.md @@ -26,13 +26,18 @@ change to what the tool does. ```python @dataclasses.dataclass(frozen=True) -class Noop: ... # empty, or already ends with exactly one terminator +class Noop: ... # empty, or already ends with exactly one terminator + + @dataclasses.dataclass(frozen=True) -class AppendLf: ... # lacks a trailing newline; append one LF +class AppendLf: ... # lacks a trailing newline; append one LF + + @dataclasses.dataclass(frozen=True) -class Truncate: # excess trailing newlines; truncate to `offset` (0 = empty) +class Truncate: # excess trailing newlines; truncate to `offset` (0 = empty) offset: int + _EofAction = Noop | AppendLf | Truncate ``` diff --git a/pyproject.toml b/pyproject.toml index c199853..22e8835 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -73,6 +73,7 @@ ignore = [ "D213", # "multi-line-summary-second-line" conflicting with D212 "COM812", # flake8-commas "Trailing comma missing" "ISC001", # flake8-implicit-str-concat + "CPY001", # no per-file copyright header ] isort.lines-after-imports = 2 isort.no-lines-before = ["standard-library", "local-folder"]