I am getting incorrect pubkeys by running mockWalletPaymentPubKey $ knownWallet 1 and mockWalletPaymentPubKey $ knownWallet 2 (from here https://youtu.be/ae7U_yKIQ0Y?t=1390).

I checked that

  • I am in the correct directory
  • I imported the wallet emulator using import Wallet.Emulator
  • and the cabal build command ran successfully.

On restarting the repl, I get the same incorrect wallet pub keys.

Note: I was able to get the correct pub keys by looking at the transactions in the simulator.

1 Answer 1


mockWalletPaymentPubKey gives you the public key for a wallet.

For Vesting.hs, you need to use the public key hash.

Try mockWalletPaymentPubKeyHash $ knownWallet 1 instead.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.