0

this is my transaction build script

cardano-cli transaction build
--mainnet
--alonzo-era
--tx-in $txhash#$txix
--tx-out $address+$output+"$tokenamount $policyid.$tokenname"
--change-address $address
--mint="$tokenamount $policyid.$tokenname"
--minting-script-file $script
--metadata-json-file metadata.json
--invalid-hereafter $slotnumber
--witness-override 2
--out-file matx.raw

And i get this error when i add tokenname with policy id if i remove the tokenname then its working fine.and also not showing tokenname in cardanoscan

option --tx-out: unexpected 'N' expecting alphanumeric asset name, white space, "+" or end of input

2 Answers 2

0

Are you using cardano-cli v1.31?

If so, please refer to Errror cardano-cli build-raw: AssetName deserisalisation failed expecting hexadecimal digit

0

This line is problematic:

--tx-out $address+$output+"$tokenamount $policyid.$tokenname"

One your variables is not set. To try it out, just put echo in front of the command to print out what the command really is with variables filled in.

2
  • --tx-out addr_test1vzzql63nddp8qdgka578hx6pats290js9kmn4uay5we9fwsgza0z3+1400000+1 71421b480f31fd04905d50d0fa5026a459f545acf78ba3f359cc053b.NFT1
    – Umeraqeel
    Nov 24, 2021 at 13:50
  • above is the echo result of tx-out
    – Umeraqeel
    Nov 24, 2021 at 13:51

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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