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

feat(bindings-ts): support multi-auth workflows #16

Closed
wants to merge 4 commits into from

Conversation

chadoh
Copy link

@chadoh chadoh commented Oct 10, 2023

  • add atomic_swap and token contracts from
    https://github.com/stellar/soroban-examples to test-wasms
  • greatly complicate ts-tests/package.json to deploy & generate
    bindings for these new contracts, plus creating an alice identity
    and minting separate amounts of two separate tokens to the root user
    and alice
  • add tests for atomic swap functionality inspired by
    https://github.com/stellar/soroban-react-atomic-swap
  • let this logic guide needed updates to bindings typescript-generated
    libraries:
    • don't return flat values
    • instead, always return an object which will have at least a
      txUnsigned and simulation key
    • object contains all possibly-relevant fields from the logic it
      performs

@chadoh chadoh force-pushed the feat/bindings-ts/multi-auth branch from 7919dbf to 888bdb7 Compare October 10, 2023 20:10
@chadoh chadoh force-pushed the chore/bindings_udate branch from ba4ecf9 to bff2f5c Compare October 16, 2023 16:07
@chadoh chadoh force-pushed the feat/bindings-ts/multi-auth branch from 888bdb7 to a578558 Compare October 16, 2023 17:14
@chadoh chadoh force-pushed the chore/bindings_udate branch from bff2f5c to 486fca1 Compare October 16, 2023 17:15
@chadoh chadoh force-pushed the feat/bindings-ts/multi-auth branch 2 times, most recently from b27ea0b to cbab0be Compare October 16, 2023 18:06
@chadoh chadoh force-pushed the chore/bindings_udate branch from 486fca1 to 779f04c Compare October 16, 2023 18:06
@chadoh chadoh force-pushed the feat/bindings-ts/multi-auth branch from cbab0be to 6cf1866 Compare October 16, 2023 19:25
chadoh and others added 3 commits October 17, 2023 12:13
* chore: update ts bindings

What
----

Update the typescript bindings with all the changes that landed in the futurenet-compatible `smartdeploy` branch since `main` stopped working with futurenet.

Why
---

Lots of good improvements and fixes are not yet in `main`, ~including tests for the generated libraries.~ _CI tests will be included in a future PR; reasonable time-sink exceeded for this one.

Closes: stellar#996

Known limitations
-----------------

The newly-added tests are not yet being exercised in CI; you can see the commit history for all the details of how we tried to work around this. At this point, we will:

- wait for stellar/quickstart#507 to get merged & included in a published quickstart image
- retry the `bindings-ts.yml` workflow, which was almost working except that friendbot was not starting properly when quickstart was run _in CI_ (though it does start properly, even if a bit slowly, when quickstart is run locally)
- after a basic run-tests-with-published-quickstart is working, the next step is to build a custom quickstart image using _this repository's_ RPC version, and use that custom quickstart to run the integration tests. This might be able to be accomplished [as described by ChatGPT here](https://chat.openai.com/share/0f355fbe-93b9-4c8d-9c12-7f54846134bd).

* build: bump delta for flaky test

* build: increase deltas in cli simulation test

---------

Co-authored-by: Willem Wyndham <willem@ahalabs.dev>
Co-authored-by: Tsachi Herman <24438559+tsachiherman@users.noreply.github.com>
* update.

* preserve cors behaviour

* update version
* feat!: remove run_in_sandbox
* fix: reorganize tests that rely on network and ignore outside of go test
* fix: use feature instead of cfg so that cargo test --list can find tests
* fix: move common tests to single functions to skip setup time
* feat!: skip wasm in invoke
* fix: fully remove all sandbox related types and args
@chadoh chadoh force-pushed the feat/bindings-ts/multi-auth branch from 6cf1866 to 73a9b60 Compare October 19, 2023 15:52
- add `atomic_swap` and `token` contracts from
  https://github.com/stellar/soroban-examples to `test-wasms`
- greatly complicate `ts-tests/package.json` to deploy & generate
  bindings for these new contracts, plus creating an `alice` identity
  and minting separate amounts of two separate tokens to the `root` user
  and `alice`
- add tests for atomic swap functionality inspired by
  https://github.com/stellar/soroban-react-atomic-swap
- let this logic guide needed updates to `bindings typescript`-generated
  libraries:
  - don't return flat values
  - instead, always return an object which will have at least a
    `txUnsigned` and `simulation` key
  - object contains all possibly-relevant fields from the logic it
    performs

Co-authored-by: Aristides Staffieri <aristides.staffieri@stellar.org>
@chadoh chadoh force-pushed the feat/bindings-ts/multi-auth branch from 73a9b60 to d37d503 Compare October 19, 2023 15:52
@chadoh
Copy link
Author

chadoh commented Oct 19, 2023

Closing in favor of stellar#1034

@chadoh chadoh closed this Oct 19, 2023
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