Release Notes
Released on 2026-03-12.
Preview features
- Add support for
lazyimport parsing (#23755) - Add support for star-unpacking of comprehensions (PEP 798) (#23788)
- Reject semantic syntax errors for lazy imports (#23757)
- Drop a few rules from the preview default set (#23879)
- [
airflow] FlagVariable.get()calls outside of task execution context (AIR003) (#23584) - [
airflow] Flag runtime-varying values in DAG/task constructor arguments (AIR304) (#23631) - [
flake8-bugbear] Implementdelattr-with-constant(B043) (#23737) - [
flake8-tidy-imports] AddTID254to enforce lazy imports (#23777) - [
flake8-tidy-imports] Allow users to ban lazy imports withTID254(#23847) - [
isort] Retainlazykeyword when sorting imports (#23762) - [
pyupgrade] Addfrom __future__ import annotationsautomatically (UP006) (#23260) - [
refurb] Supportnewlineparameter inFURB101for Python 3.13+ (#23754) - [
ruff] Addos-path-commonprefix(RUF071) (#23814) - [
ruff] Add unsafe fix for os-path-commonprefix (RUF071) (#23852) - [
ruff] LimitRUF036to typing contexts; make it unsafe for non-typing-only (#23765) - [
ruff] Use starred unpacking forRUF017in Python 3.15+ (#23789)
Bug fixes
- Fix
--add-noqacreating unwanted leading whitespace (#23773) - Fix
--add-noqabreaking shebangs (#23577) - [formatter] Fix lambda body formatting for multiline calls and subscripts (#23866)
- [formatter] Preserve required annotation parentheses in annotated assignments (#23865)
- [formatter] Preserve type-expression parentheses in the formatter (#23867)
- [
flake8-annotations] Fix stack overflow inANN401on quoted annotations with escape sequences (#23912) - [
pep8-naming] Check naming conventions inmatchpattern bindings (N806,N815,N816) (#23899) - [
perflint] Fix comment duplication in fixes (PERF401,PERF403) (#23729) - [
pyupgrade] Properly triggersuperchange in nested class (UP008) (#22677) - [
ruff] Avoid syntax errors inRUF036fixes (#23764)
Rule changes
- [
flake8-bandit] FlagS501withrequests.request(#23873) - [
flake8-executable] Fix WSL detection in non-Docker containers (#22879) - [
flake8-print] Ignorepprintcalls withstream=(#23787)
Documentation
- Update docs for Markdown code block formatting (#23871)
- [
flake8-bugbear] Fix misleading description forB904(#23731)
Contributors
- @zsol
- @carljm
- @ntBre
- @Bortlesboat
- @sososonia-cyber
- @chirizxc
- @leandrobbraga
- @11happy
- @Acelogic
- @anishgirianish
- @amyreese
- @xvchris
- @charliermarsh
- @getehen
- @Dev-iL
Install ruff 0.15.6
Install prebuilt binaries via shell script
curl --proto '=https' --tlsv1.2 -LsSf https://releases.astral.sh/github/ruff/releases/download/0.15.6/ruff-installer.sh | shInstall prebuilt binaries via powershell script
powershell -ExecutionPolicy Bypass -c "irm https://releases.astral.sh/github/ruff/releases/download/0.15.6/ruff-installer.ps1 | iex"Download ruff 0.15.6
Verifying GitHub Artifact Attestations
The artifacts in this release have attestations generated with GitHub Artifact Attestations. These can be verified by using the GitHub CLI:
gh attestation verify <file-path of downloaded artifact> --repo astral-sh/ruffYou can also download the attestation from GitHub and verify against that directly:
gh attestation verify <file-path of downloaded artifact> --bundle <file-path of downloaded attestation>