Skip to content

Allow explicit select of docstring rule to override configured convention #2606

@ngnpope

Description

@ngnpope

I know this is documented...

Setting a convention force-disables any rules that are incompatible with that convention, no matter how they're provided, which avoids accidental incompatibilities and simplifies configuration.

...but it seems a little excessive in some cases.

In particular, convention = "pep257" disables D212 and D213. PEP 257 states:

The summary line may be on the same line as the opening quotes or on the next line.

But I'd like to be a little stricter. I'd like to have convention = "pep257" and force enable D213. Not sure whether this is best as a new configuration option to make it something you have to explicitly opt in to, e.g. force-enable = ["D213"]?

(Using v0.0.241.)

Metadata

Metadata

Assignees

No one assigned

    Labels

    configurationRelated to settings and configuration

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions