-
Notifications
You must be signed in to change notification settings - Fork 61
Expand file tree
/
Copy pathpyproject.toml
More file actions
121 lines (106 loc) · 3.21 KB
/
Copy pathpyproject.toml
File metadata and controls
121 lines (106 loc) · 3.21 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
# Copyright 2026 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
[project]
name = "backend"
version = "0.1.0"
description = "Backend services and agent simulations for Race Condition"
readme = "README.md"
requires-python = ">=3.13"
dependencies = [
"a2a-sdk>=0.3.26,<0.4.0",
"asyncpg>=0.30.0",
"google-adk[extensions,eval]==1.31.1",
"google-cloud-iamconnectorcredentials>=0.1.0",
"google-cloud-aiplatform>=1.143.0",
"google-adk-community>=0.4.1",
"google-genai>=1.70.0",
"pydantic>=2.12.5",
"python-dotenv>=1.2.2",
"google-cloud-pubsub>=2.30.0",
"fastapi>=0.136.1",
"uvicorn>=0.46.0",
"httpx>=0.27.0",
"protobuf>=5.29.3,<7",
"grpcio-tools>=1.70.0",
"websockets",
"redis>=5.0.0",
"anyio>=4.8.0",
"pypdf>=6.10.2",
]
[dependency-groups]
dev = [
"pytest>=9.0.3",
"pytest-asyncio>=1.3.0",
"pytest-cov>=6.0",
"diff-cover>=9.0",
"ruff>=0.15.12",
"honcho>=1.1.0",
"respx>=0.22.0",
]
[project.scripts]
init = "scripts.core.sim:init"
start = "scripts.core.sim:start_cli"
stop = "scripts.core.sim:stop_cli"
restart = "scripts.core.sim:restart_cli"
test = "scripts.core.sim:test"
test-integration = "scripts.core.sim:test_integration"
deploy = "scripts.deploy.deploy:main"
[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"
[tool.uv]
managed = true
package = true
[[tool.uv.index]]
name = "pypi"
url = "https://pypi.org/simple"
default = true
[tool.hatch.build.targets.wheel]
packages = ["scripts"]
[tool.pytest.ini_options]
addopts = "-m 'not slow and not integration'"
asyncio_mode = "auto"
asyncio_default_fixture_loop_scope = "function"
testpaths = ["agents", "scripts/deploy"]
python_files = ["*_test.py", "test_*.py"]
markers = [
"slow: marks tests as slow (deselect with '-m \"not slow\"')",
"integration: marks tests requiring external services (Redis, PubSub)",
]
[tool.coverage.run]
source = ["agents"]
omit = ["agents/tests/*", "agents/**/test_*"]
[tool.coverage.report]
fail_under = 60
show_missing = true
[tool.pyright]
# Point pyright at the uv-managed virtualenv so `npx pyright agents/`
# resolves project dependencies without needing per-invocation flags.
# `uv sync` creates ./.venv at the repo root.
venvPath = "."
venv = ".venv"
[tool.ruff]
target-version = "py313"
line-length = 120
[tool.ruff.lint]
select = ["E", "F", "W"]
[tool.ruff.lint.per-file-ignores]
# ADK agents use late imports for App/card registration (intentional pattern)
"agents/*/agent.py" = ["E402"]
"agents/*/*/agent.py" = ["E402"]
# __init__.py files re-export symbols
"agents/**/__init__.py" = ["F401"]
# Utility with circular dep avoidance and tests with dynamic module loading
"agents/utils/a2a.py" = ["E402"]
"agents/tests/*.py" = ["E402"]