add ruff linter and refactor all code

This commit is contained in:
2024-06-09 20:54:41 +07:00
parent 5f014a4b8d
commit e65f5e16d0
6 changed files with 68 additions and 16 deletions
+18
View File
@@ -13,8 +13,26 @@ requests = "^2.31.0"
bs4 = "^0.0.2"
pymongo = "^4.6.1"
environs = "^11.0.0"
ruff = "^0.4.8"
[build-system]
requires = ["poetry-core"]
build-backend = "poetry.core.masonry.api"
[tool.ruff]
exclude = [
".git",
".ruff_cache",
".venv",
"venv",
"mongodb",
"data",
]
line-length = 92
[tool.ruff.lint]
select = ["E", "F", "UP", "I"]
[tool.ruff.format]
skip-magic-trailing-comma = true