From 04e232a193972826f1cd79ef5503cb7ad1c8db6f Mon Sep 17 00:00:00 2001 From: BANADDA MUBARAKA <83466862+BANADDA@users.noreply.github.com> Date: Thu, 17 Sep 2026 14:00:42 +0300 Subject: [PATCH] identity: a bittensor hotkey file with cryptoType 1 is sr25519 --- validator/identity.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/validator/identity.py b/validator/identity.py index 92e65a2..17ba704 100644 --- a/validator/identity.py +++ b/validator/identity.py @@ -58,9 +58,9 @@ def load_keypair(settings: Settings) -> Keypair: raw = bytes.fromhex(private[2:] if private.startswith("0x") else private) public = str(data.get("publicKey", "") or "") crypto = ( - KeypairType.SR25519 + KeypairType.ED25519 if int(data.get("cryptoType", 1) or 1) == 0 - else KeypairType.ED25519 + else KeypairType.SR25519 ) return Keypair( public_key=bytes.fromhex(public[2:] if public.startswith("0x") else public)