Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

style: fix whitespace and formatting #447

Merged
merged 1 commit into from
Jan 3, 2024

Conversation

lotharbach
Copy link
Contributor

The contributing guide advises to run make lint. I fixed all existing ones in this separate PR before starting to add my own new errors.

Before:

(teslajsonpy-py3.11) ~/src/teslajsonpy (dev ✗) make lint
poetry run flake8 teslajsonpy
teslajsonpy/controller.py:342:1: W293 blank line contains whitespace
teslajsonpy/controller.py:347:10: W291 trailing whitespace
teslajsonpy/controller.py:415:1: W293 blank line contains whitespace
teslajsonpy/controller.py:425:67: W291 trailing whitespace
teslajsonpy/controller.py:426:1: W293 blank line contains whitespace
teslajsonpy/controller.py:428:25: E126 continuation line over-indented for hanging indent
teslajsonpy/controller.py:429:21: E121 continuation line under-indented for hanging indent
teslajsonpy/controller.py:429:22: W291 trailing whitespace
teslajsonpy/controller.py:446:22: W291 trailing whitespace
teslajsonpy/controller.py:697:1: W293 blank line contains whitespace
teslajsonpy/controller.py:704:1: W293 blank line contains whitespace
teslajsonpy/controller.py:707:1: W293 blank line contains whitespace
teslajsonpy/controller.py:716:66: W291 trailing whitespace
teslajsonpy/controller.py:810:1: W293 blank line contains whitespace
teslajsonpy/controller.py:813:1: W293 blank line contains whitespace
teslajsonpy/energy.py:125:27: W291 trailing whitespace
teslajsonpy/energy.py:156:42: W291 trailing whitespace
teslajsonpy/energy.py:158:1: W293 blank line contains whitespace
teslajsonpy/energy.py:160:5: E303 too many blank lines (2)
make: *** [flake8] Error 1

After:

(teslajsonpy-py3.11) ~/src/teslajsonpy (fix-make-lint ✔) make lint
poetry run flake8 teslajsonpy
poetry run pydocstyle teslajsonpy
poetry run pylint teslajsonpy

--------------------------------------------------------------------
Your code has been rated at 10.00/10 (previous run: 10.00/10, +0.00)

@lotharbach lotharbach changed the title Fix whitespace and formatting as per make lint Fix: whitespace and formatting as per make lint Jan 3, 2024
@lotharbach lotharbach changed the title Fix: whitespace and formatting as per make lint fix: whitespace and formatting as per make lint Jan 3, 2024
@alandtse
Copy link
Collaborator

alandtse commented Jan 3, 2024

Thanks. I forgot whether we set up a pre-commit or something to enforce this. But definitely do appreciate you doing the cleanup work.

@alandtse alandtse changed the title fix: whitespace and formatting as per make lint style: fix whitespace and formatting Jan 3, 2024
@alandtse alandtse merged commit 509cf4f into zabuldon:master Jan 3, 2024
5 of 7 checks passed
@lotharbach lotharbach deleted the fix-make-lint branch January 4, 2024 09:20
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants