Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for max line length for string and comment #681

Closed
blueyed opened this issue Sep 13, 2017 · 1 comment
Closed

Support for max line length for string and comment #681

blueyed opened this issue Sep 13, 2017 · 1 comment

Comments

@blueyed
Copy link

blueyed commented Sep 13, 2017

I've found that luacheck has support for different types of max-line-length:

  • New --[no-]max-code-line-length, --[no-]max-string-line-length,
    --[no-]max-comment-line-length CLI options and corresponding
    config and inline options that limit line length only for subsets of lines
    based on line type: string lines have their line endings within a string,
    comment lines have their line endings within a comment, other lines
    are code lines

It would be nice if this was supported by pycodestyle in a similar way:

Given a max line length of 79, you often have to wrap long strings or comments (or append a # noqa comment), which might result in e.g. an error message not being easily greppable.

It would be nice to have e.g. new options max-string-line-length and max-comment-line-length that would be applied for when the line ends with a string or comment, falling back to max-line-length.

@asottile
Copy link
Member

Duplicate of #906 (which has ~slightly more context)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants