Skip to content
This repository has been archived by the owner on May 13, 2024. It is now read-only.

Commit

Permalink
chore(linting): stricter ruff config
Browse files Browse the repository at this point in the history
  • Loading branch information
c0rydoras committed Apr 16, 2024
1 parent 0738ea2 commit a059fa4
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions ruff.toml
Original file line number Diff line number Diff line change
Expand Up @@ -68,25 +68,32 @@ ignore = [
"COM812", # ignore due to conflict with formatter
"ISC001", # ignore due to conflict with formatter
"E501", # managed by formatter
"D100", # don't enforce existance of docstrings
"D101", # don't enforce existance of docstrings
"D102", # don't enforce existance of docstrings
"D103", # don't enforce existance of docstrings
"D104", # don't enforce existance of docstrings
"D105", # don't enforce existance of docstrings
"D106", # don't enforce existance of docstrings
"D107", # don't enforce existance of docstrings
]

[lint.per-file-ignores]
"**/tests/*.py" = [
"**/{conftest.py,tests/*.py}" = [
"D", # pydocstyle is optional for tests
"ANN", # flake8-annotations are optional for tests
"S101", # assert is allow in tests
"S105", # tests may have hardcoded secrets
"S106", # tests may have hardcoded passwords
"S311", # tests may use pseudo-random generators
"S108", # /tmp is allowed in tests since it's expected to be mocked
"DTZ00", # tests often run in UTC
"INP001", # tests do not need a dunder init
"PLR0913", # tests can have a lot of arguments (fixtures)
"PLR2004", # tests can use magic values
]
"**/__init__.py" = [
"D104", # dunder init does not need a docstring because it might be empty
"**/*/factories.py" = [
"S311", # factories may use pseudo-random generators
]

[lint.isort]
Expand Down

0 comments on commit a059fa4

Please sign in to comment.