- Support for new TEAL 5 features:
AppParam
expressions (#107, #123)- New
nonparticipation
transaction field (#106) - Inner transactions, zero-element
Seq
expressions, dynamic transaction array access (#115) - Logs, dynamic LogicSig argument indexes, single-element
NaryExpr
s, and creatingBytes
frombytes
andbytearray
(#117) - Extract expressions (#118)
- More efficient implementation of recursive subroutines in TEAL 5+ (#114)
- Add
WideRatio
, an expression which exposesmulw
anddivmodw
(#121, #122)
- WARNING: Due to code generation improvements, programs compiled with this version will likely produce different TEAL code than previous versions, but their functionality will be the same. Be aware that even small differences in generated TEAL code will change the address associated with escrow LogicSig contracts.
- Some unnecessary branch conditions have been removed (#120)
- Support for new TEAL 4 features:
- New logo (#88, #91)
- Added the
assembleConstants
option tocompileTeal
. When enabled, the compiler will assemble int and byte constants in the most efficient way to reduce program size (#57, #61, #66). - Added an alternative syntax for constructing
If
statements (#77, #82). - Align
Seq
with the rest of the API (#96).
- Fixed
NaryExpr.__str__
method (#102).
- WARNING: Due to code generation changes required to support TEAL 4 loops and subroutines, programs compiled with this version will likely produce different TEAL code than previous versions, but their functionality will be the same. Be aware that even small differences in generated TEAL code will change the address associated with escrow LogicSig contracts.
- Improved crypto cost docs (#81).
- Applied code formatter (#100).
- Support for new TEAL 3 features:
- Added the ability to specify the TEAL version target when using
compileTeal
(#45). - Added
ScratchVar
, an interface for storing and loading values from scratch space (#33). - Added a warning when scratch slots are loaded before anything has been stored (#47).
- Rewrote internal code generation to produce smaller programs and make future optimization easier (#26). Programs compiled with this version will likely produce different TEAL code than previous versions, but their functionality will be the same.
- Corrected documentation and examples that incorrectly used the
Txn.accounts
array (#42). - Fixed improper base32 validation and allow the use of padding (#34 and #37).
- An application deployment example,
vote_deploy.py
.
- Internal modules no longer pollute the global namespace when importing with
from pyteal import *
(#29). - Fixed several documentation typos.
- Moved signature and application mode examples into separate folders.
- TEAL v2
Txn
andGtxn
fields - TEAL v2
Global
fields TxnType
enumPop
expressionNot
expressionBitwiseNot
expressionBitwiseAnd
expressionBitwiseOr
expressionBitwiseXor
expressionNeq
(not equal) expressionAssert
expressionAssetHolding
expressionsAssetParam
expressions- State manipulation with
App
expressions Concat
expressionSubstring
expressionBytes
constructor now accepts UTF-8 stringsIf
expression now allows single branches
- Compiling a PyTeal program must now be done with the
compileTeal(program, mode)
function. The.teal()
method no longer exists. - The API for group transactions has changed from
Gtxn.field(transaction_index)
toGtxn[transaction_index].field()
. Tmpl
syntax has changed fromType(Tmpl("TMPL_NAME"))
toTmpl.Type("TMPL_NAME")
.