-
Notifications
You must be signed in to change notification settings - Fork 8
Expand file tree
/
Copy pathpyproject.toml
More file actions
123 lines (104 loc) · 4.22 KB
/
Copy pathpyproject.toml
File metadata and controls
123 lines (104 loc) · 4.22 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
[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"
[project]
name = "ditto"
version = "0.197.1"
description = "Ditto Bittensor Subnet 118 (SN118): miner CLI + validator for the language-neutral agent-memory-harness incentive layer."
readme = "README.md"
license = "MIT"
requires-python = ">=3.12,<3.14"
authors = [{ name = "heyDitto" }]
dependencies = [
# 10.3.0 carries a breaking change the subnet requires — older releases no
# longer interoperate with the chain, so pin the floor there (the lock pins
# the exact resolved version operators install).
"bittensor>=10.3.0",
# 4.1 reads the keyfile format emitted by current btcli releases.
"bittensor-wallet>=4.1.0",
"bittensor-pylon-client",
"async-substrate-interface",
"httpx>=0.27",
"pydantic>=2.12",
"psutil>=5.9",
"ditto-screening-protocol==0.18.0",
]
[project.optional-dependencies]
# Public wandb telemetry (opt-in). The validator imports wandb lazily and
# degrades to a no-op when it is absent, so this is only needed to actually
# publish stats: ``uv sync --extra telemetry`` (or ``pip install ditto[telemetry]``).
telemetry = ["wandb>=0.17"]
[tool.uv.sources]
bittensor-pylon-client = { git = "https://github.com/bittensor-church/bittensor-pylon", subdirectory = "pylon_client" }
ditto-screening-protocol = { path = "packages/ditto-screening-protocol" }
[project.scripts]
ditto = "ditto.miner_cli.__main__:main"
ditto-preview = "ditto.preview.cli:main"
[dependency-groups]
dev = [
"ruff>=0.6",
"mypy>=1.10",
"pytest>=8",
"pytest-asyncio>=0.23",
"pytest-cov>=5",
"pre-commit>=3.7",
]
release = [
"python-semantic-release==10.6.1",
]
[tool.hatch.build.targets.wheel]
packages = ["ditto"]
# ─── Ruff ────────────────────────────────────────────────────────────────────
[tool.ruff]
line-length = 88
target-version = "py312"
extend-exclude = [
"apps/platform",
"miners/dittobench-starter-kit",
"packages/ditto-screening-protocol",
"services/dittobench-api",
"services/screener-orchestrator",
"workers/screener",
]
[tool.ruff.lint]
select = ["E", "W", "F", "I", "B", "C4", "UP", "ARG", "SIM"]
extend-select = ["I"]
[tool.ruff.format]
quote-style = "double"
[tool.ruff.lint.isort]
known-first-party = ["ditto", "ditto_screening_protocol"]
# ─── Mypy ────────────────────────────────────────────────────────────────────
[tool.mypy]
python_version = "3.12"
disallow_untyped_defs = false
check_untyped_defs = true
ignore_missing_imports = true
[[tool.mypy.overrides]]
module = "ditto.tests.*"
disallow_untyped_defs = false
check_untyped_defs = false
# ─── Pytest ──────────────────────────────────────────────────────────────────
[tool.pytest.ini_options]
asyncio_mode = "auto"
testpaths = ["ditto/tests"]
markers = [
"slow: long-running tests excluded by default",
"integration: integration tests requiring real infra",
"localnet: tests against a local Bittensor network",
"e2e: end-to-end tests through the full stack",
]
addopts = ["-m", "not slow and not integration and not localnet and not e2e"]
# ─── Releases ────────────────────────────────────────────────────────────────
[tool.semantic_release]
allow_zero_version = true
build_command = "python -m ensurepip && python -m pip install --disable-pip-version-check uv==0.11.28 && uv lock --upgrade-package \"$PACKAGE_NAME\" && git add uv.lock && uv build"
commit_message = "chore(release): v{version} [skip ci]"
tag_format = "v{version}"
version_toml = ["pyproject.toml:project.version"]
version_variables = [
"ditto/__init__.py:__version__",
"research/dittobench-datagen/internal/version/version.go:Version",
]
[tool.semantic_release.branches.main]
match = "main"
prerelease = false