Skip to content

Most warnings calls do not set the stacklevel #10643

Closed
@anntzer

Description

@anntzer

Bug report

Bug summary

Calls to warnings.warn should usually set stacklevel=2 (or higher) so that the source line that gets displayed in the warnings message is the line triggering the code, not the line in mpl that has the warnings call (which is basically redundant with the warnings message itself). Right now most of the calls do not include the stacklevel argument.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Good first issueOpen a pull request against these issues if there are no active ones!

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions