code: def CreateKey(self, prikey=None):
          
          account = super(UserWallet, self).CreateKey(private_key=prikey)
          self.OnCreateAccount(account)
          contract = WalletContract.CreateSignatureContract(account.PublicKey)
          self.AddContract(contract)
          return account
docs: Create a KeyPair and store it encrypted in the database.
  
          Args:
              private_key (iterable_of_ints): (optional) 32 byte private key.
  
          Returns:
              KeyPair: a KeyPair instance.