chore: apply ruff rules on tests and app.py (#3605)

This commit is contained in:
Bowen Liang
2024-04-18 20:24:05 +08:00
committed by GitHub
parent d5448e07ab
commit d9b821cecc
92 changed files with 383 additions and 181 deletions

View File

@@ -3,9 +3,6 @@ requires-python = ">=3.10"
[tool.ruff]
exclude = [
"app.py",
"__init__.py",
"tests/",
]
line-length = 120
@@ -26,6 +23,20 @@ ignore = [
"UP032", # f-string
]
[tool.ruff.lint.per-file-ignores]
"app.py" = [
"F401", # unused-import
"F811", # redefined-while-unused
]
"__init__.py" = [
"F401", # unused-import
"F811", # redefined-while-unused
]
"tests/*" = [
"F401", # unused-import
"F811", # redefined-while-unused
]
[tool.pytest_env]
OPENAI_API_KEY = "sk-IamNotARealKeyJustForMockTestKawaiiiiiiiiii"