-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpyproject.toml
79 lines (72 loc) · 2.09 KB
/
pyproject.toml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
[project]
name = "hive-cli"
version = "0.6.7"
description = "Add your description here"
readme = "README.md"
requires-python = ">=3.12"
dependencies = [
"cryptography>=43.0.1",
"docker>=7.1.0",
"fastapi>=0.114.0",
"gitpython>=3.1.43",
"humanize>=4.11.0",
"nicegui>=2.7.0",
"poethepoet>=0.31.1",
"psygnal>=0.11.1",
"pydantic-settings>=2.4.0",
"python-dotenv>=1.0.1",
"requests>=2.32.3",
]
[dependency-groups]
dev = [
"mypy>=1.14.1",
"pre-commit-hooks>=5.0.0",
"pytest>=8.3.3",
"ruff>=0.6.4",
"types-docker>=7.1.0.20240827",
"types-pyyaml>=6.0.12.20240917",
]
[tool.poe.tasks]
prod.script = "hive_cli.server:prod()"
dev = "uv run dev.py"
lint = "uv run mypy hive_cli"
test = "uv run pytest tests"
release = "uv run release.py"
# Without build system declaration the package cannot be imported
# https://github.com/astral-sh/uv/issues/9291
# https://github.com/astral-sh/uv/issues/1626
[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"
[tool.ruff.lint]
# 1. Enable flake8-bugbear (`B`) rules, in addition to the defaults.
select = [
"E", # pycodestyle errors
"W", # pycodestyle warnings
"I", # isort (imports) styling
"N", # pep8 naming checks
"B", # bugbear checks
"ANN", # type annotations
"S", # bandid code security
"C", # improve code comprehension
"EM", # use recommended error message composition
"G", # use recommended logging format
"T20", # no print allowed
"PT", # pytest styling recommendations
"SLF", # prevent access to private members
"SIM", # code simplification recommendations
"TCH", # checks for type checking imports
"ARG", # no unused arguments
"PERF", # performance anti pattern
# "FURB", # enforces modern python
# "D", # enforce documented functions [will be enabled soon]
]
ignore = [
"ANN101"
]
# 2. Fix everything except flake8-bugbear (`B`) violations.
fixable = ["ALL"]
unfixable = ["B"]
# 3. Things to ignore
[tool.ruff.lint.per-file-ignores]
"tests/*" = ["S101"] # assert is fine in pytest