Skip to content

Commit 4567f37

Browse files
authored
Merge pull request #2837 from opentensor/release/9.4.0
Release/9.4.0
2 parents 4e6cc4a + 38a9a05 commit 4567f37

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

74 files changed

+2130
-952
lines changed

.circleci/config.yml

Lines changed: 6 additions & 49 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ jobs:
3939
python -m venv .venv
4040
. .venv/bin/activate
4141
python -m pip install --upgrade uv
42-
uv pip install ruff -c requirements/dev.txt
42+
uv pip install ruff==0.11.5
4343
4444
- save_cache:
4545
name: Save cached ruff venv
@@ -68,9 +68,7 @@ jobs:
6868
name: Install dependencies and Check compatibility
6969
command: |
7070
if [ "$REQUIREMENTS_CHANGED" == "true" ]; then
71-
sudo apt-get update
72-
sudo apt-get install -y jq curl
73-
./scripts/check_compatibility.sh << parameters.python_version >>
71+
python -m pip install ".[dev,cli]" --dry-run --python-version << parameters.python_version >> --no-deps
7472
else
7573
echo "Skipping compatibility checks..."
7674
fi
@@ -87,31 +85,19 @@ jobs:
8785
steps:
8886
- checkout
8987

90-
- restore_cache:
91-
name: Restore cached venv
92-
keys:
93-
- v2-pypi-py<< parameters.python-version >>-{{ checksum "requirements/prod.txt" }}+{{ checksum "requirements/dev.txt" }}
94-
- v2-pypi-py<< parameters.python-version >>
95-
9688
- run:
9789
name: Update & Activate venv
9890
command: |
9991
python -m venv .venv
10092
. .venv/bin/activate
10193
python -m pip install --upgrade uv
102-
uv sync --all-extras --dev
103-
104-
- save_cache:
105-
name: Save cached venv
106-
paths:
107-
- "venv/"
108-
key: v2-pypi-py<< parameters.python-version >>-{{ checksum "requirements/prod.txt" }}+{{ checksum "requirements/dev.txt" }}
94+
uv sync --extra dev --dev
10995
11096
- run:
11197
name: Install Bittensor
11298
command: |
11399
. .venv/bin/activate
114-
uv sync --all-extras --dev
100+
uv sync --extra dev --dev
115101
116102
- run:
117103
name: Instantiate Mock Wallet
@@ -178,32 +164,20 @@ jobs:
178164
steps:
179165
- checkout
180166

181-
- restore_cache:
182-
name: Restore cached venv
183-
keys:
184-
- v2-pypi-py<< parameters.python-version >>-{{ checksum "requirements/prod.txt" }}+{{ checksum "requirements/dev.txt" }}
185-
- v2-pypi-py<< parameters.python-version >>
186-
187167
- run:
188168
name: Update & Activate venv
189169
command: |
190170
python -m venv .venv
191171
. .venv/bin/activate
192172
python -m pip install --upgrade uv
193-
uv sync --all-extras --dev
173+
uv sync --extra dev --dev
194174
uv pip install flake8
195175
196-
- save_cache:
197-
name: Save cached venv
198-
paths:
199-
- "env/"
200-
key: v2-pypi-py<< parameters.python-version >>-{{ checksum "requirements/prod.txt" }}+{{ checksum "requirements/dev.txt" }}
201-
202176
- run:
203177
name: Install Bittensor
204178
command: |
205179
. .venv/bin/activate
206-
uv sync --all-extras --dev
180+
uv sync --extra dev --dev
207181
208182
- run:
209183
name: Lint with flake8
@@ -235,18 +209,6 @@ jobs:
235209
uv pip install --upgrade coveralls
236210
coveralls --finish --rcfile .coveragerc || echo "Failed to upload coverage"
237211
238-
check-version-updated:
239-
docker:
240-
- image: cimg/python:3.10
241-
steps:
242-
- checkout
243-
244-
- run:
245-
name: Version is updated
246-
command: |
247-
[[ $(git diff-tree --no-commit-id --name-only -r HEAD..master | grep bittensor/__init__.py | wc -l) == 1 ]] && echo "bittensor/__init__.py has changed"
248-
[[ $(git diff-tree --no-commit-id --name-only -r HEAD..master | grep VERSION | wc -l) == 1 ]] && echo "VERSION has changed"
249-
250212
check-changelog-updated:
251213
docker:
252214
- image: cimg/python:3.10
@@ -323,11 +285,6 @@ workflows:
323285

324286
release-branches-requirements:
325287
jobs:
326-
- check-version-updated:
327-
filters:
328-
branches:
329-
only:
330-
- /^(release|hotfix)/.*/
331288
- check-changelog-updated:
332289
filters:
333290
branches:

.github/dependabot.yml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
11
version: 2
22
updates:
33
- package-ecosystem: "pip"
4-
directory: ""
5-
file: "requirements/prod.txt"
4+
directory: "/"
65
schedule:
76
interval: "daily"
87
open-pull-requests-limit: 0 # Only security updates will be opened as PRs

.github/workflows/e2e-subtensor-tests.yaml

Lines changed: 29 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,9 @@ jobs:
3939
id: get-tests
4040
run: |
4141
test_files=$(find tests/e2e_tests -name "test*.py" | jq -R -s -c 'split("\n") | map(select(. != ""))')
42-
echo "::set-output name=test-files::$test_files"
42+
# keep it here for future debug
43+
# test_files=$(find tests/e2e_tests -type f -name "test*.py" | grep -E 'test_(incentive|commit_weights|set_weights)\.py$' | jq -R -s -c 'split("\n") | map(select(. != ""))')
44+
echo "test-files=$test_files" >> "$GITHUB_OUTPUT"
4345
shell: bash
4446

4547
pull-docker-image:
@@ -61,7 +63,7 @@ jobs:
6163
path: subtensor-localnet.tar
6264

6365
# Job to run tests in parallel
64-
run:
66+
run-e2e-test:
6567
name: ${{ matrix.test-file }} / Python ${{ matrix.python-version }}
6668
needs:
6769
- find-tests
@@ -70,7 +72,7 @@ jobs:
7072
timeout-minutes: 45
7173
strategy:
7274
fail-fast: false # Allow other matrix jobs to run even if this job fails
73-
max-parallel: 32 # Set the maximum number of parallel jobs (same as we have cores in SubtensorCI runner)
75+
max-parallel: 32 # Set the maximum number of parallel jobs (same as we have cores in ubuntu-latest runner)
7476
matrix:
7577
os:
7678
- ubuntu-latest
@@ -89,7 +91,7 @@ jobs:
8991
uses: astral-sh/setup-uv@v4
9092

9193
- name: install dependencies
92-
run: uv sync --all-extras --dev
94+
run: uv sync --extra dev --dev
9395

9496
- name: Download Cached Docker Image
9597
uses: actions/download-artifact@v4
@@ -99,5 +101,26 @@ jobs:
99101
- name: Load Docker Image
100102
run: docker load -i subtensor-localnet.tar
101103

102-
- name: Run tests
103-
run: uv run pytest ${{ matrix.test-file }} -s
104+
# - name: Run tests
105+
# run: uv run pytest ${{ matrix.test-file }} -s
106+
107+
- name: Run tests with retry
108+
run: |
109+
set +e
110+
for i in 1 2; do
111+
echo "🔁 Attempt $i: Running tests"
112+
uv run pytest ${{ matrix.test-file }} -s
113+
status=$?
114+
if [ $status -eq 0 ]; then
115+
echo "✅ Tests passed on attempt $i"
116+
break
117+
else
118+
echo "❌ Tests failed on attempt $i"
119+
if [ $i -eq 2 ]; then
120+
echo "Tests failed after 2 attempts"
121+
exit 1
122+
fi
123+
echo "Retrying..."
124+
sleep 5
125+
fi
126+
done

CHANGELOG.md

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,45 @@
11
# Changelog
22

3+
## 9.4.0 /2025-04-17
4+
5+
## What's Changed
6+
* Release/9.3.0 by @ibraheem-abe in https://github.com/opentensor/bittensor/pull/2805
7+
* Fix for flaky behavior of `test_incentive`, `test_commit_weights` and `test_set_weights` by @basfroman in https://github.com/opentensor/bittensor/pull/2795
8+
* Add `get_next_epoch_start_block` method to Async/Subtensor by @basfroman in https://github.com/opentensor/bittensor/pull/2808
9+
* Adds compatibility for torch 2.6.0+ by @thewhaleking in https://github.com/opentensor/bittensor/pull/2811
10+
* f Update CONTRIBUTING.md by @Hack666r in https://github.com/opentensor/bittensor/pull/2813
11+
* docs: replaced discord link with documentation by @sashaphmn in https://github.com/opentensor/bittensor/pull/2809
12+
* sometimes it's still flaky because the chain returns data with time offset by @basfroman in https://github.com/opentensor/bittensor/pull/2816
13+
* Remove requirements directory by @thewhaleking in https://github.com/opentensor/bittensor/pull/2812
14+
* version in one place by @thewhaleking in https://github.com/opentensor/bittensor/pull/2806
15+
* Update CONTRIBUTING hyperlinks by @thewhaleking in https://github.com/opentensor/bittensor/pull/2820
16+
* 9.3.1a1: Updates changelog by @ibraheem-abe in https://github.com/opentensor/bittensor/pull/2821
17+
* Remove cubit as extra by @thewhaleking in https://github.com/opentensor/bittensor/pull/2823
18+
* fix/roman/get-metagraph-identities by @basfroman in https://github.com/opentensor/bittensor/pull/2826
19+
* Replace waiting logic for `test_commit_reveal_v3.py` by @basfroman in https://github.com/opentensor/bittensor/pull/2827
20+
* Add `start_call` extrinsic to the sdk by @basfroman in https://github.com/opentensor/bittensor/pull/2828
21+
* Add `timelock` module by @basfroman in https://github.com/opentensor/bittensor/pull/2824
22+
* Fix: raise_error=True in AsyncSubtensor fails to get error_message by @zyzniewski-reef in https://github.com/opentensor/bittensor/pull/2771
23+
* Fix: async set_subnet_identity_extrinsic doesn't sign the extrinsic by @zyzniewski-reef in https://github.com/opentensor/bittensor/pull/2772
24+
* Update settings.py by @petryshkaCODE in https://github.com/opentensor/bittensor/pull/2814
25+
* Bumping ruff version by @basfroman in https://github.com/opentensor/bittensor/pull/2831
26+
* Fix and improve e2e tests after `start call` new limit in subtensor by @basfroman in https://github.com/opentensor/bittensor/pull/2830
27+
* Add `bittensor.timelock` module description by @basfroman in https://github.com/opentensor/bittensor/pull/2833
28+
* fix: Update broken link in `CONTRIBUTING.md` by @cypherpepe in https://github.com/opentensor/bittensor/pull/2818
29+
* docs: added a new badge by @sashaphmn in https://github.com/opentensor/bittensor/pull/2819
30+
* Fix AxonInfo initialization in get_mock_neuron function by @VolodymyrBg in https://github.com/opentensor/bittensor/pull/2803
31+
* Dendrite: log ClientOSError as Debug by @Thykof in https://github.com/opentensor/bittensor/pull/2770
32+
* remove `rao` endpoint from settings by @basfroman in https://github.com/opentensor/bittensor/pull/2834
33+
34+
## New Contributors
35+
* @Hack666r made their first contribution in https://github.com/opentensor/bittensor/pull/2813
36+
* @petryshkaCODE made their first contribution in https://github.com/opentensor/bittensor/pull/2814
37+
* @cypherpepe made their first contribution in https://github.com/opentensor/bittensor/pull/2818
38+
* @VolodymyrBg made their first contribution in https://github.com/opentensor/bittensor/pull/2803
39+
* @Thykof made their first contribution in https://github.com/opentensor/bittensor/pull/2770
40+
41+
**Full Changelog**: https://github.com/opentensor/bittensor/compare/v9.3.0...v9.4.0
42+
343
## 9.3.0 /2025-04-09
444

545
## What's Changed

Makefile

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,3 @@ install:
2121

2222
install-dev:
2323
python3 -m pip install '.[dev]'
24-
25-
install-cubit:
26-
python3 -m pip install '.[cubit]'

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,14 @@
44
[![Discord Chat](https://img.shields.io/discord/308323056592486420.svg)](https://discord.gg/bittensor)
55
[![CodeQL](https://github.com/opentensor/bittensor/actions/workflows/github-code-scanning/codeql/badge.svg)](https://github.com/opentensor/bittensor/actions)
66
[![PyPI version](https://badge.fury.io/py/bittensor.svg)](https://badge.fury.io/py/bittensor)
7+
[![Codecov](https://codecov.io/gh/opentensor/bittensor/graph/badge.svg)](https://app.codecov.io/gh/opentensor/bittensor)
78
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
89

910
---
1011

1112
## Internet-scale Neural Networks <!-- omit in toc -->
1213

13-
[Discord](https://discord.gg/qasY3HA9F9)[Network](https://taostats.io/)[Research](https://bittensor.com/whitepaper)
14+
[Discord](https://discord.gg/qasY3HA9F9)[Network](https://taostats.io/)[Research](https://bittensor.com/whitepaper)[Documentation](https://docs.bittensor.com)
1415

1516
</div>
1617

VERSION

Lines changed: 0 additions & 1 deletion
This file was deleted.

0 commit comments

Comments
 (0)