Skip to content

Commit 69cb49a

Browse files
committed
Add per-file ignore rule for Ruff
1 parent e44af2e commit 69cb49a

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

pyproject.toml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,13 +41,17 @@ select = [
4141
[tool.ruff.lint.per-file-ignores]
4242
# Trailing whitespace in comment
4343
"binder/ipython_config.py" = ["E266"]
44+
4445
# suppress `raise ... from err`
4546
# Why we ignore B904 from the object-oriented tests?
4647
# We do want to raise an assertion error if the check on the solution function attributes fails,
4748
# but Python by default will raise a TypeError via vars(solution_result)
4849
# if the result is not a class and therefore doesn't have a __dict__ attribute.
4950
"tutorial/tests/test_object_oriented_programming.py" = ["B904"]
5051

52+
# Ignore invalid names like `import torch.nn.functional as F`
53+
"25_library_pytorch_language_modeling.ipynb" = ["N812"]
54+
5155
# Ruff formatting
5256
[tool.ruff.format]
5357
quote-style = "double"

0 commit comments

Comments
 (0)