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

Too long lines (E501) fail to be reported when ending with an open triple-quoted string #616

Closed
asottile opened this issue Apr 3, 2021 · 4 comments

Comments

@asottile
Copy link
Member

asottile commented Apr 3, 2021

In GitLab by @deubeuliou on Aug 31, 2017, 02:33

Please describe how you installed Flake8

# pip install flake8

Please provide the exact, unmodified output of flake8 --bug-report

{
  "dependencies": [
    {
      "dependency": "setuptools", 
      "version": "25.1.1"
    }
  ], 
  "platform": {
    "python_implementation": "CPython", 
    "python_version": "2.7.13", 
    "system": "Linux"
  }, 
  "plugins": [
    {
      "plugin": "mccabe", 
      "version": "0.6.1"
    }, 
    {
      "plugin": "pycodestyle", 
      "version": "2.3.1"
    }, 
    {
      "plugin": "pyflakes", 
      "version": "1.5.0"
    }
  ], 
  "version": "3.3.0"
}

Please describe the problem or feature

Too long lines (E501) fail to be reported when ending open with a triple-quoted string.

If this is a bug report, please explain with examples (and example code) what you expected to happen and what actually happened.

foo.py:

$ cat foo.py 
len("this line if 86 chars long and is not reported.....", "foo bar baz spam egg", """
        some other string""")

len("this line is 86 chars long and is reported.........", """foo bar baz spam egg""",
    "some other string")

$ flake8 foo.py 
foo.py:4:80: E501 line too long (86 > 79 characters)
@asottile
Copy link
Member Author

asottile commented Apr 3, 2021

In GitLab by @sigmavirus24 on Aug 31, 2017, 05:22

This is a bug in pycodestyle. Please report it to that project (
https://github.com/pycqa/pycodestyle/issues/new).

  • Ian

@asottile
Copy link
Member Author

asottile commented Apr 3, 2021

In GitLab by @deubeuliou on Aug 31, 2017, 14:30

done: PyCQA/pycodestyle#679

@asottile
Copy link
Member Author

asottile commented Apr 3, 2021

In GitLab by @deubeuliou on Aug 31, 2017, 14:30

closed

@asottile asottile closed this as completed Apr 3, 2021
@manu2504
Copy link

manu2504 commented Jan 21, 2022

@asottile the pycodestyle issue you're referring to is an old issue, the issue persists in flake8. I reported it there in PyCQA/pycodestyle#679 (comment), they said its flake8 specific though...

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