Skip to content

MNT: upgrading ruff to 0.16.x #20113

Description

@neutrinoceros

A new ruff minor appears

Blog post: https://astral.sh/blog/ruff-v0.16.0

This one is special (to me): of the 316 rule violations we get by upgrading now, 305 are for too-many-positional-arguments, a "rule" I've been informally discussing and advising in reviews for years throughout many projects. Crucially, this rule cannot be blinding applied to existing public APIs (without breaking them), and doesn't have as much value for private APIs, but it is extremely precious for new code, so my suggestion is to add local noqa comments (trivially done with ruff itself, e.g. uvx [email protected] check astropy --select PLR0917 --add-noqa) rather than disabling the rule globally.
Other violations should be trivally fixable. I'll keep track of them here.

RUF068

ISC004

FURB192

RUF036

Metadata

Metadata

Assignees

No one assigned

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions