Skip to content

Commit 6595299

Browse files
author
Roman
committed
initialize for async instance
1 parent 745a126 commit 6595299

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

bittensor/core/subtensor_api/__init__.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,8 @@ def __init__(
6767
self.log_verbose = log_verbose
6868
self.is_async = async_subtensor
6969
self._config = config
70+
# assigned only for async instance
71+
self.initialize = None
7072
self._subtensor = self._get_subtensor()
7173

7274
# fix naming collision
@@ -92,6 +94,7 @@ def __init__(
9294
def _get_subtensor(self) -> Union["_Subtensor", "_AsyncSubtensor"]:
9395
"""Returns the subtensor instance based on the provided config and subtensor type flag."""
9496
if self.is_async:
97+
self.initialize = self._subtensor.initialize
9598
return _AsyncSubtensor(
9699
network=self.network,
97100
config=self._config,

0 commit comments

Comments
 (0)