Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to sign from polkadot-js console using Talisman #10499

Open
magecnion opened this issue Apr 24, 2024 · 0 comments
Open

Unable to sign from polkadot-js console using Talisman #10499

magecnion opened this issue Apr 24, 2024 · 0 comments

Comments

@magecnion
Copy link

magecnion commented Apr 24, 2024

When submitting a script through polkadot-js console and trying to sign using Talisman wallet I got the error Cannot sign with a locked key pair:
image

The script is one of the examples, where SENDER is the address from my Talisman wallet:

const SENDER = '5GrwvaEF5zXb26Fz9rcQpDWS57CtERHpNehXCPcNoHGKutQY';
const RECEIVER = '5FHneW46xGXgs5mUiveU4sbTyGBzmstUspZC92UhjJM694ty';

// Get a random number between 1 and 100000
const randomAmount = Math.floor((Math.random() * 100000) + 1);

// Create a extrinsic, transferring randomAmount units to Bob.
const transfer = api.tx.balances.transferAllowDeath(RECEIVER, randomAmount);

// Sign and Send the transaction
await transfer.signAndSend(SENDER, ({ events = [], status }) => {
  if (status.isInBlock) {
    console.log('Successful transfer of ' + randomAmount + ' with hash ' + status.asInBlock.toHex());
  } else {
    console.log('Status of transfer: ' + status.type);
  }

  events.forEach(({ phase, event: { data, method, section } }) => {
    console.log(phase.toString() + ' : ' + section + '.' + method + ' ' + data.toString());
  });
});

Environment

  • Brave Browser - Version 1.65.114 Chromium: 124.0.6367.60 (Official Build) (64-bit)
  • Talisman Wallet - Version v1.25.0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant