Skip to main content
5 events
when toggle format what by license comment
May 2, 2022 at 4:45 comment added marcel_g Yes, as @kolam says, you can't use show onchain to print out strings that are built at runtime from onchain code. I think this is because the script's address is derived from the hash of the validator function/onchain code, so it can only use hardcoded strings in traceError or traceIfFalse. -> I did not have any luck getting decodeUtf8 to run on chain either. I'm guessing that's because the hash I was attempting to print out didn't resolve to utf8.
Aug 25, 2021 at 9:12 history edited Aoaddeola CC BY-SA 4.0
added 4 characters in body
Aug 24, 2021 at 15:03 history edited Aoaddeola CC BY-SA 4.0
Wrong initial answer. Provided a working one
Aug 24, 2021 at 14:14 comment added kolam That won't work as show is not an inlinable function and thus cannot be used in the validation (on-chain) part of Plutus. Those functions you mentioned are meant to be used in the off-chain part of Plutus.
Aug 24, 2021 at 13:22 history answered Aoaddeola CC BY-SA 4.0