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
WIP: Clean up trailing whitespace in PEP sources #1022
Conversation
Other than satisfying your desire to "Marie Kondo" the world, what problem does this solve? |
@gvanrossum the idea comes from your review comment on a similar PR merged by you, where it was suggested to do this: #983 (review). This PR adds the automation to prevent this from happening again (unlike the merged PR) and cleans up all the remaining instances of trailing spaces so that the build works. If you've changed your mind about this topic and this is not welcome, that's fine by me. Please do close this PR and #988 in that case. Please don't assume or imply things about what motivates me to contribute here or elsewhere. I'm just trying to help out and this seemed like a trivial change to make. I don't have any desire to '"Marie Kondo" the world' and your implication that I do, is dismissive and feels more like a personal criticism of me based on an assumption, possibly made without looking at why the change has been suggested. |
(for those following via email, I've made quite a few edits to the previous comment) |
I'm glad that you want to help, and I'm sorry I made you feel that way. Let me explain what I meant (though I said it clumsily in an attempt at humor). I don't recall if the official policy is written up anywhere, and different core developers seem to feel differently about this, but I believe that cleanup PRs are usually not worth it. They add noise to There's one thing that I do think is worth fixing -- generate pep 0 without trailing spaces. If you can submit a patch for that I would welcome it. |
Thanks for the clarification. :) I am aware of how you feel about cleanup PRs (and I mostly agree). Since you'd approved and merged a similar PR and additionally asked for automation for detecting this situation, I figured this would be an okay change to make. I personally don't think having extra .rstrip() calls in genpep0 would do any good on its own so I won't be submitting a patch for that. None the less, it might be handy to close #988 if you think this isn't a change worth making. |
Fixes #988
This is a WIP but I welcome feedback on the code changes here.
The main thing left is that PEP 0 is generated with trailing spaces. I can think of two approaches to deal with that:
I'm leaning toward doing the latter.