Skip to content

Commit

Permalink
feat: fix ruff rules
Browse files Browse the repository at this point in the history
  • Loading branch information
kiyoon committed Jan 9, 2025
1 parent 3f9fef3 commit ebc31f1
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
5 changes: 5 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,8 @@ ignore = [
"ANN", # Missing type annotations
"ERA001", # commented-out code
"G", # Logging with format string
"EM", # error message has to be variable
"SLF001", # private member access
]

[tool.ruff.lint.per-file-ignores]
Expand Down Expand Up @@ -193,3 +195,6 @@ max-nested-blocks = 10
max-locals = 30
max-branches = 24

[tool.ruff.lint.mccabe]
# C901: limit the number of decision points in a function
max-complexity = 20
6 changes: 4 additions & 2 deletions src/ml_project/utils/deferred_logger.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
import logging
from collections.abc import Sequence
from typing import Any
from typing import TYPE_CHECKING, Any

if TYPE_CHECKING:
from collections.abc import Sequence


class DeferredLogger:
Expand Down

0 comments on commit ebc31f1

Please sign in to comment.