-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpyproject.toml
More file actions
153 lines (139 loc) · 3.48 KB
/
pyproject.toml
File metadata and controls
153 lines (139 loc) · 3.48 KB
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
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
[project]
name = "infraalert"
version = "1.0.0"
description = "AI-powered multi-agent system for infrastructure issue reporting and response coordination"
readme = "README.md"
requires-python = ">=3.11"
license = {text = "MIT"}
authors = [
{name = "InfraAlert Team"}
]
keywords = ["ai", "agents", "infrastructure", "google-cloud", "adk"]
classifiers = [
"Development Status :: 4 - Beta",
"Intended Audience :: Developers",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
]
[project.optional-dependencies]
dev = [
"pytest>=8.0.0",
"pytest-cov>=4.1.0",
"pytest-asyncio>=0.23.0",
"ruff>=0.4.0",
"mypy>=1.8.0",
"pre-commit>=3.6.0",
]
[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"
[tool.hatch.build.targets.wheel]
packages = ["agents", "mcp_server"]
# Ruff Configuration (Linting + Formatting)
[tool.ruff]
line-length = 100
target-version = "py312"
exclude = [
".git",
"__pycache__",
".venv",
"venv",
"env",
"build",
"dist",
"node_modules",
"webapp/frontend",
]
[tool.ruff.format]
quote-style = "double"
indent-style = "space"
docstring-code-format = true
[tool.ruff.lint]
select = [
"E", # pycodestyle errors
"F", # pyflakes
"W", # pycodestyle warnings
"B", # flake8-bugbear
"I", # isort
"UP", # pyupgrade
"S", # flake8-bandit (security)
"C4", # flake8-comprehensions
"SIM", # flake8-simplify
"TCH", # flake8-type-checking
"RUF", # Ruff-specific rules
]
ignore = [
"E203", # whitespace before ':'
"E266", # too many leading '#' for block comment
"E501", # line too long (handled by formatter)
"S101", # assert usage (ok in tests)
"S104", # binding to all interfaces
"S105", # hardcoded password (false positives)
"S106", # hardcoded password (false positives)
"B008", # function call in default argument (ok for FastAPI/Flask)
]
[tool.ruff.lint.per-file-ignores]
"tests/**/*.py" = ["S101", "S105", "S106"]
"**/tests/*.py" = ["S101", "S105", "S106"]
"conftest.py" = ["S101"]
[tool.ruff.lint.isort]
known-first-party = ["agents", "mcp_server"]
force-single-line = false
combine-as-imports = true
# Pytest Configuration
[tool.pytest.ini_options]
testpaths = ["agents", "mcp_server"]
python_files = ["test_*.py", "*_test.py"]
python_classes = ["Test*"]
python_functions = ["test_*"]
addopts = [
"-v",
"--tb=short",
"-ra",
"--strict-markers",
]
markers = [
"slow: marks tests as slow (deselect with '-m \"not slow\"')",
"integration: marks tests as integration tests",
"unit: marks tests as unit tests",
]
filterwarnings = [
"ignore::DeprecationWarning",
"ignore::PendingDeprecationWarning",
]
asyncio_mode = "auto"
[tool.coverage.run]
source = ["agents", "mcp_server"]
branch = true
omit = [
"*/tests/*",
"*/__pycache__/*",
"*/conftest.py",
]
[tool.coverage.report]
exclude_lines = [
"pragma: no cover",
"def __repr__",
"raise NotImplementedError",
"if TYPE_CHECKING:",
"if __name__ == .__main__.:",
]
show_missing = true
# MyPy Configuration
[tool.mypy]
python_version = "3.12"
warn_return_any = true
warn_unused_configs = true
warn_redundant_casts = true
disallow_untyped_defs = false
check_untyped_defs = true
ignore_missing_imports = true
[[tool.mypy.overrides]]
module = [
"google.*",
"flask.*",
"pydantic.*",
"opentelemetry.*",
"africastalking.*",
]
ignore_missing_imports = true