Skip to content

Commit 077a6d6

Browse files
committed
chore: use lock
1 parent 01ad754 commit 077a6d6

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

neurons/validators/validator.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ def __init__(self, config=None):
6969
self.query_miners_thread: Union[threading.Thread, None] = None
7070
self.score_thread: Union[threading.Thread, None] = None
7171
self.sync_thread: Union[threading.Thread, None] = None
72-
self.lock = threading.RLock()
72+
self.lock = threading.Lock()
7373

7474
self.genie_validator = GenieValidator(neuron=self)
7575
self.score_manager = ScoreManager(neuron=self)
@@ -345,7 +345,7 @@ def sync_loop(self):
345345
try:
346346
with self.lock:
347347
self.sync()
348-
self.set_weights()
348+
self.set_weights()
349349
except Exception as e:
350350
bt.logging.error(f"Error during sync: {str(e)}")
351351
if self.should_exit:

0 commit comments

Comments
 (0)