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

[th/flake8] add flake8 support (with .flake8 config, github action and fix warnings) #23

Merged
merged 4 commits into from
Sep 12, 2024

Conversation

thom311
Copy link
Contributor

@thom311 thom311 commented Aug 27, 2024

  • all: cleanup imports
  • requirements: add requirements.txt file with pip modules
  • flake8: fix various flake8 warnings
  • flake8: add ".flake8" configuration file

- sort imports
  - by name
  - imports from stdlib and pip modules first
  - "import" before "from x import"

- wrap lienes so that each import line only imports one name.
./dpu-tools/dpu-tools:61:9: F841 local variable device is assigned to but never used
./dpu-tools/dpu-tools:62:9: F841 local variable function is assigned to but never used
./pxeboot:513:22: C400 Unnecessary generator - rewrite as a list comprehension.
./reset:20:5: F841 local variable bf_pci is assigned to but never used
We need to this at least suppress E203. E203 is about
whitespace formatting and conflicts with python-black.
Black is the formatter that we use.
@bn222 bn222 merged commit ffe67d9 into bn222:main Sep 12, 2024
1 check passed
@thom311 thom311 deleted the th/flake8 branch September 12, 2024 15:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants