From 446447a4bc31638d62610ce992075716558fab1c Mon Sep 17 00:00:00 2001 From: xdustinface Date: Tue, 5 Apr 2022 10:59:17 +0200 Subject: [PATCH] wallet: Drop unused `WalletStateManager.get_derivation_index` --- chia/wallet/wallet_state_manager.py | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/chia/wallet/wallet_state_manager.py b/chia/wallet/wallet_state_manager.py index 01282e32932c..f6a2a037fb39 100644 --- a/chia/wallet/wallet_state_manager.py +++ b/chia/wallet/wallet_state_manager.py @@ -207,16 +207,6 @@ async def create( return self - def get_derivation_index(self, pubkey: G1Element, max_depth: int = 1000) -> int: - for i in range(0, max_depth): - derived = self.get_public_key(uint32(i)) - if derived == pubkey: - return i - derived = self.get_public_key_unhardened(uint32(i)) - if derived == pubkey: - return i - return -1 - def get_public_key(self, index: uint32) -> G1Element: return master_sk_to_wallet_sk(self.private_key, index).get_g1()