Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

wait for synthetic task complete #103

Merged
merged 2 commits into from
Nov 6, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion validators/services/capacity.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ class CapacityService:
def __init__(self, metagraph, dendrite):
self.metagraph = metagraph
self.dendrite: bt.dendrite = dendrite
self.timeout = 4
self.timeout = 30
self.uid_to_capacity = {}
self.remain_uid_to_capacity = {}

Expand Down
5 changes: 4 additions & 1 deletion validators/weight_setter.py
Original file line number Diff line number Diff line change
Expand Up @@ -348,7 +348,7 @@ async def get_available_uids(self):
async def check_uid(self, axon, uid):
"""Asynchronously check if a UID is available."""
try:
response = await self.dendrite(axon, IsAlive(), timeout=4)
response = await self.dendrite(axon, IsAlive(), timeout=30)
if response.completion == 'True':
bt.logging.trace(f"UID {uid} is active")
return axon # Return the axon info instead of the UID
Expand Down Expand Up @@ -599,6 +599,9 @@ async def process_queries_from_database(self):
if not self.is_epoch_end():
bt.logging.debug("no end of epoch. so continue...")
continue
if not self.synthetic_task_done:
bt.logging.debug("wait for synthetic tasks to complete.")
continue

bt.logging.info(f"start scoring process...")

Expand Down
Loading