Plutus-apps v2022-04-06

My smart contract compiles successfully however when i run the simulator i get this error

Contract instance stopped with error: "WalletContractError (ToCardanoError (Tag \"toCardanoPolicyId\" (Tag \"1 bytes\" DeserialisationError)))" ]

My plutus code is here: https://github.com/naeri-kailash/elysium-plutus/blob/master/src/Cardano/PlutusExample/Trade.hs

I have read another issue where someone got this error but their solution (CurrencySymbol needed to be changed to a policyID i believe - mine is already a policyID) was not relevant to me. Could I please have some guidance on how to go about debugging this error?

Much appreciated

  • It would be helpful if you could share the plutus code to reproduce this issue. This way someone could try to help you better.
    – eddex
    Sep 20, 2022 at 5:50
  • Please edit the question to limit it to a specific problem with enough detail to identify an adequate answer.
    – Community Bot
    Sep 20, 2022 at 5:50
  • Thank you @eddex I have added the plutus contract Sep 21, 2022 at 4:06

2 Answers 2


You could try

tkSymbol :: CurrencySymbol
tkSymbol = currencySymbol "8d803516132f6fb8ddfcf168065886bf44ecc9e0023b570963b4bac8"

elysiumtitan0 :: KnownCurrency
elysiumtitan0 = KnownCurrency (fromSymbol tkSymbol) "Token" ( (TokenName "ElysiumTitan0") :| [])

elysiumtitan1 :: KnownCurrency
elysiumtitan1 = KnownCurrency (fromSymbol tkSymbol) "Token" ( (TokenName "ElysiumTitan1") :| [])


  • Unfortunately still getting (nearly) the same error, different bytes Contract instance stopped with error: "WalletContractError (ToCardanoError (Tag \"toCardanoPolicyId\" (Tag \"56 bytes\" DeserialisationError)))" ] Sep 22, 2022 at 1:51
  • we can start to trace the error from here toCardanoPolicyId, but i'm not sure which on call to toCardanoPolicyId You can try this way to generate some token for offchain emulator trace
    – Kỳ Anh
    Sep 22, 2022 at 2:16
  • I'm having trouble importing the Plutus.Contracts module even though its showing in the docs for my version, I'll see if I can get it working and get back to you, thanks :) Sep 22, 2022 at 3:23

I have instead built the playground using the plutus-apps tag referenced in week 1 of the plutus-pioneer-program. This solved the issue although I do not know what the problem was with the tag I was using previously (v2022-04-06).

The plutus-apps tag that fixed it is 41149926c108c71831cfe8d244c83b0ee4bf5c8a.

The way I ended up trying this solution was that I tried to run the EnglishAuction contract in week01 content, and I encountered the same error so I then understood that the problem did not explicitly lie in my contract, rather the interaction between the contract and that version of the playground.

Your Answer

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

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