Skip to content

ci(ruff): reformat Python snippets in three skill markdown files - #1117

Merged
potiuk merged 1 commit into
apache:mainfrom
potiuk:fix-ruff-format-skill-snippets
Aug 26, 2026
Merged

ci(ruff): reformat Python snippets in three skill markdown files#1117
potiuk merged 1 commit into
apache:mainfrom
potiuk:fix-ruff-format-skill-snippets

Conversation

@potiuk

@potiuk potiuk commented Aug 26, 2026

Copy link
Copy Markdown
Member

Summary

  • ruff format --check currently fails on main, which breaks the required
    prek status on every open PR — including unrelated ones (spotted on chore(asf.yaml): refresh collaborators list and keep approvals through pushes #1116,
    an .asf.yaml-only change).
  • Three fenced ```python blocks inside skill docs predate the ruff 0.16.1
    bump in 5b504d8 and no longer match the formatter:
    skills/contributor-nomination/fetch.md:202,
    skills/contributor-sentiment/SKILL.md:217,
    skills/issue-reproducer/verification.md:60.
  • This applies exactly what ruff format produces and nothing else: comment
    gaps normalised to two spaces, binary operators spaced, and a blank line
    after an import re. No snippet changes behaviour or meaning.

Type of change

  • CI / dev loop (prek, workflows, validators)

Test plan

  • uv run ruff format --check skills/143 files already formatted
  • prek run --files <the three files> passes every applicable hook
    (markdownlint, lychee, check-placeholders, skill-and-tool-validate included)
  • Diff is formatter output only; no skill behaviour is touched, so no eval
    fixture changes apply.

RFC-AI-0004 compliance

Not applicable — whitespace-only changes to documentation snippets.

Linked issues

Refs #1116 (blocked by this failure).

Notes for reviewers

In issue-reproducer/verification.md the reformatted "Bad" Python block now
sits next to an unchanged Java block that still uses wide comment alignment —
ruff doesn't touch Java. The visual asymmetry is cosmetic; aligning the Java
snippet by hand seemed worse than leaving the formatter as the single source
of truth.

`ruff format --check` fails on `main`, breaking the required `prek`
status on every PR:

    3 files would be reformatted, 140 files already formatted
      skills/contributor-nomination/fetch.md:202
      skills/contributor-sentiment/SKILL.md:217
      skills/issue-reproducer/verification.md:60

All three are fenced ```python blocks inside skill docs whose
formatting predates the ruff 0.16.1 bump in 5b504d8. The changes are
what `ruff format` produces and nothing else: comment gap normalised to
two spaces, binary operators spaced, and a blank line after the `import
re` block. No snippet's behaviour or meaning changes.
@potiuk
potiuk merged commit b7da5fa into apache:main Aug 26, 2026
10 checks passed
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.

2 participants