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

Run Tools/scripts/reindent.py #94225

Merged
merged 3 commits into from Jun 26, 2022
Merged

Run Tools/scripts/reindent.py #94225

merged 3 commits into from Jun 26, 2022

Conversation

vstinner
Copy link
Member

@vstinner vstinner commented Jun 24, 2022

Reindent files which were not properly formatted (PEP 8: 4 spaces).

Remove also some trailing spaces.

Leave Lib/test/coding20731.py and Tools/c-analyzer/ unchanged.

Reindent files which were not properly formatted (PEP 8: 4 spaces).

Remove also some trailing spaces.

Leave Lib/test/coding20731.py and Tools/c-analyzer/ unchanged.
@vstinner
Copy link
Member Author

vstinner commented Jun 24, 2022

I added labels to backport the changes to reduce the risk of conflicts when backporting other changes. And also to avoid "make patchcheck" issues on backports.

@vstinner
Copy link
Member Author

vstinner commented Jun 24, 2022

I ran the following command to prepare this change:

find -name "*.py" -print0|xargs -0 -n 1 ./python Tools/scripts/reindent.py

As I wrote, I reverted changes of Lib/test/coding20731.py and in Tools/c-analyzer/.

@vstinner
Copy link
Member Author

vstinner commented Jun 24, 2022

I wrote this PR because sometimes I got strange "make patchcheck" errors on the Ubuntu job of Azure Pipelines.

@terryjreedy
Copy link
Member

terryjreedy commented Jun 24, 2022

In iomenu.py, I am condensing the 4 lines above to 1 in #94228 and am removing the tab in that PR.

@vstinner
Copy link
Member Author

vstinner commented Jun 24, 2022

In iomenu.py, I am condensing the 4 lines above to 1 in #94228 and am removing the tab in that PR.

Ok, thanks.

@vstinner
Copy link
Member Author

vstinner commented Jun 24, 2022

Oh sadly, the test_enum change was wrong. enum does generate a trailing tab.

@zware
Copy link
Member

zware commented Jun 24, 2022

In test_enum, you could change the trailing tab to \x09 like the other \x20\x20 lines.

@vstinner
Copy link
Member Author

vstinner commented Jun 24, 2022

In test_enum, you could change the trailing tab to \x09 like the other \x20\x20 lines.

I mean that enum should not create such tab :-) If someone else wants to change test_enum in a separated PR, please go ahead ;-)

@vstinner
Copy link
Member Author

vstinner commented Jun 24, 2022

I wrote this PR for socket.py ;-)

@zware
Copy link
Member

zware commented Jun 24, 2022

I mean that enum should not create such tab :-)

Fair enough; that's more on pydoc than enum, though.

@vstinner vstinner merged commit e87ada4 into python:main Jun 26, 2022
12 checks passed
@miss-islington
Copy link
Contributor

miss-islington commented Jun 26, 2022

Thanks @vstinner for the PR 🌮🎉.. I'm working now to backport this PR to: 3.10, 3.11.
🐍🍒🤖

miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Jun 26, 2022
Reindent files which were not properly formatted (PEP 8: 4 spaces).

Remove also some trailing spaces.
(cherry picked from commit e87ada4)

Co-authored-by: Victor Stinner <vstinner@python.org>
@vstinner vstinner deleted the reindent branch Jun 26, 2022
@miss-islington
Copy link
Contributor

miss-islington commented Jun 26, 2022

Sorry, @vstinner, I could not cleanly backport this to 3.10 due to a conflict.
Please backport using cherry_picker on command line.
cherry_picker e87ada48a9e5d9d03f9759138869216df0d7383a 3.10

@bedevere-bot
Copy link

bedevere-bot commented Jun 26, 2022

GH-94290 is a backport of this pull request to the 3.11 branch.

@bedevere-bot
Copy link

bedevere-bot commented Jun 26, 2022

GH-94291 is a backport of this pull request to the 3.10 branch.

@vstinner
Copy link
Member Author

vstinner commented Jun 26, 2022

Merged, thanks for reviews!

miss-islington added a commit that referenced this pull request Jun 26, 2022
Reindent files which were not properly formatted (PEP 8: 4 spaces).

Remove also some trailing spaces.
(cherry picked from commit e87ada4)

Co-authored-by: Victor Stinner <vstinner@python.org>
vstinner added a commit that referenced this pull request Jun 26, 2022
Reindent files which were not properly formatted (PEP 8: 4 spaces).

Remove also some trailing spaces.

(cherry picked from commit e87ada4)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

7 participants