def xkeys_from_seed(self, seed, passphrase): words = seed.split() n = len(words) # old version use long seed phrases if n >= 24: assert passphrase == '' xprv1, xpub1 = keystore.xkeys_from_seed(' '.join(words[0:12]), '', "m/") xprv2, xpub2 = keystore.xkeys_from_seed(' '.join(words[12:]), '', "m/") elif n==12: xprv1, xpub1 = keystore.xkeys_from_seed(seed, passphrase, "m/0'/") xprv2, xpub2 = keystore.xkeys_from_seed(seed, passphrase, "m/1'/") else: raise BaseException('unrecognized seed length') return xprv1, xpub1, xprv2, xpub2