Skip to content

Add support for isort remove_redundant_aliases option #1875

@nefrob

Description

@nefrob

Ref: https://pycqa.github.io/isort/docs/configuration/options.html.

Tells isort to remove redundant aliases from imports, such as import os as os. This defaults to False simply because some projects use these seemingly useless aliases to signify intent and change behaviour.

Configuration in ruff:

[tool.ruff.isort]
remove_redundant_aliases = true

Metadata

Metadata

Assignees

No one assigned

    Labels

    isortRelated to import sorting

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions