Skip to content

Commit

Permalink
Fix typos in pyteal/ast/abi/util.py (#467)
Browse files Browse the repository at this point in the history
  • Loading branch information
michaeldiamant authored Jul 22, 2022
1 parent 06a3e94 commit a27b31b
Showing 1 changed file with 9 additions and 13 deletions.
22 changes: 9 additions & 13 deletions pyteal/ast/abi/util.py
Original file line number Diff line number Diff line change
Expand Up @@ -159,12 +159,12 @@ def type_spec_from_annotation(annotation: Any) -> TypeSpec:

if origin is Asset:
if len(args) != 0:
raise TypeError("Asset expects 0 argsuments. Got: {}".format(args))
raise TypeError("Asset expects 0 arguments. Got: {}".format(args))
return AssetTypeSpec()

if origin is Application:
if len(args) != 0:
raise TypeError("Application expects 0 argsuments. Got: {}".format(args))
raise TypeError("Application expects 0 arguments. Got: {}".format(args))
return ApplicationTypeSpec()

if origin is Bool:
Expand Down Expand Up @@ -257,52 +257,48 @@ def type_spec_from_annotation(annotation: Any) -> TypeSpec:

if origin is Transaction:
if len(args) != 0:
raise TypeError(
"Transaction expects 0 type arguements. Got {}".format(args)
)
raise TypeError("Transaction expects 0 type arguments. Got {}".format(args))
return TransactionTypeSpec()

if origin is PaymentTransaction:
if len(args) != 0:
raise TypeError(
"PaymentTransaction expects 0 type arguements. Got {}".format(args)
"PaymentTransaction expects 0 type arguments. Got {}".format(args)
)
return PaymentTransactionTypeSpec()

if origin is KeyRegisterTransaction:
if len(args) != 0:
raise TypeError(
"KeyRegisterTransaction expects 0 type arguements. Got {}".format(args)
"KeyRegisterTransaction expects 0 type arguments. Got {}".format(args)
)
return KeyRegisterTransactionTypeSpec()

if origin is AssetConfigTransaction:
if len(args) != 0:
raise TypeError(
"AssetConfigTransaction expects 0 type arguements. Got {}".format(args)
"AssetConfigTransaction expects 0 type arguments. Got {}".format(args)
)
return AssetConfigTransactionTypeSpec()

if origin is AssetFreezeTransaction:
if len(args) != 0:
raise TypeError(
"AssetFreezeTransaction expects 0 type arguements. Got {}".format(args)
"AssetFreezeTransaction expects 0 type arguments. Got {}".format(args)
)
return AssetFreezeTransactionTypeSpec()

if origin is AssetTransferTransaction:
if len(args) != 0:
raise TypeError(
"AssetTransferTransaction expects 0 type arguements. Got {}".format(
args
)
"AssetTransferTransaction expects 0 type arguments. Got {}".format(args)
)
return AssetTransferTransactionTypeSpec()

if origin is ApplicationCallTransaction:
if len(args) != 0:
raise TypeError(
"ApplicationCallTransaction expects 0 type arguements. Got {}".format(
"ApplicationCallTransaction expects 0 type arguments. Got {}".format(
args
)
)
Expand Down

0 comments on commit a27b31b

Please sign in to comment.