-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Expand file tree
/
Copy pathpyproject.toml
More file actions
264 lines (255 loc) · 8.55 KB
/
Copy pathpyproject.toml
File metadata and controls
264 lines (255 loc) · 8.55 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
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
[build-system]
requires = ["setuptools>=68.0", "wheel"]
build-backend = "setuptools.build_meta"
[project]
name = "opensre"
version = "0.1"
description = "Open-source SRE agent for automated incident investigation and root cause analysis. Automatically analyzes alerts from Slack, Grafana, Datadog, and other tooling."
readme = "README.md"
requires-python = ">=3.12"
license = { text = "Apache-2.0" }
authors = [
{ name = "OpenSRE", email = "support@opensre.com" },
]
keywords = ["sre", "devops", "incident", "rca", "llm", "ai", "agent", "observability"]
dependencies = [
# Core AI/Agent
"anthropic>=0.77.1",
"mcp>=1.28.1",
"openai>=2.0.0",
"litellm>=1.90.0,<1.101.0",
# Data validation
"pydantic>=2.12.5,<3",
"pydantic-settings>=2.12.0,<3",
"kubernetes>=28.1.0",
# HTTP and async
"httpx[socks]>=0.27.0",
"aiohttp>=3.9.0",
"fastapi>=0.135.3",
"uvicorn[standard]>=0.30.0",
# Authentication
"PyJWT>=2.13.0",
# 50.0.0 is the first version patched for CVE-2026-69247 (GHSA-g6cj-pr64-35w5,
# PKCS#7 Bleichenbacher oracle). cryptography >=49 ships no x86-64 macOS wheel,
# so the frozen darwin-x64 release binary builds it from source against
# OpenSSL >= 3.2 (SSL_get0_group_name). release.yml pins Homebrew openssl@3
# and re-copies those dylibs into the PyInstaller onedir bundle.
"cryptography>=50.0.0,<51",
# AWS
"boto3>=1.42.88",
# Slack (Socket Mode gateway + Web API)
"slack-sdk>=3.31.0",
# Discord (Gateway WebSocket chat transport)
"discord.py>=2.4.0,<3",
# Utilities
"python-dotenv>=1.2.2",
"click>=8.1.0",
"rich>=15.0.0",
"questionary>=2.1.1",
"prompt_toolkit>=3.0.0",
"PyYAML>=6.0",
"tzdata>=2026.1",
# OpenTelemetry
"opentelemetry-api>=1.41.0",
"opentelemetry-sdk>=1.20.0",
"opentelemetry-exporter-otlp-proto-http>=1.41.0",
"opentelemetry-instrumentation>=0.40b0",
"opentelemetry-instrumentation-botocore>=0.40b0",
"opentelemetry-instrumentation-requests>=0.40b0",
# Tracer
"tracer_decorator",
# Google APIs
"google-api-python-client>=2.194.0,<3.0.0",
"google-auth>=2.0.0,<3.0.0",
# MongoDB
"pymongo>=4.6.0,<6.0.0",
# Redis
"redis>=5.0.0,<9.0.0",
# Signature verfication for discord
"PyNaCl>=1.5.0",
# MariaDB
"pymysql>=1.1.0,<2.0.0",
# ClickHouse (used by first-class SigNoz + ClickHouse integrations)
"clickhouse-connect>=0.15.1,<1.0.0",
"sentry-sdk>=2.59.0",
# File locking for atomic store operations
"filelock>=3.29.0",
"psutil>=5.9",
# Scheduler for cron-driven deliveries
"APScheduler>=3.10.0,<4.0.0",
]
[project.urls]
Homepage = "https://github.com/Tracer-Cloud/opensre"
Repository = "https://github.com/Tracer-Cloud/opensre"
Issues = "https://github.com/Tracer-Cloud/opensre/issues"
Changelog = "https://github.com/Tracer-Cloud/opensre/releases"
[project.scripts]
opensre = "surfaces.entrypoint:main"
[project.optional-dependencies]
dev = [
"pre-commit>=4.0.0",
"pytest>=8.0.0",
"pytest-asyncio>=1.3.0",
"pytest-cov>=7.1.0",
"pytest-timeout>=2.3.0",
"pytest-xdist>=3.5.0",
"ruff>=0.4.0",
"mypy>=1.10.0",
"import-linter>=2.0",
"vulture>=2.14",
"types-requests",
"types-psycopg2",
"types-PyMySQL",
"types-PyYAML",
"types-psutil",
"boto3-stubs[essential]",
"huggingface_hub>=0.26.0",
"datasets>=3.0.0",
# Exercises the Langfuse trace adapter in CI; production installs opt in
# via the ``langfuse`` extra.
"langfuse>=4.15.2,<5",
]
# Optional LLM tracing backend. Activated only when LANGFUSE_PUBLIC_KEY and
# LANGFUSE_SECRET_KEY are set; without the extra installed the runtime keeps
# running with the noop observation sink.
langfuse = [
"langfuse>=4.15.2,<5",
]
release-dist = [
"build>=1.2.0",
"twine>=6.0.0",
]
release-binary = [
"pyinstaller>=6.3.0",
]
# Backward-compatible aggregate extra.
release = [
"build>=1.2.0",
"twine>=6.0.0",
"pyinstaller>=6.3.0",
]
opensre-hub = [
"huggingface_hub>=0.26.0",
"datasets>=3.0.0",
]
kafka = [
"confluent-kafka>=2.14.0",
]
# Backward-compatible no-op extra; ClickHouse is now a core dependency.
clickhouse = [
"clickhouse-connect>=0.15.1",
]
postgresql = [
"psycopg2-binary>=2.9.0,<3.0.0",
]
azure_sql = [
"pyodbc>=5.1.0,<6.0.0",
]
# Cloud Logging is the one Yandex Cloud read that has no REST endpoint; the
# entry reader is gRPC-only. Everything else in the integration is REST, so the
# stubs stay optional and only `read_yc_logs` needs them.
yandex_cloud_logs = [
"yandexcloud>=0.300.0",
]
[tool.setuptools.packages.find]
include = [
"bootstrap*",
"config*",
"core*",
"gateway*",
"infrastructure*",
"integrations*",
"surfaces*",
"tests*",
"tools*",
]
[tool.setuptools.package-data]
"core.agent_harness.prompts" = ["opensre_system_prompt.md", "skills/**/*.md", "skills/**/scripts/*.py"]
"integrations" = ["**/SKILL.md", "yandex_cloud/api_index.json"]
"tools" = ["**/SKILL.md"]
# With pytest-xdist (-n auto), each worker writes a fragment; put them under
# .pytest_cache/ (already gitignored) instead of .coverage.<hostname>.* at repo root.
[tool.coverage.run]
data_file = ".pytest_cache/.coverage"
[tool.vulture]
paths = [
"bootstrap",
"config",
"core",
"gateway",
"infrastructure",
"integrations",
"surfaces",
"tools",
]
exclude = [
"gateway/tests/",
]
ignore_decorators = [
"@*.command", # Click / Typer subcommands
"@*.group",
"@*.callback",
"@*.add", # prompt_toolkit KeyBindings handlers
"@app.*", # FastAPI routes
"@*router.*", # FastAPI sub-routers (discord_router etc.)
"@field_validator", # Pydantic validators
"@model_validator",
"@validator",
"@cache",
"@lru_cache",
"@tool", # @tools.tool_decorator.tool registrations
"@mcp.tool",
"@register*",
]
ignore_names = [
"shell_complete", "format_help", "show", # Click overrides
"__getattr__", "__dir__", # PEP 562 lazy exports
"_normalize_*", # Pydantic field validators
"_require_*", # Pydantic model validators
"model_config", # Pydantic v2 ConfigDict alias
"verify_*", # integrations/_verifiers_loader.py
"validate_*_config", # integration config validators
"*_config_from_env", # env-backed integration helpers
"describe_llm_*", "llm_provider_*", "has_credentials_*",
"get_account_*",
"configure_grafana_cloud", "apply_otel_env_defaults", "validate_grafana_cloud_config",
"on_thread_*", "on_assistant_*", "on_cron_*",
"discord_interactions", "health_check",
"version_check", "deep_health_check",
"investigate_stream",
"clean_env", "empty_store", # pytest fixtures
"_isolated_*", "_reset_*", "_harness_*", "_no_*", # pytest fixtures / autouse hooks
"_metering_*", "metering_on",
"lex_document", # prompt_toolkit Lexer API
"do_*", "log_message", # http.server handler overrides
"_accept_*", "_tab_*", "_shift_*", "_next_*", "_previous_*", "_on_*",
"_quit", "_ctrl_c", "_bulk_*", "_handle_*", "_toggle", "_escape", "_submit",
"_escape_checkbox", "_get_choice_tokens",
"parse_chunk", "from_tokens", # fleet_monitoring meter protocol
"steer", "emit_update", "on_update", # agent runtime protocol surface
"tool_description", # slash adapter protocol
"reset_guardrail_evaluator", "reset_runtime_flags", "reset_cli_session_id",
"register_external_tool_package", "get_tool_descriptors", "load_tool",
"signoz_is_available",
"load_remote_url", "save_named_remote", "delete_named_remote", "save_remote_ops_config",
"is_cancelling", "idle_hint_ansi",
"is_held", "holder", "holder_pid", "rate_per_minute",
"should_block", "to_state",
"RichGroup",
]
# uv installs this PEP 735 group by default (`uv sync`; omit with `--no-dev`).
# `pre-commit` is also under `[project.optional-dependencies] dev` for `pip install .[dev]`.
[dependency-groups]
dev = [
"pre-commit>=4.0.0",
"pytest>=9.0.3",
"pytest-cov>=7.1.0",
# pytest.ini sets ``timeout``; without the plugin that key is silently
# inert and pytest warns "Unknown config option". Keep it in every install
# path, not just the ``dev`` extra that ``make install`` uses.
"pytest-timeout>=2.3.0",
"types-psutil>=7.2.2.20260408",
"types-PyYAML>=6.0.12",
"import-linter>=2.0",
"vulture>=2.14",
]