Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ignore tests generating TEAL file outputs used for expected comparisons #228

Merged
merged 1 commit into from
Mar 3, 2022

Conversation

michaeldiamant
Copy link
Contributor

Adds gitignore for select tests generating TEAL file outputs that should not be versioned.

  • Credit to @tzaffi for supplying the change. I simply packaged the PR.
  • Here's an example of local state before applying the PR:
~/dev/pyteal master ⇡2 *3 ───────────────────────────────────────────────────────────────────  pyteal 12:58:24 PM
❯ pytest tests
=============================================== test session starts ===============================================
platform darwin -- Python 3.10.2, pytest-7.0.1, pluggy-1.0.0
rootdir: /Users/michael/dev/pyteal
plugins: timeout-2.1.0
collected 15 items

tests/compile_test.py ...........                                                                           [ 73%]
tests/module_test.py .                                                                                      [ 80%]
tests/pass_by_ref_test.py ...                                                                               [100%]

=============================================== 15 passed in 0.76s ================================================

~/dev/pyteal master ⇡2 *3 ?9 ────────────────────────────────────────────────────────────────  pyteal 12:58:28 PM
❯ gs
# On branch: master...origin/master  |  +2  |  [*] => $e*
#
➤ Untracked files
#
#      untracked: [1] tests/teal/fac_by_ref.teal
#      untracked: [2] tests/teal/sub_even.teal
#      untracked: [3] tests/teal/sub_fastfib.teal
#      untracked: [4] tests/teal/sub_logcat.teal
#      untracked: [5] tests/teal/sub_logcat_dynamic.teal
#      untracked: [6] tests/teal/sub_mixed.teal
#      untracked: [7] tests/teal/sub_slowfib.teal
#      untracked: [8] tests/teal/swapper.teal
#      untracked: [9] tests/teal/wilt_the_stilt.teal
#

Copy link
Contributor

@tzaffi tzaffi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@michaeldiamant michaeldiamant merged commit 30d979f into algorand:master Mar 3, 2022
@michaeldiamant michaeldiamant deleted the ignore_teal_tests branch March 3, 2022 18:12
michaeldiamant added a commit that referenced this pull request Mar 4, 2022
* Fix build script invocation (#223)

* Bring #225 to master (#227)

* Ignore tests generating TEAL file outputs used for expected comparisons (#228)

* Fix typo in CONTRIBUTING.md (#229)

Co-authored-by: Jason Paulos <[email protected]>
algoidurovic pushed a commit to algoidurovic/pyteal that referenced this pull request Mar 23, 2022
algoidurovic added a commit that referenced this pull request Mar 31, 2022
* Optimization added for repeated int constants under 2**7 w/ tests

* fixed type problem and formatted

* Expanded test and added comment for clarification

* implement optimization utility with simple slot store/load canceling

* minor refactor

* reformat code

* Update pyteal/compiler/optimizer/optimizer.py

Co-authored-by: Michael Diamant <[email protected]>

* Update pyteal/compiler/optimizer/optimizer.py

Co-authored-by: Michael Diamant <[email protected]>

* Adding exponentiation to arithmatic ops docs (#134)

Add missing exponentiation operation in document

* updating to use new syntax for seq (#135)

* updating to use new syntax for seq

* rewording

* Make pylance recognize wildcard imports (#133)

* adding exports directly to top level __all__

* apply black formatter

* adding initial generate script

* fmt

* rm all from all

* adding check to travis

* reading in original __init__ and using its imports, dont write to filesystem if --check is passed

* make messages more profesh

* fix flags after black formatted them

* y

* flippin black formatter

* help text fix

* asdfasdf

* Include pyi files in build (#137)

* Revert "Optimization for constant assembly (#128)"

This reverts commit 5636ccd.

* Revert "String optimization and addition of Suffix() (#126)"

This reverts commit 7cb7b9a.

* Update to v0.9.1 (#138)

* Revert "Revert "String optimization and addition of Suffix() (#126)""

This reverts commit 564e602.

* Revert "Revert "Optimization for constant assembly (#128)""

This reverts commit cc405a5.

* Update examples.rst (#140)

* Fix type for App.globalGetEx in docs (#142)

* up max teal version (#146)

* up max teal version

* make test fail if its greater than version defined as MAX_TEAL_VERSION

* Fmt

* hardcode to 7

* Add version 6 test

* Formatting subroutines with name and newline (#148)

* using the subroutine name for the label

* adding newline before label declaration, fix tests to account for newline

* remove commented name, fix test

* only add newline for subroutines with comment

* naming with suffix

* adding test for invalid name

* Call type_of() in require_type() for better exception messages (#151)

* call type_of in require_type to catch exceptions

* fix formatting for types.py and types_test.py

* `method` pseudo-op support for ABI methods (#153)

- Add support for `method` pseudo-opcode in PyTeal.
- Add `name` field in `subroutine` to override __name__ from function implementation, for readability in generated code.

* Print diff of `__init__.pyi` (#166)

* Print diff of __init__.pyi

* Format

* Undo travis change

* C2C Feature Support (#149)

- `itxn_next` implementation / test
- `itxn_field` support for array field setting
- `gitxn / gitxna` implementation / test
- `gloadss` implementation / test

* Add BytesSqrt (#163)

* Add BytesSqrt

* Update pyteal/ast/unaryexpr_test.py

Co-authored-by: Jason Paulos <[email protected]>

Co-authored-by: Jason Paulos <[email protected]>

* adding new globals from teal6 (#168)

* adding new globals from teal6

* fmt

* Acct params get (#165)

* Adding account param getter

* Add to init

* fix op names and type

* adding tests

* allow bytes to be passed

* tweak docs, add require check for any

* Change Subroutine Wrapped Callable to a class with call method (#171)

Allows for more information (name, return type, has return) about the subroutine extractable from wrapped fnImpl by subroutine

* Subroutine Type Annotations (#182)

This PR requires that any type annotation of a Subroutine parameter or return value be of type `Expr`. Missing annotations are assumed to be `Expr`'s as well. In a follow up PR #183 this restriction will be loosened.

* fix docs referencing what apps should eval to (#191)

* Move from Travis to Github Actions (#190)

* MultiValue expression implemented to support opcodes that return multiple values (#196)

* Optimization added for repeated int constants under 2**7 w/ tests

* fixed type problem and formatted

* Expanded test and added comment for clarification

* add multivalue expr and change maybevalue to derive from multivalue

* updated tests and formatting

* reorder output slots to reflect stack ordering

* add additional assertion in MaybeValue test to enforce slot ordering

* Support TEAL 6 txn fields LastLog, StateProofPK and opcodes divw, itxnas, gitxnas (#174)

* adding new teal6 ops, no pyteal expressions defined for them yet

* Add opcode support for divw

* Add opcode support for divw (#192)

* Add opcode support for itxnas and gitxnas (#193)

* Add opcode support for itxnas and gitxnas

* Update stale reference to inner transaction limit

* Fix allowed types for GitxnaExpr txnIndex

* Remove obsolete logic for handling GitxnaExpr.teal construction

* Remove unnecessary cast and fix gitxna runtime type checking

* Move type validation to constructors for gtxn and gitxn variants

* Add missed tests from prior commit

* Fix duplicate test case

* Move index validation from subclasses to TxnaExpr

* Inline validation functions per PR feedback

* Remove unused imports

* Refactor to isinstance tupled check

* Remove TEAL v1 min version test per PR feedback

* Fix constructor type checking for GtxnExpr

* Refactor to remove duplicate type check function

* Update last_log docstring

Co-authored-by: Jason Paulos <[email protected]>

* Expose state_proof_pk txn field

* Update transaction field docs to reflect TEAL v6

* Update transaction field docs to reflect TEAL v6

Co-authored-by: michaeldiamant <[email protected]>
Co-authored-by: Jason Paulos <[email protected]>

* Fixed typo (#202)

* Add Github action to generate docset (#201)

* Add build docset step

* non-slim container

* Update docs to group transaction field tables like go-algorand (#204)

* Update accessing_transaction_field.rst to fix typo (#207)

* Add docs README to explain docs/ testing procedure (#205)

* v0.10.0 (#206)

* Update to v0.10.0

* Add latest commits to changelog

* fixing github actions to run on tags (#208)

* Update build.yml

* Update build.yml

* Fix typos in docstrings and error messages (#211)

* Test on Python 3.10 (#212)

* Update versions.rst (#210)

* Update versions.rst

content of [https://github.com/algorand/pyteal/releases] is not shown in [https://pyteal.readthedocs.io/en/latest/versions.html]

* Update docs/versions.rst

Co-authored-by: Jason Paulos <[email protected]>

Co-authored-by: Jason Paulos <[email protected]>

* Pass-by-Ref / Dynamic Scratch Variables via the `loads` and `stores` opcodes (#198)

* Pass-by-Reference Semantics
* Use a Dynamic ScratchVar to "iterate" over other ScratchVar's
* Another approach for E2E testing

* Fix build script invocation (#223)

* Bring #225 to master (#227)

* Ignore tests generating TEAL file outputs used for expected comparisons (#228)

* Fix typo in CONTRIBUTING.md (#229)

* Fix subroutine mutual recursion with different argument counts bug (#234)

* Fix mutual recursion bug

* Remove usage of set.pop

* Revert "Pass-by-Ref / Dynamic Scratch Variables via the `loads` and `stores` opcodes (#198)"

This reverts commit cf95165.

* v0.10.1 (#237)

* Revert "Revert "Pass-by-Ref / Dynamic Scratch Variables via the `loads` and `stores` opcodes (#198)""

This reverts commit 51ec8c9.

* Update user guide docs to reflect addition of DynamicScratchVar (#226)

* Update CONTRIBUTING.md on PEP 8 naming conventions policy (#241)

* implement optimization utility with simple slot store/load canceling

* minor refactor

* reformat code

* correct import format to match convention

* slot optimization awareness of reserved ids added

* fix typo

* remove dataclass usage

* slight reorg of compiler process in order to perform optimization on cfg

* clean up imports

* updated documentation and reformatted with new version of black

* remove unused imports and comments

* reformatting

* add additional optimizer unit tests

* improve testing and slight refactoring

* more renaming

* documentation and import changes

* fixed typos in docs

Co-authored-by: Michael Diamant <[email protected]>
Co-authored-by: Ben Guidarelli <[email protected]>
Co-authored-by: Jason Paulos <[email protected]>
Co-authored-by: Edward D Gaudio <[email protected]>
Co-authored-by: Joe Polny <[email protected]>
Co-authored-by: Hang Su <[email protected]>
Co-authored-by: Łukasz Ptak <[email protected]>
Co-authored-by: Zeph Grunschlag <[email protected]>
Co-authored-by: Jack <[email protected]>
Co-authored-by: Glory Agatevure <[email protected]>
Co-authored-by: Adriano Di Luzio <[email protected]>
Co-authored-by: PabloLION <[email protected]>
jasonpaulos added a commit that referenced this pull request Jul 22, 2022
* ABI Types (#154)

* initial commit to be used for reference and comparison

* Fmt

* move abi to ast

* make tuple return the deocded Tuple

* rename collections, fixed some of the mypy issues

* Fix mypy issues

* remove Literal

* add str method for abi type names

* fix names

* make imports nice

* make imports nice

* make collections generic

* rm param spec

* lie to mypy

* make dynamic array work

* [WIP] Make Add and Mul NaryExprs

* ABI refactor

* Implement decoding

* Make arrays encode to a single value

* Make types mutable

* Proof of concept map implementation

* Remove old comment

* Update Uint16 limit check

Co-authored-by: Giorgio Ciotti <[email protected]>

* provide a method to know the type name (#176)

* Refactor array implementation

* Add ComputedType and fix bug in map

* Add more int types and bool support

* Add string method

* Remove files for features that won't make it into this PR

* Remove Array.map 😢

* Make decode more powerful

* Uint bounds checking and tests

* Remove random line

* Bool tests and bugfixes

* Allow uint and bool set to copy another type

* Begin tuple and array tests, improve dynamic tuple encoding, and remove Array.forEach

* Test indexTuple and fix bugs

* Fix field shadowing

* Finish tuple tests and type tests

* Implement static and dynamic array tests

* Finish testing abi types and fix tuple encoding bug

* Add generic param to new instances of arrays

* Address feedback

* Fix tuple decoding issue

* Fix uint64 decoding test

* minor improvement to distinguish abi.Byte and abi.Uint8 (#194)

* Add docstrings to abi.Type

* Respond to feedback

* Respond to feedback & fix bug

* Fix indexTuple bug

* Add docs for TealBlock methods

* ABI Array docstrings and comments (#216)

Co-authored-by: Jason Paulos <[email protected]>
Co-authored-by: Giorgio Ciotti <[email protected]>
Co-authored-by: Hang Su <[email protected]>

* Merge with master and regenerate `__index__.pyi` (#224)

* Fix build script invocation (#223)

* Regen __init__.pyi

* Reorder CI build steps to change source files before running tests (#225)

Co-authored-by: Michael Diamant <[email protected]>

* Merge #227 into feature/abi (#231)

* Fix build script invocation (#223)

* Bring #225 to master (#227)

* Ignore tests generating TEAL file outputs used for expected comparisons (#228)

* Fix typo in CONTRIBUTING.md (#229)

Co-authored-by: Jason Paulos <[email protected]>

* Make ABI types fully specified (#222)

* Convert Type and Tuple to indexable types

* Convert and combine uint types

* Fix type and unit tests

* Convert Bool

* Fix Tuple getitem

* Convert arrays and array tests

* Fix tuple tests

* [WIP] satisfy mypy

* Refactor ABI types

* Update docs, add Tuple4 and Tuple5, and change type_spec method name

* No longer test on Python 3.6 and 3.7

* No longer test on Python 3.6 and 3.7

* Remove accidentally included file

* Add another literal test case

* Debugging through CI

* blacken

* Remove problematic test case

* Minor test coverage improvements

* Unit test to make sure type_spec_from_annotation always works on all types

* Partially address feedback

* Make uint8 != byte and use typing.Final in a few constructors

* Undo custom set methods

* Fix typo

Co-authored-by: Michael Diamant <[email protected]>

Co-authored-by: Michael Diamant <[email protected]>

* Passing ABI type arguments to Subroutine (#263)

- passing ABI variables into subroutine
- subroutine type annotations with ABI types

* ABI Method Return (#175)

Encode ABI variable and concat with `RETURN_METHOD_SELECTOR` and log it.

* Allow `ComputedType` to be passed to the `set` method on ABI types (#267)

* update minor support for setting ComputedType

* minor tweak

* backwards for 3.8 on subscriptable type

* attempt to test uint set

* minor

* cleanup

* update arrays, tuple to test

* tuple testing

* update documents

* resolving comments

* py3.10 less go

* python typing annotations

* Merge branch 'master' into feature/abi (#284)

* Move to pyteal as pt in ABI tests with concise  prefix (#286)

* ABI Strings (#278)

* Move to pyteal as pt in #278 (#287)

* Merge absolute imports into feature/abi (#288)

* Remove temporary I252 ignore on pyteal.ast.abi (#290)

* Fix abi import (#303)

* Fix abi import

* ignore flake8

* Feature/abi merge master again (#310)

Following major changes:
* Merge in Blackbox testing
* replace `SubroutineDefinition. _arg_types_and_by_refs()` by `SubroutineDefinition._validate()`
* add abi cases to `subroutine_test.py::test_validate()`

* merge conflicts

* merge again

* wip

* pass all tests after resolving conflicts

* Add `set` on address and string, change array init to accept typespec (#289)

* adding set on String and Address types

* Add convenience `make` method for ABI types (#326)

* Add make method for abi types

* Respondn to feedback

* ABI Type subroutine return (#256)

* wtf

* update

* update to f-str

* define void type

* update instantiated computed type returnedType for ABI return in subroutine

* minor

* update stuffs to help infer type annotation of return ABI

* minor

* minor

* minor

* minor

* minor

* try my best to save stuffs

* simplify decorator to single function

* tear it down

* minor

* sheeeesh emacs

* updates

* minor, renaming something

* new design, start over

* updates

* abi fn wrapper for now

* minor

* minor update on subroutine def

* minor fixes

* minor fixes

* changes

* more constraint on void ret

* update comment examples

* import from abi

* update some error msg and comments

* testcases partial

* upgrade testscripts

* Bundle optional refactorings to subroutine.py (#308)

* Bundle optional refactorings to subroutine.py

* Refactor to remove branching

* storing local changes

* pr review partly

* pr review partly

* update test script

* Abi subroutine feature merge (#315)

* resolve conflicts

* lint

* minor reconstruct

* missing imports

* missing requirements from bad merge

* cooperate with typespec n var def change

* update comments

* some comments resolving?

* trim

* update some comments

* bring testcase back

* restriction on output kwarg name

* stop ci! i am reformatting

* simplify name constrain

* resolving comments

* Use deferred subroutine expression for ABI returns (#328)

* Add subroutine deferred expr

* Allow multiple deferred blocks

* Remove error

* flake8

* Make test more realistic

* Add second test

* clean up code and comments

* remove deferred blocks function

* Add coverage for multiple ops in block error

* hack return from abi var

* a hack

* better returned type

* simplify

* add some compiler test

* flake break no way

* PR comment resolve partial

* polishing

Co-authored-by: Michael Diamant <[email protected]>
Co-authored-by: Zeph Grunschlag <[email protected]>
Co-authored-by: Zeph Grunschlag <[email protected]>
Co-authored-by: Jason Paulos <[email protected]>

* adding byte type hint to DyanamicArray parent class (#339)

* adding byte type hint to DyanamicArray parent class

* appease mypy

* specify Byte in set method instead of T

* Define level of support provided for ABIReturnSubroutine (#341)

* Testing ABI Functionality via Graviton / Dry-runs + Txn Friendly Graviton Logic Sig Example (#322)

# Blackbox Testing ABI Functionality
This PR brings in dry-run testing of ABI types and subroutines. The space of ABI-Functionality that needs testing is large, and this PR doesn't purport to provide full coverage. However, the basic tools are provided to obtain greater coverage in the future. The following specific ABI use cases are tested:

* abi_sum() which computes the sume of a DynamicArray
* integers and complex integer number (Gassian integers) are built up from basic types and basic operations are validated
* round-trip encoding and decoding of a number of ABI types

# Testing Logic Sigs which interact with their Payment Transaction
#249 introduced examples/signature/factorizer_game.py which includes a family of logic sigs that provide a payout that depends on the solution to an algebra puzzle. With a recent improvement to graviton we can now run blackbox tests on this logic sig family, and gain confidence in its correctness. See tests/integration/pure_logicsig_test.py for how this is done.

* abi_roundtrip_test::test_abi_types_comprehensive() (#355)

* adding sizeof util (#358)

* adding size_of util

* Reference Types (#361)

* adding reference types to ABI types

* Clearer Comment (#364)

* Clearer Comment and link comment to issue #184

* Bug: Graviton's report no longer has last_rows (#365)

* adding deref type to get the underlying value of the reference type (#372)

* `ABI Router` implementation and test (#170)

* init commit

* minor

* minor

* rm decorator

* update ABI router design, seems we are still working on previous design

* minor

* update condition parser here

* skeleton for handler wrapping, need to tweak on subroutine to expose more message

* module

* use subroutine fn wrapper

* update dummy method return class

* unify ast construct way

* minor

* update notes for tasks and todos

* update handler wrapping for bare app call

* minor

* update redirecting args to method registered

* minor

* minor

* update router src

* update program node

* add questions in build prog

* update executing method branch

* minor

* minor

* minor

* hide other methods, set MethodAppArgNumLimit, keyword args on exposed register func, skeleton for arg de-tuple

* minor

* update notes

* update

* add a default for no registered ast gen

* update ast construction to conds

* need some documentations

* move abi-router in abi dir

* minor

* wtf

* update

* update to f-str

* define void type

* update instantiated computed type returnedType for ABI return in subroutine

* minor

* update stuffs to help infer type annotation of return ABI

* minor

* minor

* minor

* minor

* minor

* try my best to save stuffs

* simplify decorator to single function

* tear it down

* minor

* sheeeesh emacs

* update with latest abi impl

* minors

* minor

* updates

* minor, renaming something

* new design, start over

* updates

* abi fn wrapper for now

* minor

* minor update on subroutine def

* minor fixes

* minor fixes

* changes

* more constraint on void ret

* update comment examples

* import from abi

* update some error msg and comments

* testcases partial

* upgrade testscripts

* merging feature/abi to abi-router (#305)

* merging feature/abi

* missed one

* make router use absolute imports

* linter happy?

* Export Router (#306)

* Merge branch 'master' into feature/abi (#284)

* Move to pyteal as pt in ABI tests with concise  prefix (#286)

* ABI Strings (#278)

* Move to pyteal as pt in #278 (#287)

* Merge absolute imports into feature/abi (#288)

* Remove temporary I252 ignore on pyteal.ast.abi (#290)

* Fix abi import (#303)

* Fix abi import

* ignore flake8

* move router to ast

Co-authored-by: Michael Diamant <[email protected]>
Co-authored-by: Jason Paulos <[email protected]>

* fix spacing issue

* Bundle optional refactorings to subroutine.py (#308)

* Bundle optional refactorings to subroutine.py

* Refactor to remove branching

* storing local changes

* pr review partly

* pr review partly

* update test script

* Abi subroutine feature merge (#315)

* resolve conflicts

* lint

* minor reconstruct

* missing imports

* missing requirements from bad merge

* cooperate with typespec n var def change

* update comments

* some comments resolving?

* trim

* update some comments

* bring testcase back

* restriction on output kwarg name

* stop ci! i am reformatting

* squash merge abi subroutine atm, merge again after abi subroutine into feature/abi

* conform to pep8, reconstructing

* update json generator

* simplify name constrain

* resolving comments

* Use deferred subroutine expression for ABI returns (#328)

* Add subroutine deferred expr

* Allow multiple deferred blocks

* Remove error

* flake8

* Make test more realistic

* Add second test

* clean up code and comments

* remove deferred blocks function

* Add coverage for multiple ops in block error

* updating wrap handler

* change how to de-tuple args

* update checkbox

* minor

* bug fixes

* Method sig for router (#340)

* adding method_signature to ABIReturnSubroutine

* minor, renaming

* minor

* simplify

* compiler test adding...

* documentation

* start testcases

* update router testcase

* docstring tweak

* update testcases

* update testcases

* formatting

* branch cond testing

* router contract test

* subroutine branch wrapper bare call case tested

* more testcases to barecall

* minor, need to work on method call wrapper

* half done on method call wrapper

* update on abi method wrapper with return

* detuple testcase

* compiler test need to see csp

* rm redundant type annotation

* more error msg

* renaming

* renaming is_registrable -> is_abi_routable

* reording imports, eliminate anti patterns

* remove anti-pattern

* section it out

* non_empty_power_set -> power_set

* add conflict detection to protect AST from overshadowing

* error message

* shrinked commits on pr review

* add compile_program

* fixup subroutine testcase

* remove method signature specifying, directly infer from ABIReturnSubroutine

* remove method sign field, directly infer from ABIReturnSubroutine

* relaxation of bare app call arg num restriction

* add barecall class, api change following

* rename barecall to OnCompleteAction

* remove outdated comments

* start changing router api

* eliminate contradiction for oc and creation

* remove restriction on cond

* new interface: add bare-calls on init, register method-call more fine-grained

* documentation for new interface from last discussion

* Refactor #170 to reduce visibility and mutation (#362)

* Refactor to use partition

* Designate _oc_under_call_config as private

* hide wrap handler method

* adding comment changes

* pr review partly

* partition into two methods

* hide all these methods

* arc4 compliant CallConfigs classmethod

* arc4 compliant CallConfigs documentation

* disclaimer comments

* update new abi return hash prefix

* review comments partly

* OnCompleteActions -> BareCallActions

* disclaimer change, rename CallConfigs -> MethodConfig

* disclaimer move to docstring

* better naming for naming prefix

* new ast builder

* review comments

* An attempt to add decorator syntax to abi-router (#370)

* an attempt to use decorator

* no return, or we will have python-level issue?

* minor fix

* per pr comment on on-complete-action

* eliminate potential issue

* update call config testcase

* add testcase for on complete action

* per comments

* Add a check in `method_signature` to disallow reference return types (#368)

* new ast builder

* adding check in method_signature to raise error if its attempted to be called on method with reference type as return value

* use type spec instead of str

* adding recursive type checking method and using it in subroutine method signature

* Adding one more test case for extra nesting

* appease the linter

Co-authored-by: Hang Su <[email protected]>

* add new compiler tests for router

* fix one test for wrapping bare calls

* comments fixing

* simplified oc-action post_init check

* naming variables

* comments

* comments

* testcase for method config update

* add router method only in clearstate prog

* closeout -> clearstate

* removing is_arc4_compliant

* update add method handler and method interface

* remove arc4_compliant

* Add manual test for 15+ args in abi router (#375)

Co-authored-by: Ben Guidarelli <[email protected]>
Co-authored-by: Michael Diamant <[email protected]>
Co-authored-by: Jason Paulos <[email protected]>
Co-authored-by: Zeph Grunschlag <[email protected]>
Co-authored-by: Zeph Grunschlag <[email protected]>

* Adding method_spec to ABIReturnSubroutine (#380)

* adding method_spec to ABIReturnSubroutine

* Txn types (#376)

* Add transaction abi types

* Blackbox testing unifying abi-return-subroutine and subroutine input handling (#374)

* unify subroutine case and abi-returning-subroutine

* reconstruct code on argument prep and call

* an example subroutine taking in abi arguments

* update comment example and explanation

* per pr comment

* Changes to router clear state (#386)

* define reference type spec (#383)

* define reference type spec
Co-authored-by: Jason Paulos <[email protected]>
Co-authored-by: Zeph Grunschlag <[email protected]>

* Rename decode parameters to abide by PEP8 conventions (#389)

* More abi graviton tests (#391)

* test_conditional_factorial()

* Router return subroutine (#422)

* Adding return value to add_method_call

* Method call itxn (#387)

* adding itxn method to call ABI method

* __str__ formatting (#411)

* standardize str formatting

* Check transaction type arguments (#427)

* Check transaction type arguments

* Rename Transaction.set to be private

* Check `Expr` length when converting to `abi.Address` (#432)

* Fix on previous address length check (#433)

* minor fix

* minor

* per Jason comment

* minor, formatting

* unit -> uint (#434)

* Support declaring compatible PyTeal version in source code (#429)

* Add semantic version dependency

* Add `pragma` to enforce compatible compiler versions

* Raise `TealInternalError` instead of `TealInputError`

* Switch back to `pkg_resources` and convert PEP 440 to semantic version 2.0.0

* Fix linter errors

* Make pep 440 converter private

* Add `Pragma` expression

* Refactor pragma functions from compiler to ast to avoid circular dependencies
* Add `is_valid_compiler_version` check helper for the `Pragma` expression
* Use `TealProgramError` instead of `TealInternalError`

* Test underlying TEAL is unchanged

* Refactor underlying pragma methods to parent directory

* Inherit from `Expr` instead

* Fix unclear docstring

* Document init

Document init

* Add caret compiler version tests

* Ignore unused fixture imports

* Consistently use `start_index` and `end_index` (#436)

* Consistently use start_ and end_index

* format

* allow passing router description to Contract constructor (#448)

* allow passing router description to Contract constructor

* Document new ABI features (#400)

* Initial commit

* Fix abi-docs tests (#402)

* Fix abi-docs Sphinx warnings (#401)

* Extend abi-docs with experimental design language (#403)

* Add type fundamentals section

* Add basic type usage and some docstrings for referenced methods

* Finish documenting set and fix overloaded method docs

* Add docstrings for get and __getitem__

* Add reference type docs

* Add txn type examples

* Fix errors

* Make ComputedValue parameter type covariant

* ComputedValue and subroutine sections

* ...wasn't included in previous commit

* Add bare app call and method registration examples

* Add router e2e example and compilation explanation

* Fix post-merge linter/test failures

* Add calling documentation

* Partially address feedback

* Respond to feedback

* Resolve TODOs

* Add pragma references

* didn't make it into the previous commit

* Fix Bool.__module__

* Mention stack size limit

* More pragma documentation

* Address other feedback

* Warn about reference type limits

* **cannot**

Co-authored-by: Michael Diamant <[email protected]>

* Feature/abi merge master (#457)

* Clarify minimum Python version management docs (#435)

* Foreign prefix on App and Asset arrays (#440)

* replacing foreignapps with applications

* fix assets as well

* Add Execute Method (#444)

* adding execute method to allow omission of begin/submit for common use case

* exec docstring

* update testcase

Co-authored-by: Hang Su <[email protected]>

Co-authored-by: Michael Diamant <[email protected]>
Co-authored-by: Ben Guidarelli <[email protected]>
Co-authored-by: Hang Su <[email protected]>

* `abi.Bool` improvements (#453)

* abi.Bool improvements

* Don't need Seq anymore

* nor its import

* No black, that was not a tuple

* modify integreation tests

* missed one

* Missed a file

* Rename pyteal/ast/abi/bool.py functions to follow PEP 8 conventions (#459)

* Specify dependency versions (#464)

* Rename pyteal/ast/abi/util.py functions to follow PEP 8 conventions (#460)

* Rename pyteal/ast/abi/tuple.py functions to follow PEP 8 conventions (#461)

* Fix typos in pyteal/ast/abi/util.py (#467)

* Rename encoded_string to demarcate internal usage (#466)

* Rename pyteal/ast/abi method parameters to follow PEP 8 conventions (#468)

Co-authored-by: Ben Guidarelli <[email protected]>
Co-authored-by: Jason Paulos <[email protected]>
Co-authored-by: Giorgio Ciotti <[email protected]>
Co-authored-by: Hang Su <[email protected]>
Co-authored-by: Hang Su <[email protected]>
Co-authored-by: Zeph Grunschlag <[email protected]>
Co-authored-by: Zeph Grunschlag <[email protected]>
Co-authored-by: Jacob Daitzman <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants