Skip to content

Linter: function parameters and line breaks #18

@JasonMWhite

Description

@JasonMWhite

When a function declaration uses type hints and needs to break across lines to stay within the character limit, we should have one parameter per line.

e.g.

def foo(self,
        bar: int,
        baz: str,
        qux: typing.Dict[str, typing.List[int]]) -> bool

    return True

and not:

def foo(self, bar: int, baz: str,
        qux: typing.Dict[str, typing.List[int]]) -> bool
    return True

As discussed https://github.com/Shopify/data_bang/pull/97#discussion_r105196063

@erikwright @honkfestival @cfournie does that about sum it up?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions