# ruff 0.16.4 - Product: ruff (https://whatsnew.fyi/product/ruff) - Vendor: ruff - Date: 2026-08-20 - Version: 0.16.4 - Original notes: https://github.com/astral-sh/ruff/releases/tag/0.16.4 - Permalink: https://whatsnew.fyi/product/ruff/releases/0.16.4 What's New is an index, not a publisher: every entry below links to the vendor's own release notes, which are the authoritative source. Entries are labelled where they are hand-curated sample data, pre-releases, or drawn from a secondary source such as a developer blog. Reuse: the summaries, labels and curation here are © What's New. Quote freely with attribution and a link back; wholesale republication of the corpus is not permitted — terms: https://whatsnew.fyi/terms. The vendors' own release notes remain their publishers'. --- - **added** — Add autofix for PTH116 in flake8-use-pathlib - **changed** — Restrict delete-full-slice to lists (FURB131) in refurb - **changed** — Skip FURB101 and FURB103 when the open argument is a file descriptor in refurb - **fixed** — Fix InvalidInstruction on Windows CPUs that do not support POPCNT - **fixed** — Emit semantic syntax errors in string type definitions as F722 in pyflakes - **fixed** — Allow os._exit imports in import-private-name (PLC2701) in pylint - **changed** — Align mixed t-string/bytes error message with CPython 3.14 in syntax-errors - **changed** — Add ctypes.LittleEndianStructure and related types to existing exception (RUF012) in ruff - **added** — Detect duplicate keyword arguments in syntax-errors - **added** — Detect parameters declared nonlocal in syntax-errors - **changed** — Offer display-only fixes and mark safe fixes preferred in server - **added** — Support pull diagnostics for notebook cells in server - **fixed** — Fix s390x stacker assembly in release builds - **fixed** — Guarantee minimum stack size when parsing a module, standalone expression, and suites - **changed** — Reduce configuration deserialization code size - **fixed** — Check packed AST index bounds ##### Release Notes Released on 2026-08-20. ###### Preview features - \[`flake8-use-pathlib`\] Add autofix for `PTH116` ([#26460](https://github.com/astral-sh/ruff/pull/26460)) - \[`refurb`\] Restrict `delete-full-slice` to lists (`FURB131`) ([#27711](https://github.com/astral-sh/ruff/pull/27711)) - \[`refurb`\] Skip `FURB101` and `FURB103` when the `open` argument is a file descriptor ([#27643](https://github.com/astral-sh/ruff/pull/27643)) ###### Bug fixes - Fix `InvalidInstruction` on Windows CPUs that do not support `POPCNT` ([#27803](https://github.com/astral-sh/ruff/pull/27803)) - \[`pyflakes`\] Emit semantic syntax errors in string type definitions as `F722` ([#27835](https://github.com/astral-sh/ruff/pull/27835)) - \[`pylint`\] Allow `os._exit` imports in `import-private-name` (`PLC2701`) ([#27738](https://github.com/astral-sh/ruff/pull/27738)) ###### Rule changes - [syntax-errors] Align mixed t-string/bytes error message with CPython 3.14 ([#27766](https://github.com/astral-sh/ruff/pull/27766)) - \[`ruff`\] Add `ctypes.LittleEndianStructure` and related types to existing exception (`RUF012`) ([#27753](https://github.com/astral-sh/ruff/pull/27753)) - [syntax-errors] Detect duplicate keyword arguments ([#17804](https://github.com/astral-sh/ruff/pull/17804)) - [syntax-errors] Detect parameters declared `nonlocal` ([#27628](https://github.com/astral-sh/ruff/pull/27628)) ###### Server - Offer display-only fixes and mark safe fixes preferred ([#27807](https://github.com/astral-sh/ruff/pull/27807)) - Support pull diagnostics for notebook cells ([#27779](https://github.com/astral-sh/ruff/pull/27779)) ###### Documentation - Add default indicator to rules table ([#27724](https://github.com/astral-sh/ruff/pull/27724)) - Fix broken link to Python docs ([#27757](https://github.com/astral-sh/ruff/pull/27757)) ###### Other changes - Fix s390x stacker assembly in release builds ([#27776](https://github.com/astral-sh/ruff/pull/27776)) - Guarantee minimum stack size when parsing a module, standalone expression, and suites ([#25464](https://github.com/astral-sh/ruff/pull/25464)) - Reduce configuration deserialization code size ([#27924](https://github.com/astral-sh/ruff/pull/27924)) - Check packed AST index bounds ([#27849](https://github.com/astral-sh/ruff/pull/27849)) ###### Contributors - [@AbhinavMir](https://github.com/AbhinavMir) - [@eduardorittner](https://github.com/eduardorittner) - [@royb3](https://github.com/royb3) - [@MichaReiser](https://github.com/MichaReiser) - [@carljm](https://github.com/carljm) - [@rosstitmarsh](https://github.com/rosstitmarsh) - [@ntBre](https://github.com/ntBre) - [@zaniebot](https://github.com/zaniebot) - [@ewdurbin](https://github.com/ewdurbin) - [@woodruffw](https://github.com/woodruffw) - [@Sacrimento](https://github.com/Sacrimento) - [@lakshayxi](https://github.com/lakshayxi) - [@WhiteFox0-0](https://github.com/WhiteFox0-0) - [@baltasarblanco](https://github.com/baltasarblanco) ##### Install ruff 0.16.4 ###### Install prebuilt binaries via shell script ```sh curl --proto '=https' --tlsv1.2 -LsSf https://releases.astral.sh/github/ruff/releases/download/0.16.4/ruff-installer.sh | sh ``` ###### Install prebuilt binaries via powershell script ```sh powershell -ExecutionPolicy Bypass -c "irm https://releases.astral.sh/github/ruff/releases/download/0.16.4/ruff-installer.ps1 | iex" ``` ##### Download ruff 0.16.4 | File | Platform | Checksum | |--------|----------|----------| | [ruff-aarch64-apple-darwin.tar.gz](https://releases.astral.sh/github/ruff/releases/download/0.16.4/ruff-aarch64-apple-darwin.tar.gz) | Apple Silicon macOS | [checksum](https://releases.astral.sh/github/ruff/releases/download/0.16.4/ruff-aarch64-apple-darwin.tar.gz.sha256) | | [ruff-x86_64-apple-darwin.tar.gz](https://releases.astral.sh/github/ruff/releases/download/0.16.4/ruff-x86_64-apple-darwin.tar.gz) | Intel macOS | [checksum](https://releases.astral.sh/github/ruff/releases/download/0.16.4/ruff-x86_64- _[Truncated at 4000 characters — full notes: https://github.com/astral-sh/ruff/releases/tag/0.16.4]_