Skip to content

B008 should ignore NewType wrapper #12717

@mezuzza

Description

@mezuzza

While it is possible to handle this using extend-immutable-calls, you'd have to manually add all NewType wrappers into the list if the NewType is using an immutable underlying type. The user experience would be much simpler and nicer to just use the underlying type of the NewType.

Of course, this would require some amount of type level knowledge and cross-file knowledge so I know that it'd be hard for ruff, but it also certainly doesn't fit in a type checker.

Metadata

Metadata

Assignees

No one assigned

    Labels

    type-inferenceRequires more advanced type inference.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions