-
Notifications
You must be signed in to change notification settings - Fork 291
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
W605: identical tokens cause infinite loop #449
Milestone
Comments
planning to release version 1.4.3. |
version 1.4.3 released |
This still seems to be an issue again with 1.4.4:
|
fix in #514 . planning to release version 1.5. Thanks |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
There is a bug with the way that tokens are handled with W605 that causes an infinite loop to occur when two identical W605 tokens exist on the same line of code. This infinite loop can be observed both on the command line and by adding a test to the test_autopep8.py unit test file.
Test Case Code:
escape = foo('\.bar', '\.bar')\n
Command Line:
autopep8.py src/ -i -r --exclude "config_*" -a -j 8
Workaround:
--pep8-passes <n>
. This will break the infinite loop, but a bad code-fix is put in placeescape = foo(rrrrrrrrr'\.bar', '\.bar')\n
Version Info
autopep8.py --version : autopep8 1.4.1 (pycodestyle: 2.4.0)
/usr/bin/env python --version : Python 2.7.5
The text was updated successfully, but these errors were encountered: