Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

228
Vistas
Getting Cannot sign with a locked key pair Error on Token Transfer

I create my signer wallet as follows:

const seed = bip39.mnemonicToSeedSync(WALLET_MNEMONIC, WALLET_PASSWORD);
const privateKeyBuffer = bip32
    .fromSeed(seed)
    .derivePath(`m/44'/434'/0'/0/0`).privateKey; 
const keyring = new Keyring({ss58Format: 2});
return keyring.addFromAddress('0x'+privateKeyBuffer.toString("hex"));

and I try to transfer KSM from that account into another one:

const unsub = await api.tx.balances
    .transfer(recipientAddress, amount)
    .signAndSend(signerWallet, (result) => {
        console.log(`Current status is ${result.status}`);
        if (result.status.isInBlock) {
            console.log(`Transaction included at blockHash ${result.status.asInBlock}`);
        } else if (result.status.isFinalized) {
            console.log(`Transaction finalized at blockHash ${result.status.asFinalized}`);
            unsub();
        }
    });

However I get that error:

Cannot sign with a locked key pair

What is the problem with my code?

about 4 years ago · Santiago Trujillo
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda