v0.166.0 0.16.7

low risk

astral-sh/ruffSep 9, 2026 → Sep 10, 20261 day between releases

What's New

The older release focuses on Hugo's security and template changes, while the newer release introduces Python linting preview rules and resolves docstring rule conflicts.

New Features

  • Add rule for default values on method receivers (RUF077) as a preview feature
  • Recognize re.prefixmatch syntax (RUF039, RUF055)

Improvements

  • Reuse parser name lookups when interning
  • Speed up inherited configuration resolution
  • Recognize slice and frozendict generics
  • Stop defining __cached__ for Python 3.15

Bug Fixes

  • Alternate nested quotes inside format spec interpolations
  • Mark fix unsafe when it creates docstring (ISC003)
  • Skip fixes for multi-member imports (TID254)
  • Correct D211 and D203 rule conflict diagnostic

Upgrade Notes

Review new preview rules RUF077 and RUF039/RUF055; be aware of rule changes regarding __cached__ and generic types.

The Two Releases

v0.166.0

v0.166.0

Sep 9, 2026· 1 month ago

This release focuses on security hardening, dependency upgrades (Go 1.27, KaTeX 0.18.4, Glob v1.0.0), and template improvements like the `return` keyword and `.Render` context arguments.

Full release notes
0.16.7

0.16.7

Sep 10, 2026· 1 month ago

Ruff 0.16.7 introduces new preview rules for Python syntax and resolves conflicts between specific docstring rules. The release also includes performance optimizations and bug fixes for various linting integrations.

Full release notes