Hi,
How can i convert TxnObject,TxnaExpr,TxnArray types to string in pyteal?
For example I want to print the value of Txn.sender() or Txn.accounts.length()
Hi,
How can i convert TxnObject,TxnaExpr,TxnArray types to string in pyteal?
For example I want to print the value of Txn.sender() or Txn.accounts.length()
PyTEAL is not directly executed.
Rather it is used to generate a TEAL script that is then executed by the blockchain.
TEAL does not support converting such objects to strings as this was not deemed useful in most (if not all) smart contracts.
If your goal is to debug smart contracts, the best is to use tealdbg
(Smart contract debugging - Algorand Developer Portal) or goal clerk dryrun-remote
(Make goal clerk dryrun
directly work with application calls · Issue #1653 · algorand/go-algorand · GitHub)?