Skip to content

Commit b9be0c7

Browse files
committed
Adjust flake8 settings
1 parent 3a947bd commit b9be0c7

File tree

1 file changed

+7
-1
lines changed
  • {{ cookiecutter.project_name.lower().replace(' ', '-') }}

1 file changed

+7
-1
lines changed

{{ cookiecutter.project_name.lower().replace(' ', '-') }}/pyproject.toml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -142,9 +142,15 @@ allowed-confusables = [
142142
"RUF001", # String contains ambiguous letter
143143
]
144144

145-
[tool.ruff.lint.flake8-tidy-imports] # https://docs.astral.sh/ruff/settings/#flake8-tidy-imports
145+
[tool.ruff.lint.flake8-tidy-imports] # https://docs.astral.sh/ruff/settings/#lintflake8-tidy-imports
146146
ban-relative-imports = "all"
147147

148+
[tool.ruff.lint.flake8-boolean-trap] # https://docs.astral.sh/ruff/settings/#lintflake8-bugbear
149+
extend-allowed-calls = ["pydantic.Field", "django.db.models.Value"]
150+
151+
[tool.ruff.lint.flake8-bugbear] # https://docs.astral.sh/ruff/settings/#lintflake8-bugbear
152+
extend-immutable-calls = ["fastapi.Depends", "fastapi.Query", "fastapi.Path", "fastapi.Body", "fastapi_filter.FilterDepends"]
153+
148154
[tool.ruff.lint.isort] # https://docs.astral.sh/ruff/settings/#isort
149155
section-order = ["future", "typing", "standard-library", "third-party", "first-party", "local-folder"]
150156
lines-between-types = 1

0 commit comments

Comments
 (0)