File tree Expand file tree Collapse file tree 2 files changed +9
-3
lines changed
Expand file tree Collapse file tree 2 files changed +9
-3
lines changed Original file line number Diff line number Diff line change @@ -18,7 +18,6 @@ dependencies = [
1818 " async-substrate-interface>=1.4.2" ,
1919 " aiohttp~=3.10.2" ,
2020 " backoff~=2.2.1" ,
21- " click>=8.2.0" ,
2221 " GitPython>=3.0.0" ,
2322 " netaddr~=1.3.0" ,
2423 " numpy>=2.0.1,<3.0.0" ,
@@ -29,6 +28,7 @@ dependencies = [
2928 " scalecodec==1.2.11" ,
3029 " typer>=0.16" ,
3130 " bittensor-wallet>=3.0.7" ,
31+ " packaging" ,
3232 " plotille>=5.0.0" ,
3333 " plotly>=6.0.0" ,
3434]
Original file line number Diff line number Diff line change 1+ import importlib
12import inspect
23import os
34import re
67import sys
78from typing import TYPE_CHECKING , Optional
89
9- from bittensor_cli .cli import CLIManager
1010from bittensor_wallet import Keypair , Wallet
11+ from packaging .version import parse as parse_version , Version
1112from typer .testing import CliRunner
1213
14+ from bittensor_cli .cli import CLIManager
15+
1316if TYPE_CHECKING :
1417 from async_substrate_interface .async_substrate import AsyncSubstrateInterface
1518
@@ -55,7 +58,10 @@ def exec_command(
5558 extra_args .extend (["--network" , "ws://127.0.0.1:9945" ])
5659
5760 # Capture stderr separately from stdout
58- runner = CliRunner ()
61+ if parse_version (importlib .metadata .version ("click" )) < Version ("8.2.0" ):
62+ runner = CliRunner (mix_stderr = False )
63+ else :
64+ runner = CliRunner ()
5965 # Prepare the command arguments
6066 args = [
6167 command ,
You can’t perform that action at this time.
0 commit comments