Skip to content

Commit

Permalink
top: Enable ruff linter check for F821 undefined-name.
Browse files Browse the repository at this point in the history
Very helpful for catching typos or missing imports when writing code!

Description can be found at
https://beta.ruff.rs/docs/rules/undefined-name/

Parent commits contain various small fixes and inline ignores for this
check.  The only blanket exception is manifest files, which are numerous
and evaluated with some global names pre-defined - these can be globally
ignored.

Signed-off-by: Angus Gratton <angus@redyak.com.au>
  • Loading branch information
projectgus authored and dpgeorge committed Aug 16, 2023
1 parent 1a5c9b9 commit 40fcbe1
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ ignore = [
"F401",
"F403",
"F405",
"F821",
"PLC1901",
]
line-length = 337
Expand All @@ -46,3 +45,7 @@ max-complexity = 40

[tool.ruff.per-file-ignores]
"ports/cc3200/tools/uniflash.py" = ["E711"]

# manifest.py files are evaluated with some global names pre-defined
"**/manifest.py" = ["F821"]
"ports/**/boards/manifest*.py" = ["F821"]

0 comments on commit 40fcbe1

Please sign in to comment.