/oss · 1 merged

psf/black

The most widely used Python code formatter.

the project on GitHub (opens in a new tab)
  1. 12 Nov 2026

    Formatting a selection keeps stacked decorators valid

    What was broken
    Formatting only some lines of a file indented with two spaces or tabs broke stacked decorators elsewhere, and Black stopped with an invalid code error.
    What I changed
    Each decorator outside the selection is now kept and re-indented on its own.
    Why it matters
    Format-selection in editors works on these files.

    see the code, #5672 (opens in a new tab)

← every project