-
Notifications
You must be signed in to change notification settings - Fork 532
PEP8 violation cleanup - Nov2017 #2358
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
Conversation
…rts: interfaces.freesurfer
…next logical line
…alse:' or 'if not cond:'
…alse:' or 'if not cond:'
May I ask to merge this after #2325? |
My PR had some conflicts with master. I corrected those conflicts with e98e51b. For all conflicts, I chose master over my PR, except for the errors E501:
|
@oesteban, added the entries to CHANGES. I wasn't aware about |
There are still 9493 E501 violations in the code left, mostly caused by the following 29 files:
Do you want me to clean them up with this PR or should I gather them in a new PR to split the review process? Also, for the possibility that this was missed. I've opened two issues (#2356, #2357) with additonal clean up suggestions. |
I'd leave those E501 for another PR. BTW, is that with 79 or 99 characters long? I'd go for extending the line width a bit. |
+1 for extending the line width |
This was done with max. 79 characters per line. Using 99 characters would reduce the number of errors from ~9500 to ~4000. I'm ok to change the line length to 99, but if it's about the effort to clean it. 79 length is fine for me. The difference is anyhow not too big. The 4000 errors of 99 max length are caused by 180 files and the 9500 errors of 79 max length are caused by 225 files. |
Thanks a lot for this effort @miykael. It will pay back shortly after we merge it. I'm pretty swamped right now, so I would ask @djarecka or @mgxd to have the final look and merge this PR. Thank you all for this work 👍 Regarding the line width, I see there's not a huge difference. But I presume the top 50 files more rapidly evolving in nipype will not be included in the list of 180 files, while some will in the list of 225 for 79 chars. |
@miykael - thanks for the work! Have you decided to move other changes to new PRs? Is this PR ready to review? |
@oesteban and @djarecka - thanks for the nice feedback. @djarecka - I haven't done anything more for the moment. In my opinion it's ready to be reviewed. Once it's merged, I will tackle the remaining violations (if that's ok). Perhaps best by file, so that too rapidly evolving files can be excluded from merging. |
@djarecka, cool. Just saw @satra's PR, makes the whole thing much simpler and easier to maintain. As satra said, it's alot to look at. But yapf does a really good job and seems to pick up even some additional style issues that wouldn't create a PEP error, such as:
So for me, it's ok to review satra's PR and close this one, once everything was merged. |
This PR cleans up most of the PEP8 violations mentioned in #2306, except
E501 - line too long (82 > 79 characters)
. E501 will be attempted at a later time point, as it implies up to 10'000 mostly manual edits.For more detailed information about the remaining violations, see #2306.