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

Re-enable formatting after define methods #619

Merged
merged 1 commit into from Nov 26, 2020

Conversation

greschd
Copy link
Member

@greschd greschd commented Nov 20, 2020

The calculations/__init__.py contained a # yapf: disable statement, but no # yapf: enable. My understanding is that single # yapf: disable are "allowed" only at the end of a specific line that shouldn't be formatted, otherwise it will apply for the entire rest of the file (see the examples in their README).

Here we add a # yapf: enable statement after the things that shouldn't be formatted, and apply the resulting formatting changes.

EDIT: Turns out calculations/__init__.py isn't the only affected file, updated the PR to add matching # yapf: enable everywhere.

@greschd greschd added the pr/blocked PR is blocked by another PR that should be merged first label Nov 20, 2020
@greschd greschd requested a review from sphuber November 20, 2020 10:29
@greschd greschd changed the title Fix formatting of calculations/__init__.py Re-enable formatting after define methods Nov 20, 2020
@greschd greschd removed the pr/blocked PR is blocked by another PR that should be merged first label Nov 24, 2020
The `define` methods typically contained a `# yapf: disable`
statement, but no matching `# yapf: enable`. As a result,
formatting was disabled for the remainder of the files.

This commit adds matching `enable` statements, and contains the
resulting formatting changes.
Copy link
Contributor

@sphuber sphuber left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @greschd . Love me some auto formatting

@sphuber sphuber merged commit 2c6d02f into aiidateam:develop Nov 26, 2020
@greschd greschd deleted the fix/formatting branch November 26, 2020 12:37
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

2 participants