diff --git a/.circleci/config.yml b/.circleci/config.yml new file mode 100644 index 000000000..62291703e --- /dev/null +++ b/.circleci/config.yml @@ -0,0 +1,31 @@ +# Use the latest 2.1 version of CircleCI pipeline process engine. +# See: https://circleci.com/docs/configuration-reference +version: 2.1 + +# Define a job to be invoked later in a workflow. +# See: https://circleci.com/docs/jobs-steps/#jobs-overview & https://circleci.com/docs/configuration-reference/#jobs +jobs: + say-hello: + # Specify the execution environment. You can specify an image from Docker Hub or use one of our convenience images from CircleCI's Developer Hub. + # See: https://circleci.com/docs/executor-intro/ & https://circleci.com/docs/configuration-reference/#executor-job + docker: + # Specify the version you desire here + # See: https://circleci.com/developer/images/image/cimg/base + - image: cimg/base:current + + # Add steps to the job + # See: https://circleci.com/docs/jobs-steps/#steps-overview & https://circleci.com/docs/configuration-reference/#steps + steps: + # Checkout the code as the first step. + - checkout + - run: + name: "Say hello" + command: "echo Hello, World!" + +# Orchestrate jobs using workflows +# See: https://circleci.com/docs/workflows/ & https://circleci.com/docs/configuration-reference/#workflows +workflows: + say-hello-workflow: # This is the name of the workflow, feel free to change it to better match your workflow. + # Inside the workflow, you define the jobs you want to run. + jobs: + - say-hello \ No newline at end of file diff --git a/.eslintrc.js b/.eslintrc.js index 585418a5b..6c3aa9069 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -1,4 +1,4 @@ -const { off } = require("process") +const { off } = require('process') module.exports = { parser: '@typescript-eslint/parser', @@ -36,7 +36,6 @@ module.exports = { 'import/no-named-as-default-member': 'off', 'import/export': 'off' - // 'import/order': [ // 'warn', // { @@ -47,6 +46,5 @@ module.exports = { // } // }, // ] - } } diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS new file mode 100644 index 000000000..7f34c7a88 --- /dev/null +++ b/.github/CODEOWNERS @@ -0,0 +1 @@ +* @0xsequence/disable-codeowners-notifications @0xsequence/core diff --git a/.github/actions/install-dependencies/action.yml b/.github/actions/install-dependencies/action.yml index 39beabeb4..e683e293b 100644 --- a/.github/actions/install-dependencies/action.yml +++ b/.github/actions/install-dependencies/action.yml @@ -4,6 +4,11 @@ runs: using: 'composite' steps: + - name: Setup Node + uses: actions/setup-node@v4 + with: + node-version: 20 + - name: Setup PNPM uses: pnpm/action-setup@v3 with: @@ -17,7 +22,7 @@ runs: echo "STORE_PATH=$(pnpm store path)" >> $GITHUB_OUTPUT - name: Setup pnpm cache - uses: actions/cache@v3 + uses: actions/cache@v4 with: path: | ${{ steps.pnpm-cache.outputs.STORE_PATH }} @@ -28,11 +33,6 @@ runs: restore-keys: | ${{ runner.os }}-pnpm-store- - - name: Setup Node - uses: actions/setup-node@v3 - with: - node-version: 20 - - name: Install dependencies shell: bash run: pnpm install --frozen-lockfile diff --git a/.github/workflows/pnpm-format.yml b/.github/workflows/pnpm-format.yml new file mode 100644 index 000000000..1be36e1a6 --- /dev/null +++ b/.github/workflows/pnpm-format.yml @@ -0,0 +1,27 @@ +name: pnpm format + +on: + workflow_call: + +jobs: + run: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v4 + with: + ref: ${{ github.head_ref }} + fetch-depth: 20 + + - uses: ./.github/actions/install-dependencies + + - run: pnpm format + + - name: Commit back + uses: 0xsequence/actions/git-commit@v0.0.4 + env: + API_TOKEN_GITHUB: ${{ secrets.GH_TOKEN_GIT_COMMIT }} + with: + files: './' + branch: ${{ github.head_ref }} + commit_message: '[AUTOMATED] pnpm format' diff --git a/.github/workflows/pr:pnpm-format-label.yml b/.github/workflows/pr:pnpm-format-label.yml new file mode 100644 index 000000000..84fb27cb3 --- /dev/null +++ b/.github/workflows/pr:pnpm-format-label.yml @@ -0,0 +1,23 @@ +name: pnpm-format-label + +on: + pull_request: + types: [labeled] + +jobs: + proto: + if: ${{ github.event.label.name == 'pnpm format' }} + uses: ./.github/workflows/pnpm-format.yml + secrets: inherit + + rm: + if: ${{ github.event.label.name == 'pnpm format' }} + runs-on: ubuntu-latest + steps: + - name: Remove the label + run: | + LABEL=$(echo "${{ github.event.label.name }}" | sed 's/ /%20/g') + curl -X DELETE \ + -H "Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}" \ + -H "Accept: application/vnd.github.v3+json" \ + https://api.github.com/repos/${{ github.repository }}/issues/${{ github.event.pull_request.number }}/labels/$LABEL diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index d49eea949..e632f35dc 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -7,7 +7,7 @@ jobs: name: Install dependencies runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: ./.github/actions/install-dependencies build: @@ -15,7 +15,7 @@ jobs: runs-on: ubuntu-latest needs: [install] steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: ./.github/actions/install-dependencies - run: pnpm typecheck - run: pnpm lint @@ -26,7 +26,7 @@ jobs: runs-on: ubuntu-latest needs: [install] steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: ./.github/actions/install-dependencies - run: pnpm --filter 0xsequence test @@ -35,7 +35,7 @@ jobs: runs-on: ubuntu-latest needs: [install] steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: ./.github/actions/install-dependencies - run: pnpm --filter abi test @@ -44,7 +44,7 @@ jobs: runs-on: ubuntu-latest needs: [install] steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: ./.github/actions/install-dependencies - run: pnpm --filter account test @@ -53,7 +53,7 @@ jobs: runs-on: ubuntu-latest needs: [install] steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: ./.github/actions/install-dependencies - run: pnpm --filter api test @@ -62,33 +62,34 @@ jobs: runs-on: ubuntu-latest needs: [install] steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: ./.github/actions/install-dependencies - run: pnpm --filter auth test - tests-deployer: - name: Run deployer tests + + tests-core: + name: Run core tests runs-on: ubuntu-latest needs: [install] steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: ./.github/actions/install-dependencies - - run: pnpm --filter deployer test + - run: pnpm --filter core test - tests-estimator: - name: Run estimator tests + tests-deployer: + name: Run deployer tests runs-on: ubuntu-latest needs: [install] steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: ./.github/actions/install-dependencies - - run: pnpm --filter estimator test + - run: pnpm --filter deployer test tests-guard: name: Run guard tests runs-on: ubuntu-latest needs: [install] steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: ./.github/actions/install-dependencies - run: pnpm --filter guard test @@ -97,7 +98,7 @@ jobs: runs-on: ubuntu-latest needs: [install] steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: ./.github/actions/install-dependencies - run: pnpm --filter indexer test @@ -106,7 +107,7 @@ jobs: runs-on: ubuntu-latest needs: [install] steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: ./.github/actions/install-dependencies - run: pnpm --filter metadata test @@ -115,25 +116,16 @@ jobs: runs-on: ubuntu-latest needs: [install] steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: ./.github/actions/install-dependencies - run: pnpm --filter migration test - tests-multicall: - name: Run multicall tests - runs-on: ubuntu-latest - needs: [install] - steps: - - uses: actions/checkout@v3 - - uses: ./.github/actions/install-dependencies - - run: pnpm --filter multicall test - tests-network: name: Run network tests runs-on: ubuntu-latest needs: [install] steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: ./.github/actions/install-dependencies - run: pnpm --filter network test @@ -142,7 +134,7 @@ jobs: runs-on: ubuntu-latest needs: [install] steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: ./.github/actions/install-dependencies - run: pnpm --filter provider test @@ -151,7 +143,7 @@ jobs: runs-on: ubuntu-latest needs: [install] steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: ./.github/actions/install-dependencies - run: pnpm --filter relayer test @@ -160,7 +152,7 @@ jobs: runs-on: ubuntu-latest needs: [install] steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: ./.github/actions/install-dependencies - run: pnpm --filter replacer test @@ -169,7 +161,7 @@ jobs: runs-on: ubuntu-latest needs: [install] steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: ./.github/actions/install-dependencies - run: pnpm --filter sessions test @@ -178,25 +170,16 @@ jobs: runs-on: ubuntu-latest needs: [install] steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: ./.github/actions/install-dependencies - run: pnpm --filter signhub test - tests-simulator: - name: Run simulator tests - runs-on: ubuntu-latest - needs: [install] - steps: - - uses: actions/checkout@v3 - - uses: ./.github/actions/install-dependencies - - run: pnpm --filter simulator test - tests-utils: name: Run utils tests runs-on: ubuntu-latest needs: [install] steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: ./.github/actions/install-dependencies - run: pnpm --filter utils test @@ -205,7 +188,7 @@ jobs: runs-on: ubuntu-latest needs: [install] steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: ./.github/actions/install-dependencies - run: pnpm --filter waas test @@ -214,7 +197,7 @@ jobs: runs-on: ubuntu-latest needs: [install] steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: ./.github/actions/install-dependencies - run: pnpm --filter wallet test @@ -223,11 +206,11 @@ jobs: # runs-on: ubuntu-latest # needs: [install] # steps: - # - uses: actions/checkout@v3 - # - uses: actions/setup-node@v3 + # - uses: actions/checkout@v4 + # - uses: actions/setup-node@v4 # with: # node-version: 20 - # - uses: actions/cache@v3 + # - uses: actions/cache@v4 # id: pnpm-cache # with: # path: | diff --git a/README.md b/README.md index 0dd6b6565..6df5ac14b 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,4 @@ -0xsequence -========== +# 0xsequence [Sequence](https://sequence.xyz): a modular web3 stack and smart wallet for Ethereum chains @@ -15,7 +14,6 @@ or `yarn add 0xsequence ethers` - ## Packages - [0xsequence](./packages/0xsequence) @@ -25,6 +23,7 @@ or - [@0xsequence/core](./packages/core) - [@0xsequence/deployer](./packages/deployer) - [@0xsequence/guard](./packages/guard) +- [@0xsequence/marketplace](./packages/marketplace) - [@0xsequence/multicall](./packages/multicall) - [@0xsequence/network](./packages/network) - [@0xsequence/provider](./packages/provider) @@ -35,7 +34,6 @@ or - [@0xsequence/utils](./packages/utils) - [@0xsequence/wallet](./packages/wallet) - ## Development Environment Below are notes and instructions on how to get your development environment up and running, @@ -68,49 +66,58 @@ and enjoyable. 7. **Versioning** -- this repository uses the handy [changesets](https://github.com/atlassian/changesets) package for package versioning across the monorepo, as well as changelogs. See _Releasing_ section below. - ## Releasing to NPM 0xsequence uses changesets to do versioning. This makes releasing really easy and changelogs are automatically generated. ### How to do a release -1. Run `pnpm` to make sure everything is up to date -2. Code.. do your magic -3. Run `pnpm changeset` to generate a new .changeset/ entry explaining the code changes -4. Version bump all packages regardless of them having changes or not -5. Run `pnpm i` to update the pnpm-lock.yaml. -6. Commit and submit your changes as a PR for review -7. Once merged and you're ready to make a release, continue to the next step. If you're not - ready to make a release, then go back to step 2. -8. Run `pnpm build && pnpm test` to double check all tests pass -9. Run `pnpm version-packages` to bump versions of the packages -10. Run `pnpm install` so we update our pnpm-lock.yaml file with our newly created version -11. Commit files after versioning. This is the commit that will be published and tagged: `git push --no-verify` -12. Run `pnpm release`. If the 2FA code timesout while publishing, run the command again - with a new code, only the packages that were not published will be published. -13. Finally, push your git tags, via: `git push --tags --no-verify` - +Authorization on https://www.npmjs.com/ to push to the 0xsequence organization's packages is required. + +0. (first time) `pnpm login` +1. check that master is passing tests on github +2. (warning: destructive) start from a clean repo: + `git checkout master && git reset --hard && git clean -dfx && pnpm i` +3. for each new change: + a. `pnpm changeset` + b. select all packages + c. update all packages with either a minor or patch bump according to semver + d. add a summary of the form: `package: description of a single change` + e. repeat a-d until all changes are accounted for +4. `pnpm changeset:version && pnpm i && pnpm build && pnpm i` +5. `git diff` and copy the newest version according to the changelogs +6. `git commit -a -m ` +7. `git push` +8. `pnpm changeset:publish` and enter your 2fa totp token when prompted +9. `git push --tags` ## How to do a snapshot release +Authorization on https://www.npmjs.com/ to push to the 0xsequence organization's packages is required. + Snapshot releases are versioned as 0.0.0-YYYYmmddHHMMSS and are intended for testing builds only. -1. `pnpm snapshot` (select all packages even if unchanged, the message is not important) -2. Do not commit any changes to package.json's or CHANGELOG.md's that happened during 1. +0. (first time) `pnpm login` +1. (warning: destructive) start from a clean repo: + `git checkout && git reset --hard && git clean -dfx && pnpm i` +2. `pnpm changeset:snapshot` + a. select all packages + b. update all packages with a patch bump + c. any summary is ok + d. enter your 2fa totp token when prompted + e. note the snapshot version 0.0.0-YYYYmmddHHMMSS +3. `git reset --hard` ## NOTES 1. Browser tests can be run with `pnpm test` or, separately `pnpm test:server` and `pnpm test:run` 2. To run a specific test, run `pnpm test:only `, ie. `pnpm test:only window-transport` - ## TIPS -* If you're using node v18+ and you hit the error `Error: error:0308010C:digital envelope routines::unsupported`, +- If you're using node v18+ and you hit the error `Error: error:0308010C:digital envelope routines::unsupported`, make sure to first set, `export NODE_OPTIONS=--openssl-legacy-provider` - ## LICENSE Apache-2.0 diff --git a/SECURITY.md b/SECURITY.md new file mode 100644 index 000000000..034e84803 --- /dev/null +++ b/SECURITY.md @@ -0,0 +1,21 @@ +# Security Policy + +## Supported Versions + +Use this section to tell people about which versions of your project are +currently being supported with security updates. + +| Version | Supported | +| ------- | ------------------ | +| 5.1.x | :white_check_mark: | +| 5.0.x | :x: | +| 4.0.x | :white_check_mark: | +| < 4.0 | :x: | + +## Reporting a Vulnerability + +Use this section to tell people how to report a vulnerability. + +Tell them where to go, how often they can expect to get an update on a +reported vulnerability, what to expect if the vulnerability is accepted or +declined, etc. diff --git a/azure-pipelines.yml b/azure-pipelines.yml new file mode 100644 index 000000000..676233afa --- /dev/null +++ b/azure-pipelines.yml @@ -0,0 +1,21 @@ +# Node.js +# Build a general Node.js project with npm. +# Add steps that analyze code, save build artifacts, deploy, and more: +# https://docs.microsoft.com/azure/devops/pipelines/languages/javascript + +trigger: +- master + +pool: + vmImage: ubuntu-latest + +steps: +- task: NodeTool@0 + inputs: + versionSpec: '10.x' + displayName: 'Install Node.js' + +- script: | + npm install + npm run build + displayName: 'npm install and build' diff --git a/package.json b/package.json index b203d8027..098bca2f6 100644 --- a/package.json +++ b/package.json @@ -7,9 +7,9 @@ "watch": "preconstruct watch", "clean": "rimraf ./node_modules", "changeset": "changeset", - "version-packages": "changeset version && pnpm update-version", - "release": "pnpm build && changeset publish", - "snapshot": "changeset && changeset version --snapshot && pnpm i && pnpm build && changeset publish --tag snapshot && git tag | grep '0\\.0\\.0' | xargs git tag -d && echo && echo -n 'Published sequence.js snapshot ' && grep '^## ' packages/0xsequence/CHANGELOG.md | head -n 1 | cut -c 4-", + "changeset:version": "changeset version && pnpm update-version", + "changeset:publish": "pnpm build && changeset publish", + "changeset:snapshot": "changeset && changeset version --snapshot && pnpm i && pnpm build && changeset publish --tag snapshot && git tag | grep '0\\.0\\.0' | xargs git tag -d && echo && echo -n 'Published sequence.js snapshot ' && grep '^## ' packages/0xsequence/CHANGELOG.md | head -n 1 | cut -c 4-", "update-version": "node ./scripts/update-version", "test": "pnpm -r --workspace-concurrency=1 test", "test:parallel": "pnpm -r test", @@ -36,15 +36,13 @@ "@0xsequence/api": "workspace:*", "@0xsequence/auth": "workspace:*", "@0xsequence/deployer": "workspace:*", - "@0xsequence/estimator": "workspace:*", "@0xsequence/guard": "workspace:*", "@0xsequence/indexer": "workspace:*", + "@0xsequence/marketplace": "workspace:*", "@0xsequence/metadata": "workspace:*", - "@0xsequence/multicall": "workspace:*", "@0xsequence/network": "workspace:*", "@0xsequence/provider": "workspace:*", "@0xsequence/relayer": "workspace:*", - "@0xsequence/simulator": "workspace:*", "@0xsequence/utils": "workspace:*", "@0xsequence/wallet": "workspace:*", "@babel/core": "^7.21.4", @@ -54,34 +52,35 @@ "@babel/runtime": "^7.21.0", "@changesets/changelog-github": "^0.5.0", "@changesets/cli": "^2.26.1", - "@preconstruct/cli": "^2.8.1", + "@nomicfoundation/hardhat-toolbox": "^5.0.0", + "@preconstruct/cli": "^2.8.9", "@types/chai": "^4.3.11", "@types/chai-as-promised": "^7.1.8", "@types/mocha": "^10.0.6", - "@types/node": "^20.10.4", - "@typescript-eslint/eslint-plugin": "^6.13.2", - "@typescript-eslint/parser": "^6.13.2", - "ava": "^6.0.1", + "@types/node": "^22.7.9", + "@typescript-eslint/eslint-plugin": "^8.11.0", + "@typescript-eslint/parser": "^8.11.0", + "ava": "^6.1.3", "chai": "^4.3.10", "chai-as-promised": "^7.1.1", - "concurrently": "^8.2.2", + "concurrently": "^9.0.1", "eslint": "^8.39.0", "eslint-config-prettier": "^9.1.0", "eslint-plugin-import": "^2.27.5", "eslint-plugin-prettier": "^5.0.1", - "ethers": "^5.7.2", + "ethers": "6.13.4", "express": "^4.18.2", - "hardhat": "^2.20.1", + "hardhat": "^2.22.14", "husky": "^8.0.0", "mocha": "^10.1.0", - "nyc": "^15.1.0", + "nyc": "^17.1.0", "prettier": "^3.0.0", - "puppeteer": "^21.6.0", - "rimraf": "^5.0.5", + "puppeteer": "^23.10.3", + "rimraf": "^6.0.1", "ts-node": "^10.9.2", - "tsx": "^4.6.2", - "typescript": "~5.3.3", - "wait-on": "^7.2.0" + "tsx": "^4.19.1", + "typescript": "~5.6.3", + "wait-on": "^8.0.1" }, "resolutions": {}, "workspaces": [ @@ -97,6 +96,7 @@ }, "pnpm": { "overrides": { + "bufferutil": "^4.0.8", "node-forge@<1.0.0": ">=1.0.0", "node-forge@<1.3.0": ">=1.3.0", "got@<11.8.5": ">=11.8.5", diff --git a/packages/0xsequence/CHANGELOG.md b/packages/0xsequence/CHANGELOG.md index 030a2c5d9..45ca0c613 100644 --- a/packages/0xsequence/CHANGELOG.md +++ b/packages/0xsequence/CHANGELOG.md @@ -1,5 +1,1233 @@ # 0xsequence +## 2.2.14 + +### Patch Changes + +- Somnia Testnet and Monad Testnet +- Updated dependencies + - @0xsequence/abi@2.2.14 + - @0xsequence/account@2.2.14 + - @0xsequence/api@2.2.14 + - @0xsequence/auth@2.2.14 + - @0xsequence/core@2.2.14 + - @0xsequence/guard@2.2.14 + - @0xsequence/indexer@2.2.14 + - @0xsequence/metadata@2.2.14 + - @0xsequence/migration@2.2.14 + - @0xsequence/network@2.2.14 + - @0xsequence/provider@2.2.14 + - @0xsequence/relayer@2.2.14 + - @0xsequence/sessions@2.2.14 + - @0xsequence/signhub@2.2.14 + - @0xsequence/utils@2.2.14 + - @0xsequence/wallet@2.2.14 + +## 2.2.13 + +### Patch Changes + +- Add XR1 to all networks +- Updated dependencies + - @0xsequence/abi@2.2.13 + - @0xsequence/account@2.2.13 + - @0xsequence/api@2.2.13 + - @0xsequence/auth@2.2.13 + - @0xsequence/core@2.2.13 + - @0xsequence/guard@2.2.13 + - @0xsequence/indexer@2.2.13 + - @0xsequence/metadata@2.2.13 + - @0xsequence/migration@2.2.13 + - @0xsequence/network@2.2.13 + - @0xsequence/provider@2.2.13 + - @0xsequence/relayer@2.2.13 + - @0xsequence/sessions@2.2.13 + - @0xsequence/signhub@2.2.13 + - @0xsequence/utils@2.2.13 + - @0xsequence/wallet@2.2.13 + +## 2.2.12 + +### Patch Changes + +- Add XR1 +- Updated dependencies + - @0xsequence/abi@2.2.12 + - @0xsequence/account@2.2.12 + - @0xsequence/api@2.2.12 + - @0xsequence/auth@2.2.12 + - @0xsequence/core@2.2.12 + - @0xsequence/guard@2.2.12 + - @0xsequence/indexer@2.2.12 + - @0xsequence/metadata@2.2.12 + - @0xsequence/migration@2.2.12 + - @0xsequence/network@2.2.12 + - @0xsequence/provider@2.2.12 + - @0xsequence/relayer@2.2.12 + - @0xsequence/sessions@2.2.12 + - @0xsequence/signhub@2.2.12 + - @0xsequence/utils@2.2.12 + - @0xsequence/wallet@2.2.12 + +## 2.2.11 + +### Patch Changes + +- Relayer updates +- Updated dependencies + - @0xsequence/abi@2.2.11 + - @0xsequence/account@2.2.11 + - @0xsequence/api@2.2.11 + - @0xsequence/auth@2.2.11 + - @0xsequence/core@2.2.11 + - @0xsequence/guard@2.2.11 + - @0xsequence/indexer@2.2.11 + - @0xsequence/metadata@2.2.11 + - @0xsequence/migration@2.2.11 + - @0xsequence/network@2.2.11 + - @0xsequence/provider@2.2.11 + - @0xsequence/relayer@2.2.11 + - @0xsequence/sessions@2.2.11 + - @0xsequence/signhub@2.2.11 + - @0xsequence/utils@2.2.11 + - @0xsequence/wallet@2.2.11 + +## 2.2.10 + +### Patch Changes + +- Etherlink support +- Updated dependencies + - @0xsequence/abi@2.2.10 + - @0xsequence/account@2.2.10 + - @0xsequence/api@2.2.10 + - @0xsequence/auth@2.2.10 + - @0xsequence/core@2.2.10 + - @0xsequence/guard@2.2.10 + - @0xsequence/indexer@2.2.10 + - @0xsequence/metadata@2.2.10 + - @0xsequence/migration@2.2.10 + - @0xsequence/network@2.2.10 + - @0xsequence/provider@2.2.10 + - @0xsequence/relayer@2.2.10 + - @0xsequence/sessions@2.2.10 + - @0xsequence/signhub@2.2.10 + - @0xsequence/utils@2.2.10 + - @0xsequence/wallet@2.2.10 + +## 2.2.9 + +### Patch Changes + +- Indexer gateway native token balances +- Updated dependencies + - @0xsequence/abi@2.2.9 + - @0xsequence/account@2.2.9 + - @0xsequence/api@2.2.9 + - @0xsequence/auth@2.2.9 + - @0xsequence/core@2.2.9 + - @0xsequence/guard@2.2.9 + - @0xsequence/indexer@2.2.9 + - @0xsequence/metadata@2.2.9 + - @0xsequence/migration@2.2.9 + - @0xsequence/network@2.2.9 + - @0xsequence/provider@2.2.9 + - @0xsequence/relayer@2.2.9 + - @0xsequence/sessions@2.2.9 + - @0xsequence/signhub@2.2.9 + - @0xsequence/utils@2.2.9 + - @0xsequence/wallet@2.2.9 + +## 2.2.8 + +### Patch Changes + +- Add Moonbeam and Moonbase Alpha +- Updated dependencies + - @0xsequence/abi@2.2.8 + - @0xsequence/account@2.2.8 + - @0xsequence/api@2.2.8 + - @0xsequence/auth@2.2.8 + - @0xsequence/core@2.2.8 + - @0xsequence/guard@2.2.8 + - @0xsequence/indexer@2.2.8 + - @0xsequence/metadata@2.2.8 + - @0xsequence/migration@2.2.8 + - @0xsequence/network@2.2.8 + - @0xsequence/provider@2.2.8 + - @0xsequence/relayer@2.2.8 + - @0xsequence/sessions@2.2.8 + - @0xsequence/signhub@2.2.8 + - @0xsequence/utils@2.2.8 + - @0xsequence/wallet@2.2.8 + +## 2.2.7 + +### Patch Changes + +- Update Builder package +- Updated dependencies + - @0xsequence/abi@2.2.7 + - @0xsequence/account@2.2.7 + - @0xsequence/api@2.2.7 + - @0xsequence/auth@2.2.7 + - @0xsequence/core@2.2.7 + - @0xsequence/guard@2.2.7 + - @0xsequence/indexer@2.2.7 + - @0xsequence/metadata@2.2.7 + - @0xsequence/migration@2.2.7 + - @0xsequence/network@2.2.7 + - @0xsequence/provider@2.2.7 + - @0xsequence/relayer@2.2.7 + - @0xsequence/sessions@2.2.7 + - @0xsequence/signhub@2.2.7 + - @0xsequence/utils@2.2.7 + - @0xsequence/wallet@2.2.7 + +## 2.2.6 + +### Patch Changes + +- Update relayer package +- Updated dependencies + - @0xsequence/abi@2.2.6 + - @0xsequence/account@2.2.6 + - @0xsequence/api@2.2.6 + - @0xsequence/auth@2.2.6 + - @0xsequence/core@2.2.6 + - @0xsequence/guard@2.2.6 + - @0xsequence/indexer@2.2.6 + - @0xsequence/metadata@2.2.6 + - @0xsequence/migration@2.2.6 + - @0xsequence/network@2.2.6 + - @0xsequence/provider@2.2.6 + - @0xsequence/relayer@2.2.6 + - @0xsequence/sessions@2.2.6 + - @0xsequence/signhub@2.2.6 + - @0xsequence/utils@2.2.6 + - @0xsequence/wallet@2.2.6 + +## 2.2.5 + +### Patch Changes + +- auth: fix sequence indexer gateway url +- account: immutable wallet proxy hook +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.2.5 + - @0xsequence/account@2.2.5 + - @0xsequence/api@2.2.5 + - @0xsequence/auth@2.2.5 + - @0xsequence/core@2.2.5 + - @0xsequence/guard@2.2.5 + - @0xsequence/indexer@2.2.5 + - @0xsequence/metadata@2.2.5 + - @0xsequence/migration@2.2.5 + - @0xsequence/network@2.2.5 + - @0xsequence/provider@2.2.5 + - @0xsequence/relayer@2.2.5 + - @0xsequence/sessions@2.2.5 + - @0xsequence/signhub@2.2.5 + - @0xsequence/utils@2.2.5 + - @0xsequence/wallet@2.2.5 + +## 2.2.4 + +### Patch Changes + +- network: update soneium mainnet block explorer url +- waas: signTypedData intent support +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.2.4 + - @0xsequence/account@2.2.4 + - @0xsequence/api@2.2.4 + - @0xsequence/auth@2.2.4 + - @0xsequence/core@2.2.4 + - @0xsequence/guard@2.2.4 + - @0xsequence/indexer@2.2.4 + - @0xsequence/metadata@2.2.4 + - @0xsequence/migration@2.2.4 + - @0xsequence/network@2.2.4 + - @0xsequence/provider@2.2.4 + - @0xsequence/relayer@2.2.4 + - @0xsequence/sessions@2.2.4 + - @0xsequence/signhub@2.2.4 + - @0xsequence/utils@2.2.4 + - @0xsequence/wallet@2.2.4 + +## 2.2.3 + +### Patch Changes + +- provider: updating initWallet to use connected network configs if they exist +- Updated dependencies + - @0xsequence/abi@2.2.3 + - @0xsequence/account@2.2.3 + - @0xsequence/api@2.2.3 + - @0xsequence/auth@2.2.3 + - @0xsequence/core@2.2.3 + - @0xsequence/guard@2.2.3 + - @0xsequence/indexer@2.2.3 + - @0xsequence/metadata@2.2.3 + - @0xsequence/migration@2.2.3 + - @0xsequence/network@2.2.3 + - @0xsequence/provider@2.2.3 + - @0xsequence/relayer@2.2.3 + - @0xsequence/sessions@2.2.3 + - @0xsequence/signhub@2.2.3 + - @0xsequence/utils@2.2.3 + - @0xsequence/wallet@2.2.3 + +## 2.2.2 + +### Patch Changes + +- pass projectAccessKey to relayer at all times +- Updated dependencies + - @0xsequence/abi@2.2.2 + - @0xsequence/account@2.2.2 + - @0xsequence/api@2.2.2 + - @0xsequence/auth@2.2.2 + - @0xsequence/core@2.2.2 + - @0xsequence/guard@2.2.2 + - @0xsequence/indexer@2.2.2 + - @0xsequence/metadata@2.2.2 + - @0xsequence/migration@2.2.2 + - @0xsequence/network@2.2.2 + - @0xsequence/provider@2.2.2 + - @0xsequence/relayer@2.2.2 + - @0xsequence/sessions@2.2.2 + - @0xsequence/signhub@2.2.2 + - @0xsequence/utils@2.2.2 + - @0xsequence/wallet@2.2.2 + +## 2.2.1 + +### Patch Changes + +- waas-ethers: sign typed data +- Updated dependencies + - @0xsequence/abi@2.2.1 + - @0xsequence/account@2.2.1 + - @0xsequence/api@2.2.1 + - @0xsequence/auth@2.2.1 + - @0xsequence/core@2.2.1 + - @0xsequence/guard@2.2.1 + - @0xsequence/indexer@2.2.1 + - @0xsequence/metadata@2.2.1 + - @0xsequence/migration@2.2.1 + - @0xsequence/network@2.2.1 + - @0xsequence/provider@2.2.1 + - @0xsequence/relayer@2.2.1 + - @0xsequence/sessions@2.2.1 + - @0xsequence/signhub@2.2.1 + - @0xsequence/utils@2.2.1 + - @0xsequence/wallet@2.2.1 + +## 2.2.0 + +### Minor Changes + +- indexer: gateway client +- @0xsequence/builder +- upgrade puppeteer to v23.10.3 + +### Patch Changes + +- Updated dependencies +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.2.0 + - @0xsequence/account@2.2.0 + - @0xsequence/api@2.2.0 + - @0xsequence/auth@2.2.0 + - @0xsequence/core@2.2.0 + - @0xsequence/guard@2.2.0 + - @0xsequence/indexer@2.2.0 + - @0xsequence/metadata@2.2.0 + - @0xsequence/migration@2.2.0 + - @0xsequence/network@2.2.0 + - @0xsequence/provider@2.2.0 + - @0xsequence/relayer@2.2.0 + - @0xsequence/sessions@2.2.0 + - @0xsequence/signhub@2.2.0 + - @0xsequence/utils@2.2.0 + - @0xsequence/wallet@2.2.0 + +## 2.1.8 + +### Patch Changes + +- Add Soneium Mainnet +- Updated dependencies + - @0xsequence/abi@2.1.8 + - @0xsequence/account@2.1.8 + - @0xsequence/api@2.1.8 + - @0xsequence/auth@2.1.8 + - @0xsequence/core@2.1.8 + - @0xsequence/guard@2.1.8 + - @0xsequence/indexer@2.1.8 + - @0xsequence/metadata@2.1.8 + - @0xsequence/migration@2.1.8 + - @0xsequence/network@2.1.8 + - @0xsequence/provider@2.1.8 + - @0xsequence/relayer@2.1.8 + - @0xsequence/sessions@2.1.8 + - @0xsequence/signhub@2.1.8 + - @0xsequence/utils@2.1.8 + - @0xsequence/wallet@2.1.8 + +## 2.1.7 + +### Patch Changes + +- guard: pass project access key to guard requests +- Updated dependencies + - @0xsequence/abi@2.1.7 + - @0xsequence/account@2.1.7 + - @0xsequence/api@2.1.7 + - @0xsequence/auth@2.1.7 + - @0xsequence/core@2.1.7 + - @0xsequence/guard@2.1.7 + - @0xsequence/indexer@2.1.7 + - @0xsequence/metadata@2.1.7 + - @0xsequence/migration@2.1.7 + - @0xsequence/network@2.1.7 + - @0xsequence/provider@2.1.7 + - @0xsequence/relayer@2.1.7 + - @0xsequence/sessions@2.1.7 + - @0xsequence/signhub@2.1.7 + - @0xsequence/utils@2.1.7 + - @0xsequence/wallet@2.1.7 + +## 2.1.6 + +### Patch Changes + +- Add LAOS and Telos Testnet chains +- Updated dependencies + - @0xsequence/abi@2.1.6 + - @0xsequence/account@2.1.6 + - @0xsequence/api@2.1.6 + - @0xsequence/auth@2.1.6 + - @0xsequence/core@2.1.6 + - @0xsequence/guard@2.1.6 + - @0xsequence/indexer@2.1.6 + - @0xsequence/metadata@2.1.6 + - @0xsequence/migration@2.1.6 + - @0xsequence/network@2.1.6 + - @0xsequence/provider@2.1.6 + - @0xsequence/relayer@2.1.6 + - @0xsequence/sessions@2.1.6 + - @0xsequence/signhub@2.1.6 + - @0xsequence/utils@2.1.6 + - @0xsequence/wallet@2.1.6 + +## 2.1.5 + +### Patch Changes + +- account: save presigned configuration with reference chain id 1 +- Updated dependencies + - @0xsequence/abi@2.1.5 + - @0xsequence/account@2.1.5 + - @0xsequence/api@2.1.5 + - @0xsequence/auth@2.1.5 + - @0xsequence/core@2.1.5 + - @0xsequence/guard@2.1.5 + - @0xsequence/indexer@2.1.5 + - @0xsequence/metadata@2.1.5 + - @0xsequence/migration@2.1.5 + - @0xsequence/network@2.1.5 + - @0xsequence/provider@2.1.5 + - @0xsequence/relayer@2.1.5 + - @0xsequence/sessions@2.1.5 + - @0xsequence/signhub@2.1.5 + - @0xsequence/utils@2.1.5 + - @0xsequence/wallet@2.1.5 + +## 2.1.4 + +### Patch Changes + +- provider: pass projectAccessKey into MuxMessageProvider +- Updated dependencies + - @0xsequence/abi@2.1.4 + - @0xsequence/account@2.1.4 + - @0xsequence/api@2.1.4 + - @0xsequence/auth@2.1.4 + - @0xsequence/core@2.1.4 + - @0xsequence/guard@2.1.4 + - @0xsequence/indexer@2.1.4 + - @0xsequence/metadata@2.1.4 + - @0xsequence/migration@2.1.4 + - @0xsequence/network@2.1.4 + - @0xsequence/provider@2.1.4 + - @0xsequence/relayer@2.1.4 + - @0xsequence/sessions@2.1.4 + - @0xsequence/signhub@2.1.4 + - @0xsequence/utils@2.1.4 + - @0xsequence/wallet@2.1.4 + +## 2.1.3 + +### Patch Changes + +- waas: time drift date fix due to strange browser quirk +- Updated dependencies + - @0xsequence/abi@2.1.3 + - @0xsequence/account@2.1.3 + - @0xsequence/api@2.1.3 + - @0xsequence/auth@2.1.3 + - @0xsequence/core@2.1.3 + - @0xsequence/guard@2.1.3 + - @0xsequence/indexer@2.1.3 + - @0xsequence/metadata@2.1.3 + - @0xsequence/migration@2.1.3 + - @0xsequence/network@2.1.3 + - @0xsequence/provider@2.1.3 + - @0xsequence/relayer@2.1.3 + - @0xsequence/sessions@2.1.3 + - @0xsequence/signhub@2.1.3 + - @0xsequence/utils@2.1.3 + - @0xsequence/wallet@2.1.3 + +## 2.1.2 + +### Patch Changes + +- provider: export analytics correctly +- Updated dependencies + - @0xsequence/abi@2.1.2 + - @0xsequence/account@2.1.2 + - @0xsequence/api@2.1.2 + - @0xsequence/auth@2.1.2 + - @0xsequence/core@2.1.2 + - @0xsequence/guard@2.1.2 + - @0xsequence/indexer@2.1.2 + - @0xsequence/metadata@2.1.2 + - @0xsequence/migration@2.1.2 + - @0xsequence/network@2.1.2 + - @0xsequence/provider@2.1.2 + - @0xsequence/relayer@2.1.2 + - @0xsequence/sessions@2.1.2 + - @0xsequence/signhub@2.1.2 + - @0xsequence/utils@2.1.2 + - @0xsequence/wallet@2.1.2 + +## 2.1.1 + +### Patch Changes + +- Add LAOS chain support +- Updated dependencies + - @0xsequence/abi@2.1.1 + - @0xsequence/account@2.1.1 + - @0xsequence/api@2.1.1 + - @0xsequence/auth@2.1.1 + - @0xsequence/core@2.1.1 + - @0xsequence/guard@2.1.1 + - @0xsequence/indexer@2.1.1 + - @0xsequence/metadata@2.1.1 + - @0xsequence/migration@2.1.1 + - @0xsequence/network@2.1.1 + - @0xsequence/provider@2.1.1 + - @0xsequence/relayer@2.1.1 + - @0xsequence/sessions@2.1.1 + - @0xsequence/signhub@2.1.1 + - @0xsequence/utils@2.1.1 + - @0xsequence/wallet@2.1.1 + +## 2.1.0 + +### Minor Changes + +- account: forward project access key when estimating fees and sending transactions + +### Patch Changes + +- sessions: save signatures with reference chain id +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.1.0 + - @0xsequence/account@2.1.0 + - @0xsequence/api@2.1.0 + - @0xsequence/auth@2.1.0 + - @0xsequence/core@2.1.0 + - @0xsequence/guard@2.1.0 + - @0xsequence/indexer@2.1.0 + - @0xsequence/metadata@2.1.0 + - @0xsequence/migration@2.1.0 + - @0xsequence/network@2.1.0 + - @0xsequence/provider@2.1.0 + - @0xsequence/relayer@2.1.0 + - @0xsequence/sessions@2.1.0 + - @0xsequence/signhub@2.1.0 + - @0xsequence/utils@2.1.0 + - @0xsequence/wallet@2.1.0 + +## 2.0.26 + +### Patch Changes + +- account: fix chain id comparison +- Updated dependencies + - @0xsequence/abi@2.0.26 + - @0xsequence/account@2.0.26 + - @0xsequence/api@2.0.26 + - @0xsequence/auth@2.0.26 + - @0xsequence/core@2.0.26 + - @0xsequence/guard@2.0.26 + - @0xsequence/indexer@2.0.26 + - @0xsequence/metadata@2.0.26 + - @0xsequence/migration@2.0.26 + - @0xsequence/network@2.0.26 + - @0xsequence/provider@2.0.26 + - @0xsequence/relayer@2.0.26 + - @0xsequence/sessions@2.0.26 + - @0xsequence/signhub@2.0.26 + - @0xsequence/utils@2.0.26 + - @0xsequence/wallet@2.0.26 + +## 2.0.25 + +### Patch Changes + +- skale-nebula: deploy gas limit = 10m +- Updated dependencies + - @0xsequence/abi@2.0.25 + - @0xsequence/account@2.0.25 + - @0xsequence/api@2.0.25 + - @0xsequence/auth@2.0.25 + - @0xsequence/core@2.0.25 + - @0xsequence/guard@2.0.25 + - @0xsequence/indexer@2.0.25 + - @0xsequence/metadata@2.0.25 + - @0xsequence/migration@2.0.25 + - @0xsequence/network@2.0.25 + - @0xsequence/provider@2.0.25 + - @0xsequence/relayer@2.0.25 + - @0xsequence/sessions@2.0.25 + - @0xsequence/signhub@2.0.25 + - @0xsequence/utils@2.0.25 + - @0xsequence/wallet@2.0.25 + +## 2.0.24 + +### Patch Changes + +- sessions: arweave: configurable gateway url +- waas: use /status to get time drift before sending any intents +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.24 + - @0xsequence/account@2.0.24 + - @0xsequence/api@2.0.24 + - @0xsequence/auth@2.0.24 + - @0xsequence/core@2.0.24 + - @0xsequence/guard@2.0.24 + - @0xsequence/indexer@2.0.24 + - @0xsequence/metadata@2.0.24 + - @0xsequence/migration@2.0.24 + - @0xsequence/network@2.0.24 + - @0xsequence/provider@2.0.24 + - @0xsequence/relayer@2.0.24 + - @0xsequence/sessions@2.0.24 + - @0xsequence/signhub@2.0.24 + - @0xsequence/utils@2.0.24 + - @0xsequence/wallet@2.0.24 + +## 2.0.23 + +### Patch Changes + +- Add The Root Network support +- Updated dependencies + - @0xsequence/abi@2.0.23 + - @0xsequence/account@2.0.23 + - @0xsequence/api@2.0.23 + - @0xsequence/auth@2.0.23 + - @0xsequence/core@2.0.23 + - @0xsequence/guard@2.0.23 + - @0xsequence/indexer@2.0.23 + - @0xsequence/metadata@2.0.23 + - @0xsequence/migration@2.0.23 + - @0xsequence/network@2.0.23 + - @0xsequence/provider@2.0.23 + - @0xsequence/relayer@2.0.23 + - @0xsequence/sessions@2.0.23 + - @0xsequence/signhub@2.0.23 + - @0xsequence/utils@2.0.23 + - @0xsequence/wallet@2.0.23 + +## 2.0.22 + +### Patch Changes + +- Add SKALE Nebula Mainnet support +- Updated dependencies + - @0xsequence/abi@2.0.22 + - @0xsequence/account@2.0.22 + - @0xsequence/api@2.0.22 + - @0xsequence/auth@2.0.22 + - @0xsequence/core@2.0.22 + - @0xsequence/guard@2.0.22 + - @0xsequence/indexer@2.0.22 + - @0xsequence/metadata@2.0.22 + - @0xsequence/migration@2.0.22 + - @0xsequence/network@2.0.22 + - @0xsequence/provider@2.0.22 + - @0xsequence/relayer@2.0.22 + - @0xsequence/sessions@2.0.22 + - @0xsequence/signhub@2.0.22 + - @0xsequence/utils@2.0.22 + - @0xsequence/wallet@2.0.22 + +## 2.0.21 + +### Patch Changes + +- account: add publishWitnessFor +- Updated dependencies + - @0xsequence/abi@2.0.21 + - @0xsequence/account@2.0.21 + - @0xsequence/api@2.0.21 + - @0xsequence/auth@2.0.21 + - @0xsequence/core@2.0.21 + - @0xsequence/guard@2.0.21 + - @0xsequence/indexer@2.0.21 + - @0xsequence/metadata@2.0.21 + - @0xsequence/migration@2.0.21 + - @0xsequence/network@2.0.21 + - @0xsequence/provider@2.0.21 + - @0xsequence/relayer@2.0.21 + - @0xsequence/sessions@2.0.21 + - @0xsequence/signhub@2.0.21 + - @0xsequence/utils@2.0.21 + - @0xsequence/wallet@2.0.21 + +## 2.0.20 + +### Patch Changes + +- upgrade deps, and improve waas session status handling +- Updated dependencies + - @0xsequence/abi@2.0.20 + - @0xsequence/account@2.0.20 + - @0xsequence/api@2.0.20 + - @0xsequence/auth@2.0.20 + - @0xsequence/core@2.0.20 + - @0xsequence/guard@2.0.20 + - @0xsequence/indexer@2.0.20 + - @0xsequence/metadata@2.0.20 + - @0xsequence/migration@2.0.20 + - @0xsequence/network@2.0.20 + - @0xsequence/provider@2.0.20 + - @0xsequence/relayer@2.0.20 + - @0xsequence/sessions@2.0.20 + - @0xsequence/signhub@2.0.20 + - @0xsequence/utils@2.0.20 + - @0xsequence/wallet@2.0.20 + +## 2.0.19 + +### Patch Changes + +- Add Immutable zkEVM support +- Updated dependencies + - @0xsequence/abi@2.0.19 + - @0xsequence/account@2.0.19 + - @0xsequence/api@2.0.19 + - @0xsequence/auth@2.0.19 + - @0xsequence/core@2.0.19 + - @0xsequence/guard@2.0.19 + - @0xsequence/indexer@2.0.19 + - @0xsequence/metadata@2.0.19 + - @0xsequence/migration@2.0.19 + - @0xsequence/network@2.0.19 + - @0xsequence/provider@2.0.19 + - @0xsequence/relayer@2.0.19 + - @0xsequence/sessions@2.0.19 + - @0xsequence/signhub@2.0.19 + - @0xsequence/utils@2.0.19 + - @0xsequence/wallet@2.0.19 + +## 2.0.18 + +### Patch Changes + +- waas: new contractCall transaction type +- sessions: add arweave owner +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.18 + - @0xsequence/account@2.0.18 + - @0xsequence/api@2.0.18 + - @0xsequence/auth@2.0.18 + - @0xsequence/core@2.0.18 + - @0xsequence/guard@2.0.18 + - @0xsequence/indexer@2.0.18 + - @0xsequence/metadata@2.0.18 + - @0xsequence/migration@2.0.18 + - @0xsequence/network@2.0.18 + - @0xsequence/provider@2.0.18 + - @0xsequence/relayer@2.0.18 + - @0xsequence/sessions@2.0.18 + - @0xsequence/signhub@2.0.18 + - @0xsequence/utils@2.0.18 + - @0xsequence/wallet@2.0.18 + +## 2.0.17 + +### Patch Changes + +- update waas auth to clear session before signIn +- Updated dependencies + - @0xsequence/abi@2.0.17 + - @0xsequence/account@2.0.17 + - @0xsequence/api@2.0.17 + - @0xsequence/auth@2.0.17 + - @0xsequence/core@2.0.17 + - @0xsequence/guard@2.0.17 + - @0xsequence/indexer@2.0.17 + - @0xsequence/metadata@2.0.17 + - @0xsequence/migration@2.0.17 + - @0xsequence/network@2.0.17 + - @0xsequence/provider@2.0.17 + - @0xsequence/relayer@2.0.17 + - @0xsequence/sessions@2.0.17 + - @0xsequence/signhub@2.0.17 + - @0xsequence/utils@2.0.17 + - @0xsequence/wallet@2.0.17 + +## 2.0.16 + +### Patch Changes + +- Removed Astar chains +- Updated dependencies + - @0xsequence/abi@2.0.16 + - @0xsequence/account@2.0.16 + - @0xsequence/api@2.0.16 + - @0xsequence/auth@2.0.16 + - @0xsequence/core@2.0.16 + - @0xsequence/guard@2.0.16 + - @0xsequence/indexer@2.0.16 + - @0xsequence/metadata@2.0.16 + - @0xsequence/migration@2.0.16 + - @0xsequence/network@2.0.16 + - @0xsequence/provider@2.0.16 + - @0xsequence/relayer@2.0.16 + - @0xsequence/sessions@2.0.16 + - @0xsequence/signhub@2.0.16 + - @0xsequence/utils@2.0.16 + - @0xsequence/wallet@2.0.16 + +## 2.0.15 + +### Patch Changes + +- indexer: update bindings with token balance additions +- Updated dependencies + - @0xsequence/abi@2.0.15 + - @0xsequence/account@2.0.15 + - @0xsequence/api@2.0.15 + - @0xsequence/auth@2.0.15 + - @0xsequence/core@2.0.15 + - @0xsequence/guard@2.0.15 + - @0xsequence/indexer@2.0.15 + - @0xsequence/metadata@2.0.15 + - @0xsequence/migration@2.0.15 + - @0xsequence/network@2.0.15 + - @0xsequence/provider@2.0.15 + - @0xsequence/relayer@2.0.15 + - @0xsequence/sessions@2.0.15 + - @0xsequence/signhub@2.0.15 + - @0xsequence/utils@2.0.15 + - @0xsequence/wallet@2.0.15 + +## 2.0.14 + +### Patch Changes + +- sessions: arweave config reader +- network: add b3 and apechain mainnet configs +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.14 + - @0xsequence/account@2.0.14 + - @0xsequence/api@2.0.14 + - @0xsequence/auth@2.0.14 + - @0xsequence/core@2.0.14 + - @0xsequence/guard@2.0.14 + - @0xsequence/indexer@2.0.14 + - @0xsequence/metadata@2.0.14 + - @0xsequence/migration@2.0.14 + - @0xsequence/network@2.0.14 + - @0xsequence/provider@2.0.14 + - @0xsequence/relayer@2.0.14 + - @0xsequence/sessions@2.0.14 + - @0xsequence/signhub@2.0.14 + - @0xsequence/utils@2.0.14 + - @0xsequence/wallet@2.0.14 + +## 2.0.13 + +### Patch Changes + +- network: toy-testnet +- Updated dependencies + - @0xsequence/abi@2.0.13 + - @0xsequence/account@2.0.13 + - @0xsequence/api@2.0.13 + - @0xsequence/auth@2.0.13 + - @0xsequence/core@2.0.13 + - @0xsequence/guard@2.0.13 + - @0xsequence/indexer@2.0.13 + - @0xsequence/metadata@2.0.13 + - @0xsequence/migration@2.0.13 + - @0xsequence/network@2.0.13 + - @0xsequence/provider@2.0.13 + - @0xsequence/relayer@2.0.13 + - @0xsequence/sessions@2.0.13 + - @0xsequence/signhub@2.0.13 + - @0xsequence/utils@2.0.13 + - @0xsequence/wallet@2.0.13 + +## 2.0.12 + +### Patch Changes + +- api: update bindings +- Updated dependencies + - @0xsequence/abi@2.0.12 + - @0xsequence/account@2.0.12 + - @0xsequence/api@2.0.12 + - @0xsequence/auth@2.0.12 + - @0xsequence/core@2.0.12 + - @0xsequence/guard@2.0.12 + - @0xsequence/indexer@2.0.12 + - @0xsequence/metadata@2.0.12 + - @0xsequence/migration@2.0.12 + - @0xsequence/network@2.0.12 + - @0xsequence/provider@2.0.12 + - @0xsequence/relayer@2.0.12 + - @0xsequence/sessions@2.0.12 + - @0xsequence/signhub@2.0.12 + - @0xsequence/utils@2.0.12 + - @0xsequence/wallet@2.0.12 + +## 2.0.11 + +### Patch Changes + +- waas: intents test fix +- api: update bindings +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.11 + - @0xsequence/account@2.0.11 + - @0xsequence/api@2.0.11 + - @0xsequence/auth@2.0.11 + - @0xsequence/core@2.0.11 + - @0xsequence/guard@2.0.11 + - @0xsequence/indexer@2.0.11 + - @0xsequence/metadata@2.0.11 + - @0xsequence/migration@2.0.11 + - @0xsequence/network@2.0.11 + - @0xsequence/provider@2.0.11 + - @0xsequence/relayer@2.0.11 + - @0xsequence/sessions@2.0.11 + - @0xsequence/signhub@2.0.11 + - @0xsequence/utils@2.0.11 + - @0xsequence/wallet@2.0.11 + +## 2.0.10 + +### Patch Changes + +- network: soneium minato testnet +- Updated dependencies + - @0xsequence/abi@2.0.10 + - @0xsequence/account@2.0.10 + - @0xsequence/api@2.0.10 + - @0xsequence/auth@2.0.10 + - @0xsequence/core@2.0.10 + - @0xsequence/guard@2.0.10 + - @0xsequence/indexer@2.0.10 + - @0xsequence/metadata@2.0.10 + - @0xsequence/migration@2.0.10 + - @0xsequence/network@2.0.10 + - @0xsequence/provider@2.0.10 + - @0xsequence/relayer@2.0.10 + - @0xsequence/sessions@2.0.10 + - @0xsequence/signhub@2.0.10 + - @0xsequence/utils@2.0.10 + - @0xsequence/wallet@2.0.10 + +## 2.0.9 + +### Patch Changes + +- network: fix SKALE network name +- Updated dependencies + - @0xsequence/abi@2.0.9 + - @0xsequence/account@2.0.9 + - @0xsequence/api@2.0.9 + - @0xsequence/auth@2.0.9 + - @0xsequence/core@2.0.9 + - @0xsequence/guard@2.0.9 + - @0xsequence/indexer@2.0.9 + - @0xsequence/metadata@2.0.9 + - @0xsequence/migration@2.0.9 + - @0xsequence/network@2.0.9 + - @0xsequence/provider@2.0.9 + - @0xsequence/relayer@2.0.9 + - @0xsequence/sessions@2.0.9 + - @0xsequence/signhub@2.0.9 + - @0xsequence/utils@2.0.9 + - @0xsequence/wallet@2.0.9 + +## 2.0.8 + +### Patch Changes + +- metadata: update bindings +- Updated dependencies + - @0xsequence/abi@2.0.8 + - @0xsequence/account@2.0.8 + - @0xsequence/api@2.0.8 + - @0xsequence/auth@2.0.8 + - @0xsequence/core@2.0.8 + - @0xsequence/guard@2.0.8 + - @0xsequence/indexer@2.0.8 + - @0xsequence/metadata@2.0.8 + - @0xsequence/migration@2.0.8 + - @0xsequence/network@2.0.8 + - @0xsequence/provider@2.0.8 + - @0xsequence/relayer@2.0.8 + - @0xsequence/sessions@2.0.8 + - @0xsequence/signhub@2.0.8 + - @0xsequence/utils@2.0.8 + - @0xsequence/wallet@2.0.8 + +## 2.0.7 + +### Patch Changes + +- wallet request handler fix +- Updated dependencies + - @0xsequence/abi@2.0.7 + - @0xsequence/account@2.0.7 + - @0xsequence/api@2.0.7 + - @0xsequence/auth@2.0.7 + - @0xsequence/core@2.0.7 + - @0xsequence/guard@2.0.7 + - @0xsequence/indexer@2.0.7 + - @0xsequence/metadata@2.0.7 + - @0xsequence/migration@2.0.7 + - @0xsequence/network@2.0.7 + - @0xsequence/provider@2.0.7 + - @0xsequence/relayer@2.0.7 + - @0xsequence/sessions@2.0.7 + - @0xsequence/signhub@2.0.7 + - @0xsequence/utils@2.0.7 + - @0xsequence/wallet@2.0.7 + +## 2.0.6 + +### Patch Changes + +- network: matic -> pol +- Updated dependencies + - @0xsequence/abi@2.0.6 + - @0xsequence/account@2.0.6 + - @0xsequence/api@2.0.6 + - @0xsequence/auth@2.0.6 + - @0xsequence/core@2.0.6 + - @0xsequence/guard@2.0.6 + - @0xsequence/indexer@2.0.6 + - @0xsequence/metadata@2.0.6 + - @0xsequence/migration@2.0.6 + - @0xsequence/network@2.0.6 + - @0xsequence/provider@2.0.6 + - @0xsequence/relayer@2.0.6 + - @0xsequence/sessions@2.0.6 + - @0xsequence/signhub@2.0.6 + - @0xsequence/utils@2.0.6 + - @0xsequence/wallet@2.0.6 + +## 2.0.5 + +### Patch Changes + +- provider: update databeat to 0.9.2 +- Updated dependencies + - @0xsequence/abi@2.0.5 + - @0xsequence/account@2.0.5 + - @0xsequence/api@2.0.5 + - @0xsequence/auth@2.0.5 + - @0xsequence/core@2.0.5 + - @0xsequence/guard@2.0.5 + - @0xsequence/indexer@2.0.5 + - @0xsequence/metadata@2.0.5 + - @0xsequence/migration@2.0.5 + - @0xsequence/network@2.0.5 + - @0xsequence/provider@2.0.5 + - @0xsequence/relayer@2.0.5 + - @0xsequence/sessions@2.0.5 + - @0xsequence/signhub@2.0.5 + - @0xsequence/utils@2.0.5 + - @0xsequence/wallet@2.0.5 + +## 2.0.4 + +### Patch Changes + +- network: add skale-nebula-testnet +- Updated dependencies + - @0xsequence/abi@2.0.4 + - @0xsequence/account@2.0.4 + - @0xsequence/api@2.0.4 + - @0xsequence/auth@2.0.4 + - @0xsequence/core@2.0.4 + - @0xsequence/guard@2.0.4 + - @0xsequence/indexer@2.0.4 + - @0xsequence/metadata@2.0.4 + - @0xsequence/migration@2.0.4 + - @0xsequence/network@2.0.4 + - @0xsequence/provider@2.0.4 + - @0xsequence/relayer@2.0.4 + - @0xsequence/sessions@2.0.4 + - @0xsequence/signhub@2.0.4 + - @0xsequence/utils@2.0.4 + - @0xsequence/wallet@2.0.4 + +## 2.0.3 + +### Patch Changes + +- waas: check session status in SequenceWaaS.isSignedIn() +- Updated dependencies + - @0xsequence/abi@2.0.3 + - @0xsequence/account@2.0.3 + - @0xsequence/api@2.0.3 + - @0xsequence/auth@2.0.3 + - @0xsequence/core@2.0.3 + - @0xsequence/guard@2.0.3 + - @0xsequence/indexer@2.0.3 + - @0xsequence/metadata@2.0.3 + - @0xsequence/migration@2.0.3 + - @0xsequence/network@2.0.3 + - @0xsequence/provider@2.0.3 + - @0xsequence/relayer@2.0.3 + - @0xsequence/sessions@2.0.3 + - @0xsequence/signhub@2.0.3 + - @0xsequence/utils@2.0.3 + - @0xsequence/wallet@2.0.3 + +## 2.0.2 + +### Patch Changes + +- sessions: property convert serialized bignumber hex value to bigint +- Updated dependencies + - @0xsequence/abi@2.0.2 + - @0xsequence/account@2.0.2 + - @0xsequence/api@2.0.2 + - @0xsequence/auth@2.0.2 + - @0xsequence/core@2.0.2 + - @0xsequence/guard@2.0.2 + - @0xsequence/indexer@2.0.2 + - @0xsequence/metadata@2.0.2 + - @0xsequence/migration@2.0.2 + - @0xsequence/network@2.0.2 + - @0xsequence/provider@2.0.2 + - @0xsequence/relayer@2.0.2 + - @0xsequence/sessions@2.0.2 + - @0xsequence/signhub@2.0.2 + - @0xsequence/utils@2.0.2 + - @0xsequence/wallet@2.0.2 + +## 2.0.1 + +### Patch Changes + +- waas: http signature check for authenticator requests +- provider: unwrap legacy json rpc responses +- use json replacer and reviver for bigints +- Updated dependencies +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.1 + - @0xsequence/account@2.0.1 + - @0xsequence/api@2.0.1 + - @0xsequence/auth@2.0.1 + - @0xsequence/core@2.0.1 + - @0xsequence/guard@2.0.1 + - @0xsequence/indexer@2.0.1 + - @0xsequence/metadata@2.0.1 + - @0xsequence/migration@2.0.1 + - @0xsequence/network@2.0.1 + - @0xsequence/provider@2.0.1 + - @0xsequence/relayer@2.0.1 + - @0xsequence/sessions@2.0.1 + - @0xsequence/signhub@2.0.1 + - @0xsequence/utils@2.0.1 + - @0xsequence/wallet@2.0.1 + +## 2.0.0 + +### Major Changes + +- ethers v6 + +### Patch Changes + +- Updated dependencies + - @0xsequence/abi@2.0.0 + - @0xsequence/account@2.0.0 + - @0xsequence/api@2.0.0 + - @0xsequence/auth@2.0.0 + - @0xsequence/core@2.0.0 + - @0xsequence/guard@2.0.0 + - @0xsequence/indexer@2.0.0 + - @0xsequence/metadata@2.0.0 + - @0xsequence/migration@2.0.0 + - @0xsequence/network@2.0.0 + - @0xsequence/provider@2.0.0 + - @0xsequence/relayer@2.0.0 + - @0xsequence/sessions@2.0.0 + - @0xsequence/signhub@2.0.0 + - @0xsequence/utils@2.0.0 + - @0xsequence/wallet@2.0.0 + +## 1.10.15 + +### Patch Changes + +- utils: extractProjectIdFromAccessKey +- Updated dependencies + - @0xsequence/abi@1.10.15 + - @0xsequence/account@1.10.15 + - @0xsequence/api@1.10.15 + - @0xsequence/auth@1.10.15 + - @0xsequence/core@1.10.15 + - @0xsequence/guard@1.10.15 + - @0xsequence/indexer@1.10.15 + - @0xsequence/metadata@1.10.15 + - @0xsequence/migration@1.10.15 + - @0xsequence/multicall@1.10.15 + - @0xsequence/network@1.10.15 + - @0xsequence/provider@1.10.15 + - @0xsequence/relayer@1.10.15 + - @0xsequence/sessions@1.10.15 + - @0xsequence/signhub@1.10.15 + - @0xsequence/utils@1.10.15 + - @0xsequence/wallet@1.10.15 + ## 1.10.14 ### Patch Changes diff --git a/packages/0xsequence/package.json b/packages/0xsequence/package.json index 5fc1524ce..aa41f48ad 100644 --- a/packages/0xsequence/package.json +++ b/packages/0xsequence/package.json @@ -1,6 +1,6 @@ { "name": "0xsequence", - "version": "1.10.14", + "version": "2.2.14", "description": "Sequence: a modular web3 stack and smart wallet for Ethereum chains", "repository": "https://github.com/0xsequence/sequence.js", "source": "src/index.ts", @@ -27,6 +27,9 @@ "stop:ganache": "ps aux | grep ganache | grep -v grep | awk '{print $2}' | xargs kill -9", "typecheck": "tsc --noEmit" }, + "peerDependencies": { + "ethers": ">=6" + }, "dependencies": { "@0xsequence/abi": "workspace:*", "@0xsequence/account": "workspace:*", @@ -37,7 +40,6 @@ "@0xsequence/indexer": "workspace:*", "@0xsequence/metadata": "workspace:*", "@0xsequence/migration": "workspace:*", - "@0xsequence/multicall": "workspace:*", "@0xsequence/network": "workspace:*", "@0xsequence/provider": "workspace:*", "@0xsequence/relayer": "workspace:*", @@ -46,17 +48,14 @@ "@0xsequence/utils": "workspace:*", "@0xsequence/wallet": "workspace:*" }, - "peerDependencies": { - "ethers": ">=5.5 < 6" - }, "devDependencies": { "@0xsequence/tests": "workspace:*", - "@0xsequence/wallet-contracts": "^2.0.0", + "@0xsequence/wallet-contracts": "^3.0.1", "@babel/plugin-transform-runtime": "^7.19.6", "babel-loader": "^9.1.0", - "ethers": "^5.7.2", + "ethers": "6.13.4", "ganache": "^7.5.0", - "hardhat": "^2.20.1", + "hardhat": "^2.22.14", "html-webpack-plugin": "^5.3.1", "webpack": "^5.65.0", "webpack-cli": "^4.6.0", diff --git a/packages/0xsequence/src/multicall.ts b/packages/0xsequence/src/multicall.ts deleted file mode 100644 index 76f619a9c..000000000 --- a/packages/0xsequence/src/multicall.ts +++ /dev/null @@ -1 +0,0 @@ -export * from '@0xsequence/multicall' diff --git a/packages/0xsequence/src/network.ts b/packages/0xsequence/src/network.ts index 137b376ef..1d9b96b92 100644 --- a/packages/0xsequence/src/network.ts +++ b/packages/0xsequence/src/network.ts @@ -4,9 +4,12 @@ export type { JsonRpcRequest, JsonRpcResponse, JsonRpcResponseCallback, - JsonRpcHandlerFunc, - JsonRpcFetchFunc, - JsonRpcRequestFunc, + JsonRpcHandler, + JsonRpcSender, + EIP1193Provider, + EIP1193ProviderFunc, + JsonRpcSendFunc, + JsonRpcSendAsyncFunc, JsonRpcMiddleware, JsonRpcMiddlewareHandler, NetworkConfig, diff --git a/packages/0xsequence/src/sequence.ts b/packages/0xsequence/src/sequence.ts index 6eda8e9d9..fac5905f2 100644 --- a/packages/0xsequence/src/sequence.ts +++ b/packages/0xsequence/src/sequence.ts @@ -4,7 +4,6 @@ export * as auth from './auth' export * as guard from './guard' export * as indexer from './indexer' export * as metadata from './metadata' -export * as multicall from './multicall' export * as network from './network' export * as provider from './provider' export * as relayer from './relayer' diff --git a/packages/0xsequence/src/utils.ts b/packages/0xsequence/src/utils.ts index b82801f35..40b856986 100644 --- a/packages/0xsequence/src/utils.ts +++ b/packages/0xsequence/src/utils.ts @@ -2,4 +2,4 @@ export * from '@0xsequence/utils' export { isValidSignature, isValidMessageSignature, isValidTypedDataSignature, isWalletUpToDate } from '@0xsequence/provider' -export type { Deferrable, TypedData, TypedDataDomain, TypedDataField, LogLevel, LoggerConfig } from '@0xsequence/utils' +export type { TypedData, TypedDataDomain, TypedDataField, LogLevel, LoggerConfig } from '@0xsequence/utils' diff --git a/packages/0xsequence/tests/browser/json-rpc-provider/rpc.test.ts b/packages/0xsequence/tests/browser/json-rpc-provider/rpc.test.ts index 1e234ee69..4e4f2e574 100644 --- a/packages/0xsequence/tests/browser/json-rpc-provider/rpc.test.ts +++ b/packages/0xsequence/tests/browser/json-rpc-provider/rpc.test.ts @@ -1,14 +1,12 @@ -import { ethers } from 'ethers' import { test, assert } from '../../utils/assert' import { configureLogger } from '@0xsequence/utils' -import { JsonRpcProvider, loggingProviderMiddleware } from '@0xsequence/network' +import { JsonRpcProvider } from '@0xsequence/network' configureLogger({ logLevel: 'DEBUG', silence: false }) export const tests = async () => { - // const provider = new ethers.providers.JsonRpcProvider('http://localhost:8545', 31337) - const provider = new JsonRpcProvider('http://localhost:8545', { chainId: 31337 }) + const provider = new JsonRpcProvider('http://localhost:8545', { chainId: 31337 }, { cacheTimeout: -1 }) await test('sending a json-rpc request', async () => { { @@ -17,23 +15,23 @@ export const tests = async () => { } { const chainId = await provider.send('eth_chainId', []) - assert.true(ethers.BigNumber.from(chainId).toString() === '31337') + assert.equal(BigInt(chainId), 31337n) } { const chainId = await provider.send('eth_chainId', []) - assert.true(ethers.BigNumber.from(chainId).toString() === '31337') + assert.equal(BigInt(chainId), 31337n) } { const chainId = await provider.send('eth_chainId', []) - assert.true(ethers.BigNumber.from(chainId).toString() === '31337') + assert.equal(BigInt(chainId), 31337n) } { const chainId = await provider.send('eth_chainId', []) - assert.true(ethers.BigNumber.from(chainId).toString() === '31337') + assert.equal(BigInt(chainId), 31337n) } { const netVersion = await provider.send('net_version', []) - assert.true(netVersion === '31337') + assert.equal(netVersion, '31337') } }) } diff --git a/packages/0xsequence/tests/browser/mock-wallet/mock-wallet.test.ts b/packages/0xsequence/tests/browser/mock-wallet/mock-wallet.test.ts index 6ee073cb7..38e761aeb 100644 --- a/packages/0xsequence/tests/browser/mock-wallet/mock-wallet.test.ts +++ b/packages/0xsequence/tests/browser/mock-wallet/mock-wallet.test.ts @@ -21,14 +21,14 @@ const main = async () => { // // Providers // - const provider = new ethers.providers.JsonRpcProvider('http://localhost:8545') - const provider2 = new ethers.providers.JsonRpcProvider('http://localhost:9545') + const provider = new ethers.JsonRpcProvider('http://localhost:8545', undefined, { cacheTimeout: -1 }) + const provider2 = new ethers.JsonRpcProvider('http://localhost:9545', undefined, { cacheTimeout: -1 }) // // Deploy Sequence WalletContext (deterministic) // - const deployedWalletContext = await utils.context.deploySequenceContexts(provider.getSigner()) - await utils.context.deploySequenceContexts(provider2.getSigner()) + const deployedWalletContext = await utils.context.deploySequenceContexts(await provider.getSigner()) + await utils.context.deploySequenceContexts(await provider2.getSigner()) // Generate a new wallet every time, otherwise tests will fail // due to EIP-6492 being used only sometimes (some tests deploy the wallet) @@ -42,7 +42,7 @@ const main = async () => { { name: 'hardhat', chainId: 31337, - rpcUrl: provider.connection.url, + rpcUrl: provider._getConnection().url, provider: provider, relayer: relayer, isDefaultChain: true, @@ -55,7 +55,7 @@ const main = async () => { { name: 'hardhat2', chainId: 31338, - rpcUrl: provider2.connection.url, + rpcUrl: provider2._getConnection().url, provider: provider2, relayer: relayer2, nativeToken: { diff --git a/packages/0xsequence/tests/browser/mux-transport/mux.test.ts b/packages/0xsequence/tests/browser/mux-transport/mux.test.ts index d69114376..dcacdcced 100644 --- a/packages/0xsequence/tests/browser/mux-transport/mux.test.ts +++ b/packages/0xsequence/tests/browser/mux-transport/mux.test.ts @@ -26,14 +26,14 @@ export const tests = async () => { // // Providers // - const provider1 = new ethers.providers.JsonRpcProvider('http://localhost:8545') - const provider2 = new ethers.providers.JsonRpcProvider('http://localhost:9545') + const provider1 = new ethers.JsonRpcProvider('http://localhost:8545', undefined, { cacheTimeout: -1 }) + const provider2 = new ethers.JsonRpcProvider('http://localhost:9545', undefined, { cacheTimeout: -1 }) // // Deploy Sequence WalletContext (deterministic). // - const deployedWalletContext = await utils.context.deploySequenceContexts(provider1.getSigner()) - await utils.context.deploySequenceContexts(provider2.getSigner()) + const deployedWalletContext = await utils.context.deploySequenceContexts(await provider1.getSigner()) + await utils.context.deploySequenceContexts(await provider2.getSigner()) console.log('walletContext:', deployedWalletContext) // @@ -55,18 +55,20 @@ export const tests = async () => { // Network available list const networks: NetworkConfig[] = [ + // @ts-ignore { name: 'hardhat', chainId: 31337, - rpcUrl: provider1.connection.url, + rpcUrl: provider1._getConnection().url, provider: provider1, relayer: relayer1, isDefaultChain: true }, + // @ts-ignore { name: 'hardhat2', chainId: 31338, - rpcUrl: provider2.connection.url, + rpcUrl: provider2._getConnection().url, provider: provider2, relayer: relayer2 } diff --git a/packages/0xsequence/tests/browser/proxy-transport/channel.test.ts b/packages/0xsequence/tests/browser/proxy-transport/channel.test.ts index ae8e56f77..2a9e2dd66 100644 --- a/packages/0xsequence/tests/browser/proxy-transport/channel.test.ts +++ b/packages/0xsequence/tests/browser/proxy-transport/channel.test.ts @@ -64,17 +64,22 @@ export const tests = async () => { // relayer account is same as owner here const relayer = new LocalRelayer(owner) - const rpcProvider = new ethers.providers.JsonRpcProvider('http://localhost:8545') - const contexts = await utils.context.deploySequenceContexts(rpcProvider.getSigner()) + const rpcProvider = new ethers.JsonRpcProvider('http://localhost:8545', undefined, { cacheTimeout: -1 }) + const contexts = await utils.context.deploySequenceContexts(await rpcProvider.getSigner()) const networks = [ { name: 'hardhat', chainId: 31337, - rpcUrl: rpcProvider.connection.url, + rpcUrl: rpcProvider._getConnection().url, provider: rpcProvider, relayer: relayer, - isDefaultChain: true + isDefaultChain: true, + nativeToken: { + symbol: 'ETH', + name: 'Ether', + decimals: 18 + } } ] @@ -122,30 +127,27 @@ export const tests = async () => { const address = client.getAddress() await test('verifying getAddress result', async () => { - assert.equal(address, ethers.utils.getAddress('0x91A858FbBa42E7EE200b4303b1A8B2F0BD139663'), 'wallet address') + assert.equal(address, ethers.getAddress('0x91A858FbBa42E7EE200b4303b1A8B2F0BD139663'), 'wallet address') }) await test('sending a json-rpc request', async () => { - await walletProvider.sendAsync({ jsonrpc: '2.0', id: 88, method: 'eth_accounts', params: [] }, (err, resp) => { - assert.true(!err, 'error is empty') - assert.true(!!resp, 'response successful') - assert.true(resp!.result == address, 'response address check') - }) + const result = await walletProvider.request({ method: 'eth_accounts', params: [] }) + assert.equal(result[0], address, 'response address check') }) await test('get chain id', async () => { const chainIdClient = client.getChainId() assert.equal(chainIdClient, 31337, 'chain id match') - const netVersion = await client.send({ method: 'net_version' }) + const netVersion = await client.request({ method: 'net_version' }) assert.equal(netVersion, '31337', 'net_version check') - const chainId = await client.send({ method: 'eth_chainId' }) + const chainId = await client.request({ method: 'eth_chainId' }) assert.equal(chainId, '0x7a69', 'eth_chainId check') }) await test('sign a message and validate/recover', async () => { - const message = ethers.utils.toUtf8Bytes('hihi') + const message = ethers.toUtf8Bytes('hihi') // // Sign the message diff --git a/packages/0xsequence/tests/browser/testutils/accounts.ts b/packages/0xsequence/tests/browser/testutils/accounts.ts index 1b8ad32e5..0b84bfe09 100644 --- a/packages/0xsequence/tests/browser/testutils/accounts.ts +++ b/packages/0xsequence/tests/browser/testutils/accounts.ts @@ -1,4 +1,4 @@ -import { ethers, Wallet as EOAWallet, providers } from 'ethers' +import { ethers } from 'ethers' // testAccounts with 10000 ETH each export const testAccounts = [ @@ -28,16 +28,16 @@ export const testAccounts = [ } ] -export const getEOAWallet = (privateKey: string, provider?: string | ethers.providers.Provider): EOAWallet => { +export const getEOAWallet = (privateKey: string, provider?: string | ethers.Provider): ethers.Wallet => { // defaults if (!provider) { provider = 'http://localhost:8545' } - const wallet = new EOAWallet(privateKey) + const wallet = new ethers.Wallet(privateKey) if (typeof provider === 'string') { - return wallet.connect(new providers.JsonRpcProvider(provider)) + return wallet.connect(new ethers.JsonRpcProvider(provider, undefined, { cacheTimeout: -1 })) } else { return wallet.connect(provider) } diff --git a/packages/0xsequence/tests/browser/testutils/deploy-wallet-context.ts b/packages/0xsequence/tests/browser/testutils/deploy-wallet-context.ts index 58bdeb1aa..fc3805e16 100644 --- a/packages/0xsequence/tests/browser/testutils/deploy-wallet-context.ts +++ b/packages/0xsequence/tests/browser/testutils/deploy-wallet-context.ts @@ -23,9 +23,9 @@ // // deployWalletContext will deploy the Sequence WalletContext via the UniversalDeployer // // which will return deterministic contract addresses between calls. -// export const deployWalletContext = async (...providers: ethers.providers.JsonRpcProvider[]): Promise => { +// export const deployWalletContext = async (...providers: ethers.JsonRpcProvider[]): Promise => { // if (!providers || providers.length === 0) { -// providers.push(new ethers.providers.JsonRpcProvider('http://localhost:8545')) +// providers.push(new ethers.JsonRpcProvider('http://localhost:8545')) // } // // Memoize the result. Even though its universal/deterministic, caching the result @@ -39,8 +39,8 @@ // const wallet = getEOAWallet(testAccounts[0].privateKey, provider) // // Universal deployer for deterministic contract addresses -// const universalDeployer = new UniversalDeployer('local', wallet.provider as ethers.providers.JsonRpcProvider) -// const txParams = { gasLimit: 8000000, gasPrice: ethers.BigNumber.from(10).pow(9).mul(10) } +// const universalDeployer = new UniversalDeployer('local', wallet.provider as ethers.JsonRpcProvider) +// const txParams = { gasLimit: 8000000, gasPrice: 10n.pow(9).mul(10) } // const walletFactory = await universalDeployer.deploy('WalletFactory', Factory__factory as any, txParams) // const mainModule = await universalDeployer.deploy('MainModule', MainModule__factory as any, txParams, 0, walletFactory.address) diff --git a/packages/0xsequence/tests/browser/testutils/wallet.ts b/packages/0xsequence/tests/browser/testutils/wallet.ts index 52b7124d9..8f74d0841 100644 --- a/packages/0xsequence/tests/browser/testutils/wallet.ts +++ b/packages/0xsequence/tests/browser/testutils/wallet.ts @@ -1,15 +1,12 @@ -import { ethers, Wallet as EOAWallet } from 'ethers' +import { ethers } from 'ethers' +import { toHexString } from '@0xsequence/utils' -export const sendETH = ( - eoaWallet: EOAWallet, - toAddress: string, - amount: ethers.BigNumber -): Promise => { +export const sendETH = (eoaWallet: ethers.Wallet, toAddress: string, amount: bigint): Promise => { const tx = { gasPrice: '0x55555', gasLimit: '0x55555', to: toAddress, - value: amount.toHexString(), + value: toHexString(amount), data: '0x' } return eoaWallet.sendTransaction(tx) diff --git a/packages/0xsequence/tests/browser/wallet-provider/dapp.test.ts b/packages/0xsequence/tests/browser/wallet-provider/dapp.test.ts index 99c55cd03..d3ccb8713 100644 --- a/packages/0xsequence/tests/browser/wallet-provider/dapp.test.ts +++ b/packages/0xsequence/tests/browser/wallet-provider/dapp.test.ts @@ -1,8 +1,8 @@ import { commons, v2 } from '@0xsequence/core' import { SequenceClient, SequenceProvider, DefaultProviderConfig, MemoryItemStore } from '@0xsequence/provider' import { context } from '@0xsequence/tests' -import { configureLogger } from '@0xsequence/utils' -import { ethers, TypedDataDomain, TypedDataField } from 'ethers' +import { configureLogger, parseEther } from '@0xsequence/utils' +import { ethers } from 'ethers' import { test, assert } from '../../utils/assert' import { testAccounts, getEOAWallet, sendETH } from '../testutils' @@ -21,12 +21,12 @@ export const tests = async () => { // Deploy Sequence WalletContext (deterministic). // const deployedWalletContext = await (async () => { - const provider = new ethers.providers.JsonRpcProvider('http://localhost:8545') - const signer = provider.getSigner() + const provider = new ethers.JsonRpcProvider('http://localhost:8545', undefined, { cacheTimeout: -1 }) + const signer = await provider.getSigner() return context.deploySequenceContexts(signer) })() - const hardhatProvider = new ethers.providers.JsonRpcProvider('http://localhost:8545') + const hardhatProvider = new ethers.JsonRpcProvider('http://localhost:8545', undefined, { cacheTimeout: -1 }) const client = new SequenceClient(transportsConfig, new MemoryItemStore(), { defaultChainId: 31337 }) const wallet = new SequenceProvider(client, chainId => { @@ -35,7 +35,7 @@ export const tests = async () => { } if (chainId === 31338) { - return new ethers.providers.JsonRpcProvider('http://localhost:9545') + return new ethers.JsonRpcProvider('http://localhost:9545', undefined, { cacheTimeout: -1 }) } throw new Error(`No provider for chainId ${chainId}`) @@ -97,7 +97,7 @@ export const tests = async () => { assert.equal(networks.length, 2, '2 networks') assert.true(networks[0].isDefaultChain!, '1st network is DefaultChain') assert.true(!networks[1].isDefaultChain, '1st network is not DefaultChain') - assert.true(networks[1].chainId === 31338, 'authChainId is correct') + assert.equal(networks[1].chainId, 31338, 'authChainId is correct') const authProvider = wallet.getProvider(31338)! assert.equal(authProvider.getChainId(), 31338, 'authProvider chainId is 31338') @@ -107,7 +107,7 @@ export const tests = async () => { await test('getAddress', async () => { const address = wallet.getAddress() - assert.true(ethers.utils.isAddress(address), 'wallet address is valid') + assert.true(ethers.isAddress(address), 'wallet address is valid') }) await test('getWalletConfig', async () => { @@ -115,11 +115,11 @@ export const tests = async () => { const config = allWalletConfigs as v2.config.WalletConfig assert.equal(config.version, 2, 'wallet config version is correct') - assert.true(ethers.BigNumber.from(2).eq(config.threshold), 'config, 2 threshold') - assert.true(ethers.BigNumber.from(0).eq(config.checkpoint), 'config, 0 checkpoint') + assert.equal(BigInt(config.threshold), 2n, 'config, 2 threshold') + assert.equal(BigInt(config.checkpoint), 0n, 'config, 0 checkpoint') assert.true(v2.config.isSignerLeaf(config.tree), 'config, isSignerLeaf') - assert.true(ethers.utils.isAddress((config.tree as v2.config.SignerLeaf).address), 'config, signer address') - assert.true(ethers.BigNumber.from(2).eq((config.tree as v2.config.SignerLeaf).weight), 'config, signer weight') + assert.true(ethers.isAddress((config.tree as v2.config.SignerLeaf).address), 'config, signer address') + assert.equal(BigInt((config.tree as v2.config.SignerLeaf).weight), 2n, 'config, signer weight') }) await test('multiple networks', async () => { @@ -128,13 +128,13 @@ export const tests = async () => { assert.equal(provider.getChainId(), 31337, 'provider chainId is 31337') const network = await provider.getNetwork() - assert.equal(network.chainId, 31337, 'chain id match') + assert.equal(network.chainId, 31337n, 'chain id match') const netVersion = await provider.send('net_version', []) assert.equal(netVersion, '31337', 'net_version check') const chainId = await provider.send('eth_chainId', []) - assert.equal(chainId, ethers.utils.hexValue(31337), 'eth_chainId check') + assert.equal(chainId, ethers.toQuantity(31337), 'eth_chainId check') const chainId2 = await signer.getChainId() assert.equal(chainId2, 31337, 'chainId check') @@ -146,13 +146,13 @@ export const tests = async () => { assert.equal(provider2.getChainId(), 31338, '2nd chain, chainId is 31338 - 2') const network = await provider2.getNetwork() - assert.equal(network.chainId, 31338, '2nd chain, chain id match - 3') + assert.equal(network.chainId, 31338n, '2nd chain, chain id match - 3') const netVersion = await provider2.send('net_version', []) assert.equal(netVersion, '31338', '2nd chain, net_version check - 4') const chainId = await provider2.send('eth_chainId', []) - assert.equal(chainId, ethers.utils.hexValue(31338), '2nd chain, eth_chainId check - 5') + assert.equal(chainId, ethers.toQuantity(31338), '2nd chain, eth_chainId check - 5') const chainId2 = await provider2.getSigner().getChainId() assert.equal(chainId2, 31338, '2nd chain, chainId check - 6') @@ -161,8 +161,8 @@ export const tests = async () => { await test('listAccounts', async () => { const signers = provider.listAccounts() - assert.true(signers.length === 1, 'signers, single owner') - assert.true(signers[0] === wallet.getAddress(), 'signers, check address') + assert.equal(signers.length, 1, 'signers, single owner') + assert.equal(signers[0], wallet.getAddress(), 'signers, check address') }) await test('signMessage on defaultChain', async () => { @@ -170,7 +170,7 @@ export const tests = async () => { const chainId = wallet.getChainId() const message = 'hihi' - const message2 = ethers.utils.toUtf8Bytes('hihi') + const message2 = ethers.toUtf8Bytes(message) // Sign the message const sigs = await Promise.all( @@ -189,6 +189,9 @@ export const tests = async () => { return sig }) ) + + assert.equal(sigs[0], sigs[1], 'signatures should match even if message type is different') + const sig = sigs[0] // Verify the signature @@ -200,14 +203,14 @@ export const tests = async () => { const address = wallet.getAddress() const chainId = wallet.getChainId() - const domain: TypedDataDomain = { + const domain: ethers.TypedDataDomain = { name: 'Ether Mail', version: '1', chainId: chainId, verifyingContract: '0xCcCCccccCCCCcCCCCCCcCcCccCcCCCcCcccccccC' } - const types: { [key: string]: TypedDataField[] } = { + const types: { [key: string]: ethers.TypedDataField[] } = { Person: [ { name: 'name', type: 'string' }, { name: 'wallet', type: 'address' } @@ -252,7 +255,7 @@ export const tests = async () => { await test('getBalance', async () => { // technically, the mock-wallet's single signer owner has some ETH.. const balanceSigner1 = await provider.getBalance('0x4e37E14f5d5AAC4DF1151C6E8DF78B7541680853') - assert.true(balanceSigner1.gt(ethers.BigNumber.from(0)), 'signer1 balance > 0') + assert.true(balanceSigner1 > 0n, 'signer1 balance > 0') }) await test('fund sequence wallet', async () => { @@ -260,13 +263,13 @@ export const tests = async () => { const testAccount = getEOAWallet(testAccounts[0].privateKey) const walletBalanceBefore = await signer.getBalance() - const ethAmount = ethers.utils.parseEther('10.1234') + const ethAmount = parseEther('10.1234') const txResp = await sendETH(testAccount, wallet.getAddress(), ethAmount) const txReceipt = await provider.getTransactionReceipt(txResp.hash) - assert.true(txReceipt.status === 1, 'eth sent from signer1') + assert.equal(txReceipt?.status, 1, 'eth sent from signer1') const walletBalanceAfter = await signer.getBalance() - assert.true(walletBalanceAfter.sub(walletBalanceBefore).eq(ethAmount), `wallet received ${ethAmount} eth`) + assert.equal(walletBalanceAfter - walletBalanceBefore, ethAmount, `wallet received ${ethAmount} eth`) }) const testSendETH = async ( @@ -286,7 +289,7 @@ export const tests = async () => { const toAddress = testAccounts[1].address const toBalanceBefore = await provider.getBalance(toAddress) - const ethAmount = ethers.utils.parseEther('1.4242') + const ethAmount = parseEther('1.4242') // NOTE: when a wallet is undeployed (counterfactual), and although the txn contents are to send from our // sequence wallet to the test account, the transaction by the Sequence Wallet instance will be sent `to` the @@ -306,7 +309,7 @@ export const tests = async () => { const beforeWalletDeployed = (await hardhatProvider.getCode(wallet.getAddress())) !== '0x' // NOTE/TODO: gasPrice even if set will be set again by the LocalRelayer, we should allow it to be overridden - const tx: ethers.providers.TransactionRequest = { + const tx: ethers.TransactionRequest = { from: walletAddress, to: toAddress, value: ethAmount @@ -320,7 +323,7 @@ export const tests = async () => { const txResp = await signer.sendTransaction(tx) const txReceipt = await txResp.wait() - assert.true(txReceipt.status === 1, 'txn sent successfully') + assert.equal(txReceipt?.status, 1, 'txn sent successfully') assert.true( (await hardhatProvider.getCode(wallet.getAddress())) !== '0x', 'wallet must be in deployed state after the txn' @@ -328,27 +331,27 @@ export const tests = async () => { // transaction is sent to the deployed wallet, if the wallet is deployed.. otherwise its sent to guestModule if (beforeWalletDeployed) { - assert.equal(txReceipt.to, wallet.getAddress(), 'recipient is correct') + assert.equal(txReceipt?.to, wallet.getAddress(), 'recipient is correct') } else { - assert.equal(txReceipt.to, walletContext[2].guestModule, 'recipient is correct') + assert.equal(txReceipt?.to, walletContext[2].guestModule, 'recipient is correct') } // Ensure fromAddress sent their eth const walletBalanceAfter = await signer.getBalance() - const sent = walletBalanceAfter.sub(walletBalanceBefore).mul(-1) + const sent = (walletBalanceAfter - walletBalanceBefore) * -1n - assert.true(sent.eq(ethAmount), `wallet sent ${sent} eth while expected ${ethAmount}`) + assert.equal(sent, ethAmount, `wallet sent ${sent} eth while expected ${ethAmount}`) // Ensure toAddress received their eth const toBalanceAfter = await provider.getBalance(toAddress) - const received = toBalanceAfter.sub(toBalanceBefore) - assert.true(received.eq(ethAmount), `toAddress received ${received} eth while expected ${ethAmount}`) + const received = toBalanceAfter - toBalanceBefore + assert.equal(received, ethAmount, `toAddress received ${received} eth while expected ${ethAmount}`) // Extra checks if (opts.gasLimit) { // In our test, we are passing a high gas limit for an internal transaction, so overall // transaction must be higher than this value if it used our value correctly - assert.true(txResp.gasLimit.gte(opts.gasLimit), 'sendETH, using higher gasLimit') + assert.true(txResp.gasLimit >= BigInt(opts.gasLimit), 'sendETH, using higher gasLimit') } } }) @@ -362,14 +365,14 @@ export const tests = async () => { await test('sendTransaction batch', async () => { const testAccount = getEOAWallet(testAccounts[1].privateKey) - const ethAmount1 = ethers.utils.parseEther('1.234') - const ethAmount2 = ethers.utils.parseEther('0.456') + const ethAmount1 = parseEther('1.234') + const ethAmount2 = parseEther('0.456') - const tx1: ethers.providers.TransactionRequest = { + const tx1: ethers.TransactionRequest = { to: testAccount.address, value: ethAmount1 } - const tx2: ethers.providers.TransactionRequest = { + const tx2: ethers.TransactionRequest = { to: testAccount.address, value: ethAmount2 } @@ -380,26 +383,23 @@ export const tests = async () => { await txnResp.wait() const toBalanceAfter = await provider.getBalance(testAccount.address) - const sent = toBalanceAfter.sub(toBalanceBefore) - const expected = ethAmount1.add(ethAmount2) - assert.true( - sent.eq(ethAmount1.add(ethAmount2)), - `wallet sent ${sent} eth while expected ${expected} (${ethAmount1} + ${ethAmount2})` - ) + const sent = toBalanceAfter - toBalanceBefore + const expected = ethAmount1 + ethAmount2 + assert.equal(sent, expected, `wallet sent ${sent} eth while expected ${expected} (${ethAmount1} + ${ethAmount2})`) }) await test('sendTransaction batch format 2', async () => { const testAccount = getEOAWallet(testAccounts[1].privateKey) - const ethAmount1 = ethers.utils.parseEther('1.234') - const ethAmount2 = ethers.utils.parseEther('0.456') + const ethAmount1 = parseEther('1.234') + const ethAmount2 = parseEther('0.456') - const tx1: ethers.providers.TransactionRequest = { + const tx1: ethers.TransactionRequest = { to: testAccount.address, value: ethAmount1 } - const tx2: ethers.providers.TransactionRequest = { + const tx2: ethers.TransactionRequest = { to: testAccount.address, value: ethAmount2 } @@ -410,19 +410,16 @@ export const tests = async () => { await txnResp.wait() const toBalanceAfter = await provider.getBalance(testAccount.address) - const sent = toBalanceAfter.sub(toBalanceBefore) - const expected = ethAmount1.add(ethAmount2) - assert.true( - sent.eq(ethAmount1.add(ethAmount2)), - `wallet sent ${sent} eth while expected ${expected} (${ethAmount1} + ${ethAmount2})` - ) + const sent = toBalanceAfter - toBalanceBefore + const expected = ethAmount1 + ethAmount2 + assert.equal(sent, expected, `wallet sent ${sent} eth while expected ${expected} (${ethAmount1} + ${ethAmount2})`) }) await test('sendTransaction batch format 3', async () => { const testAccount = getEOAWallet(testAccounts[1].privateKey) - const ethAmount1 = ethers.utils.parseEther('1.234') - const ethAmount2 = ethers.utils.parseEther('0.456') + const ethAmount1 = parseEther('1.234') + const ethAmount2 = parseEther('0.456') const tx1: commons.transaction.Transaction = { to: testAccount.address, @@ -440,12 +437,9 @@ export const tests = async () => { await txnResp.wait() const toBalanceAfter = await provider.getBalance(testAccount.address) - const sent = toBalanceAfter.sub(toBalanceBefore) - const expected = ethAmount1.add(ethAmount2) - assert.true( - sent.eq(ethAmount1.add(ethAmount2)), - `wallet sent ${sent} eth while expected ${expected} (${ethAmount1} + ${ethAmount2})` - ) + const sent = toBalanceAfter - toBalanceBefore + const expected = ethAmount1 + ethAmount2 + assert.equal(sent, expected, `wallet sent ${sent} eth while expected ${expected} (${ethAmount1} + ${ethAmount2})`) }) await test('sendETH from the sequence smart wallet (authChain)', async () => { @@ -472,24 +466,12 @@ export const tests = async () => { // initial balances { const testAccount = getEOAWallet(testAccounts[0].privateKey, provider2) - const walletBalanceBefore = await testAccount.getBalance() + const walletBalanceBefore = await provider2.getBalance(await testAccount.getAddress()) const mainTestAccount = getEOAWallet(testAccounts[0].privateKey, wallet.getProvider()) - const mainWalletBalanceBefore = await mainTestAccount.getBalance() - - assert.true(walletBalanceBefore.toString() !== mainWalletBalanceBefore.toString(), 'balances across networks do not match') - - // test different code paths lead to same results - assert.equal( - (await provider2.getBalance(await testAccount.getAddress())).toString(), - (await testAccount.getBalance()).toString(), - 'balance match 1' - ) - assert.equal( - (await provider.getBalance(await mainTestAccount.getAddress())).toString(), - (await mainTestAccount.getBalance()).toString(), - 'balance match 2' - ) + const mainWalletBalanceBefore = await provider.getBalance(await mainTestAccount.getAddress()) + + assert.true(walletBalanceBefore !== mainWalletBalanceBefore, 'balances across networks do not match') } // first, lets move some ETH info the wallet from teh testnet seed account @@ -497,16 +479,16 @@ export const tests = async () => { const testAccount = getEOAWallet(testAccounts[0].privateKey, provider2) const walletBalanceBefore = await signer2.getBalance() - const ethAmount = ethers.utils.parseEther('4.2') + const ethAmount = parseEther('4.2') // const txResp = await sendETH(testAccount, await wallet.getAddress(), ethAmount) // const txReceipt = await provider2.getTransactionReceipt(txResp.hash) const txReceipt = await (await sendETH(testAccount, wallet.getAddress(), ethAmount)).wait() - assert.true(txReceipt.status === 1, 'eth sent') + assert.equal(txReceipt?.status, 1, 'eth sent') const walletBalanceAfter = await signer2.getBalance() - assert.true(walletBalanceAfter.sub(walletBalanceBefore).eq(ethAmount), `wallet received ${ethAmount} eth`) + assert.equal(walletBalanceAfter - walletBalanceBefore, ethAmount, `wallet received ${ethAmount} eth`) } // using sequence wallet on the authChain, send eth back to anotehr seed account via @@ -519,7 +501,7 @@ export const tests = async () => { const toAddress = testAccounts[1].address const toBalanceBefore = await provider2.getBalance(toAddress) - const ethAmount = ethers.utils.parseEther('1.1234') + const ethAmount = parseEther('1.1234') const tx = { from: walletAddress, @@ -528,16 +510,18 @@ export const tests = async () => { } const txReceipt = await (await signer2.sendTransaction(tx)).wait() - assert.true(txReceipt.status === 1, 'txn sent successfully') + assert.equal(txReceipt?.status, 1, 'txn sent successfully') assert.true((await hardhatProvider.getCode(walletAddress)) !== '0x', 'wallet must be in deployed state after the txn') // Ensure fromAddress sent their eth const walletBalanceAfter = await signer2.getBalance() - assert.true(walletBalanceAfter.sub(walletBalanceBefore).mul(-1).eq(ethAmount), `wallet sent ${ethAmount} eth`) + const sent = (walletBalanceAfter - walletBalanceBefore) * -1n + + assert.equal(sent, ethAmount, `wallet sent ${ethAmount} eth`) // Ensure toAddress received their eth const toBalanceAfter = await provider2.getBalance(toAddress) - assert.true(toBalanceAfter.sub(toBalanceBefore).eq(ethAmount), `toAddress received ${ethAmount} eth`) + assert.equal(toBalanceAfter - toBalanceBefore, ethAmount, `toAddress received ${ethAmount} eth`) } }) } diff --git a/packages/0xsequence/tests/browser/wallet-provider/dapp2.test.ts b/packages/0xsequence/tests/browser/wallet-provider/dapp2.test.ts index 79d1c7597..e4839b67f 100644 --- a/packages/0xsequence/tests/browser/wallet-provider/dapp2.test.ts +++ b/packages/0xsequence/tests/browser/wallet-provider/dapp2.test.ts @@ -1,6 +1,6 @@ import { DefaultProviderConfig, MemoryItemStore, SequenceClient, SequenceProvider } from '@0xsequence/provider' import { configureLogger } from '@0xsequence/utils' -import { ethers, TypedDataDomain, TypedDataField } from 'ethers' +import { ethers } from 'ethers' import { test, assert } from '../../utils/assert' configureLogger({ logLevel: 'DEBUG', silence: false }) @@ -14,7 +14,7 @@ export const tests = async () => { walletAppURL: 'http://localhost:9999/mock-wallet/mock-wallet.test.html' } - const hardhatProvider = new ethers.providers.JsonRpcProvider('http://localhost:8545') + const hardhatProvider = new ethers.JsonRpcProvider('http://localhost:8545', undefined, { cacheTimeout: -1 }) const client = new SequenceClient(transportsConfig, new MemoryItemStore(), { defaultChainId: 31338 }) const provider = new SequenceProvider(client, chainId => { @@ -23,7 +23,7 @@ export const tests = async () => { } if (chainId === 31338) { - return new ethers.providers.JsonRpcProvider('http://localhost:9545') + return new ethers.JsonRpcProvider('http://localhost:9545', undefined, { cacheTimeout: -1 }) } throw new Error(`No provider for chainId ${chainId}`) @@ -57,7 +57,7 @@ export const tests = async () => { assert.equal(provider.getChainId(), 31338, 'provider chainId is 31338') const network = await provider.getNetwork() - assert.equal(network.chainId, 31338, 'chain id match') + assert.equal(network.chainId, 31338n, 'chain id match') }) await test('getNetworks()', async () => { @@ -88,14 +88,14 @@ export const tests = async () => { const address = provider.getAddress() const chainId = provider.getChainId() - const domain: TypedDataDomain = { + const domain: ethers.TypedDataDomain = { name: 'Ether Mail', version: '1', chainId: chainId, verifyingContract: '0xCcCCccccCCCCcCCCCCCcCcCccCcCCCcCcccccccC' } - const types: { [key: string]: TypedDataField[] } = { + const types: { [key: string]: ethers.TypedDataField[] } = { Person: [ { name: 'name', type: 'string' }, { name: 'wallet', type: 'address' } diff --git a/packages/0xsequence/tests/browser/window-transport/dapp.test.ts b/packages/0xsequence/tests/browser/window-transport/dapp.test.ts index aa0812c29..12c6bd9f3 100644 --- a/packages/0xsequence/tests/browser/window-transport/dapp.test.ts +++ b/packages/0xsequence/tests/browser/window-transport/dapp.test.ts @@ -13,8 +13,8 @@ walletProvider.register() export const tests = async () => { await (async () => { - const provider = new ethers.providers.JsonRpcProvider('http://localhost:8545') - const signer = provider.getSigner() + const provider = new ethers.JsonRpcProvider('http://localhost:8545', undefined, { cacheTimeout: -1 }) + const signer = await provider.getSigner() return context.deploySequenceContexts(signer) })() @@ -27,44 +27,39 @@ export const tests = async () => { // TODO: try this again, but turn off hardhat, to ensure our error reponses are working correctly.. // .. - const provider = new ethers.providers.Web3Provider(walletProvider) - const signer = provider.getSigner() + const provider = new ethers.BrowserProvider(walletProvider, undefined, { cacheTimeout: -1 }) + const signer = await provider.getSigner() + const address = await signer.getAddress() - const chainId = await signer.getChainId() + const { chainId } = await provider.getNetwork() await test('getAddress', async () => { - assert.true(ethers.utils.isAddress(address), 'wallet address') + assert.true(ethers.isAddress(address), 'wallet address') }) await test('sending a json-rpc request', async () => { - await walletProvider.sendAsync({ jsonrpc: '2.0', id: 88, method: 'eth_accounts', params: [] }, (err, resp) => { - assert.true(!err, 'error is empty') - assert.true(!!resp, 'response successful') - assert.true(resp!.result[0] === address, 'response address check') - }) + const result = await walletProvider.request({ method: 'eth_accounts', params: [] }) + assert.equal(result[0], address, 'response address check') const resp = await provider.send('eth_accounts', []) assert.true(!!resp, 'response successful') - assert.true(resp[0] === address, 'response address check') + assert.equal(resp[0], address, 'response address check') }) await test('get chain id', async () => { const network = await provider.getNetwork() - assert.equal(network.chainId, 31337, 'chain id match') + assert.equal(network.chainId, 31337n, 'chain id match') const netVersion = await provider.send('net_version', []) assert.equal(netVersion, '31337', 'net_version check') const chainId = await provider.send('eth_chainId', []) assert.equal(chainId, '0x7a69', 'eth_chainId check') - - const chainId2 = await signer.getChainId() - assert.equal(chainId2, 31337, 'chainId check') }) // NOTE: when a dapp wants to verify SmartWallet signed messages, they will need to verify against EIP-1271 await test('sign a message and validate/recover', async () => { - const message = ethers.utils.toUtf8Bytes('hihi') + const message = ethers.toUtf8Bytes('hihi') // TODO: signer should be a Sequence signer, and should be able to specify the chainId // however, for a single wallet, it can check the chainId and throw if doesnt match, for multi-wallet it will select @@ -123,8 +118,8 @@ export const tests = async () => { // Verify the message signature // - const messageHash = ethers.utils._TypedDataEncoder.hash(typedData.domain, typedData.types, typedData.message) - const messageDigest = ethers.utils.arrayify(messageHash) + const messageHash = ethers.TypedDataEncoder.hash(typedData.domain, typedData.types, typedData.message) + const messageDigest = ethers.getBytes(messageHash) const isValid = await isValidSignature(address, messageDigest, sig, provider) assert.true(isValid, 'signature is valid - 6') diff --git a/packages/0xsequence/tests/utils/assert.ts b/packages/0xsequence/tests/utils/assert.ts index 413851dcd..6af2b776c 100644 --- a/packages/0xsequence/tests/utils/assert.ts +++ b/packages/0xsequence/tests/utils/assert.ts @@ -1,9 +1,30 @@ -const testResults = [] +interface Entry { + title: string + pass: boolean | null + startTime: number + error: string | null + stack: string | null +} + +declare global { + interface Window { + __testResults: Entry[] + } +} + +const testResults: Entry[] = [] -;(window as any).__testResults = testResults +window.__testResults = testResults export const test = async (title: string, run: () => void) => { - const entry = { + console.log(`\n +╔══════════════════════════════════════════════════════════════════════════════╗ +║ ║ +║ ${title}${' '.repeat(77 - title.length)}║ +║ ║ +╚══════════════════════════════════════════════════════════════════════════════╝\n`) + + const entry: Entry = { title: title, pass: null, startTime: performance.now(), diff --git a/packages/0xsequence/tests/utils/browser-test-runner.ts b/packages/0xsequence/tests/utils/browser-test-runner.ts index 5bb74cf41..4a709a570 100644 --- a/packages/0xsequence/tests/utils/browser-test-runner.ts +++ b/packages/0xsequence/tests/utils/browser-test-runner.ts @@ -1,6 +1,5 @@ import test from 'ava' -import puppeteer from 'puppeteer' -import { spawnSync } from 'child_process' +import * as puppeteer from 'puppeteer' export const runBrowserTests = async (title: string, path: string) => { test.serial(title, browserContext, async (t, page: puppeteer.Page) => { @@ -58,8 +57,8 @@ export const runBrowserTests = async (title: string, path: string) => { export const browserContext = async (t, run) => { const browser = await puppeteer.launch({ - executablePath: getChromePath(), - args: ['--headless'] + headless: true, + args: ['--no-sandbox', '--disable-setuid-sandbox'] }) const page = await browser.newPage() try { @@ -70,21 +69,21 @@ export const browserContext = async (t, run) => { } } -const getChromePath = (): string | undefined => { - if (process.env['NIX_PATH']) { - // nixos users are unable to use the chrome bin packaged with puppeteer, - // so instead we use the locally installed chrome or chromium binary. - for (const bin of ['google-chrome-stable', 'chromium']) { - const out = spawnSync('which', [bin]) - if (out.status === 0) { - const executablePath = out.stdout.toString().trim() - return executablePath - } - } - console.error('Unable to find `google-chrome-stable` or `chromium` binary on your NixOS system.') - process.exit(1) - } else { - // undefined will use the chrome version packaged with puppeteer npm package - return undefined - } -} +// const getChromePath = (): string | undefined => { +// if (process.env['NIX_PATH']) { +// // nixos users are unable to use the chrome bin packaged with puppeteer, +// // so instead we use the locally installed chrome or chromium binary. +// for (const bin of ['google-chrome-stable', 'chromium']) { +// const out = spawnSync('which', [bin]) +// if (out.status === 0) { +// const executablePath = out.stdout.toString().trim() +// return executablePath +// } +// } +// console.error('Unable to find `google-chrome-stable` or `chromium` binary on your NixOS system.') +// process.exit(1) +// } else { +// // undefined will use the chrome version packaged with puppeteer npm package +// return undefined +// } +// } diff --git a/packages/abi/CHANGELOG.md b/packages/abi/CHANGELOG.md index 15092de06..b145403f4 100644 --- a/packages/abi/CHANGELOG.md +++ b/packages/abi/CHANGELOG.md @@ -1,5 +1,331 @@ # @0xsequence/abi +## 2.2.14 + +### Patch Changes + +- Somnia Testnet and Monad Testnet + +## 2.2.13 + +### Patch Changes + +- Add XR1 to all networks + +## 2.2.12 + +### Patch Changes + +- Add XR1 + +## 2.2.11 + +### Patch Changes + +- Relayer updates + +## 2.2.10 + +### Patch Changes + +- Etherlink support + +## 2.2.9 + +### Patch Changes + +- Indexer gateway native token balances + +## 2.2.8 + +### Patch Changes + +- Add Moonbeam and Moonbase Alpha + +## 2.2.7 + +### Patch Changes + +- Update Builder package + +## 2.2.6 + +### Patch Changes + +- Update relayer package + +## 2.2.5 + +### Patch Changes + +- auth: fix sequence indexer gateway url +- account: immutable wallet proxy hook + +## 2.2.4 + +### Patch Changes + +- network: update soneium mainnet block explorer url +- waas: signTypedData intent support + +## 2.2.3 + +### Patch Changes + +- provider: updating initWallet to use connected network configs if they exist + +## 2.2.2 + +### Patch Changes + +- pass projectAccessKey to relayer at all times + +## 2.2.1 + +### Patch Changes + +- waas-ethers: sign typed data + +## 2.2.0 + +### Minor Changes + +- indexer: gateway client +- @0xsequence/builder +- upgrade puppeteer to v23.10.3 + +## 2.1.8 + +### Patch Changes + +- Add Soneium Mainnet + +## 2.1.7 + +### Patch Changes + +- guard: pass project access key to guard requests + +## 2.1.6 + +### Patch Changes + +- Add LAOS and Telos Testnet chains + +## 2.1.5 + +### Patch Changes + +- account: save presigned configuration with reference chain id 1 + +## 2.1.4 + +### Patch Changes + +- provider: pass projectAccessKey into MuxMessageProvider + +## 2.1.3 + +### Patch Changes + +- waas: time drift date fix due to strange browser quirk + +## 2.1.2 + +### Patch Changes + +- provider: export analytics correctly + +## 2.1.1 + +### Patch Changes + +- Add LAOS chain support + +## 2.1.0 + +### Minor Changes + +- account: forward project access key when estimating fees and sending transactions + +### Patch Changes + +- sessions: save signatures with reference chain id + +## 2.0.26 + +### Patch Changes + +- account: fix chain id comparison + +## 2.0.25 + +### Patch Changes + +- skale-nebula: deploy gas limit = 10m + +## 2.0.24 + +### Patch Changes + +- sessions: arweave: configurable gateway url +- waas: use /status to get time drift before sending any intents + +## 2.0.23 + +### Patch Changes + +- Add The Root Network support + +## 2.0.22 + +### Patch Changes + +- Add SKALE Nebula Mainnet support + +## 2.0.21 + +### Patch Changes + +- account: add publishWitnessFor + +## 2.0.20 + +### Patch Changes + +- upgrade deps, and improve waas session status handling + +## 2.0.19 + +### Patch Changes + +- Add Immutable zkEVM support + +## 2.0.18 + +### Patch Changes + +- waas: new contractCall transaction type +- sessions: add arweave owner + +## 2.0.17 + +### Patch Changes + +- update waas auth to clear session before signIn + +## 2.0.16 + +### Patch Changes + +- Removed Astar chains + +## 2.0.15 + +### Patch Changes + +- indexer: update bindings with token balance additions + +## 2.0.14 + +### Patch Changes + +- sessions: arweave config reader +- network: add b3 and apechain mainnet configs + +## 2.0.13 + +### Patch Changes + +- network: toy-testnet + +## 2.0.12 + +### Patch Changes + +- api: update bindings + +## 2.0.11 + +### Patch Changes + +- waas: intents test fix +- api: update bindings + +## 2.0.10 + +### Patch Changes + +- network: soneium minato testnet + +## 2.0.9 + +### Patch Changes + +- network: fix SKALE network name + +## 2.0.8 + +### Patch Changes + +- metadata: update bindings + +## 2.0.7 + +### Patch Changes + +- wallet request handler fix + +## 2.0.6 + +### Patch Changes + +- network: matic -> pol + +## 2.0.5 + +### Patch Changes + +- provider: update databeat to 0.9.2 + +## 2.0.4 + +### Patch Changes + +- network: add skale-nebula-testnet + +## 2.0.3 + +### Patch Changes + +- waas: check session status in SequenceWaaS.isSignedIn() + +## 2.0.2 + +### Patch Changes + +- sessions: property convert serialized bignumber hex value to bigint + +## 2.0.1 + +### Patch Changes + +- waas: http signature check for authenticator requests +- provider: unwrap legacy json rpc responses +- use json replacer and reviver for bigints + +## 2.0.0 + +### Major Changes + +- ethers v6 + +## 1.10.15 + +### Patch Changes + +- utils: extractProjectIdFromAccessKey + ## 1.10.14 ### Patch Changes diff --git a/packages/abi/package.json b/packages/abi/package.json index bf133663b..a591e0e06 100644 --- a/packages/abi/package.json +++ b/packages/abi/package.json @@ -1,6 +1,6 @@ { "name": "@0xsequence/abi", - "version": "1.10.14", + "version": "2.2.14", "description": "abi sub-package for Sequence", "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/abi", "source": "src/index.ts", diff --git a/packages/abi/src/wallet/index.ts b/packages/abi/src/wallet/index.ts index cb9bdf867..73a90929a 100644 --- a/packages/abi/src/wallet/index.ts +++ b/packages/abi/src/wallet/index.ts @@ -4,8 +4,10 @@ import * as erc6492 from './erc6492' import * as factory from './factory' import * as mainModule from './mainModule' import * as mainModuleUpgradable from './mainModuleUpgradable' +import * as moduleHooks from './moduleHooks' import * as sequenceUtils from './sequenceUtils' import * as requireFreshSigner from './libs/requireFreshSigners' +import * as walletProxyHook from './walletProxyHook' export const walletContracts = { erc6492, @@ -14,6 +16,8 @@ export const walletContracts = { factory, mainModule, mainModuleUpgradable, + moduleHooks, sequenceUtils, - requireFreshSigner + requireFreshSigner, + walletProxyHook } diff --git a/packages/abi/src/wallet/moduleHooks.ts b/packages/abi/src/wallet/moduleHooks.ts new file mode 100644 index 000000000..e35174b94 --- /dev/null +++ b/packages/abi/src/wallet/moduleHooks.ts @@ -0,0 +1,248 @@ +export const abi = [ + { + inputs: [ + { + internalType: 'bytes4', + name: '_signature', + type: 'bytes4' + } + ], + name: 'HookAlreadyExists', + type: 'error' + }, + { + inputs: [ + { + internalType: 'bytes4', + name: '_signature', + type: 'bytes4' + } + ], + name: 'HookDoesNotExist', + type: 'error' + }, + { + inputs: [ + { + internalType: 'address', + name: '_sender', + type: 'address' + }, + { + internalType: 'address', + name: '_self', + type: 'address' + } + ], + name: 'OnlySelfAuth', + type: 'error' + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: 'bytes4', + name: '_signature', + type: 'bytes4' + }, + { + indexed: false, + internalType: 'address', + name: '_implementation', + type: 'address' + } + ], + name: 'DefinedHook', + type: 'event' + }, + { + stateMutability: 'payable', + type: 'fallback' + }, + { + inputs: [ + { + internalType: 'bytes4', + name: '_signature', + type: 'bytes4' + }, + { + internalType: 'address', + name: '_implementation', + type: 'address' + } + ], + name: 'addHook', + outputs: [], + stateMutability: 'nonpayable', + type: 'function' + }, + { + inputs: [ + { + internalType: 'address', + name: '', + type: 'address' + }, + { + internalType: 'address', + name: '', + type: 'address' + }, + { + internalType: 'uint256[]', + name: '', + type: 'uint256[]' + }, + { + internalType: 'uint256[]', + name: '', + type: 'uint256[]' + }, + { + internalType: 'bytes', + name: '', + type: 'bytes' + } + ], + name: 'onERC1155BatchReceived', + outputs: [ + { + internalType: 'bytes4', + name: '', + type: 'bytes4' + } + ], + stateMutability: 'nonpayable', + type: 'function' + }, + { + inputs: [ + { + internalType: 'address', + name: '', + type: 'address' + }, + { + internalType: 'address', + name: '', + type: 'address' + }, + { + internalType: 'uint256', + name: '', + type: 'uint256' + }, + { + internalType: 'uint256', + name: '', + type: 'uint256' + }, + { + internalType: 'bytes', + name: '', + type: 'bytes' + } + ], + name: 'onERC1155Received', + outputs: [ + { + internalType: 'bytes4', + name: '', + type: 'bytes4' + } + ], + stateMutability: 'nonpayable', + type: 'function' + }, + { + inputs: [ + { + internalType: 'address', + name: '', + type: 'address' + }, + { + internalType: 'address', + name: '', + type: 'address' + }, + { + internalType: 'uint256', + name: '', + type: 'uint256' + }, + { + internalType: 'bytes', + name: '', + type: 'bytes' + } + ], + name: 'onERC721Received', + outputs: [ + { + internalType: 'bytes4', + name: '', + type: 'bytes4' + } + ], + stateMutability: 'nonpayable', + type: 'function' + }, + { + inputs: [ + { + internalType: 'bytes4', + name: '_signature', + type: 'bytes4' + } + ], + name: 'readHook', + outputs: [ + { + internalType: 'address', + name: '', + type: 'address' + } + ], + stateMutability: 'view', + type: 'function' + }, + { + inputs: [ + { + internalType: 'bytes4', + name: '_signature', + type: 'bytes4' + } + ], + name: 'removeHook', + outputs: [], + stateMutability: 'nonpayable', + type: 'function' + }, + { + inputs: [ + { + internalType: 'bytes4', + name: '_interfaceID', + type: 'bytes4' + } + ], + name: 'supportsInterface', + outputs: [ + { + internalType: 'bool', + name: '', + type: 'bool' + } + ], + stateMutability: 'pure', + type: 'function' + }, + { + stateMutability: 'payable', + type: 'receive' + } +] as const diff --git a/packages/abi/src/wallet/walletProxyHook.ts b/packages/abi/src/wallet/walletProxyHook.ts new file mode 100644 index 000000000..d977e1f0a --- /dev/null +++ b/packages/abi/src/wallet/walletProxyHook.ts @@ -0,0 +1,9 @@ +export const abi = [ + { + type: 'function', + name: 'PROXY_getImplementation', + inputs: [], + outputs: [{ name: '', type: 'address', internalType: 'address' }], + stateMutability: 'view' + } +] as const diff --git a/packages/account/CHANGELOG.md b/packages/account/CHANGELOG.md index a6cd32c68..70017e707 100644 --- a/packages/account/CHANGELOG.md +++ b/packages/account/CHANGELOG.md @@ -1,5 +1,816 @@ # @0xsequence/account +## 2.2.14 + +### Patch Changes + +- Somnia Testnet and Monad Testnet +- Updated dependencies + - @0xsequence/abi@2.2.14 + - @0xsequence/core@2.2.14 + - @0xsequence/migration@2.2.14 + - @0xsequence/network@2.2.14 + - @0xsequence/relayer@2.2.14 + - @0xsequence/sessions@2.2.14 + - @0xsequence/utils@2.2.14 + - @0xsequence/wallet@2.2.14 + +## 2.2.13 + +### Patch Changes + +- Add XR1 to all networks +- Updated dependencies + - @0xsequence/abi@2.2.13 + - @0xsequence/core@2.2.13 + - @0xsequence/migration@2.2.13 + - @0xsequence/network@2.2.13 + - @0xsequence/relayer@2.2.13 + - @0xsequence/sessions@2.2.13 + - @0xsequence/utils@2.2.13 + - @0xsequence/wallet@2.2.13 + +## 2.2.12 + +### Patch Changes + +- Add XR1 +- Updated dependencies + - @0xsequence/abi@2.2.12 + - @0xsequence/core@2.2.12 + - @0xsequence/migration@2.2.12 + - @0xsequence/network@2.2.12 + - @0xsequence/relayer@2.2.12 + - @0xsequence/sessions@2.2.12 + - @0xsequence/utils@2.2.12 + - @0xsequence/wallet@2.2.12 + +## 2.2.11 + +### Patch Changes + +- Relayer updates +- Updated dependencies + - @0xsequence/abi@2.2.11 + - @0xsequence/core@2.2.11 + - @0xsequence/migration@2.2.11 + - @0xsequence/network@2.2.11 + - @0xsequence/relayer@2.2.11 + - @0xsequence/sessions@2.2.11 + - @0xsequence/utils@2.2.11 + - @0xsequence/wallet@2.2.11 + +## 2.2.10 + +### Patch Changes + +- Etherlink support +- Updated dependencies + - @0xsequence/abi@2.2.10 + - @0xsequence/core@2.2.10 + - @0xsequence/migration@2.2.10 + - @0xsequence/network@2.2.10 + - @0xsequence/relayer@2.2.10 + - @0xsequence/sessions@2.2.10 + - @0xsequence/utils@2.2.10 + - @0xsequence/wallet@2.2.10 + +## 2.2.9 + +### Patch Changes + +- Indexer gateway native token balances +- Updated dependencies + - @0xsequence/abi@2.2.9 + - @0xsequence/core@2.2.9 + - @0xsequence/migration@2.2.9 + - @0xsequence/network@2.2.9 + - @0xsequence/relayer@2.2.9 + - @0xsequence/sessions@2.2.9 + - @0xsequence/utils@2.2.9 + - @0xsequence/wallet@2.2.9 + +## 2.2.8 + +### Patch Changes + +- Add Moonbeam and Moonbase Alpha +- Updated dependencies + - @0xsequence/abi@2.2.8 + - @0xsequence/core@2.2.8 + - @0xsequence/migration@2.2.8 + - @0xsequence/network@2.2.8 + - @0xsequence/relayer@2.2.8 + - @0xsequence/sessions@2.2.8 + - @0xsequence/utils@2.2.8 + - @0xsequence/wallet@2.2.8 + +## 2.2.7 + +### Patch Changes + +- Update Builder package +- Updated dependencies + - @0xsequence/abi@2.2.7 + - @0xsequence/core@2.2.7 + - @0xsequence/migration@2.2.7 + - @0xsequence/network@2.2.7 + - @0xsequence/relayer@2.2.7 + - @0xsequence/sessions@2.2.7 + - @0xsequence/utils@2.2.7 + - @0xsequence/wallet@2.2.7 + +## 2.2.6 + +### Patch Changes + +- Update relayer package +- Updated dependencies + - @0xsequence/abi@2.2.6 + - @0xsequence/core@2.2.6 + - @0xsequence/migration@2.2.6 + - @0xsequence/network@2.2.6 + - @0xsequence/relayer@2.2.6 + - @0xsequence/sessions@2.2.6 + - @0xsequence/utils@2.2.6 + - @0xsequence/wallet@2.2.6 + +## 2.2.5 + +### Patch Changes + +- auth: fix sequence indexer gateway url +- account: immutable wallet proxy hook +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.2.5 + - @0xsequence/core@2.2.5 + - @0xsequence/migration@2.2.5 + - @0xsequence/network@2.2.5 + - @0xsequence/relayer@2.2.5 + - @0xsequence/sessions@2.2.5 + - @0xsequence/utils@2.2.5 + - @0xsequence/wallet@2.2.5 + +## 2.2.4 + +### Patch Changes + +- network: update soneium mainnet block explorer url +- waas: signTypedData intent support +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.2.4 + - @0xsequence/core@2.2.4 + - @0xsequence/migration@2.2.4 + - @0xsequence/network@2.2.4 + - @0xsequence/relayer@2.2.4 + - @0xsequence/sessions@2.2.4 + - @0xsequence/utils@2.2.4 + - @0xsequence/wallet@2.2.4 + +## 2.2.3 + +### Patch Changes + +- provider: updating initWallet to use connected network configs if they exist +- Updated dependencies + - @0xsequence/abi@2.2.3 + - @0xsequence/core@2.2.3 + - @0xsequence/migration@2.2.3 + - @0xsequence/network@2.2.3 + - @0xsequence/relayer@2.2.3 + - @0xsequence/sessions@2.2.3 + - @0xsequence/utils@2.2.3 + - @0xsequence/wallet@2.2.3 + +## 2.2.2 + +### Patch Changes + +- pass projectAccessKey to relayer at all times +- Updated dependencies + - @0xsequence/abi@2.2.2 + - @0xsequence/core@2.2.2 + - @0xsequence/migration@2.2.2 + - @0xsequence/network@2.2.2 + - @0xsequence/relayer@2.2.2 + - @0xsequence/sessions@2.2.2 + - @0xsequence/utils@2.2.2 + - @0xsequence/wallet@2.2.2 + +## 2.2.1 + +### Patch Changes + +- waas-ethers: sign typed data +- Updated dependencies + - @0xsequence/abi@2.2.1 + - @0xsequence/core@2.2.1 + - @0xsequence/migration@2.2.1 + - @0xsequence/network@2.2.1 + - @0xsequence/relayer@2.2.1 + - @0xsequence/sessions@2.2.1 + - @0xsequence/utils@2.2.1 + - @0xsequence/wallet@2.2.1 + +## 2.2.0 + +### Minor Changes + +- indexer: gateway client +- @0xsequence/builder +- upgrade puppeteer to v23.10.3 + +### Patch Changes + +- Updated dependencies +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.2.0 + - @0xsequence/core@2.2.0 + - @0xsequence/migration@2.2.0 + - @0xsequence/network@2.2.0 + - @0xsequence/relayer@2.2.0 + - @0xsequence/sessions@2.2.0 + - @0xsequence/utils@2.2.0 + - @0xsequence/wallet@2.2.0 + +## 2.1.8 + +### Patch Changes + +- Add Soneium Mainnet +- Updated dependencies + - @0xsequence/abi@2.1.8 + - @0xsequence/core@2.1.8 + - @0xsequence/migration@2.1.8 + - @0xsequence/network@2.1.8 + - @0xsequence/relayer@2.1.8 + - @0xsequence/sessions@2.1.8 + - @0xsequence/utils@2.1.8 + - @0xsequence/wallet@2.1.8 + +## 2.1.7 + +### Patch Changes + +- guard: pass project access key to guard requests +- Updated dependencies + - @0xsequence/abi@2.1.7 + - @0xsequence/core@2.1.7 + - @0xsequence/migration@2.1.7 + - @0xsequence/network@2.1.7 + - @0xsequence/relayer@2.1.7 + - @0xsequence/sessions@2.1.7 + - @0xsequence/utils@2.1.7 + - @0xsequence/wallet@2.1.7 + +## 2.1.6 + +### Patch Changes + +- Add LAOS and Telos Testnet chains +- Updated dependencies + - @0xsequence/abi@2.1.6 + - @0xsequence/core@2.1.6 + - @0xsequence/migration@2.1.6 + - @0xsequence/network@2.1.6 + - @0xsequence/relayer@2.1.6 + - @0xsequence/sessions@2.1.6 + - @0xsequence/utils@2.1.6 + - @0xsequence/wallet@2.1.6 + +## 2.1.5 + +### Patch Changes + +- account: save presigned configuration with reference chain id 1 +- Updated dependencies + - @0xsequence/abi@2.1.5 + - @0xsequence/core@2.1.5 + - @0xsequence/migration@2.1.5 + - @0xsequence/network@2.1.5 + - @0xsequence/relayer@2.1.5 + - @0xsequence/sessions@2.1.5 + - @0xsequence/utils@2.1.5 + - @0xsequence/wallet@2.1.5 + +## 2.1.4 + +### Patch Changes + +- provider: pass projectAccessKey into MuxMessageProvider +- Updated dependencies + - @0xsequence/abi@2.1.4 + - @0xsequence/core@2.1.4 + - @0xsequence/migration@2.1.4 + - @0xsequence/network@2.1.4 + - @0xsequence/relayer@2.1.4 + - @0xsequence/sessions@2.1.4 + - @0xsequence/utils@2.1.4 + - @0xsequence/wallet@2.1.4 + +## 2.1.3 + +### Patch Changes + +- waas: time drift date fix due to strange browser quirk +- Updated dependencies + - @0xsequence/abi@2.1.3 + - @0xsequence/core@2.1.3 + - @0xsequence/migration@2.1.3 + - @0xsequence/network@2.1.3 + - @0xsequence/relayer@2.1.3 + - @0xsequence/sessions@2.1.3 + - @0xsequence/utils@2.1.3 + - @0xsequence/wallet@2.1.3 + +## 2.1.2 + +### Patch Changes + +- provider: export analytics correctly +- Updated dependencies + - @0xsequence/abi@2.1.2 + - @0xsequence/core@2.1.2 + - @0xsequence/migration@2.1.2 + - @0xsequence/network@2.1.2 + - @0xsequence/relayer@2.1.2 + - @0xsequence/sessions@2.1.2 + - @0xsequence/utils@2.1.2 + - @0xsequence/wallet@2.1.2 + +## 2.1.1 + +### Patch Changes + +- Add LAOS chain support +- Updated dependencies + - @0xsequence/abi@2.1.1 + - @0xsequence/core@2.1.1 + - @0xsequence/migration@2.1.1 + - @0xsequence/network@2.1.1 + - @0xsequence/relayer@2.1.1 + - @0xsequence/sessions@2.1.1 + - @0xsequence/utils@2.1.1 + - @0xsequence/wallet@2.1.1 + +## 2.1.0 + +### Minor Changes + +- account: forward project access key when estimating fees and sending transactions + +### Patch Changes + +- sessions: save signatures with reference chain id +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.1.0 + - @0xsequence/core@2.1.0 + - @0xsequence/migration@2.1.0 + - @0xsequence/network@2.1.0 + - @0xsequence/relayer@2.1.0 + - @0xsequence/sessions@2.1.0 + - @0xsequence/utils@2.1.0 + - @0xsequence/wallet@2.1.0 + +## 2.0.26 + +### Patch Changes + +- account: fix chain id comparison +- Updated dependencies + - @0xsequence/abi@2.0.26 + - @0xsequence/core@2.0.26 + - @0xsequence/migration@2.0.26 + - @0xsequence/network@2.0.26 + - @0xsequence/relayer@2.0.26 + - @0xsequence/sessions@2.0.26 + - @0xsequence/utils@2.0.26 + - @0xsequence/wallet@2.0.26 + +## 2.0.25 + +### Patch Changes + +- skale-nebula: deploy gas limit = 10m +- Updated dependencies + - @0xsequence/abi@2.0.25 + - @0xsequence/core@2.0.25 + - @0xsequence/migration@2.0.25 + - @0xsequence/network@2.0.25 + - @0xsequence/relayer@2.0.25 + - @0xsequence/sessions@2.0.25 + - @0xsequence/utils@2.0.25 + - @0xsequence/wallet@2.0.25 + +## 2.0.24 + +### Patch Changes + +- sessions: arweave: configurable gateway url +- waas: use /status to get time drift before sending any intents +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.24 + - @0xsequence/core@2.0.24 + - @0xsequence/migration@2.0.24 + - @0xsequence/network@2.0.24 + - @0xsequence/relayer@2.0.24 + - @0xsequence/sessions@2.0.24 + - @0xsequence/utils@2.0.24 + - @0xsequence/wallet@2.0.24 + +## 2.0.23 + +### Patch Changes + +- Add The Root Network support +- Updated dependencies + - @0xsequence/abi@2.0.23 + - @0xsequence/core@2.0.23 + - @0xsequence/migration@2.0.23 + - @0xsequence/network@2.0.23 + - @0xsequence/relayer@2.0.23 + - @0xsequence/sessions@2.0.23 + - @0xsequence/utils@2.0.23 + - @0xsequence/wallet@2.0.23 + +## 2.0.22 + +### Patch Changes + +- Add SKALE Nebula Mainnet support +- Updated dependencies + - @0xsequence/abi@2.0.22 + - @0xsequence/core@2.0.22 + - @0xsequence/migration@2.0.22 + - @0xsequence/network@2.0.22 + - @0xsequence/relayer@2.0.22 + - @0xsequence/sessions@2.0.22 + - @0xsequence/utils@2.0.22 + - @0xsequence/wallet@2.0.22 + +## 2.0.21 + +### Patch Changes + +- account: add publishWitnessFor +- Updated dependencies + - @0xsequence/abi@2.0.21 + - @0xsequence/core@2.0.21 + - @0xsequence/migration@2.0.21 + - @0xsequence/network@2.0.21 + - @0xsequence/relayer@2.0.21 + - @0xsequence/sessions@2.0.21 + - @0xsequence/utils@2.0.21 + - @0xsequence/wallet@2.0.21 + +## 2.0.20 + +### Patch Changes + +- upgrade deps, and improve waas session status handling +- Updated dependencies + - @0xsequence/abi@2.0.20 + - @0xsequence/core@2.0.20 + - @0xsequence/migration@2.0.20 + - @0xsequence/network@2.0.20 + - @0xsequence/relayer@2.0.20 + - @0xsequence/sessions@2.0.20 + - @0xsequence/utils@2.0.20 + - @0xsequence/wallet@2.0.20 + +## 2.0.19 + +### Patch Changes + +- Add Immutable zkEVM support +- Updated dependencies + - @0xsequence/abi@2.0.19 + - @0xsequence/core@2.0.19 + - @0xsequence/migration@2.0.19 + - @0xsequence/network@2.0.19 + - @0xsequence/relayer@2.0.19 + - @0xsequence/sessions@2.0.19 + - @0xsequence/utils@2.0.19 + - @0xsequence/wallet@2.0.19 + +## 2.0.18 + +### Patch Changes + +- waas: new contractCall transaction type +- sessions: add arweave owner +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.18 + - @0xsequence/core@2.0.18 + - @0xsequence/migration@2.0.18 + - @0xsequence/network@2.0.18 + - @0xsequence/relayer@2.0.18 + - @0xsequence/sessions@2.0.18 + - @0xsequence/utils@2.0.18 + - @0xsequence/wallet@2.0.18 + +## 2.0.17 + +### Patch Changes + +- update waas auth to clear session before signIn +- Updated dependencies + - @0xsequence/abi@2.0.17 + - @0xsequence/core@2.0.17 + - @0xsequence/migration@2.0.17 + - @0xsequence/network@2.0.17 + - @0xsequence/relayer@2.0.17 + - @0xsequence/sessions@2.0.17 + - @0xsequence/utils@2.0.17 + - @0xsequence/wallet@2.0.17 + +## 2.0.16 + +### Patch Changes + +- Removed Astar chains +- Updated dependencies + - @0xsequence/abi@2.0.16 + - @0xsequence/core@2.0.16 + - @0xsequence/migration@2.0.16 + - @0xsequence/network@2.0.16 + - @0xsequence/relayer@2.0.16 + - @0xsequence/sessions@2.0.16 + - @0xsequence/utils@2.0.16 + - @0xsequence/wallet@2.0.16 + +## 2.0.15 + +### Patch Changes + +- indexer: update bindings with token balance additions +- Updated dependencies + - @0xsequence/abi@2.0.15 + - @0xsequence/core@2.0.15 + - @0xsequence/migration@2.0.15 + - @0xsequence/network@2.0.15 + - @0xsequence/relayer@2.0.15 + - @0xsequence/sessions@2.0.15 + - @0xsequence/utils@2.0.15 + - @0xsequence/wallet@2.0.15 + +## 2.0.14 + +### Patch Changes + +- sessions: arweave config reader +- network: add b3 and apechain mainnet configs +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.14 + - @0xsequence/core@2.0.14 + - @0xsequence/migration@2.0.14 + - @0xsequence/network@2.0.14 + - @0xsequence/relayer@2.0.14 + - @0xsequence/sessions@2.0.14 + - @0xsequence/utils@2.0.14 + - @0xsequence/wallet@2.0.14 + +## 2.0.13 + +### Patch Changes + +- network: toy-testnet +- Updated dependencies + - @0xsequence/abi@2.0.13 + - @0xsequence/core@2.0.13 + - @0xsequence/migration@2.0.13 + - @0xsequence/network@2.0.13 + - @0xsequence/relayer@2.0.13 + - @0xsequence/sessions@2.0.13 + - @0xsequence/utils@2.0.13 + - @0xsequence/wallet@2.0.13 + +## 2.0.12 + +### Patch Changes + +- api: update bindings +- Updated dependencies + - @0xsequence/abi@2.0.12 + - @0xsequence/core@2.0.12 + - @0xsequence/migration@2.0.12 + - @0xsequence/network@2.0.12 + - @0xsequence/relayer@2.0.12 + - @0xsequence/sessions@2.0.12 + - @0xsequence/utils@2.0.12 + - @0xsequence/wallet@2.0.12 + +## 2.0.11 + +### Patch Changes + +- waas: intents test fix +- api: update bindings +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.11 + - @0xsequence/core@2.0.11 + - @0xsequence/migration@2.0.11 + - @0xsequence/network@2.0.11 + - @0xsequence/relayer@2.0.11 + - @0xsequence/sessions@2.0.11 + - @0xsequence/utils@2.0.11 + - @0xsequence/wallet@2.0.11 + +## 2.0.10 + +### Patch Changes + +- network: soneium minato testnet +- Updated dependencies + - @0xsequence/abi@2.0.10 + - @0xsequence/core@2.0.10 + - @0xsequence/migration@2.0.10 + - @0xsequence/network@2.0.10 + - @0xsequence/relayer@2.0.10 + - @0xsequence/sessions@2.0.10 + - @0xsequence/utils@2.0.10 + - @0xsequence/wallet@2.0.10 + +## 2.0.9 + +### Patch Changes + +- network: fix SKALE network name +- Updated dependencies + - @0xsequence/abi@2.0.9 + - @0xsequence/core@2.0.9 + - @0xsequence/migration@2.0.9 + - @0xsequence/network@2.0.9 + - @0xsequence/relayer@2.0.9 + - @0xsequence/sessions@2.0.9 + - @0xsequence/utils@2.0.9 + - @0xsequence/wallet@2.0.9 + +## 2.0.8 + +### Patch Changes + +- metadata: update bindings +- Updated dependencies + - @0xsequence/abi@2.0.8 + - @0xsequence/core@2.0.8 + - @0xsequence/migration@2.0.8 + - @0xsequence/network@2.0.8 + - @0xsequence/relayer@2.0.8 + - @0xsequence/sessions@2.0.8 + - @0xsequence/utils@2.0.8 + - @0xsequence/wallet@2.0.8 + +## 2.0.7 + +### Patch Changes + +- wallet request handler fix +- Updated dependencies + - @0xsequence/abi@2.0.7 + - @0xsequence/core@2.0.7 + - @0xsequence/migration@2.0.7 + - @0xsequence/network@2.0.7 + - @0xsequence/relayer@2.0.7 + - @0xsequence/sessions@2.0.7 + - @0xsequence/utils@2.0.7 + - @0xsequence/wallet@2.0.7 + +## 2.0.6 + +### Patch Changes + +- network: matic -> pol +- Updated dependencies + - @0xsequence/abi@2.0.6 + - @0xsequence/core@2.0.6 + - @0xsequence/migration@2.0.6 + - @0xsequence/network@2.0.6 + - @0xsequence/relayer@2.0.6 + - @0xsequence/sessions@2.0.6 + - @0xsequence/utils@2.0.6 + - @0xsequence/wallet@2.0.6 + +## 2.0.5 + +### Patch Changes + +- provider: update databeat to 0.9.2 +- Updated dependencies + - @0xsequence/abi@2.0.5 + - @0xsequence/core@2.0.5 + - @0xsequence/migration@2.0.5 + - @0xsequence/network@2.0.5 + - @0xsequence/relayer@2.0.5 + - @0xsequence/sessions@2.0.5 + - @0xsequence/utils@2.0.5 + - @0xsequence/wallet@2.0.5 + +## 2.0.4 + +### Patch Changes + +- network: add skale-nebula-testnet +- Updated dependencies + - @0xsequence/abi@2.0.4 + - @0xsequence/core@2.0.4 + - @0xsequence/migration@2.0.4 + - @0xsequence/network@2.0.4 + - @0xsequence/relayer@2.0.4 + - @0xsequence/sessions@2.0.4 + - @0xsequence/utils@2.0.4 + - @0xsequence/wallet@2.0.4 + +## 2.0.3 + +### Patch Changes + +- waas: check session status in SequenceWaaS.isSignedIn() +- Updated dependencies + - @0xsequence/abi@2.0.3 + - @0xsequence/core@2.0.3 + - @0xsequence/migration@2.0.3 + - @0xsequence/network@2.0.3 + - @0xsequence/relayer@2.0.3 + - @0xsequence/sessions@2.0.3 + - @0xsequence/utils@2.0.3 + - @0xsequence/wallet@2.0.3 + +## 2.0.2 + +### Patch Changes + +- sessions: property convert serialized bignumber hex value to bigint +- Updated dependencies + - @0xsequence/abi@2.0.2 + - @0xsequence/core@2.0.2 + - @0xsequence/migration@2.0.2 + - @0xsequence/network@2.0.2 + - @0xsequence/relayer@2.0.2 + - @0xsequence/sessions@2.0.2 + - @0xsequence/utils@2.0.2 + - @0xsequence/wallet@2.0.2 + +## 2.0.1 + +### Patch Changes + +- waas: http signature check for authenticator requests +- provider: unwrap legacy json rpc responses +- use json replacer and reviver for bigints +- Updated dependencies +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.1 + - @0xsequence/core@2.0.1 + - @0xsequence/migration@2.0.1 + - @0xsequence/network@2.0.1 + - @0xsequence/relayer@2.0.1 + - @0xsequence/sessions@2.0.1 + - @0xsequence/utils@2.0.1 + - @0xsequence/wallet@2.0.1 + +## 2.0.0 + +### Major Changes + +- ethers v6 + +### Patch Changes + +- Updated dependencies + - @0xsequence/abi@2.0.0 + - @0xsequence/core@2.0.0 + - @0xsequence/migration@2.0.0 + - @0xsequence/network@2.0.0 + - @0xsequence/relayer@2.0.0 + - @0xsequence/sessions@2.0.0 + - @0xsequence/utils@2.0.0 + - @0xsequence/wallet@2.0.0 + +## 1.10.15 + +### Patch Changes + +- utils: extractProjectIdFromAccessKey +- Updated dependencies + - @0xsequence/abi@1.10.15 + - @0xsequence/core@1.10.15 + - @0xsequence/migration@1.10.15 + - @0xsequence/network@1.10.15 + - @0xsequence/relayer@1.10.15 + - @0xsequence/sessions@1.10.15 + - @0xsequence/utils@1.10.15 + - @0xsequence/wallet@1.10.15 + ## 1.10.14 ### Patch Changes diff --git a/packages/account/package.json b/packages/account/package.json index ade5693c5..d8b3a5ddd 100644 --- a/packages/account/package.json +++ b/packages/account/package.json @@ -1,6 +1,6 @@ { "name": "@0xsequence/account", - "version": "1.10.14", + "version": "2.2.14", "description": "tools for migrating sequence wallets to new versions", "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/account", "source": "src/index.ts", @@ -16,6 +16,9 @@ "start:hardhat2": "hardhat node --hostname 0.0.0.0 --port 7048 --config ./hardhat2.config.js", "test:coverage": "nyc pnpm test" }, + "peerDependencies": { + "ethers": ">=6" + }, "dependencies": { "@0xsequence/abi": "workspace:*", "@0xsequence/core": "workspace:*", @@ -24,13 +27,13 @@ "@0xsequence/relayer": "workspace:*", "@0xsequence/sessions": "workspace:*", "@0xsequence/utils": "workspace:*", - "@0xsequence/wallet": "workspace:*", - "ethers": "^5.5.2" + "@0xsequence/wallet": "workspace:*" }, "devDependencies": { "@0xsequence/signhub": "workspace:*", "@0xsequence/tests": "workspace:*", "@istanbuljs/nyc-config-typescript": "^1.0.2", + "ethers": "6.13.4", "nyc": "^15.1.0" }, "files": [ diff --git a/packages/account/src/account.ts b/packages/account/src/account.ts index 3243842eb..0a486c473 100644 --- a/packages/account/src/account.ts +++ b/packages/account/src/account.ts @@ -1,14 +1,13 @@ import { walletContracts } from '@0xsequence/abi' import { commons, universal } from '@0xsequence/core' -import { WalletSignRequestMetadata } from '@0xsequence/core/src/commons' import { migrator, defaults, version } from '@0xsequence/migration' import { ChainId, NetworkConfig } from '@0xsequence/network' import { FeeOption, FeeQuote, isRelayer, Relayer, RpcRelayer } from '@0xsequence/relayer' import { tracker } from '@0xsequence/sessions' import { SignatureOrchestrator } from '@0xsequence/signhub' -import { encodeTypedDataDigest, getEthersConnectionInfo } from '@0xsequence/utils' +import { encodeTypedDataDigest, getFetchRequest } from '@0xsequence/utils' import { Wallet } from '@0xsequence/wallet' -import { ethers, TypedDataDomain, TypedDataField } from 'ethers' +import { ethers } from 'ethers' import { AccountSigner, AccountSignerOptions } from './signer' export type AccountStatus = { @@ -82,11 +81,11 @@ class Chain0Reader implements commons.reader.Reader { return undefined } - async nonce(_wallet: string, _space: ethers.BigNumberish): Promise { - return ethers.constants.Zero + async nonce(_wallet: string, _space: ethers.BigNumberish): Promise { + return 0n } - async isValidSignature(_wallet: string, _digest: ethers.utils.BytesLike, _signature: ethers.utils.BytesLike): Promise { + async isValidSignature(_wallet: string, _digest: ethers.BytesLike, _signature: ethers.BytesLike): Promise { throw new Error('Method not supported.') } } @@ -108,7 +107,7 @@ export class Account { private projectAccessKey?: string constructor(options: AccountOptions) { - this.address = ethers.utils.getAddress(options.address) + this.address = ethers.getAddress(options.address) this.contexts = options.contexts this.tracker = options.tracker @@ -178,26 +177,32 @@ export class Account { } network(chainId: ethers.BigNumberish): NetworkConfig { - const tcid = ethers.BigNumber.from(chainId) - const found = this.networks.find(n => tcid.eq(n.chainId)) + const tcid = BigInt(chainId) + const found = this.networks.find(n => tcid === BigInt(n.chainId)) if (!found) throw new Error(`Network not found for chainId ${chainId}`) return found } - providerFor(chainId: ethers.BigNumberish): ethers.providers.Provider { + providerFor(chainId: ethers.BigNumberish): ethers.Provider { const found = this.network(chainId) - if (!found.provider && !found.rpcUrl) throw new Error(`Provider not found for chainId ${chainId}`) + if (!found.provider && !found.rpcUrl) { + throw new Error(`Provider not found for chainId ${chainId}`) + } + + const network = new ethers.Network(found.name, found.chainId) + return ( found.provider || - new ethers.providers.StaticJsonRpcProvider(getEthersConnectionInfo(found.rpcUrl, this.projectAccessKey, this.jwt), { - name: '', - chainId: ethers.BigNumber.from(chainId).toNumber() + new ethers.JsonRpcProvider(getFetchRequest(found.rpcUrl, this.projectAccessKey, this.jwt), network, { + staticNetwork: network }) ) } reader(chainId: ethers.BigNumberish): commons.reader.Reader { - if (ethers.constants.Zero.eq(chainId)) return new Chain0Reader() + if (BigInt(chainId) === 0n) { + return new Chain0Reader() + } // TODO: Networks should be able to provide a reader directly // and we should default to the on-chain reader @@ -210,9 +215,9 @@ export class Account { if (isRelayer(found.relayer)) return found.relayer return new RpcRelayer({ ...found.relayer, - // If there's an access key, we don't pass the JWT, because browser-side usage of this code mandates an access key - // and passing a JWT causes a CORS error. - ...(this.projectAccessKey ? { projectAccessKey: this.projectAccessKey } : { jwtAuth: this.jwt }) + // we pass both projectAccessKey and jwtAuth because the projectAccessKey is + // used either for unauthenticated access, or gas sponsorship even if the jwtAuth is provided, + ...{ projectAccessKey: this.projectAccessKey, jwtAuth: this.jwt } }) } @@ -241,7 +246,7 @@ export class Account { config: commons.config.Config, coders: typeof this.coders ): Wallet { - const isNetworkZero = ethers.constants.Zero.eq(chainId) + const isNetworkZero = BigInt(chainId) === 0n return new Wallet({ config, context, @@ -397,13 +402,46 @@ export class Account { status: AccountStatus, chainId: ethers.BigNumberish ): Promise { + txs = Array.isArray(txs) ? txs : [txs] // if onchain wallet config is not up to date // then we should append an extra transaction that updates it // to the latest "lazy" state if (status.onChain.imageHash !== status.imageHash) { const wallet = this.walletForStatus(chainId, status) const updateConfig = await wallet.buildUpdateConfigurationTransaction(status.config) - return [Array.isArray(txs) ? txs : [txs], updateConfig.transactions].flat() + txs = [...txs, ...updateConfig.transactions] + } + + // On immutable chains, we add the WalletProxyHook + const { proxyImplementationHook } = this.contexts[status.config.version] + if (proxyImplementationHook && (chainId === ChainId.IMMUTABLE_ZKEVM || chainId === ChainId.IMMUTABLE_ZKEVM_TESTNET)) { + const provider = this.providerFor(chainId) + if (provider) { + const hook = new ethers.Contract(this.address, walletContracts.walletProxyHook.abi, provider) + let implementation + try { + implementation = await hook.PROXY_getImplementation() + } catch (e) { + // Handle below + console.log('Error getting implementation address', e) + } + if (!implementation || implementation === ethers.ZeroAddress) { + console.log('Adding wallet proxy hook') + const hooksInterface = new ethers.Interface(walletContracts.moduleHooks.abi) + const tx: commons.transaction.Transaction = { + to: this.address, + data: hooksInterface.encodeFunctionData(hooksInterface.getFunction('addHook')!, [ + '0x90611127', + proxyImplementationHook + ]), + gasLimit: 50000, // Expected ~28k gas. Buffer added + delegateCall: false, + revertOnError: false, + value: 0 + } + txs = [tx, ...txs] + } + } } return txs @@ -485,8 +523,34 @@ export class Account { return coder.trim(chainedSignature) } + async publishWitnessFor(signers: string[], chainId: ethers.BigNumberish = 0): Promise { + const digest = ethers.id(`This is a Sequence account woo! ${Date.now()}`) + + const status = await this.status(chainId) + const allOfAll = this.coders.config.fromSimple({ + threshold: signers.length, + checkpoint: 0, + signers: signers.map(s => ({ + address: s, + weight: 1 + })) + }) + + const wallet = this.walletFor(chainId, status.original.context, allOfAll, this.coders) + const signature = await wallet.signDigest(digest) + + const decoded = this.coders.signature.decode(signature) + const signatures = this.coders.signature.signaturesOfDecoded(decoded) + + if (signatures.length === 0) { + throw new Error('No signatures found') + } + + return this.tracker.saveWitnesses({ wallet: this.address, digest, chainId, signatures }) + } + async publishWitness(): Promise { - const digest = ethers.utils.keccak256(ethers.utils.toUtf8Bytes(`This is a Sequence account woo! ${Date.now()}`)) + const digest = ethers.id(`This is a Sequence account woo! ${Date.now()}`) const signature = await this.signDigest(digest, 0, false) const decoded = this.coders.signature.decode(signature) const signatures = this.coders.signature.signaturesOfDecoded(decoded) @@ -506,7 +570,7 @@ export class Account { // So we ignore the state on "chain zero" and instead use one of the states of the networks // wallet-webapp should ensure the wallet is as migrated as possible, trying to mimic // the behaviour of being migrated on all chains - const chainRef = ethers.constants.Zero.eq(chainId) ? this.networks[0].chainId : chainId + const chainRef = BigInt(chainId) === 0n ? this.networks[0].chainId : chainId const status = await this.status(chainRef) this.mustBeFullyMigrated(status) @@ -541,8 +605,12 @@ export class Account { } buildOnChainSignature(digest: ethers.BytesLike): { bundle: commons.transaction.TransactionBundle; signature: string } { - const subdigest = commons.signature.subdigestOf({ digest: ethers.utils.hexlify(digest), chainId: 0, address: this.address }) - const hexSubdigest = ethers.utils.hexlify(subdigest) + const subdigest = commons.signature.subdigestOf({ + digest: ethers.hexlify(digest), + chainId: 0, + address: this.address + }) + const hexSubdigest = ethers.hexlify(subdigest) const config = this.coders.config.fromSimple({ // Threshold *only* needs to be > 0, this is not a magic number // we only use 2 ** 15 because it may lead to lower gas costs in some chains @@ -552,7 +620,7 @@ export class Account { subdigests: [hexSubdigest] }) - const walletInterface = new ethers.utils.Interface(walletContracts.mainModule.abi) + const walletInterface = new ethers.Interface(walletContracts.mainModule.abi) const bundle: commons.transaction.TransactionBundle = { entrypoint: this.address, transactions: [ @@ -590,12 +658,12 @@ export class Account { throw new Error('Cannot build EIP-6492 signature without bootstrap transactions') } - const encoded = ethers.utils.defaultAbiCoder.encode( + const encoded = ethers.AbiCoder.defaultAbiCoder().encode( ['address', 'bytes', 'bytes'], [bootstrapBundle.entrypoint, commons.transaction.encodeBundleExecData(bootstrapBundle), signature] ) - return ethers.utils.solidityPack(['bytes', 'bytes32'], [encoded, commons.EIP6492.EIP_6492_SUFFIX]) + return ethers.solidityPacked(['bytes', 'bytes32'], [encoded, commons.EIP6492.EIP_6492_SUFFIX]) } async editConfig(changes: { @@ -606,7 +674,7 @@ export class Account { const currentConfig = await this.status(0).then(s => s.config) const newConfig = this.coders.config.editConfig(currentConfig, { ...changes, - checkpoint: this.coders.config.checkpointOf(currentConfig).add(1) + checkpoint: this.coders.config.checkpointOf(currentConfig) + 1n }) return this.updateConfig(newConfig) @@ -630,7 +698,8 @@ export class Account { await this.tracker.savePresignedConfiguration({ wallet: this.address, nextConfig: config, - signature + signature, + referenceChainId: 1 }) // safety check, tracker should have a reverse lookup for the imageHash @@ -665,13 +734,19 @@ export class Account { // Add wallet deployment if needed if (!status.onChain.deployed) { + let gasLimit: bigint | undefined + switch (BigInt(chainId)) { + case BigInt(ChainId.SKALE_NEBULA): + gasLimit = 10000000n + break + } + // Wallet deployment will vary depending on the version // so we need to use the context to get the correct deployment - const deployTransaction = Wallet.buildDeployTransaction(status.original.context, status.original.imageHash) + const deployTransaction = Wallet.buildDeployTransaction(status.original.context, status.original.imageHash, gasLimit) transactions.push(...deployTransaction.transactions) } - const len = transactions.length // Get pending migrations transactions.push( @@ -718,7 +793,7 @@ export class Account { chainId: ethers.BigNumberish, cantValidateBehavior: 'ignore' | 'eip6492' | 'throw' = 'ignore' ): Promise { - return this.signDigest(ethers.utils.keccak256(message), chainId, true, cantValidateBehavior) + return this.signDigest(ethers.keccak256(message), chainId, true, cantValidateBehavior) } async signTransactions( @@ -735,7 +810,7 @@ export class Account { const wallet = this.walletForStatus(chainId, status) - const metadata: WalletSignRequestMetadata = { + const metadata: commons.WalletSignRequestMetadata = { address: this.address, digest: '', // Set in wallet.signTransactions chainId, @@ -839,10 +914,11 @@ export class Account { chainId: ethers.BigNumberish, quote?: FeeQuote, pstatus?: AccountStatus, - callback?: (bundle: commons.transaction.IntendedTransactionBundle) => void - ): Promise { + callback?: (bundle: commons.transaction.IntendedTransactionBundle) => void, + projectAccessKey?: string + ): Promise { if (!Array.isArray(signedBundle)) { - return this.sendSignedTransactions([signedBundle], chainId, quote, pstatus, callback) + return this.sendSignedTransactions([signedBundle], chainId, quote, pstatus, callback, projectAccessKey) } const status = pstatus || (await this.status(chainId)) this.mustBeFullyMigrated(status) @@ -850,7 +926,7 @@ export class Account { const decoratedBundle = await this.decorateTransactions(signedBundle, status, chainId) callback?.(decoratedBundle) - return this.relayer(chainId).relay(decoratedBundle, quote) + return this.relayer(chainId).relay(decoratedBundle, quote, undefined, projectAccessKey) } async fillGasLimits( @@ -869,6 +945,7 @@ export class Account { status?: AccountStatus, options?: { simulate?: boolean + projectAccessKey?: string } ): Promise<{ options: FeeOption[] @@ -887,7 +964,7 @@ export class Account { const stubSignature = wallet.coders.config.buildStubSignature(wallet.config, stubSignatureOverrides) // Now we can decorate the transactions as always, but we need to manually build the signed bundle - const intentId = ethers.utils.hexlify(ethers.utils.randomBytes(32)) + const intentId = ethers.hexlify(ethers.randomBytes(32)) const signedBundle: commons.transaction.SignedTransactionBundle = { chainId, intent: { @@ -911,12 +988,14 @@ export class Account { chainId: ethers.BigNumberish stubSignatureOverrides: Map simulateForFeeOptions?: boolean + projectAccessKey?: string }): Promise { const status = await this.status(args.chainId) const transactions = await this.fillGasLimits(args.txs, args.chainId, status) const gasRefundQuote = await this.gasRefundQuotes(transactions, args.chainId, args.stubSignatureOverrides, status, { - simulate: args.simulateForFeeOptions + simulate: args.simulateForFeeOptions, + projectAccessKey: args.projectAccessKey }) const flatDecorated = commons.transaction.unwind(this.address, gasRefundQuote.decorated.transactions) @@ -937,8 +1016,9 @@ export class Account { options?: { nonceSpace?: ethers.BigNumberish serial?: boolean + projectAccessKey?: string } - ): Promise { + ): Promise { const status = await this.status(chainId) const predecorated = skipPreDecorate ? txs : await this.predecorateTransactions(txs, status, chainId) @@ -953,12 +1033,12 @@ export class Account { } bundles.push(...childBundles.filter(b => b.transactions.length > 0)) - return this.sendSignedTransactions(bundles, chainId, quote, undefined, callback) + return this.sendSignedTransactions(bundles, chainId, quote, undefined, callback, options?.projectAccessKey) } async signTypedData( - domain: TypedDataDomain, - types: Record>, + domain: ethers.TypedDataDomain, + types: Record>, message: Record, chainId: ethers.BigNumberish, cantValidateBehavior: 'ignore' | 'eip6492' | 'throw' = 'ignore' diff --git a/packages/account/src/orchestrator/wrapper.ts b/packages/account/src/orchestrator/wrapper.ts index ab9e16c3f..9efa34af1 100644 --- a/packages/account/src/orchestrator/wrapper.ts +++ b/packages/account/src/orchestrator/wrapper.ts @@ -15,10 +15,10 @@ export class AccountOrchestratorWrapper implements signers.SapientSigner { return this.account.address } - getChainIdFromMetadata(metadata: object): ethers.BigNumber { + getChainIdFromMetadata(metadata: object): bigint { try { const { chainId } = metadata as MetadataWithChainId - return ethers.BigNumber.from(chainId) + return BigInt(chainId) } catch (err) { // Invalid metadata object throw new Error('AccountOrchestratorWrapper only supports metadata with chain id') @@ -46,7 +46,7 @@ export class AccountOrchestratorWrapper implements signers.SapientSigner { return this.account.decorateTransactions(bundle, status) } - sign(message: ethers.utils.BytesLike, metadata: object): Promise { + sign(message: ethers.BytesLike, metadata: object): Promise { if (!commons.isWalletSignRequestMetadata(metadata)) { throw new Error('AccountOrchestratorWrapper only supports wallet metadata requests') } @@ -63,7 +63,7 @@ export class AccountOrchestratorWrapper implements signers.SapientSigner { notifyStatusChange(_i: string, _s: Status, _m: object): void {} - suffix(): ethers.utils.BytesLike { - return [3] + suffix(): ethers.BytesLike { + return new Uint8Array([3]) } } diff --git a/packages/account/src/signer.ts b/packages/account/src/signer.ts index 770752e29..56b4b16ab 100644 --- a/packages/account/src/signer.ts +++ b/packages/account/src/signer.ts @@ -3,14 +3,14 @@ import { Account } from './account' import { ethers } from 'ethers' import { commons } from '@0xsequence/core' import { FeeOption, proto } from '@0xsequence/relayer' -import { isDeferrable } from './utils' +import { toHexString } from '@0xsequence/utils' export type AccountSignerOptions = { nonceSpace?: ethers.BigNumberish cantValidateBehavior?: 'ignore' | 'eip6492' | 'throw' stubSignatureOverrides?: Map selectFee?: ( - txs: ethers.utils.Deferrable | commons.transaction.Transactionish, + txs: ethers.TransactionRequest | commons.transaction.Transactionish, options: FeeOption[] ) => Promise } @@ -18,7 +18,7 @@ export type AccountSignerOptions = { function encodeGasRefundTransaction(option?: FeeOption) { if (!option) return [] - const value = ethers.BigNumber.from(option.value) + const value = BigInt(option.value) switch (option.token.type) { case proto.FeeTokenType.UNKNOWN: @@ -28,8 +28,8 @@ function encodeGasRefundTransaction(option?: FeeOption) { revertOnError: true, gasLimit: option.gasLimit, to: option.to, - value: value.toHexString(), - data: [] + value: toHexString(value), + data: '0x' } ] @@ -45,7 +45,7 @@ function encodeGasRefundTransaction(option?: FeeOption) { gasLimit: option.gasLimit, to: option.token.contractAddress, value: 0, - data: new ethers.utils.Interface([ + data: new ethers.Interface([ { constant: false, inputs: [{ type: 'address' }, { type: 'uint256' }], @@ -53,7 +53,7 @@ function encodeGasRefundTransaction(option?: FeeOption) { outputs: [], type: 'function' } - ]).encodeFunctionData('transfer', [option.to, value.toHexString()]) + ]).encodeFunctionData('transfer', [option.to, toHexString(value)]) } ] @@ -62,9 +62,7 @@ function encodeGasRefundTransaction(option?: FeeOption) { } } -export class AccountSigner implements ethers.Signer { - public readonly _isSigner = true - +export class AccountSigner implements ethers.AbstractSigner { constructor( public account: Account, public chainId: ChainId, @@ -79,14 +77,19 @@ export class AccountSigner implements ethers.Signer { return this.account.address } - signMessage(message: string | ethers.utils.Bytes): Promise { + signMessage(message: string | ethers.BytesLike): Promise { return this.account.signMessage(message, this.chainId, this.options?.cantValidateBehavior ?? 'throw') } - private async defaultSelectFee( - _txs: ethers.utils.Deferrable | commons.transaction.Transactionish, - options: FeeOption[] - ): Promise { + signTypedData( + domain: ethers.TypedDataDomain, + types: Record>, + value: Record + ): Promise { + return this.account.signTypedData(domain, types, value, this.chainId, this.options?.cantValidateBehavior ?? 'throw') + } + + private async defaultSelectFee(_txs: commons.transaction.Transactionish, options: FeeOption[]): Promise { // If no options, return undefined if (options.length === 0) return undefined @@ -106,14 +109,14 @@ export class AccountSigner implements ethers.Signer { if (option.token.type === proto.FeeTokenType.UNKNOWN) { // Native token const balance = await this.getBalance() - if (balance.gte(ethers.BigNumber.from(option.value))) { + if (balance >= BigInt(option.value)) { return option } } else if (option.token.contractAddress && option.token.type === proto.FeeTokenType.ERC20_TOKEN) { // ERC20 token const token = new ethers.Contract(option.token.contractAddress, balanceOfAbi, this.provider) const balance = await token.balanceOf(this.account.address) - if (balance.gte(ethers.BigNumber.from(option.value))) { + if (balance >= BigInt(option.value)) { return option } } else { @@ -125,15 +128,11 @@ export class AccountSigner implements ethers.Signer { } async sendTransaction( - txsPromise: ethers.utils.Deferrable | commons.transaction.Transactionish, + txs: commons.transaction.Transactionish, options?: { simulateForFeeOptions?: boolean } - ): Promise { - const txs = isDeferrable(txsPromise) - ? await ethers.utils.resolveProperties(txsPromise as ethers.utils.Deferrable) - : txsPromise - + ): Promise { const prepare = await this.account.prepareTransactions({ txs, chainId: this.chainId, @@ -157,18 +156,15 @@ export class AccountSigner implements ethers.Signer { nonceSpace: this.options.nonceSpace } : undefined - ) as Promise // Will always have a transaction response + ) as Promise // Will always have a transaction response } - getBalance(blockTag?: ethers.providers.BlockTag | undefined): Promise { + getBalance(blockTag?: ethers.BlockTag | undefined): Promise { return this.provider.getBalance(this.account.address, blockTag) } - call( - transaction: ethers.utils.Deferrable, - blockTag?: ethers.providers.BlockTag | undefined - ): Promise { - return this.provider.call(transaction, blockTag) + call(transaction: ethers.TransactionRequest, blockTag?: ethers.BlockTag): Promise { + return this.provider.call({ ...transaction, blockTag }) } async resolveName(name: string): Promise { @@ -177,43 +173,47 @@ export class AccountSigner implements ethers.Signer { return res } - connect(_provider: ethers.providers.Provider): ethers.Signer { + connect(_provider: ethers.Provider): ethers.Signer { throw new Error('Method not implemented.') } - signTransaction(transaction: ethers.utils.Deferrable): Promise { + signTransaction(transaction: ethers.TransactionRequest): Promise { throw new Error('Method not implemented.') } - getTransactionCount(blockTag?: ethers.providers.BlockTag | undefined): Promise { + getTransactionCount(blockTag?: ethers.BlockTag | undefined): Promise { throw new Error('Method not implemented.') } - estimateGas(transaction: ethers.utils.Deferrable): Promise { + estimateGas(transaction: ethers.TransactionRequest): Promise { throw new Error('Method not implemented.') } getChainId(): Promise { - return Promise.resolve(ethers.BigNumber.from(this.chainId).toNumber()) + return Promise.resolve(Number(this.chainId)) + } + + getGasPrice(): Promise { + throw new Error('Method not implemented.') + } + + getFeeData(): Promise { + throw new Error('Method not implemented.') } - getGasPrice(): Promise { + getNonce(blockTag?: ethers.BlockTag): Promise { throw new Error('Method not implemented.') } - getFeeData(): Promise { + populateCall(tx: ethers.TransactionRequest): Promise> { throw new Error('Method not implemented.') } - checkTransaction( - transaction: ethers.utils.Deferrable - ): ethers.utils.Deferrable { + checkTransaction(transaction: ethers.TransactionRequest): ethers.TransactionRequest { throw new Error('Method not implemented.') } - populateTransaction( - transaction: ethers.utils.Deferrable - ): Promise { + async populateTransaction(tx: ethers.TransactionRequest): Promise> { throw new Error('Method not implemented.') } diff --git a/packages/account/src/utils.ts b/packages/account/src/utils.ts deleted file mode 100644 index b8d715ec6..000000000 --- a/packages/account/src/utils.ts +++ /dev/null @@ -1,14 +0,0 @@ -import { ethers } from 'ethers' - -function isPromise(value: any): value is Promise { - return !!value && typeof value.then === 'function' -} - -export function isDeferrable(value: any): value is ethers.utils.Deferrable { - // The value is deferrable if any of the properties is a Promises - if (typeof value === 'object') { - return Object.keys(value).some(key => isPromise(value[key])) - } - - return false -} diff --git a/packages/account/tests/account.spec.ts b/packages/account/tests/account.spec.ts index 056e22686..0aa96ff8e 100644 --- a/packages/account/tests/account.spec.ts +++ b/packages/account/tests/account.spec.ts @@ -20,8 +20,8 @@ const { expect } = chai.use(chaiAsPromised) const deterministic = false describe('Account', () => { - let provider1: ethers.providers.JsonRpcProvider - let provider2: ethers.providers.JsonRpcProvider + let provider1: ethers.BrowserProvider + let provider2: ethers.JsonRpcProvider let signer1: ethers.Signer let signer2: ethers.Signer @@ -89,14 +89,14 @@ describe('Account', () => { } before(async () => { - provider1 = new ethers.providers.Web3Provider(hardhat.network.provider as any) - provider2 = new ethers.providers.JsonRpcProvider('http://127.0.0.1:7048') + provider1 = new ethers.BrowserProvider(hardhat.network.provider as any, undefined, { cacheTimeout: -1 }) + provider2 = new ethers.JsonRpcProvider('http://127.0.0.1:7048', undefined, { cacheTimeout: -1 }) // TODO: Implement migrations on local config tracker tracker = new trackers.local.LocalConfigTracker(provider1) - signer1 = provider1.getSigner() - signer2 = provider2.getSigner() + signer1 = await provider1.getSigner() + signer2 = await provider2.getSigner() networks = [ { @@ -279,12 +279,12 @@ describe('Account', () => { await account.doBootstrap(networks[0].chainId) - const msg = ethers.utils.toUtf8Bytes('Hello World') + const msg = ethers.toUtf8Bytes('Hello World') const sig = await account.signMessage(msg, networks[0].chainId) const valid = await commons.EIP1271.isValidEIP1271Signature( account.address, - ethers.utils.keccak256(msg), + ethers.keccak256(msg), sig, networks[0].provider! ) @@ -295,12 +295,12 @@ describe('Account', () => { it('Should sign and validate a message with nested account', async () => { const { accountOuter } = await createNestedAccount('sign and validate nested') - const msg = ethers.utils.toUtf8Bytes('Hello World') + const msg = ethers.toUtf8Bytes('Hello World') const sig = await accountOuter.signMessage(msg, networks[0].chainId) const valid = await commons.EIP1271.isValidEIP1271Signature( accountOuter.address, - ethers.utils.keccak256(msg), + ethers.keccak256(msg), sig, networks[0].provider! ) @@ -366,10 +366,10 @@ describe('Account', () => { orchestrator: new Orchestrator([signer]) }) - const msg = ethers.utils.toUtf8Bytes('Hello World') + const msg = ethers.toUtf8Bytes('Hello World') const sig = await account.signMessage(msg, networks[0].chainId, 'eip6492') - const valid = await account.reader(networks[0].chainId).isValidSignature(account.address, ethers.utils.keccak256(msg), sig) + const valid = await account.reader(networks[0].chainId).isValidSignature(account.address, ethers.keccak256(msg), sig) expect(valid).to.be.true }) @@ -377,12 +377,12 @@ describe('Account', () => { it('Should sign and validate a message without being deployed with nested account', async () => { const { accountOuter } = await createNestedAccount('sign and validate nested undeployed', true, false) - const msg = ethers.utils.toUtf8Bytes('Hello World') + const msg = ethers.toUtf8Bytes('Hello World') const sig = await accountOuter.signMessage(msg, networks[0].chainId, 'eip6492') const valid = await accountOuter .reader(networks[0].chainId) - .isValidSignature(accountOuter.address, ethers.utils.keccak256(msg), sig) + .isValidSignature(accountOuter.address, ethers.keccak256(msg), sig) expect(valid).to.be.true }) @@ -418,12 +418,12 @@ describe('Account', () => { }) await accountOuter.doBootstrap(networks[0].chainId) - const msg = ethers.utils.toUtf8Bytes('Hello World') + const msg = ethers.toUtf8Bytes('Hello World') const sig = await accountOuter.signMessage(msg, networks[0].chainId) const valid = await accountOuter .reader(networks[0].chainId) - .isValidSignature(accountOuter.address, ethers.utils.keccak256(msg), sig) + .isValidSignature(accountOuter.address, ethers.keccak256(msg), sig) expect(valid).to.be.true }) @@ -442,7 +442,7 @@ describe('Account', () => { orchestrator: new Orchestrator([signer]) }) - const msg = ethers.utils.toUtf8Bytes('Hello World') + const msg = ethers.toUtf8Bytes('Hello World') const sig = account.signMessage(msg, networks[0].chainId, 'throw') expect(sig).to.be.rejected @@ -451,7 +451,7 @@ describe('Account', () => { it('Should refuse to sign when not deployed (nested)', async () => { const { accountOuter } = await createNestedAccount('refuse to sign undeployed', false, false) - const msg = ethers.utils.toUtf8Bytes('Hello World') + const msg = ethers.toUtf8Bytes('Hello World') const sig = accountOuter.signMessage(msg, networks[0].chainId, 'eip6492') // Note EIP-6492 throws when nested not deployed expect(sig).to.be.rejected @@ -485,7 +485,7 @@ describe('Account', () => { const simpleConfig2 = { threshold: 4, - checkpoint: await account.status(0).then(s => ethers.BigNumber.from(s.checkpoint).add(1)), + checkpoint: await account.status(0).then(s => BigInt(s.checkpoint) + 1n), signers: [ { address: signer2a.address, @@ -564,7 +564,7 @@ describe('Account', () => { }) it('Should sign a message', async () => { - const msg = ethers.utils.toUtf8Bytes('Hello World') + const msg = ethers.toUtf8Bytes('Hello World') const sig = await account.signMessage(msg, networks[0].chainId) const canOnchainValidate = await account.status(networks[0].chainId).then(s => s.canOnchainValidate) @@ -573,7 +573,7 @@ describe('Account', () => { const valid = await commons.EIP1271.isValidEIP1271Signature( account.address, - ethers.utils.keccak256(msg), + ethers.keccak256(msg), sig, networks[0].provider! ) @@ -618,7 +618,7 @@ describe('Account', () => { }) it('Should sign a message', async () => { - const msg = ethers.utils.toUtf8Bytes('Hello World') + const msg = ethers.toUtf8Bytes('Hello World') const sig = await account.signMessage(msg, networks[0].chainId) const canOnchainValidate = await account.status(networks[0].chainId).then(s => s.canOnchainValidate) @@ -627,7 +627,7 @@ describe('Account', () => { const valid = await commons.EIP1271.isValidEIP1271Signature( account.address, - ethers.utils.keccak256(msg), + ethers.keccak256(msg), sig, networks[0].provider! ) @@ -651,7 +651,7 @@ describe('Account', () => { const simpleConfig3 = { threshold: 5, - checkpoint: await account.status(0).then(s => ethers.BigNumber.from(s.checkpoint).add(1)), + checkpoint: await account.status(0).then(s => BigInt(s.checkpoint) + 1n), signers: [ { address: signer3a.address, @@ -693,7 +693,7 @@ describe('Account', () => { }) it('Should sign a message', async () => { - const msg = ethers.utils.toUtf8Bytes('Hello World') + const msg = ethers.toUtf8Bytes('Hello World') const sig = await account.signMessage(msg, networks[0].chainId) const canOnchainValidate = await account.status(networks[0].chainId).then(s => s.canOnchainValidate) @@ -705,7 +705,7 @@ describe('Account', () => { const valid = await commons.EIP1271.isValidEIP1271Signature( account.address, - ethers.utils.keccak256(msg), + ethers.keccak256(msg), sig, networks[0].provider! ) @@ -742,7 +742,7 @@ describe('Account', () => { const simpleConfig2 = { threshold: 6, - checkpoint: await account.status(0).then(s => ethers.BigNumber.from(s.checkpoint).add(1)), + checkpoint: await account.status(0).then(s => BigInt(s.checkpoint) + 1n), signers: [ { address: signer2a.address, @@ -789,7 +789,7 @@ describe('Account', () => { // Old account may be an address that's not even deployed const signer1 = randomWallet('Should migrate undeployed account') - const simpleConfig = { + const simpleConfig: commons.config.SimpleConfig = { threshold: 1, checkpoint: 0, signers: [ @@ -945,6 +945,7 @@ describe('Account', () => { const tx1 = await account.sendTransaction([defaultTx], networks[0].chainId) expect(tx1).to.not.be.undefined + await tx1!.wait() const status1b = await account.status(networks[0].chainId) expect(status1b.fullyMigrated).to.be.true @@ -1247,6 +1248,7 @@ describe('Account', () => { beforeEach(async () => { // Old account may be an address that's not even deployed const signer1 = randomWallet( + // @ts-ignore 'Signing messages - After migrating' + account?.address ?? '' // Append prev address to entropy to avoid collisions ) @@ -1276,81 +1278,79 @@ describe('Account', () => { }) it('Should validate a message signed by undeployed migrated wallet', async () => { - const msg = ethers.utils.toUtf8Bytes('I like that you are reading our tests') + const msg = ethers.toUtf8Bytes('I like that you are reading our tests') const sig = await account.signMessage(msg, networks[0].chainId, 'eip6492') - const valid = await account - .reader(networks[0].chainId) - .isValidSignature(account.address, ethers.utils.keccak256(msg), sig) + const valid = await account.reader(networks[0].chainId).isValidSignature(account.address, ethers.keccak256(msg), sig) expect(valid).to.be.true }) it('Should reject a message signed by undeployed migrated wallet (if set the throw)', async () => { - const msg = ethers.utils.toUtf8Bytes('I do not know what to write here anymore') + const msg = ethers.toUtf8Bytes('I do not know what to write here anymore') const sig = account.signMessage(msg, networks[0].chainId, 'throw') await expect(sig).to.be.rejected }) it('Should return an invalid signature by undeployed migrated wallet (if set to ignore)', async () => { - const msg = ethers.utils.toUtf8Bytes('Sending a hug') + const msg = ethers.toUtf8Bytes('Sending a hug') const sig = await account.signMessage(msg, networks[0].chainId, 'ignore') - const valid = await account - .reader(networks[0].chainId) - .isValidSignature(account.address, ethers.utils.keccak256(msg), sig) + const valid = await account.reader(networks[0].chainId).isValidSignature(account.address, ethers.keccak256(msg), sig) expect(valid).to.be.false }) it('Should validate a message signed by deployed migrated wallet (deployed with v1)', async () => { const deployTx = Wallet.buildDeployTransaction(contexts[1], imageHash) - await signer1.sendTransaction({ - to: deployTx.entrypoint, - data: commons.transaction.encodeBundleExecData(deployTx) - }) + await signer1 + .sendTransaction({ + to: deployTx.entrypoint, + data: commons.transaction.encodeBundleExecData(deployTx) + }) + .then(t => t.wait()) - expect(await networks[0].provider!.getCode(account.address).then(c => ethers.utils.arrayify(c).length)).to.not.equal(0) + expect(await networks[0].provider!.getCode(account.address).then(c => ethers.getBytes(c).length)).to.not.equal(0) - const msg = ethers.utils.toUtf8Bytes('Everything seems to be working fine so far') + const msg = ethers.toUtf8Bytes('Everything seems to be working fine so far') const sig = await account.signMessage(msg, networks[0].chainId, 'eip6492') - const valid = await account - .reader(networks[0].chainId) - .isValidSignature(account.address, ethers.utils.keccak256(msg), sig) + const valid = await account.reader(networks[0].chainId).isValidSignature(account.address, ethers.keccak256(msg), sig) expect(valid).to.be.true }) it('Should fail to sign a message signed by deployed migrated wallet (deployed with v1) if throw', async () => { const deployTx = Wallet.buildDeployTransaction(contexts[1], imageHash) - await signer1.sendTransaction({ - to: deployTx.entrypoint, - data: commons.transaction.encodeBundleExecData(deployTx) - }) + await signer1 + .sendTransaction({ + to: deployTx.entrypoint, + data: commons.transaction.encodeBundleExecData(deployTx) + }) + .then(tx => tx.wait()) - expect(await networks[0].provider!.getCode(account.address).then(c => ethers.utils.arrayify(c).length)).to.not.equal(0) + expect(await networks[0].provider!.getCode(account.address).then(c => ethers.getBytes(c).length)).to.not.equal(0) - const msg = ethers.utils.toUtf8Bytes('Everything seems to be working fine so far') + const msg = ethers.toUtf8Bytes('Everything seems to be working fine so far') const sig = account.signMessage(msg, networks[0].chainId, 'throw') expect(sig).to.be.rejected }) it('Should return an invalid signature by deployed migrated wallet (deployed with v1) if ignore', async () => { const deployTx = Wallet.buildDeployTransaction(contexts[1], imageHash) - await signer1.sendTransaction({ - to: deployTx.entrypoint, - data: commons.transaction.encodeBundleExecData(deployTx) - }) + await signer1 + .sendTransaction({ + to: deployTx.entrypoint, + data: commons.transaction.encodeBundleExecData(deployTx) + }) + .then(tx => tx.wait()) - expect(await networks[0].provider!.getCode(account.address).then(c => ethers.utils.arrayify(c).length)).to.not.equal(0) + expect(await networks[0].provider!.getCode(account.address).then(c => ethers.getBytes(c).length)).to.not.equal(0) - const msg = ethers.utils.toUtf8Bytes('Everything seems to be working fine so far') + const msg = ethers.toUtf8Bytes('Everything seems to be working fine so far') const sig = await account.signMessage(msg, networks[0].chainId, 'ignore') - const valid = await account - .reader(networks[0].chainId) - .isValidSignature(account.address, ethers.utils.keccak256(msg), sig) + const valid = await account.reader(networks[0].chainId).isValidSignature(account.address, ethers.keccak256(msg), sig) expect(valid).to.be.false }) @@ -1362,10 +1362,10 @@ describe('Account', () => { let signer: ethers.Wallet let account: Account - let getNonce: (response: ethers.providers.TransactionResponse) => { space: ethers.BigNumber; nonce: ethers.BigNumber } + let getNonce: (response: ethers.TransactionResponse) => { space: bigint; nonce: bigint } before(async () => { - const mainModule = new ethers.utils.Interface(walletContracts.mainModule.abi) + const mainModule = new ethers.Interface(walletContracts.mainModule.abi) getNonce = ({ data }) => { const [_, encoded] = mainModule.decodeFunctionData('execute', data) @@ -1410,8 +1410,8 @@ describe('Account', () => { let { space, nonce } = getNonce(response) - expect(space.eq(6492)).to.be.true - expect(nonce.eq(0)).to.be.true + expect(space === 6492n).to.be.true + expect(nonce === 0n).to.be.true await response.wait() @@ -1431,8 +1431,8 @@ describe('Account', () => { space = encoded.space nonce = encoded.nonce - expect(space.eq(6492)).to.be.true - expect(nonce.eq(1)).to.be.true + expect(space === 6492n).to.be.true + expect(nonce === 1n).to.be.true }) it('Should select random nonces by default', async () => { @@ -1443,8 +1443,8 @@ describe('Account', () => { const { space: firstSpace, nonce: firstNonce } = getNonce(response) - expect(firstSpace.eq(0)).to.be.false - expect(firstNonce.eq(0)).to.be.true + expect(firstSpace === 0n).to.be.false + expect(firstNonce === 0n).to.be.true // not necessary, parallel execution is ok: // await response.wait() @@ -1456,10 +1456,10 @@ describe('Account', () => { const { space: secondSpace, nonce: secondNonce } = getNonce(response) - expect(secondSpace.eq(0)).to.be.false - expect(secondNonce.eq(0)).to.be.true + expect(secondSpace === 0n).to.be.false + expect(secondNonce === 0n).to.be.true - expect(secondSpace.eq(firstSpace)).to.be.false + expect(secondSpace === firstSpace).to.be.false }) it('Should respect the serial option', async () => { @@ -1477,8 +1477,8 @@ describe('Account', () => { let { space, nonce } = getNonce(response) - expect(space.eq(0)).to.be.true - expect(nonce.eq(0)).to.be.true + expect(space === 0n).to.be.true + expect(nonce === 0n).to.be.true await response.wait() @@ -1498,8 +1498,8 @@ describe('Account', () => { space = encoded.space nonce = encoded.nonce - expect(space.eq(0)).to.be.true - expect(nonce.eq(1)).to.be.true + expect(space === 0n).to.be.true + expect(nonce === 1n).to.be.true }) }) }) @@ -1514,7 +1514,7 @@ export function now(): number { } export function randomWallet(entropy: number | string): ethers.Wallet { - return new ethers.Wallet(randomBytes(32, entropy)) + return new ethers.Wallet(ethers.hexlify(randomBytes(32, entropy))) } export function randomFraction(entropy: number | string): number { @@ -1527,10 +1527,10 @@ export function randomBytes(length: number, entropy: number | string): Uint8Arra if (deterministic) { let bytes = '' while (bytes.length < 2 * length) { - bytes += ethers.utils.id(`${bytes}${entropy}`).slice(2) + bytes += ethers.id(`${bytes}${entropy}`).slice(2) } - return ethers.utils.arrayify(`0x${bytes.slice(0, 2 * length)}`) + return ethers.getBytes(`0x${bytes.slice(0, 2 * length)}`) } else { - return ethers.utils.randomBytes(length) + return ethers.randomBytes(length) } } diff --git a/packages/account/tests/signer.spec.ts b/packages/account/tests/signer.spec.ts index cdc8aede4..e5f51824e 100644 --- a/packages/account/tests/signer.spec.ts +++ b/packages/account/tests/signer.spec.ts @@ -14,12 +14,13 @@ import hardhat from 'hardhat' import { Account } from '../src/account' import { now, randomWallet } from './account.spec' import { createERC20 } from '@0xsequence/tests/src/tokens/erc20' +import { parseEther } from '@0xsequence/utils' const { expect } = chai.use(chaiAsPromised) describe('Account signer', () => { - let provider1: ethers.providers.JsonRpcProvider - let provider2: ethers.providers.JsonRpcProvider + let provider1: ethers.BrowserProvider + let provider2: ethers.JsonRpcProvider let signer1: ethers.Signer let signer2: ethers.Signer @@ -36,8 +37,11 @@ describe('Account signer', () => { } before(async () => { - provider1 = new ethers.providers.Web3Provider(hardhat.network.provider as any) - provider2 = new ethers.providers.JsonRpcProvider('http://127.0.0.1:7048') + provider1 = new ethers.BrowserProvider(hardhat.network.provider as any, undefined, { cacheTimeout: -1 }) + provider2 = new ethers.JsonRpcProvider('http://127.0.0.1:7048', undefined, { cacheTimeout: -1 }) + + signer1 = await provider1.getSigner() + signer2 = await provider2.getSigner() // TODO: Implement migrations on local config tracker tracker = new trackers.local.LocalConfigTracker(provider1) as any @@ -48,7 +52,7 @@ describe('Account signer', () => { name: 'hardhat', provider: provider1, rpcUrl: '', - relayer: new LocalRelayer(provider1.getSigner()), + relayer: new LocalRelayer(signer1), nativeToken: { symbol: 'ETH', name: 'Ether', @@ -60,7 +64,7 @@ describe('Account signer', () => { name: 'hardhat2', provider: provider2, rpcUrl: 'http://127.0.0.1:7048', - relayer: new LocalRelayer(provider2.getSigner()), + relayer: new LocalRelayer(signer2), nativeToken: { symbol: 'ETH', name: 'Ether', @@ -69,9 +73,6 @@ describe('Account signer', () => { } ] - signer1 = provider1.getSigner() - signer2 = provider2.getSigner() - contexts = await utils.context.deploySequenceContexts(signer1) const context2 = await utils.context.deploySequenceContexts(signer2) @@ -85,9 +86,9 @@ describe('Account signer', () => { }) describe('with new account', () => { - var account: Account - var config: any - var accountSigner: ethers.Wallet + let account: Account + let config: any + let accountSigner: ethers.Wallet beforeEach(async () => { accountSigner = randomWallet('Should create a new account') @@ -160,7 +161,7 @@ describe('Account signer', () => { it('should fail to sign message because not deployed', async () => { const signer = account.getSigner(chainId) - await expect(signer.signMessage(ethers.utils.randomBytes(32))).to.be.rejectedWith('Wallet cannot validate onchain') + await expect(signer.signMessage(ethers.randomBytes(32))).to.be.rejectedWith('Wallet cannot validate onchain') }) it('should sign message after deployment', async () => { @@ -172,7 +173,7 @@ describe('Account signer', () => { expect(await signer.provider.getCode(account.address)).to.not.equal('0x') - const signature = await signer.signMessage(ethers.utils.randomBytes(32)) + const signature = await signer.signMessage(ethers.randomBytes(32)) expect(signature).to.exist expect(signature).to.not.equal('0x') }) @@ -180,7 +181,7 @@ describe('Account signer', () => { it('should sign a message (undeployed) when using EIP6492', async () => { const signer = account.getSigner(chainId, { cantValidateBehavior: 'eip6492' }) - const signature = await signer.signMessage(ethers.utils.randomBytes(32)) + const signature = await signer.signMessage(ethers.randomBytes(32)) expect(signature).to.exist expect(signature).to.not.equal('0x') }) @@ -220,8 +221,8 @@ describe('Account signer', () => { }) describe('select fee', () => { - var account: never - var getAccount: (feeOptions: FeeOption[], feeQuote: FeeQuote) => Promise + let account: never + let getAccount: (feeOptions: FeeOption[], feeQuote: FeeQuote) => Promise beforeEach(async () => { class LocalRelayerWithFee extends LocalRelayer { @@ -242,7 +243,7 @@ describe('Account signer', () => { async getFeeOptionsRaw( _entrypoint: string, - _data: ethers.utils.BytesLike, + _data: ethers.BytesLike, _options?: { simulate?: boolean } ): Promise<{ options: FeeOption[] }> { return { options: this.feeOptions, quote: this.quote } as any @@ -259,7 +260,7 @@ describe('Account signer', () => { signedTxs: commons.transaction.IntendedTransactionBundle, quote?: FeeQuote | undefined, waitForReceipt?: boolean | undefined - ): Promise> { + ): Promise> { expect(quote).to.equal(this.quote) return super.relay(signedTxs, quote, waitForReceipt) } @@ -298,7 +299,7 @@ describe('Account signer', () => { const feeQuote: FeeQuote = { _tag: 'FeeQuote', - _quote: ethers.utils.randomBytes(99) + _quote: ethers.randomBytes(99) } const account = await getAccount(feeOptions, feeQuote) @@ -330,14 +331,14 @@ describe('Account signer', () => { logoURL: '' }, to: ethers.Wallet.createRandom().address, - value: ethers.utils.parseEther('12').toString(), + value: parseEther('12').toString(), gasLimit: 100000 } ] const feeQuote: FeeQuote = { _tag: 'FeeQuote', - _quote: ethers.utils.randomBytes(99) + _quote: ethers.randomBytes(99) } const account = await getAccount(feeOptions, feeQuote) @@ -367,23 +368,23 @@ describe('Account signer', () => { symbol: 'TEST', type: proto.FeeTokenType.ERC20_TOKEN, logoURL: '', - contractAddress: token.address + contractAddress: await token.getAddress() }, to: recipient, - value: ethers.utils.parseEther('250').toString(), + value: parseEther('250').toString(), gasLimit: 400000 } ] const feeQuote: FeeQuote = { _tag: 'FeeQuote', - _quote: ethers.utils.randomBytes(99) + _quote: ethers.randomBytes(99) } const account = await getAccount(feeOptions, feeQuote) const signer = account.getSigner(chainId) - await token.mint(account.address, ethers.utils.parseEther('6000')) + await token.getFunction('mint')(account.address, parseEther('6000')) const res = await signer.sendTransaction({ to: ethers.Wallet.createRandom().address @@ -393,7 +394,7 @@ describe('Account signer', () => { expect(res.hash).to.exist expect(await signer.provider.getTransaction(res.hash)).to.exist - expect(await token.balanceOf(recipient)).to.deep.equal(ethers.utils.parseEther('250')) + expect(await token.getFunction('balanceOf')(recipient)).to.equal(parseEther('250')) }) it('should reject ERC20 fee if not enough balance', async () => { @@ -408,17 +409,17 @@ describe('Account signer', () => { symbol: 'TEST', type: proto.FeeTokenType.ERC20_TOKEN, logoURL: '', - contractAddress: token.address + contractAddress: await token.getAddress() }, to: recipient, - value: ethers.utils.parseEther('250').toString(), + value: parseEther('250').toString(), gasLimit: 400000 } ] const feeQuote: FeeQuote = { _tag: 'FeeQuote', - _quote: ethers.utils.randomBytes(99) + _quote: ethers.randomBytes(99) } const account = await getAccount(feeOptions, feeQuote) @@ -445,7 +446,7 @@ describe('Account signer', () => { logoURL: '' }, to: recipient, - value: ethers.utils.parseEther('12').toString(), + value: parseEther('12').toString(), gasLimit: 100000 }, { @@ -455,23 +456,23 @@ describe('Account signer', () => { symbol: 'TEST', type: proto.FeeTokenType.ERC20_TOKEN, logoURL: '', - contractAddress: token.address + contractAddress: await token.getAddress() }, to: recipient, - value: ethers.utils.parseEther('11').toString(), + value: parseEther('11').toString(), gasLimit: 400000 } ] const feeQuote: FeeQuote = { _tag: 'FeeQuote', - _quote: ethers.utils.randomBytes(99) + _quote: ethers.randomBytes(99) } const account = await getAccount(feeOptions, feeQuote) const signer = account.getSigner(chainId) - await token.mint(account.address, ethers.utils.parseEther('11')) + await token.getFunction('mint')(account.address, parseEther('11')) const res = await signer.sendTransaction({ to: ethers.Wallet.createRandom().address @@ -481,7 +482,7 @@ describe('Account signer', () => { expect(res.hash).to.exist expect(await signer.provider.getTransaction(res.hash)).to.exist - expect(await token.balanceOf(recipient)).to.deep.equal(ethers.utils.parseEther('11')) + expect(await token.getFunction('balanceOf')(recipient)).to.equal(parseEther('11')) }) it('should select fee using callback (first option)', async () => { @@ -509,17 +510,17 @@ describe('Account signer', () => { symbol: 'TEST', type: proto.FeeTokenType.ERC20_TOKEN, logoURL: '', - contractAddress: token.address + contractAddress: await token.getAddress() }, to: recipient, - value: ethers.utils.parseEther('11').toString(), + value: parseEther('11').toString(), gasLimit: 400000 } ] const feeQuote: FeeQuote = { _tag: 'FeeQuote', - _quote: ethers.utils.randomBytes(99) + _quote: ethers.randomBytes(99) } const account = await getAccount(feeOptions, feeQuote) @@ -543,8 +544,8 @@ describe('Account signer', () => { expect(res.hash).to.exist expect(await signer.provider.getTransaction(res.hash)).to.exist - expect(await signer.provider.getBalance(recipient)).to.deep.equal(ethers.BigNumber.from('5')) - expect(await token.balanceOf(recipient)).to.deep.equal(ethers.utils.parseEther('0')) + expect(await signer.provider.getBalance(recipient)).to.equal(5n) + expect(await token.getFunction('balanceOf')(recipient)).to.equal(parseEther('0')) }) it('should select fee using callback (second option)', async () => { @@ -572,17 +573,17 @@ describe('Account signer', () => { symbol: 'TEST', type: proto.FeeTokenType.ERC20_TOKEN, logoURL: '', - contractAddress: token.address + contractAddress: await token.getAddress() }, to: recipient, - value: ethers.utils.parseEther('11').toString(), + value: parseEther('11').toString(), gasLimit: 400000 } ] const feeQuote: FeeQuote = { _tag: 'FeeQuote', - _quote: ethers.utils.randomBytes(99) + _quote: ethers.randomBytes(99) } const account = await getAccount(feeOptions, feeQuote) @@ -593,7 +594,7 @@ describe('Account signer', () => { } }) - await token.mint(account.address, ethers.utils.parseEther('11')) + await token.getFunction('mint')(account.address, parseEther('11')) const res = await signer.sendTransaction({ to: ethers.Wallet.createRandom().address @@ -603,8 +604,8 @@ describe('Account signer', () => { expect(res.hash).to.exist expect(await signer.provider.getTransaction(res.hash)).to.exist - expect(await signer.provider.getBalance(recipient)).to.deep.equal(ethers.BigNumber.from('0')) - expect(await token.balanceOf(recipient)).to.deep.equal(ethers.utils.parseEther('11')) + expect(await signer.provider.getBalance(recipient)).to.equal(0n) + expect(await token.getFunction('balanceOf')(recipient)).to.equal(parseEther('11')) }) }) }) @@ -612,7 +613,7 @@ describe('Account signer', () => { it('should send transactions on multiple nonce spaces one by one', async () => { const signer1 = account.getSigner(chainId, { nonceSpace: '0x01' }) const signer2 = account.getSigner(chainId, { nonceSpace: 2 }) - const randomSpace = ethers.BigNumber.from(ethers.utils.hexlify(ethers.utils.randomBytes(12))) + const randomSpace = BigInt(ethers.hexlify(ethers.randomBytes(12))) const signer3 = account.getSigner(chainId, { nonceSpace: randomSpace }) @@ -642,25 +643,23 @@ describe('Account signer', () => { // Should have used all spaces const wallet = account.walletForStatus(chainId, await account.status(chainId)) - const nonceSpace1 = await wallet.getNonce('0x01').then(r => ethers.BigNumber.from(r)) + const nonceSpace1 = await wallet.getNonce('0x01').then(r => BigInt(r)) expect(nonceSpace1.toString()).to.equal('1') - const nonceSpace2 = await wallet.getNonce(2).then(r => ethers.BigNumber.from(r)) + const nonceSpace2 = await wallet.getNonce(2).then(r => BigInt(r)) expect(nonceSpace2.toString()).to.equal('1') - const nonceSpace3 = await wallet.getNonce(randomSpace).then(r => ethers.BigNumber.from(r)) + const nonceSpace3 = await wallet.getNonce(randomSpace).then(r => BigInt(r)) expect(nonceSpace3.toString()).to.equal('1') - const nonceSpace4 = await wallet.getNonce('0x04').then(r => ethers.BigNumber.from(r)) + const nonceSpace4 = await wallet.getNonce('0x04').then(r => BigInt(r)) expect(nonceSpace4.toString()).to.equal('1') - const nonceSpace5 = await wallet - .getNonce('0xffffffffffffffffffffffffffffffffffffffff') - .then(r => ethers.BigNumber.from(r)) + const nonceSpace5 = await wallet.getNonce('0xffffffffffffffffffffffffffffffffffffffff').then(r => BigInt(r)) expect(nonceSpace5.toString()).to.equal('1') // Unused space should have nonce 0 - const nonceSpace6 = await wallet.getNonce('0x06').then(r => ethers.BigNumber.from(r)) + const nonceSpace6 = await wallet.getNonce('0x06').then(r => BigInt(r)) expect(nonceSpace6.toString()).to.equal('0') // Using a space should consume it @@ -668,7 +667,7 @@ describe('Account signer', () => { to: ethers.Wallet.createRandom().address }) - const nonceSpace1b = await wallet.getNonce('0x01').then(r => ethers.BigNumber.from(r)) + const nonceSpace1b = await wallet.getNonce('0x01').then(r => BigInt(r)) expect(nonceSpace1b.toString()).to.equal('2') }) @@ -680,7 +679,7 @@ describe('Account signer', () => { it('should send transactions on multiple nonce spaces at once', async () => { const signer1 = account.getSigner(chainId, { nonceSpace: '0x01' }) const signer2 = account.getSigner(chainId, { nonceSpace: 2 }) - const randomSpace = ethers.BigNumber.from(ethers.utils.hexlify(ethers.utils.randomBytes(12))) + const randomSpace = BigInt(ethers.hexlify(ethers.randomBytes(12))) const signer3 = account.getSigner(chainId, { nonceSpace: randomSpace }) @@ -727,25 +726,23 @@ describe('Account signer', () => { // Should have used all spaces const wallet = account.walletForStatus(chainId, await account.status(chainId)) - const nonceSpace1 = await wallet.getNonce('0x01').then(r => ethers.BigNumber.from(r)) + const nonceSpace1 = await wallet.getNonce('0x01').then(r => BigInt(r)) expect(nonceSpace1.toString()).to.equal('1') - const nonceSpace2 = await wallet.getNonce(2).then(r => ethers.BigNumber.from(r)) + const nonceSpace2 = await wallet.getNonce(2).then(r => BigInt(r)) expect(nonceSpace2.toString()).to.equal('1') - const nonceSpace3 = await wallet.getNonce(randomSpace).then(r => ethers.BigNumber.from(r)) + const nonceSpace3 = await wallet.getNonce(randomSpace).then(r => BigInt(r)) expect(nonceSpace3.toString()).to.equal('1') - const nonceSpace4 = await wallet.getNonce('0x04').then(r => ethers.BigNumber.from(r)) + const nonceSpace4 = await wallet.getNonce('0x04').then(r => BigInt(r)) expect(nonceSpace4.toString()).to.equal('1') - const nonceSpace5 = await wallet - .getNonce('0xffffffffffffffffffffffffffffffffffffffff') - .then(r => ethers.BigNumber.from(r)) + const nonceSpace5 = await wallet.getNonce('0xffffffffffffffffffffffffffffffffffffffff').then(r => BigInt(r)) expect(nonceSpace5.toString()).to.equal('1') // Unused space should have nonce 0 - const nonceSpace6 = await wallet.getNonce('0x06').then(r => ethers.BigNumber.from(r)) + const nonceSpace6 = await wallet.getNonce('0x06').then(r => BigInt(r)) expect(nonceSpace6.toString()).to.equal('0') // Using a space should consume it @@ -753,14 +750,14 @@ describe('Account signer', () => { to: ethers.Wallet.createRandom().address }) - const nonceSpace1b = await wallet.getNonce('0x01').then(r => ethers.BigNumber.from(r)) + const nonceSpace1b = await wallet.getNonce('0x01').then(r => BigInt(r)) expect(nonceSpace1b.toString()).to.equal('2') }) it('should send 100 parallel transactions using different spaces', async () => { const signers = new Array(100).fill(0).map(() => account.getSigner(chainId, { - nonceSpace: ethers.BigNumber.from(ethers.utils.hexlify(ethers.utils.randomBytes(12))) + nonceSpace: BigInt(ethers.hexlify(ethers.randomBytes(12))) }) ) @@ -795,7 +792,7 @@ describe('Account signer', () => { it('should send multiple transactions on multiple nonce spaces at once', async () => { const signer1 = account.getSigner(chainId, { nonceSpace: '0x01' }) const signer2 = account.getSigner(chainId, { nonceSpace: 2 }) - const randomSpace = ethers.BigNumber.from(ethers.utils.hexlify(ethers.utils.randomBytes(12))) + const randomSpace = BigInt(ethers.hexlify(ethers.randomBytes(12))) const signer3 = account.getSigner(chainId, { nonceSpace: randomSpace @@ -861,25 +858,23 @@ describe('Account signer', () => { // Should have used all spaces const wallet = account.walletForStatus(chainId, await account.status(chainId)) - const nonceSpace2 = await wallet.getNonce(2).then(r => ethers.BigNumber.from(r)) + const nonceSpace2 = await wallet.getNonce(2).then(r => BigInt(r)) expect(nonceSpace2.toString()).to.equal('2') - const nonceSpace1 = await wallet.getNonce('0x01').then(r => ethers.BigNumber.from(r)) + const nonceSpace1 = await wallet.getNonce('0x01').then(r => BigInt(r)) expect(nonceSpace1.toString()).to.equal('2') - const nonceSpace3 = await wallet.getNonce(randomSpace).then(r => ethers.BigNumber.from(r)) + const nonceSpace3 = await wallet.getNonce(randomSpace).then(r => BigInt(r)) expect(nonceSpace3.toString()).to.equal('2') - const nonceSpace4 = await wallet.getNonce('0x04').then(r => ethers.BigNumber.from(r)) + const nonceSpace4 = await wallet.getNonce('0x04').then(r => BigInt(r)) expect(nonceSpace4.toString()).to.equal('2') - const nonceSpace5 = await wallet - .getNonce('0xffffffffffffffffffffffffffffffffffffffff') - .then(r => ethers.BigNumber.from(r)) + const nonceSpace5 = await wallet.getNonce('0xffffffffffffffffffffffffffffffffffffffff').then(r => BigInt(r)) expect(nonceSpace5.toString()).to.equal('2') // Unused space should have nonce 0 - const nonceSpace6 = await wallet.getNonce('0x06').then(r => ethers.BigNumber.from(r)) + const nonceSpace6 = await wallet.getNonce('0x06').then(r => BigInt(r)) expect(nonceSpace6.toString()).to.equal('0') // Using a space should consume it @@ -887,7 +882,7 @@ describe('Account signer', () => { to: ethers.Wallet.createRandom().address }) - const nonceSpace1b = await wallet.getNonce('0x01').then(r => ethers.BigNumber.from(r)) + const nonceSpace1b = await wallet.getNonce('0x01').then(r => BigInt(r)) expect(nonceSpace1b.toString()).to.equal('3') }) }) diff --git a/packages/api/CHANGELOG.md b/packages/api/CHANGELOG.md index e40204e34..e01127acd 100644 --- a/packages/api/CHANGELOG.md +++ b/packages/api/CHANGELOG.md @@ -1,5 +1,331 @@ # @0xsequence/api +## 2.2.14 + +### Patch Changes + +- Somnia Testnet and Monad Testnet + +## 2.2.13 + +### Patch Changes + +- Add XR1 to all networks + +## 2.2.12 + +### Patch Changes + +- Add XR1 + +## 2.2.11 + +### Patch Changes + +- Relayer updates + +## 2.2.10 + +### Patch Changes + +- Etherlink support + +## 2.2.9 + +### Patch Changes + +- Indexer gateway native token balances + +## 2.2.8 + +### Patch Changes + +- Add Moonbeam and Moonbase Alpha + +## 2.2.7 + +### Patch Changes + +- Update Builder package + +## 2.2.6 + +### Patch Changes + +- Update relayer package + +## 2.2.5 + +### Patch Changes + +- auth: fix sequence indexer gateway url +- account: immutable wallet proxy hook + +## 2.2.4 + +### Patch Changes + +- network: update soneium mainnet block explorer url +- waas: signTypedData intent support + +## 2.2.3 + +### Patch Changes + +- provider: updating initWallet to use connected network configs if they exist + +## 2.2.2 + +### Patch Changes + +- pass projectAccessKey to relayer at all times + +## 2.2.1 + +### Patch Changes + +- waas-ethers: sign typed data + +## 2.2.0 + +### Minor Changes + +- indexer: gateway client +- @0xsequence/builder +- upgrade puppeteer to v23.10.3 + +## 2.1.8 + +### Patch Changes + +- Add Soneium Mainnet + +## 2.1.7 + +### Patch Changes + +- guard: pass project access key to guard requests + +## 2.1.6 + +### Patch Changes + +- Add LAOS and Telos Testnet chains + +## 2.1.5 + +### Patch Changes + +- account: save presigned configuration with reference chain id 1 + +## 2.1.4 + +### Patch Changes + +- provider: pass projectAccessKey into MuxMessageProvider + +## 2.1.3 + +### Patch Changes + +- waas: time drift date fix due to strange browser quirk + +## 2.1.2 + +### Patch Changes + +- provider: export analytics correctly + +## 2.1.1 + +### Patch Changes + +- Add LAOS chain support + +## 2.1.0 + +### Minor Changes + +- account: forward project access key when estimating fees and sending transactions + +### Patch Changes + +- sessions: save signatures with reference chain id + +## 2.0.26 + +### Patch Changes + +- account: fix chain id comparison + +## 2.0.25 + +### Patch Changes + +- skale-nebula: deploy gas limit = 10m + +## 2.0.24 + +### Patch Changes + +- sessions: arweave: configurable gateway url +- waas: use /status to get time drift before sending any intents + +## 2.0.23 + +### Patch Changes + +- Add The Root Network support + +## 2.0.22 + +### Patch Changes + +- Add SKALE Nebula Mainnet support + +## 2.0.21 + +### Patch Changes + +- account: add publishWitnessFor + +## 2.0.20 + +### Patch Changes + +- upgrade deps, and improve waas session status handling + +## 2.0.19 + +### Patch Changes + +- Add Immutable zkEVM support + +## 2.0.18 + +### Patch Changes + +- waas: new contractCall transaction type +- sessions: add arweave owner + +## 2.0.17 + +### Patch Changes + +- update waas auth to clear session before signIn + +## 2.0.16 + +### Patch Changes + +- Removed Astar chains + +## 2.0.15 + +### Patch Changes + +- indexer: update bindings with token balance additions + +## 2.0.14 + +### Patch Changes + +- sessions: arweave config reader +- network: add b3 and apechain mainnet configs + +## 2.0.13 + +### Patch Changes + +- network: toy-testnet + +## 2.0.12 + +### Patch Changes + +- api: update bindings + +## 2.0.11 + +### Patch Changes + +- waas: intents test fix +- api: update bindings + +## 2.0.10 + +### Patch Changes + +- network: soneium minato testnet + +## 2.0.9 + +### Patch Changes + +- network: fix SKALE network name + +## 2.0.8 + +### Patch Changes + +- metadata: update bindings + +## 2.0.7 + +### Patch Changes + +- wallet request handler fix + +## 2.0.6 + +### Patch Changes + +- network: matic -> pol + +## 2.0.5 + +### Patch Changes + +- provider: update databeat to 0.9.2 + +## 2.0.4 + +### Patch Changes + +- network: add skale-nebula-testnet + +## 2.0.3 + +### Patch Changes + +- waas: check session status in SequenceWaaS.isSignedIn() + +## 2.0.2 + +### Patch Changes + +- sessions: property convert serialized bignumber hex value to bigint + +## 2.0.1 + +### Patch Changes + +- waas: http signature check for authenticator requests +- provider: unwrap legacy json rpc responses +- use json replacer and reviver for bigints + +## 2.0.0 + +### Major Changes + +- ethers v6 + +## 1.10.15 + +### Patch Changes + +- utils: extractProjectIdFromAccessKey + ## 1.10.14 ### Patch Changes diff --git a/packages/api/package.json b/packages/api/package.json index 64fc8c394..fada728cf 100644 --- a/packages/api/package.json +++ b/packages/api/package.json @@ -1,6 +1,6 @@ { "name": "@0xsequence/api", - "version": "1.10.14", + "version": "2.2.14", "description": "api sub-package for Sequence", "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/api", "source": "src/index.ts", diff --git a/packages/api/src/api.gen.ts b/packages/api/src/api.gen.ts index 514bc19f8..d9507163f 100644 --- a/packages/api/src/api.gen.ts +++ b/packages/api/src/api.gen.ts @@ -1,10 +1,14 @@ /* eslint-disable */ -// sequence-api v0.4.0 d3f5f1338693d60d58f87bc408a076218201a097 +// sequence-api v0.4.0 c3eb9010746703c095291691cd8f08dc04999062 // -- -// Code generated by webrpc-gen@v0.18.7 with typescript generator. DO NOT EDIT. +// Code generated by webrpc-gen@v0.22.0 with typescript generator. DO NOT EDIT. // // webrpc-gen -schema=api.ridl -target=typescript -client -out=./clients/api.gen.ts +export const WebrpcHeader = 'Webrpc' + +export const WebrpcHeaderValue = 'webrpc@v0.22.0;gen-typescript@v0.16.1;sequence-api@v0.4.0' + // WebRPC description and code-gen version export const WebRPCVersion = 'v1' @@ -12,7 +16,55 @@ export const WebRPCVersion = 'v1' export const WebRPCSchemaVersion = 'v0.4.0' // Schema hash generated from your RIDL schema -export const WebRPCSchemaHash = 'd3f5f1338693d60d58f87bc408a076218201a097' +export const WebRPCSchemaHash = 'c3eb9010746703c095291691cd8f08dc04999062' + +type WebrpcGenVersions = { + webrpcGenVersion: string + codeGenName: string + codeGenVersion: string + schemaName: string + schemaVersion: string +} + +export function VersionFromHeader(headers: Headers): WebrpcGenVersions { + const headerValue = headers.get(WebrpcHeader) + if (!headerValue) { + return { + webrpcGenVersion: '', + codeGenName: '', + codeGenVersion: '', + schemaName: '', + schemaVersion: '' + } + } + + return parseWebrpcGenVersions(headerValue) +} + +function parseWebrpcGenVersions(header: string): WebrpcGenVersions { + const versions = header.split(';') + if (versions.length < 3) { + return { + webrpcGenVersion: '', + codeGenName: '', + codeGenVersion: '', + schemaName: '', + schemaVersion: '' + } + } + + const [_, webrpcGenVersion] = versions[0].split('@') + const [codeGenName, codeGenVersion] = versions[1].split('@') + const [schemaName, schemaVersion] = versions[2].split('@') + + return { + webrpcGenVersion, + codeGenName, + codeGenVersion, + schemaName, + schemaVersion + } +} // // Types @@ -23,6 +75,20 @@ export enum SortOrder { ASC = 'ASC' } +export enum SardinePaymentType { + ach = 'ach', + debit = 'debit', + credit = 'credit', + us_debit = 'us_debit', + international_debit = 'international_debit', + international_credit = 'international_credit' +} + +export enum SardineQuoteType { + buy = 'buy', + sell = 'sell' +} + export enum TokenType { ERC20 = 'ERC20', ERC721 = 'ERC721', @@ -64,6 +130,12 @@ export interface SequenceContext { utils: string } +export interface PublicKey { + id: string + x: string + y: string +} + export interface User { address: string username: string @@ -175,6 +247,7 @@ export interface ExchangeRate { export interface LinkedWallet { id: number + walletType?: string walletAddress: string linkedWalletAddress: string createdAt?: string @@ -196,7 +269,7 @@ export interface SortBy { order: SortOrder } -export interface NftCheckoutParams { +export interface SardineNFTCheckoutParams { name: string imageUrl: string network: string @@ -214,7 +287,7 @@ export interface NftCheckoutParams { approvedSpenderAddress?: string } -export interface NftCheckout { +export interface SardineNFTCheckout { token: string expiresAt: string orderId: string @@ -244,6 +317,119 @@ export interface SardineOrder { recipientAddress: string } +export interface SardineRegion { + countryCode: string + isAllowedOnRamp: boolean + isAllowedOnNFT: boolean + isBasicKycRequired: Array + isSsnRequired: Array + name: string + currencyCode: string + isPayrollSupported: boolean + supportedDocuments: Array + paymentMethods: Array + states: Array +} + +export interface SardineRegionPaymentMethod { + name: string + isAllowedOnRamp: boolean + isAllowedOnNFT: boolean + subTypes: Array + type: string + subType: string +} + +export interface SardineRegionState { + code: string + name: string + isAllowedOnRamp: boolean + isAllowedOnNFT: boolean +} + +export interface SardineSupportedToken { + network: string + assetSymbol: string + assetName: string + chainId: string + tokenName: string + token: string + tokenAddress: string +} + +export interface SardineSupportedTokenForSwap { + isSupported: boolean + isSupportedForAbstraction: boolean + currentBalance: string +} + +export interface SardineEnabledToken { + network: string + assetSymbol: string + assetName: string + chainId: string + tokenName: string + token: string + tokenAddress: string +} + +export interface SardineGetQuoteParams { + assetType: string + network: string + total: number + currency?: string + paymentType?: SardinePaymentType + quoteType?: SardineQuoteType + walletAddress?: string +} + +export interface SardineQuote { + quantity: number + network: string + assetType: string + total: number + currency: string + expiresAt: string + paymentType: string + price: number + subtotal: number + transactionFee: number + networkFee: number + highNetworkFee: boolean + minTransactionValue: number + maxTransactionValue: number + liquidityProvider: string +} + +export interface SardineFiatCurrency { + currencyCode: string + name: string + currencySymbol: string + paymentOptions: Array + supportingCountries: Array +} + +export interface SardinePaymentOption { + name: string + dailyLimit: number + weeklyLimit: number + monthlyLimit: number + maxAmount: number + minAmount: number + subTypes: Array + type: string + subType: string + processingTime: string +} + +export interface SwapPrice { + currencyAddress: string + currencyBalance: string + price: string + maxPrice: string + transactionValue: string +} + export interface SwapQuote { currencyAddress: string currencyBalance: string @@ -251,23 +437,21 @@ export interface SwapQuote { maxPrice: string to: string transactionData: string + transactionValue: string approveData: string } export interface CurrencyGroup { - id: number name: string tokens: Array } export interface CurrencyGroupToken { - id: number - currencyGroupId: number chainId: number tokenAddress: string } -export interface InventoryPaymentConfig { +export interface OffchainInventory { id: number projectId: number chainId: number @@ -285,9 +469,9 @@ export interface InventoryPaymentConfig { deletedAt?: string } -export interface InventoryPayment { +export interface OffchainPayment { id: number - inventoryPaymentConfigId: number + offchainInventoryId: number productRecipient: string paymentChainId: number paymentTokenAddress: string @@ -297,9 +481,9 @@ export interface InventoryPayment { processedAt?: string } -export interface InventoryPaymentResponse { +export interface PaymentResponse { paymentId: number - inventoryPaymentConfigId: number + offchainInventoryId: number chainId: number externalProductId: string paymentTokenAddress: string @@ -312,6 +496,10 @@ export interface InventoryPaymentResponse { txData: string } +export interface AdoptedChildWallet { + address: string +} + export interface API { ping(headers?: object, signal?: AbortSignal): Promise version(headers?: object, signal?: AbortSignal): Promise @@ -325,6 +513,8 @@ export interface API { headers?: object, signal?: AbortSignal ): Promise + registerPublicKey(args: RegisterPublicKeyArgs, headers?: object, signal?: AbortSignal): Promise + getPublicKey(args: GetPublicKeyArgs, headers?: object, signal?: AbortSignal): Promise friendList(args: FriendListArgs, headers?: object, signal?: AbortSignal): Promise getFriendByAddress(args: GetFriendByAddressArgs, headers?: object, signal?: AbortSignal): Promise searchFriends(args: SearchFriendsArgs, headers?: object, signal?: AbortSignal): Promise @@ -347,17 +537,6 @@ export interface API { userStorageDelete(args: UserStorageDeleteArgs, headers?: object, signal?: AbortSignal): Promise userStorageFetchAll(args: UserStorageFetchAllArgs, headers?: object, signal?: AbortSignal): Promise getMoonpayLink(args: GetMoonpayLinkArgs, headers?: object, signal?: AbortSignal): Promise - getSardineClientToken(headers?: object, signal?: AbortSignal): Promise - getSardineNFTCheckoutToken( - args: GetSardineNFTCheckoutTokenArgs, - headers?: object, - signal?: AbortSignal - ): Promise - getSardineNFTCheckoutOrderStatus( - args: GetSardineNFTCheckoutOrderStatusArgs, - headers?: object, - signal?: AbortSignal - ): Promise resolveENSAddress(args: ResolveENSAddressArgs, headers?: object, signal?: AbortSignal): Promise isValidSignature(args: IsValidSignatureArgs, headers?: object, signal?: AbortSignal): Promise isValidMessageSignature( @@ -371,6 +550,38 @@ export interface API { signal?: AbortSignal ): Promise isValidETHAuthProof(args: IsValidETHAuthProofArgs, headers?: object, signal?: AbortSignal): Promise + sardineGetClientToken(headers?: object, signal?: AbortSignal): Promise + sardineGetNFTCheckoutToken( + args: SardineGetNFTCheckoutTokenArgs, + headers?: object, + signal?: AbortSignal + ): Promise + sardineGetNFTCheckoutOrderStatus( + args: SardineGetNFTCheckoutOrderStatusArgs, + headers?: object, + signal?: AbortSignal + ): Promise + sardineGetSupportedRegions(headers?: object, signal?: AbortSignal): Promise + sardineGetSupportedFiatCurrencies(headers?: object, signal?: AbortSignal): Promise + sardineGetSupportedTokens(headers?: object, signal?: AbortSignal): Promise + sardineGetSupportedTokenForSwap( + args: SardineGetSupportedTokenForSwapArgs, + headers?: object, + signal?: AbortSignal + ): Promise + sardineGetEnabledTokens(headers?: object, signal?: AbortSignal): Promise + sardineGetQuote(args: SardineGetQuoteArgs, headers?: object, signal?: AbortSignal): Promise + getSardineClientToken(headers?: object, signal?: AbortSignal): Promise + getSardineNFTCheckoutToken( + args: GetSardineNFTCheckoutTokenArgs, + headers?: object, + signal?: AbortSignal + ): Promise + getSardineNFTCheckoutOrderStatus( + args: GetSardineNFTCheckoutOrderStatusArgs, + headers?: object, + signal?: AbortSignal + ): Promise getCoinPrices(args: GetCoinPricesArgs, headers?: object, signal?: AbortSignal): Promise getCollectiblePrices( args: GetCollectiblePricesArgs, @@ -403,41 +614,46 @@ export interface API { headers?: object, signal?: AbortSignal ): Promise - getSwapQuotes(args: GetSwapQuotesArgs, headers?: object, signal?: AbortSignal): Promise - addCurrencyGroup(args: AddCurrencyGroupArgs, headers?: object, signal?: AbortSignal): Promise - updateCurrencyGroup(args: UpdateCurrencyGroupArgs, headers?: object, signal?: AbortSignal): Promise + listAdoptedWallets(args: ListAdoptedWalletsArgs, headers?: object, signal?: AbortSignal): Promise + getSwapPrice(args: GetSwapPriceArgs, headers?: object, signal?: AbortSignal): Promise + getSwapPrices(args: GetSwapPricesArgs, headers?: object, signal?: AbortSignal): Promise + getSwapQuote(args: GetSwapQuoteArgs, headers?: object, signal?: AbortSignal): Promise listCurrencyGroups(headers?: object, signal?: AbortSignal): Promise - deleteCurrencyGroup(args: DeleteCurrencyGroupArgs, headers?: object, signal?: AbortSignal): Promise - addInventoryPaymentConfig( - args: AddInventoryPaymentConfigArgs, + addOffchainInventory( + args: AddOffchainInventoryArgs, + headers?: object, + signal?: AbortSignal + ): Promise + getOffchainInventory( + args: GetOffchainInventoryArgs, headers?: object, signal?: AbortSignal - ): Promise - getInventoryPaymentConfig( - args: GetInventoryPaymentConfigArgs, + ): Promise + listOffchainInventories( + args: ListOffchainInventoriesArgs, headers?: object, signal?: AbortSignal - ): Promise - listInventoryPaymentConfigs( - args: ListInventoryPaymentConfigsArgs, + ): Promise + updateOffchainInventory( + args: UpdateOffchainInventoryArgs, headers?: object, signal?: AbortSignal - ): Promise - updateInventoryPaymentConfig( - args: UpdateInventoryPaymentConfigArgs, + ): Promise + deleteOffchainInventory( + args: DeleteOffchainInventoryArgs, headers?: object, signal?: AbortSignal - ): Promise - deleteInventoryPaymentConfig( - args: DeleteInventoryPaymentConfigArgs, + ): Promise + requestOffchainPayment( + args: RequestOffchainPaymentArgs, headers?: object, signal?: AbortSignal - ): Promise - requestInventoryPayment( - args: RequestInventoryPaymentArgs, + ): Promise + listOffchainPayments( + args: ListOffchainPaymentsArgs, headers?: object, signal?: AbortSignal - ): Promise + ): Promise } export interface PingArgs {} @@ -496,6 +712,20 @@ export interface SendPasswordlessLinkArgs { export interface SendPasswordlessLinkReturn { status: boolean } +export interface RegisterPublicKeyArgs { + publicKey: PublicKey +} + +export interface RegisterPublicKeyReturn { + status: boolean +} +export interface GetPublicKeyArgs { + id: string +} + +export interface GetPublicKeyReturn { + publicKey: PublicKey +} export interface FriendListArgs { nickname?: string page?: Page @@ -607,25 +837,6 @@ export interface GetMoonpayLinkArgs { export interface GetMoonpayLinkReturn { signedUrl: string } -export interface GetSardineClientTokenArgs {} - -export interface GetSardineClientTokenReturn { - token: string -} -export interface GetSardineNFTCheckoutTokenArgs { - params: NftCheckoutParams -} - -export interface GetSardineNFTCheckoutTokenReturn { - resp: NftCheckout -} -export interface GetSardineNFTCheckoutOrderStatusArgs { - orderId: string -} - -export interface GetSardineNFTCheckoutOrderStatusReturn { - resp: SardineOrder -} export interface ResolveENSAddressArgs { ens: string } @@ -673,6 +884,79 @@ export interface IsValidETHAuthProofArgs { export interface IsValidETHAuthProofReturn { isValid: boolean } +export interface SardineGetClientTokenArgs {} + +export interface SardineGetClientTokenReturn { + token: string +} +export interface SardineGetNFTCheckoutTokenArgs { + params: SardineNFTCheckoutParams +} + +export interface SardineGetNFTCheckoutTokenReturn { + resp: SardineNFTCheckout +} +export interface SardineGetNFTCheckoutOrderStatusArgs { + orderId: string +} + +export interface SardineGetNFTCheckoutOrderStatusReturn { + resp: SardineOrder +} +export interface SardineGetSupportedRegionsArgs {} + +export interface SardineGetSupportedRegionsReturn { + regions: Array +} +export interface SardineGetSupportedFiatCurrenciesArgs {} + +export interface SardineGetSupportedFiatCurrenciesReturn { + tokens: Array +} +export interface SardineGetSupportedTokensArgs {} + +export interface SardineGetSupportedTokensReturn { + tokens: Array +} +export interface SardineGetSupportedTokenForSwapArgs { + network: string + tokenAddress: string +} + +export interface SardineGetSupportedTokenForSwapReturn { + token: SardineSupportedTokenForSwap +} +export interface SardineGetEnabledTokensArgs {} + +export interface SardineGetEnabledTokensReturn { + tokens: Array +} +export interface SardineGetQuoteArgs { + params: SardineGetQuoteParams +} + +export interface SardineGetQuoteReturn { + quote: SardineQuote +} +export interface GetSardineClientTokenArgs {} + +export interface GetSardineClientTokenReturn { + token: string +} +export interface GetSardineNFTCheckoutTokenArgs { + params: SardineNFTCheckoutParams +} + +export interface GetSardineNFTCheckoutTokenReturn { + resp: SardineNFTCheckout +} +export interface GetSardineNFTCheckoutOrderStatusArgs { + orderId: string +} + +export interface GetSardineNFTCheckoutOrderStatusReturn { + resp: SardineOrder +} export interface GetCoinPricesArgs { tokens: Array } @@ -758,30 +1042,35 @@ export interface PaperSessionSecret2Return { secret: string } export interface LinkWalletArgs { - chainId: string - walletAddress: string - ethAuthProofString: string + parentWalletAddress: string + parentWalletMessage: string + parentWalletSignature: string + linkedWalletAddress: string linkedWalletMessage: string linkedWalletSignature: string + signatureChainId: string + linkedWalletType?: string } export interface LinkWalletReturn { status: boolean - linkedWalletAddress: string } export interface GetLinkedWalletsArgs { - walletAddress: string + parentWalletAddress: string + parentWalletMessage: string + parentWalletSignature: string + signatureChainId: string } export interface GetLinkedWalletsReturn { - linkedWallets: Array + linkedWallets: Array } export interface RemoveLinkedWalletArgs { - chainId: string - walletAddress: string - ethAuthProofString: string - linkedWalletMessage: string - linkedWalletSignature: string + parentWalletAddress: string + parentWalletMessage: string + parentWalletSignature: string + linkedWalletAddress: string + signatureChainId: string } export interface RemoveLinkedWalletReturn { @@ -805,83 +1094,105 @@ export interface ValidateWaaSVerificationNonceArgs { export interface ValidateWaaSVerificationNonceReturn { walletAddress: string } -export interface GetSwapQuotesArgs { - userAddress: string - currencyAddress: string - currencyAmount: string +export interface ListAdoptedWalletsArgs { + page?: Page +} + +export interface ListAdoptedWalletsReturn { + page: Page + wallets: Array +} +export interface GetSwapPriceArgs { + buyCurrencyAddress: string + sellCurrencyAddress: string + buyAmount: string chainId: number - includeApprove: boolean + slippagePercentage?: number } -export interface GetSwapQuotesReturn { - swapQuotes: Array +export interface GetSwapPriceReturn { + swapPrice: SwapPrice } -export interface AddCurrencyGroupArgs { - currencyGroup: CurrencyGroup +export interface GetSwapPricesArgs { + userAddress: string + buyCurrencyAddress: string + buyAmount: string + chainId: number + slippagePercentage?: number } -export interface AddCurrencyGroupReturn { - groupId: number +export interface GetSwapPricesReturn { + swapPrices: Array } -export interface UpdateCurrencyGroupArgs { - currencyGroup: CurrencyGroup +export interface GetSwapQuoteArgs { + userAddress: string + buyCurrencyAddress: string + sellCurrencyAddress: string + buyAmount: string + chainId: number + includeApprove: boolean + slippagePercentage?: number } -export interface UpdateCurrencyGroupReturn {} +export interface GetSwapQuoteReturn { + swapQuote: SwapQuote +} export interface ListCurrencyGroupsArgs {} export interface ListCurrencyGroupsReturn { currencyGroups: Array } -export interface DeleteCurrencyGroupArgs { - groupId: number -} - -export interface DeleteCurrencyGroupReturn { - ok: boolean -} -export interface AddInventoryPaymentConfigArgs { - config: InventoryPaymentConfig +export interface AddOffchainInventoryArgs { + inventory: OffchainInventory } -export interface AddInventoryPaymentConfigReturn { - configId: number +export interface AddOffchainInventoryReturn { + inventoryId: number } -export interface GetInventoryPaymentConfigArgs { - configId: number +export interface GetOffchainInventoryArgs { + inventoryId: number } -export interface GetInventoryPaymentConfigReturn { - config: InventoryPaymentConfig +export interface GetOffchainInventoryReturn { + inventory: OffchainInventory } -export interface ListInventoryPaymentConfigsArgs { +export interface ListOffchainInventoriesArgs { projectId: number } -export interface ListInventoryPaymentConfigsReturn { - configs: Array +export interface ListOffchainInventoriesReturn { + inventory: Array } -export interface UpdateInventoryPaymentConfigArgs { - config: InventoryPaymentConfig +export interface UpdateOffchainInventoryArgs { + inventory: OffchainInventory } -export interface UpdateInventoryPaymentConfigReturn {} -export interface DeleteInventoryPaymentConfigArgs { - configId: number +export interface UpdateOffchainInventoryReturn {} +export interface DeleteOffchainInventoryArgs { + inventoryId: number } -export interface DeleteInventoryPaymentConfigReturn { +export interface DeleteOffchainInventoryReturn { ok: boolean } -export interface RequestInventoryPaymentArgs { - configId: number +export interface RequestOffchainPaymentArgs { + inventoryId: number recipient: string chainId?: number tokenAddress?: string } -export interface RequestInventoryPaymentReturn { - payment: InventoryPaymentResponse +export interface RequestOffchainPaymentReturn { + payment: PaymentResponse +} +export interface ListOffchainPaymentsArgs { + inventoryId: number + page?: Page +} + +export interface ListOffchainPaymentsReturn { + page: Page + payments: Array } // @@ -893,7 +1204,7 @@ export class API implements API { protected path = '/rpc/API/' constructor(hostname: string, fetch: Fetch) { - this.hostname = hostname + this.hostname = hostname.replace(/\/*$/, '') this.fetch = (input: RequestInfo, init?: RequestInit) => fetch(input, init) } @@ -1031,6 +1342,36 @@ export class API implements API { ) } + registerPublicKey = (args: RegisterPublicKeyArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('RegisterPublicKey'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + status: _data.status + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + getPublicKey = (args: GetPublicKeyArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('GetPublicKey'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + publicKey: _data.publicKey + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + friendList = (args: FriendListArgs, headers?: object, signal?: AbortSignal): Promise => { return this.fetch(this.url('FriendList'), createHTTPRequest(args, headers, signal)).then( res => { @@ -1265,12 +1606,13 @@ export class API implements API { ) } - getSardineClientToken = (headers?: object, signal?: AbortSignal): Promise => { - return this.fetch(this.url('GetSardineClientToken'), createHTTPRequest({}, headers, signal)).then( + resolveENSAddress = (args: ResolveENSAddressArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('ResolveENSAddress'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { return { - token: _data.token + address: _data.address, + ok: _data.ok } }) }, @@ -1280,16 +1622,12 @@ export class API implements API { ) } - getSardineNFTCheckoutToken = ( - args: GetSardineNFTCheckoutTokenArgs, - headers?: object, - signal?: AbortSignal - ): Promise => { - return this.fetch(this.url('GetSardineNFTCheckoutToken'), createHTTPRequest(args, headers, signal)).then( + isValidSignature = (args: IsValidSignatureArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('IsValidSignature'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { return { - resp: _data.resp + isValid: _data.isValid } }) }, @@ -1299,16 +1637,16 @@ export class API implements API { ) } - getSardineNFTCheckoutOrderStatus = ( - args: GetSardineNFTCheckoutOrderStatusArgs, + isValidMessageSignature = ( + args: IsValidMessageSignatureArgs, headers?: object, signal?: AbortSignal - ): Promise => { - return this.fetch(this.url('GetSardineNFTCheckoutOrderStatus'), createHTTPRequest(args, headers, signal)).then( + ): Promise => { + return this.fetch(this.url('IsValidMessageSignature'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { return { - resp: _data.resp + isValid: _data.isValid } }) }, @@ -1318,13 +1656,16 @@ export class API implements API { ) } - resolveENSAddress = (args: ResolveENSAddressArgs, headers?: object, signal?: AbortSignal): Promise => { - return this.fetch(this.url('ResolveENSAddress'), createHTTPRequest(args, headers, signal)).then( + isValidTypedDataSignature = ( + args: IsValidTypedDataSignatureArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('IsValidTypedDataSignature'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { return { - address: _data.address, - ok: _data.ok + isValid: _data.isValid } }) }, @@ -1334,8 +1675,12 @@ export class API implements API { ) } - isValidSignature = (args: IsValidSignatureArgs, headers?: object, signal?: AbortSignal): Promise => { - return this.fetch(this.url('IsValidSignature'), createHTTPRequest(args, headers, signal)).then( + isValidETHAuthProof = ( + args: IsValidETHAuthProofArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('IsValidETHAuthProof'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { return { @@ -1349,16 +1694,31 @@ export class API implements API { ) } - isValidMessageSignature = ( - args: IsValidMessageSignatureArgs, + sardineGetClientToken = (headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('SardineGetClientToken'), createHTTPRequest({}, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + token: _data.token + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + sardineGetNFTCheckoutToken = ( + args: SardineGetNFTCheckoutTokenArgs, headers?: object, signal?: AbortSignal - ): Promise => { - return this.fetch(this.url('IsValidMessageSignature'), createHTTPRequest(args, headers, signal)).then( + ): Promise => { + return this.fetch(this.url('SardineGetNFTCheckoutToken'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { return { - isValid: _data.isValid + resp: _data.resp } }) }, @@ -1368,16 +1728,16 @@ export class API implements API { ) } - isValidTypedDataSignature = ( - args: IsValidTypedDataSignatureArgs, + sardineGetNFTCheckoutOrderStatus = ( + args: SardineGetNFTCheckoutOrderStatusArgs, headers?: object, signal?: AbortSignal - ): Promise => { - return this.fetch(this.url('IsValidTypedDataSignature'), createHTTPRequest(args, headers, signal)).then( + ): Promise => { + return this.fetch(this.url('SardineGetNFTCheckoutOrderStatus'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { return { - isValid: _data.isValid + resp: _data.resp } }) }, @@ -1387,16 +1747,147 @@ export class API implements API { ) } - isValidETHAuthProof = ( - args: IsValidETHAuthProofArgs, + sardineGetSupportedRegions = (headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('SardineGetSupportedRegions'), createHTTPRequest({}, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + regions: >_data.regions + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + sardineGetSupportedFiatCurrencies = ( headers?: object, signal?: AbortSignal - ): Promise => { - return this.fetch(this.url('IsValidETHAuthProof'), createHTTPRequest(args, headers, signal)).then( + ): Promise => { + return this.fetch(this.url('SardineGetSupportedFiatCurrencies'), createHTTPRequest({}, headers, signal)).then( res => { return buildResponse(res).then(_data => { return { - isValid: _data.isValid + tokens: >_data.tokens + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + sardineGetSupportedTokens = (headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('SardineGetSupportedTokens'), createHTTPRequest({}, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + tokens: >_data.tokens + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + sardineGetSupportedTokenForSwap = ( + args: SardineGetSupportedTokenForSwapArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('SardineGetSupportedTokenForSwap'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + token: _data.token + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + sardineGetEnabledTokens = (headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('SardineGetEnabledTokens'), createHTTPRequest({}, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + tokens: >_data.tokens + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + sardineGetQuote = (args: SardineGetQuoteArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('SardineGetQuote'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + quote: _data.quote + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + getSardineClientToken = (headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('GetSardineClientToken'), createHTTPRequest({}, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + token: _data.token + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + getSardineNFTCheckoutToken = ( + args: GetSardineNFTCheckoutTokenArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('GetSardineNFTCheckoutToken'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + resp: _data.resp + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + getSardineNFTCheckoutOrderStatus = ( + args: GetSardineNFTCheckoutOrderStatusArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('GetSardineNFTCheckoutOrderStatus'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + resp: _data.resp } }) }, @@ -1592,8 +2083,7 @@ export class API implements API { res => { return buildResponse(res).then(_data => { return { - status: _data.status, - linkedWalletAddress: _data.linkedWalletAddress + status: _data.status } }) }, @@ -1608,7 +2098,7 @@ export class API implements API { res => { return buildResponse(res).then(_data => { return { - linkedWallets: >_data.linkedWallets + linkedWallets: >_data.linkedWallets } }) }, @@ -1676,12 +2166,17 @@ export class API implements API { ) } - getSwapQuotes = (args: GetSwapQuotesArgs, headers?: object, signal?: AbortSignal): Promise => { - return this.fetch(this.url('GetSwapQuotes'), createHTTPRequest(args, headers, signal)).then( + listAdoptedWallets = ( + args: ListAdoptedWalletsArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('ListAdoptedWallets'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { return { - swapQuotes: >_data.swapQuotes + page: _data.page, + wallets: >_data.wallets } }) }, @@ -1691,12 +2186,12 @@ export class API implements API { ) } - addCurrencyGroup = (args: AddCurrencyGroupArgs, headers?: object, signal?: AbortSignal): Promise => { - return this.fetch(this.url('AddCurrencyGroup'), createHTTPRequest(args, headers, signal)).then( + getSwapPrice = (args: GetSwapPriceArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('GetSwapPrice'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { return { - groupId: _data.groupId + swapPrice: _data.swapPrice } }) }, @@ -1706,15 +2201,28 @@ export class API implements API { ) } - updateCurrencyGroup = ( - args: UpdateCurrencyGroupArgs, - headers?: object, - signal?: AbortSignal - ): Promise => { - return this.fetch(this.url('UpdateCurrencyGroup'), createHTTPRequest(args, headers, signal)).then( + getSwapPrices = (args: GetSwapPricesArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('GetSwapPrices'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { - return {} + return { + swapPrices: >_data.swapPrices + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + getSwapQuote = (args: GetSwapQuoteArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('GetSwapQuote'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + swapQuote: _data.swapQuote + } }) }, error => { @@ -1738,16 +2246,16 @@ export class API implements API { ) } - deleteCurrencyGroup = ( - args: DeleteCurrencyGroupArgs, + addOffchainInventory = ( + args: AddOffchainInventoryArgs, headers?: object, signal?: AbortSignal - ): Promise => { - return this.fetch(this.url('DeleteCurrencyGroup'), createHTTPRequest(args, headers, signal)).then( + ): Promise => { + return this.fetch(this.url('AddOffchainInventory'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { return { - ok: _data.ok + inventoryId: _data.inventoryId } }) }, @@ -1757,16 +2265,16 @@ export class API implements API { ) } - addInventoryPaymentConfig = ( - args: AddInventoryPaymentConfigArgs, + getOffchainInventory = ( + args: GetOffchainInventoryArgs, headers?: object, signal?: AbortSignal - ): Promise => { - return this.fetch(this.url('AddInventoryPaymentConfig'), createHTTPRequest(args, headers, signal)).then( + ): Promise => { + return this.fetch(this.url('GetOffchainInventory'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { return { - configId: _data.configId + inventory: _data.inventory } }) }, @@ -1776,16 +2284,16 @@ export class API implements API { ) } - getInventoryPaymentConfig = ( - args: GetInventoryPaymentConfigArgs, + listOffchainInventories = ( + args: ListOffchainInventoriesArgs, headers?: object, signal?: AbortSignal - ): Promise => { - return this.fetch(this.url('GetInventoryPaymentConfig'), createHTTPRequest(args, headers, signal)).then( + ): Promise => { + return this.fetch(this.url('ListOffchainInventories'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { return { - config: _data.config + inventory: >_data.inventory } }) }, @@ -1795,17 +2303,15 @@ export class API implements API { ) } - listInventoryPaymentConfigs = ( - args: ListInventoryPaymentConfigsArgs, + updateOffchainInventory = ( + args: UpdateOffchainInventoryArgs, headers?: object, signal?: AbortSignal - ): Promise => { - return this.fetch(this.url('ListInventoryPaymentConfigs'), createHTTPRequest(args, headers, signal)).then( + ): Promise => { + return this.fetch(this.url('UpdateOffchainInventory'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { - return { - configs: >_data.configs - } + return {} }) }, error => { @@ -1814,15 +2320,17 @@ export class API implements API { ) } - updateInventoryPaymentConfig = ( - args: UpdateInventoryPaymentConfigArgs, + deleteOffchainInventory = ( + args: DeleteOffchainInventoryArgs, headers?: object, signal?: AbortSignal - ): Promise => { - return this.fetch(this.url('UpdateInventoryPaymentConfig'), createHTTPRequest(args, headers, signal)).then( + ): Promise => { + return this.fetch(this.url('DeleteOffchainInventory'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { - return {} + return { + ok: _data.ok + } }) }, error => { @@ -1831,16 +2339,16 @@ export class API implements API { ) } - deleteInventoryPaymentConfig = ( - args: DeleteInventoryPaymentConfigArgs, + requestOffchainPayment = ( + args: RequestOffchainPaymentArgs, headers?: object, signal?: AbortSignal - ): Promise => { - return this.fetch(this.url('DeleteInventoryPaymentConfig'), createHTTPRequest(args, headers, signal)).then( + ): Promise => { + return this.fetch(this.url('RequestOffchainPayment'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { return { - ok: _data.ok + payment: _data.payment } }) }, @@ -1850,16 +2358,17 @@ export class API implements API { ) } - requestInventoryPayment = ( - args: RequestInventoryPaymentArgs, + listOffchainPayments = ( + args: ListOffchainPaymentsArgs, headers?: object, signal?: AbortSignal - ): Promise => { - return this.fetch(this.url('RequestInventoryPayment'), createHTTPRequest(args, headers, signal)).then( + ): Promise => { + return this.fetch(this.url('ListOffchainPayments'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { return { - payment: _data.payment + page: _data.page, + payments: >_data.payments } }) }, @@ -1871,9 +2380,12 @@ export class API implements API { } const createHTTPRequest = (body: object = {}, headers: object = {}, signal: AbortSignal | null = null): object => { + const reqHeaders: { [key: string]: string } = { ...headers, 'Content-Type': 'application/json' } + reqHeaders[WebrpcHeader] = WebrpcHeaderValue + return { method: 'POST', - headers: { ...headers, 'Content-Type': 'application/json' }, + headers: reqHeaders, body: JSON.stringify(body || {}), signal } @@ -2118,6 +2630,32 @@ export class SessionExpiredError extends WebrpcError { } } +export class MethodNotFoundError extends WebrpcError { + constructor( + name: string = 'MethodNotFound', + code: number = 1003, + message: string = 'Method not found', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, MethodNotFoundError.prototype) + } +} + +export class RequestConflictError extends WebrpcError { + constructor( + name: string = 'RequestConflict', + code: number = 1004, + message: string = 'Conflict with target resource', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, RequestConflictError.prototype) + } +} + export class AbortedError extends WebrpcError { constructor( name: string = 'Aborted', @@ -2144,6 +2682,175 @@ export class GeoblockedError extends WebrpcError { } } +export class RateLimitedError extends WebrpcError { + constructor( + name: string = 'RateLimited', + code: number = 1007, + message: string = 'Rate-limited. Please slow down.', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, RateLimitedError.prototype) + } +} + +export class ProjectNotFoundError extends WebrpcError { + constructor( + name: string = 'ProjectNotFound', + code: number = 1008, + message: string = 'Project not found', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, ProjectNotFoundError.prototype) + } +} + +export class AccessKeyNotFoundError extends WebrpcError { + constructor( + name: string = 'AccessKeyNotFound', + code: number = 1101, + message: string = 'Access key not found', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, AccessKeyNotFoundError.prototype) + } +} + +export class AccessKeyMismatchError extends WebrpcError { + constructor( + name: string = 'AccessKeyMismatch', + code: number = 1102, + message: string = 'Access key mismatch', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, AccessKeyMismatchError.prototype) + } +} + +export class InvalidOriginError extends WebrpcError { + constructor( + name: string = 'InvalidOrigin', + code: number = 1103, + message: string = 'Invalid origin for Access Key', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, InvalidOriginError.prototype) + } +} + +export class InvalidServiceError extends WebrpcError { + constructor( + name: string = 'InvalidService', + code: number = 1104, + message: string = 'Service not enabled for Access key', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, InvalidServiceError.prototype) + } +} + +export class UnauthorizedUserError extends WebrpcError { + constructor( + name: string = 'UnauthorizedUser', + code: number = 1105, + message: string = 'Unauthorized user', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, UnauthorizedUserError.prototype) + } +} + +export class QuotaExceededError extends WebrpcError { + constructor( + name: string = 'QuotaExceeded', + code: number = 1200, + message: string = 'Quota request exceeded', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, QuotaExceededError.prototype) + } +} + +export class QuotaRateLimitError extends WebrpcError { + constructor( + name: string = 'QuotaRateLimit', + code: number = 1201, + message: string = 'Quota rate limit exceeded', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, QuotaRateLimitError.prototype) + } +} + +export class NoDefaultKeyError extends WebrpcError { + constructor( + name: string = 'NoDefaultKey', + code: number = 1300, + message: string = 'No default access key found', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, NoDefaultKeyError.prototype) + } +} + +export class MaxAccessKeysError extends WebrpcError { + constructor( + name: string = 'MaxAccessKeys', + code: number = 1301, + message: string = 'Access keys limit reached', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, MaxAccessKeysError.prototype) + } +} + +export class AtLeastOneKeyError extends WebrpcError { + constructor( + name: string = 'AtLeastOneKey', + code: number = 1302, + message: string = 'You need at least one Access Key', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, AtLeastOneKeyError.prototype) + } +} + +export class TimeoutError extends WebrpcError { + constructor( + name: string = 'Timeout', + code: number = 1900, + message: string = 'Request timed out', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, TimeoutError.prototype) + } +} + export class InvalidArgumentError extends WebrpcError { constructor( name: string = 'InvalidArgument', @@ -2196,6 +2903,19 @@ export class NotFoundError extends WebrpcError { } } +export class UnsupportedNetworkError extends WebrpcError { + constructor( + name: string = 'UnsupportedNetwork', + code: number = 3008, + message: string = 'Unsupported network', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, UnsupportedNetworkError.prototype) + } +} + export enum errors { WebrpcEndpoint = 'WebrpcEndpoint', WebrpcRequestFailed = 'WebrpcRequestFailed', @@ -2211,15 +2931,70 @@ export enum errors { Unauthorized = 'Unauthorized', PermissionDenied = 'PermissionDenied', SessionExpired = 'SessionExpired', + MethodNotFound = 'MethodNotFound', + RequestConflict = 'RequestConflict', Aborted = 'Aborted', Geoblocked = 'Geoblocked', + RateLimited = 'RateLimited', + ProjectNotFound = 'ProjectNotFound', + AccessKeyNotFound = 'AccessKeyNotFound', + AccessKeyMismatch = 'AccessKeyMismatch', + InvalidOrigin = 'InvalidOrigin', + InvalidService = 'InvalidService', + UnauthorizedUser = 'UnauthorizedUser', + QuotaExceeded = 'QuotaExceeded', + QuotaRateLimit = 'QuotaRateLimit', + NoDefaultKey = 'NoDefaultKey', + MaxAccessKeys = 'MaxAccessKeys', + AtLeastOneKey = 'AtLeastOneKey', + Timeout = 'Timeout', InvalidArgument = 'InvalidArgument', Unavailable = 'Unavailable', QueryFailed = 'QueryFailed', - NotFound = 'NotFound' -} - -const webrpcErrorByCode: { [code: number]: any } = { + NotFound = 'NotFound', + UnsupportedNetwork = 'UnsupportedNetwork' +} + +export enum WebrpcErrorCodes { + WebrpcEndpoint = 0, + WebrpcRequestFailed = -1, + WebrpcBadRoute = -2, + WebrpcBadMethod = -3, + WebrpcBadRequest = -4, + WebrpcBadResponse = -5, + WebrpcServerPanic = -6, + WebrpcInternalError = -7, + WebrpcClientDisconnected = -8, + WebrpcStreamLost = -9, + WebrpcStreamFinished = -10, + Unauthorized = 1000, + PermissionDenied = 1001, + SessionExpired = 1002, + MethodNotFound = 1003, + RequestConflict = 1004, + Aborted = 1005, + Geoblocked = 1006, + RateLimited = 1007, + ProjectNotFound = 1008, + AccessKeyNotFound = 1101, + AccessKeyMismatch = 1102, + InvalidOrigin = 1103, + InvalidService = 1104, + UnauthorizedUser = 1105, + QuotaExceeded = 1200, + QuotaRateLimit = 1201, + NoDefaultKey = 1300, + MaxAccessKeys = 1301, + AtLeastOneKey = 1302, + Timeout = 1900, + InvalidArgument = 2000, + Unavailable = 2002, + QueryFailed = 2003, + NotFound = 3000, + UnsupportedNetwork = 3008 +} + +export const webrpcErrorByCode: { [code: number]: any } = { [0]: WebrpcEndpointError, [-1]: WebrpcRequestFailedError, [-2]: WebrpcBadRouteError, @@ -2234,12 +3009,28 @@ const webrpcErrorByCode: { [code: number]: any } = { [1000]: UnauthorizedError, [1001]: PermissionDeniedError, [1002]: SessionExpiredError, + [1003]: MethodNotFoundError, + [1004]: RequestConflictError, [1005]: AbortedError, [1006]: GeoblockedError, + [1007]: RateLimitedError, + [1008]: ProjectNotFoundError, + [1101]: AccessKeyNotFoundError, + [1102]: AccessKeyMismatchError, + [1103]: InvalidOriginError, + [1104]: InvalidServiceError, + [1105]: UnauthorizedUserError, + [1200]: QuotaExceededError, + [1201]: QuotaRateLimitError, + [1300]: NoDefaultKeyError, + [1301]: MaxAccessKeysError, + [1302]: AtLeastOneKeyError, + [1900]: TimeoutError, [2000]: InvalidArgumentError, [2002]: UnavailableError, [2003]: QueryFailedError, - [3000]: NotFoundError + [3000]: NotFoundError, + [3008]: UnsupportedNetworkError } export type Fetch = (input: RequestInfo, init?: RequestInit) => Promise diff --git a/packages/api/src/index.ts b/packages/api/src/index.ts index 2c512d892..e7b9ab042 100644 --- a/packages/api/src/index.ts +++ b/packages/api/src/index.ts @@ -2,8 +2,6 @@ export * from './api.gen' import { API as ApiRpc } from './api.gen' -const fetch = globalThis.fetch - export class SequenceAPIClient extends ApiRpc { constructor( hostname: string, diff --git a/packages/auth/CHANGELOG.md b/packages/auth/CHANGELOG.md index 367469fcb..759fd966b 100644 --- a/packages/auth/CHANGELOG.md +++ b/packages/auth/CHANGELOG.md @@ -1,5 +1,1024 @@ # @0xsequence/auth +## 2.2.14 + +### Patch Changes + +- Somnia Testnet and Monad Testnet +- Updated dependencies + - @0xsequence/abi@2.2.14 + - @0xsequence/account@2.2.14 + - @0xsequence/api@2.2.14 + - @0xsequence/core@2.2.14 + - @0xsequence/indexer@2.2.14 + - @0xsequence/metadata@2.2.14 + - @0xsequence/migration@2.2.14 + - @0xsequence/network@2.2.14 + - @0xsequence/sessions@2.2.14 + - @0xsequence/signhub@2.2.14 + - @0xsequence/utils@2.2.14 + - @0xsequence/wallet@2.2.14 + +## 2.2.13 + +### Patch Changes + +- Add XR1 to all networks +- Updated dependencies + - @0xsequence/abi@2.2.13 + - @0xsequence/account@2.2.13 + - @0xsequence/api@2.2.13 + - @0xsequence/core@2.2.13 + - @0xsequence/indexer@2.2.13 + - @0xsequence/metadata@2.2.13 + - @0xsequence/migration@2.2.13 + - @0xsequence/network@2.2.13 + - @0xsequence/sessions@2.2.13 + - @0xsequence/signhub@2.2.13 + - @0xsequence/utils@2.2.13 + - @0xsequence/wallet@2.2.13 + +## 2.2.12 + +### Patch Changes + +- Add XR1 +- Updated dependencies + - @0xsequence/abi@2.2.12 + - @0xsequence/account@2.2.12 + - @0xsequence/api@2.2.12 + - @0xsequence/core@2.2.12 + - @0xsequence/indexer@2.2.12 + - @0xsequence/metadata@2.2.12 + - @0xsequence/migration@2.2.12 + - @0xsequence/network@2.2.12 + - @0xsequence/sessions@2.2.12 + - @0xsequence/signhub@2.2.12 + - @0xsequence/utils@2.2.12 + - @0xsequence/wallet@2.2.12 + +## 2.2.11 + +### Patch Changes + +- Relayer updates +- Updated dependencies + - @0xsequence/abi@2.2.11 + - @0xsequence/account@2.2.11 + - @0xsequence/api@2.2.11 + - @0xsequence/core@2.2.11 + - @0xsequence/indexer@2.2.11 + - @0xsequence/metadata@2.2.11 + - @0xsequence/migration@2.2.11 + - @0xsequence/network@2.2.11 + - @0xsequence/sessions@2.2.11 + - @0xsequence/signhub@2.2.11 + - @0xsequence/utils@2.2.11 + - @0xsequence/wallet@2.2.11 + +## 2.2.10 + +### Patch Changes + +- Etherlink support +- Updated dependencies + - @0xsequence/abi@2.2.10 + - @0xsequence/account@2.2.10 + - @0xsequence/api@2.2.10 + - @0xsequence/core@2.2.10 + - @0xsequence/indexer@2.2.10 + - @0xsequence/metadata@2.2.10 + - @0xsequence/migration@2.2.10 + - @0xsequence/network@2.2.10 + - @0xsequence/sessions@2.2.10 + - @0xsequence/signhub@2.2.10 + - @0xsequence/utils@2.2.10 + - @0xsequence/wallet@2.2.10 + +## 2.2.9 + +### Patch Changes + +- Indexer gateway native token balances +- Updated dependencies + - @0xsequence/abi@2.2.9 + - @0xsequence/account@2.2.9 + - @0xsequence/api@2.2.9 + - @0xsequence/core@2.2.9 + - @0xsequence/indexer@2.2.9 + - @0xsequence/metadata@2.2.9 + - @0xsequence/migration@2.2.9 + - @0xsequence/network@2.2.9 + - @0xsequence/sessions@2.2.9 + - @0xsequence/signhub@2.2.9 + - @0xsequence/utils@2.2.9 + - @0xsequence/wallet@2.2.9 + +## 2.2.8 + +### Patch Changes + +- Add Moonbeam and Moonbase Alpha +- Updated dependencies + - @0xsequence/abi@2.2.8 + - @0xsequence/account@2.2.8 + - @0xsequence/api@2.2.8 + - @0xsequence/core@2.2.8 + - @0xsequence/indexer@2.2.8 + - @0xsequence/metadata@2.2.8 + - @0xsequence/migration@2.2.8 + - @0xsequence/network@2.2.8 + - @0xsequence/sessions@2.2.8 + - @0xsequence/signhub@2.2.8 + - @0xsequence/utils@2.2.8 + - @0xsequence/wallet@2.2.8 + +## 2.2.7 + +### Patch Changes + +- Update Builder package +- Updated dependencies + - @0xsequence/abi@2.2.7 + - @0xsequence/account@2.2.7 + - @0xsequence/api@2.2.7 + - @0xsequence/core@2.2.7 + - @0xsequence/indexer@2.2.7 + - @0xsequence/metadata@2.2.7 + - @0xsequence/migration@2.2.7 + - @0xsequence/network@2.2.7 + - @0xsequence/sessions@2.2.7 + - @0xsequence/signhub@2.2.7 + - @0xsequence/utils@2.2.7 + - @0xsequence/wallet@2.2.7 + +## 2.2.6 + +### Patch Changes + +- Update relayer package +- Updated dependencies + - @0xsequence/abi@2.2.6 + - @0xsequence/account@2.2.6 + - @0xsequence/api@2.2.6 + - @0xsequence/core@2.2.6 + - @0xsequence/indexer@2.2.6 + - @0xsequence/metadata@2.2.6 + - @0xsequence/migration@2.2.6 + - @0xsequence/network@2.2.6 + - @0xsequence/sessions@2.2.6 + - @0xsequence/signhub@2.2.6 + - @0xsequence/utils@2.2.6 + - @0xsequence/wallet@2.2.6 + +## 2.2.5 + +### Patch Changes + +- auth: fix sequence indexer gateway url +- account: immutable wallet proxy hook +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.2.5 + - @0xsequence/account@2.2.5 + - @0xsequence/api@2.2.5 + - @0xsequence/core@2.2.5 + - @0xsequence/indexer@2.2.5 + - @0xsequence/metadata@2.2.5 + - @0xsequence/migration@2.2.5 + - @0xsequence/network@2.2.5 + - @0xsequence/sessions@2.2.5 + - @0xsequence/signhub@2.2.5 + - @0xsequence/utils@2.2.5 + - @0xsequence/wallet@2.2.5 + +## 2.2.4 + +### Patch Changes + +- network: update soneium mainnet block explorer url +- waas: signTypedData intent support +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.2.4 + - @0xsequence/account@2.2.4 + - @0xsequence/api@2.2.4 + - @0xsequence/core@2.2.4 + - @0xsequence/indexer@2.2.4 + - @0xsequence/metadata@2.2.4 + - @0xsequence/migration@2.2.4 + - @0xsequence/network@2.2.4 + - @0xsequence/sessions@2.2.4 + - @0xsequence/signhub@2.2.4 + - @0xsequence/utils@2.2.4 + - @0xsequence/wallet@2.2.4 + +## 2.2.3 + +### Patch Changes + +- provider: updating initWallet to use connected network configs if they exist +- Updated dependencies + - @0xsequence/abi@2.2.3 + - @0xsequence/account@2.2.3 + - @0xsequence/api@2.2.3 + - @0xsequence/core@2.2.3 + - @0xsequence/indexer@2.2.3 + - @0xsequence/metadata@2.2.3 + - @0xsequence/migration@2.2.3 + - @0xsequence/network@2.2.3 + - @0xsequence/sessions@2.2.3 + - @0xsequence/signhub@2.2.3 + - @0xsequence/utils@2.2.3 + - @0xsequence/wallet@2.2.3 + +## 2.2.2 + +### Patch Changes + +- pass projectAccessKey to relayer at all times +- Updated dependencies + - @0xsequence/abi@2.2.2 + - @0xsequence/account@2.2.2 + - @0xsequence/api@2.2.2 + - @0xsequence/core@2.2.2 + - @0xsequence/indexer@2.2.2 + - @0xsequence/metadata@2.2.2 + - @0xsequence/migration@2.2.2 + - @0xsequence/network@2.2.2 + - @0xsequence/sessions@2.2.2 + - @0xsequence/signhub@2.2.2 + - @0xsequence/utils@2.2.2 + - @0xsequence/wallet@2.2.2 + +## 2.2.1 + +### Patch Changes + +- waas-ethers: sign typed data +- Updated dependencies + - @0xsequence/abi@2.2.1 + - @0xsequence/account@2.2.1 + - @0xsequence/api@2.2.1 + - @0xsequence/core@2.2.1 + - @0xsequence/indexer@2.2.1 + - @0xsequence/metadata@2.2.1 + - @0xsequence/migration@2.2.1 + - @0xsequence/network@2.2.1 + - @0xsequence/sessions@2.2.1 + - @0xsequence/signhub@2.2.1 + - @0xsequence/utils@2.2.1 + - @0xsequence/wallet@2.2.1 + +## 2.2.0 + +### Minor Changes + +- indexer: gateway client +- @0xsequence/builder +- upgrade puppeteer to v23.10.3 + +### Patch Changes + +- Updated dependencies +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.2.0 + - @0xsequence/account@2.2.0 + - @0xsequence/api@2.2.0 + - @0xsequence/core@2.2.0 + - @0xsequence/indexer@2.2.0 + - @0xsequence/metadata@2.2.0 + - @0xsequence/migration@2.2.0 + - @0xsequence/network@2.2.0 + - @0xsequence/sessions@2.2.0 + - @0xsequence/signhub@2.2.0 + - @0xsequence/utils@2.2.0 + - @0xsequence/wallet@2.2.0 + +## 2.1.8 + +### Patch Changes + +- Add Soneium Mainnet +- Updated dependencies + - @0xsequence/abi@2.1.8 + - @0xsequence/account@2.1.8 + - @0xsequence/api@2.1.8 + - @0xsequence/core@2.1.8 + - @0xsequence/indexer@2.1.8 + - @0xsequence/metadata@2.1.8 + - @0xsequence/migration@2.1.8 + - @0xsequence/network@2.1.8 + - @0xsequence/sessions@2.1.8 + - @0xsequence/signhub@2.1.8 + - @0xsequence/utils@2.1.8 + - @0xsequence/wallet@2.1.8 + +## 2.1.7 + +### Patch Changes + +- guard: pass project access key to guard requests +- Updated dependencies + - @0xsequence/abi@2.1.7 + - @0xsequence/account@2.1.7 + - @0xsequence/api@2.1.7 + - @0xsequence/core@2.1.7 + - @0xsequence/indexer@2.1.7 + - @0xsequence/metadata@2.1.7 + - @0xsequence/migration@2.1.7 + - @0xsequence/network@2.1.7 + - @0xsequence/sessions@2.1.7 + - @0xsequence/signhub@2.1.7 + - @0xsequence/utils@2.1.7 + - @0xsequence/wallet@2.1.7 + +## 2.1.6 + +### Patch Changes + +- Add LAOS and Telos Testnet chains +- Updated dependencies + - @0xsequence/abi@2.1.6 + - @0xsequence/account@2.1.6 + - @0xsequence/api@2.1.6 + - @0xsequence/core@2.1.6 + - @0xsequence/indexer@2.1.6 + - @0xsequence/metadata@2.1.6 + - @0xsequence/migration@2.1.6 + - @0xsequence/network@2.1.6 + - @0xsequence/sessions@2.1.6 + - @0xsequence/signhub@2.1.6 + - @0xsequence/utils@2.1.6 + - @0xsequence/wallet@2.1.6 + +## 2.1.5 + +### Patch Changes + +- account: save presigned configuration with reference chain id 1 +- Updated dependencies + - @0xsequence/abi@2.1.5 + - @0xsequence/account@2.1.5 + - @0xsequence/api@2.1.5 + - @0xsequence/core@2.1.5 + - @0xsequence/indexer@2.1.5 + - @0xsequence/metadata@2.1.5 + - @0xsequence/migration@2.1.5 + - @0xsequence/network@2.1.5 + - @0xsequence/sessions@2.1.5 + - @0xsequence/signhub@2.1.5 + - @0xsequence/utils@2.1.5 + - @0xsequence/wallet@2.1.5 + +## 2.1.4 + +### Patch Changes + +- provider: pass projectAccessKey into MuxMessageProvider +- Updated dependencies + - @0xsequence/abi@2.1.4 + - @0xsequence/account@2.1.4 + - @0xsequence/api@2.1.4 + - @0xsequence/core@2.1.4 + - @0xsequence/indexer@2.1.4 + - @0xsequence/metadata@2.1.4 + - @0xsequence/migration@2.1.4 + - @0xsequence/network@2.1.4 + - @0xsequence/sessions@2.1.4 + - @0xsequence/signhub@2.1.4 + - @0xsequence/utils@2.1.4 + - @0xsequence/wallet@2.1.4 + +## 2.1.3 + +### Patch Changes + +- waas: time drift date fix due to strange browser quirk +- Updated dependencies + - @0xsequence/abi@2.1.3 + - @0xsequence/account@2.1.3 + - @0xsequence/api@2.1.3 + - @0xsequence/core@2.1.3 + - @0xsequence/indexer@2.1.3 + - @0xsequence/metadata@2.1.3 + - @0xsequence/migration@2.1.3 + - @0xsequence/network@2.1.3 + - @0xsequence/sessions@2.1.3 + - @0xsequence/signhub@2.1.3 + - @0xsequence/utils@2.1.3 + - @0xsequence/wallet@2.1.3 + +## 2.1.2 + +### Patch Changes + +- provider: export analytics correctly +- Updated dependencies + - @0xsequence/abi@2.1.2 + - @0xsequence/account@2.1.2 + - @0xsequence/api@2.1.2 + - @0xsequence/core@2.1.2 + - @0xsequence/indexer@2.1.2 + - @0xsequence/metadata@2.1.2 + - @0xsequence/migration@2.1.2 + - @0xsequence/network@2.1.2 + - @0xsequence/sessions@2.1.2 + - @0xsequence/signhub@2.1.2 + - @0xsequence/utils@2.1.2 + - @0xsequence/wallet@2.1.2 + +## 2.1.1 + +### Patch Changes + +- Add LAOS chain support +- Updated dependencies + - @0xsequence/abi@2.1.1 + - @0xsequence/account@2.1.1 + - @0xsequence/api@2.1.1 + - @0xsequence/core@2.1.1 + - @0xsequence/indexer@2.1.1 + - @0xsequence/metadata@2.1.1 + - @0xsequence/migration@2.1.1 + - @0xsequence/network@2.1.1 + - @0xsequence/sessions@2.1.1 + - @0xsequence/signhub@2.1.1 + - @0xsequence/utils@2.1.1 + - @0xsequence/wallet@2.1.1 + +## 2.1.0 + +### Minor Changes + +- account: forward project access key when estimating fees and sending transactions + +### Patch Changes + +- sessions: save signatures with reference chain id +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.1.0 + - @0xsequence/account@2.1.0 + - @0xsequence/api@2.1.0 + - @0xsequence/core@2.1.0 + - @0xsequence/indexer@2.1.0 + - @0xsequence/metadata@2.1.0 + - @0xsequence/migration@2.1.0 + - @0xsequence/network@2.1.0 + - @0xsequence/sessions@2.1.0 + - @0xsequence/signhub@2.1.0 + - @0xsequence/utils@2.1.0 + - @0xsequence/wallet@2.1.0 + +## 2.0.26 + +### Patch Changes + +- account: fix chain id comparison +- Updated dependencies + - @0xsequence/abi@2.0.26 + - @0xsequence/account@2.0.26 + - @0xsequence/api@2.0.26 + - @0xsequence/core@2.0.26 + - @0xsequence/indexer@2.0.26 + - @0xsequence/metadata@2.0.26 + - @0xsequence/migration@2.0.26 + - @0xsequence/network@2.0.26 + - @0xsequence/sessions@2.0.26 + - @0xsequence/signhub@2.0.26 + - @0xsequence/utils@2.0.26 + - @0xsequence/wallet@2.0.26 + +## 2.0.25 + +### Patch Changes + +- skale-nebula: deploy gas limit = 10m +- Updated dependencies + - @0xsequence/abi@2.0.25 + - @0xsequence/account@2.0.25 + - @0xsequence/api@2.0.25 + - @0xsequence/core@2.0.25 + - @0xsequence/indexer@2.0.25 + - @0xsequence/metadata@2.0.25 + - @0xsequence/migration@2.0.25 + - @0xsequence/network@2.0.25 + - @0xsequence/sessions@2.0.25 + - @0xsequence/signhub@2.0.25 + - @0xsequence/utils@2.0.25 + - @0xsequence/wallet@2.0.25 + +## 2.0.24 + +### Patch Changes + +- sessions: arweave: configurable gateway url +- waas: use /status to get time drift before sending any intents +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.24 + - @0xsequence/account@2.0.24 + - @0xsequence/api@2.0.24 + - @0xsequence/core@2.0.24 + - @0xsequence/indexer@2.0.24 + - @0xsequence/metadata@2.0.24 + - @0xsequence/migration@2.0.24 + - @0xsequence/network@2.0.24 + - @0xsequence/sessions@2.0.24 + - @0xsequence/signhub@2.0.24 + - @0xsequence/utils@2.0.24 + - @0xsequence/wallet@2.0.24 + +## 2.0.23 + +### Patch Changes + +- Add The Root Network support +- Updated dependencies + - @0xsequence/abi@2.0.23 + - @0xsequence/account@2.0.23 + - @0xsequence/api@2.0.23 + - @0xsequence/core@2.0.23 + - @0xsequence/indexer@2.0.23 + - @0xsequence/metadata@2.0.23 + - @0xsequence/migration@2.0.23 + - @0xsequence/network@2.0.23 + - @0xsequence/sessions@2.0.23 + - @0xsequence/signhub@2.0.23 + - @0xsequence/utils@2.0.23 + - @0xsequence/wallet@2.0.23 + +## 2.0.22 + +### Patch Changes + +- Add SKALE Nebula Mainnet support +- Updated dependencies + - @0xsequence/abi@2.0.22 + - @0xsequence/account@2.0.22 + - @0xsequence/api@2.0.22 + - @0xsequence/core@2.0.22 + - @0xsequence/indexer@2.0.22 + - @0xsequence/metadata@2.0.22 + - @0xsequence/migration@2.0.22 + - @0xsequence/network@2.0.22 + - @0xsequence/sessions@2.0.22 + - @0xsequence/signhub@2.0.22 + - @0xsequence/utils@2.0.22 + - @0xsequence/wallet@2.0.22 + +## 2.0.21 + +### Patch Changes + +- account: add publishWitnessFor +- Updated dependencies + - @0xsequence/abi@2.0.21 + - @0xsequence/account@2.0.21 + - @0xsequence/api@2.0.21 + - @0xsequence/core@2.0.21 + - @0xsequence/indexer@2.0.21 + - @0xsequence/metadata@2.0.21 + - @0xsequence/migration@2.0.21 + - @0xsequence/network@2.0.21 + - @0xsequence/sessions@2.0.21 + - @0xsequence/signhub@2.0.21 + - @0xsequence/utils@2.0.21 + - @0xsequence/wallet@2.0.21 + +## 2.0.20 + +### Patch Changes + +- upgrade deps, and improve waas session status handling +- Updated dependencies + - @0xsequence/abi@2.0.20 + - @0xsequence/account@2.0.20 + - @0xsequence/api@2.0.20 + - @0xsequence/core@2.0.20 + - @0xsequence/indexer@2.0.20 + - @0xsequence/metadata@2.0.20 + - @0xsequence/migration@2.0.20 + - @0xsequence/network@2.0.20 + - @0xsequence/sessions@2.0.20 + - @0xsequence/signhub@2.0.20 + - @0xsequence/utils@2.0.20 + - @0xsequence/wallet@2.0.20 + +## 2.0.19 + +### Patch Changes + +- Add Immutable zkEVM support +- Updated dependencies + - @0xsequence/abi@2.0.19 + - @0xsequence/account@2.0.19 + - @0xsequence/api@2.0.19 + - @0xsequence/core@2.0.19 + - @0xsequence/indexer@2.0.19 + - @0xsequence/metadata@2.0.19 + - @0xsequence/migration@2.0.19 + - @0xsequence/network@2.0.19 + - @0xsequence/sessions@2.0.19 + - @0xsequence/signhub@2.0.19 + - @0xsequence/utils@2.0.19 + - @0xsequence/wallet@2.0.19 + +## 2.0.18 + +### Patch Changes + +- waas: new contractCall transaction type +- sessions: add arweave owner +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.18 + - @0xsequence/account@2.0.18 + - @0xsequence/api@2.0.18 + - @0xsequence/core@2.0.18 + - @0xsequence/indexer@2.0.18 + - @0xsequence/metadata@2.0.18 + - @0xsequence/migration@2.0.18 + - @0xsequence/network@2.0.18 + - @0xsequence/sessions@2.0.18 + - @0xsequence/signhub@2.0.18 + - @0xsequence/utils@2.0.18 + - @0xsequence/wallet@2.0.18 + +## 2.0.17 + +### Patch Changes + +- update waas auth to clear session before signIn +- Updated dependencies + - @0xsequence/abi@2.0.17 + - @0xsequence/account@2.0.17 + - @0xsequence/api@2.0.17 + - @0xsequence/core@2.0.17 + - @0xsequence/indexer@2.0.17 + - @0xsequence/metadata@2.0.17 + - @0xsequence/migration@2.0.17 + - @0xsequence/network@2.0.17 + - @0xsequence/sessions@2.0.17 + - @0xsequence/signhub@2.0.17 + - @0xsequence/utils@2.0.17 + - @0xsequence/wallet@2.0.17 + +## 2.0.16 + +### Patch Changes + +- Removed Astar chains +- Updated dependencies + - @0xsequence/abi@2.0.16 + - @0xsequence/account@2.0.16 + - @0xsequence/api@2.0.16 + - @0xsequence/core@2.0.16 + - @0xsequence/indexer@2.0.16 + - @0xsequence/metadata@2.0.16 + - @0xsequence/migration@2.0.16 + - @0xsequence/network@2.0.16 + - @0xsequence/sessions@2.0.16 + - @0xsequence/signhub@2.0.16 + - @0xsequence/utils@2.0.16 + - @0xsequence/wallet@2.0.16 + +## 2.0.15 + +### Patch Changes + +- indexer: update bindings with token balance additions +- Updated dependencies + - @0xsequence/abi@2.0.15 + - @0xsequence/account@2.0.15 + - @0xsequence/api@2.0.15 + - @0xsequence/core@2.0.15 + - @0xsequence/indexer@2.0.15 + - @0xsequence/metadata@2.0.15 + - @0xsequence/migration@2.0.15 + - @0xsequence/network@2.0.15 + - @0xsequence/sessions@2.0.15 + - @0xsequence/signhub@2.0.15 + - @0xsequence/utils@2.0.15 + - @0xsequence/wallet@2.0.15 + +## 2.0.14 + +### Patch Changes + +- sessions: arweave config reader +- network: add b3 and apechain mainnet configs +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.14 + - @0xsequence/account@2.0.14 + - @0xsequence/api@2.0.14 + - @0xsequence/core@2.0.14 + - @0xsequence/indexer@2.0.14 + - @0xsequence/metadata@2.0.14 + - @0xsequence/migration@2.0.14 + - @0xsequence/network@2.0.14 + - @0xsequence/sessions@2.0.14 + - @0xsequence/signhub@2.0.14 + - @0xsequence/utils@2.0.14 + - @0xsequence/wallet@2.0.14 + +## 2.0.13 + +### Patch Changes + +- network: toy-testnet +- Updated dependencies + - @0xsequence/abi@2.0.13 + - @0xsequence/account@2.0.13 + - @0xsequence/api@2.0.13 + - @0xsequence/core@2.0.13 + - @0xsequence/indexer@2.0.13 + - @0xsequence/metadata@2.0.13 + - @0xsequence/migration@2.0.13 + - @0xsequence/network@2.0.13 + - @0xsequence/sessions@2.0.13 + - @0xsequence/signhub@2.0.13 + - @0xsequence/utils@2.0.13 + - @0xsequence/wallet@2.0.13 + +## 2.0.12 + +### Patch Changes + +- api: update bindings +- Updated dependencies + - @0xsequence/abi@2.0.12 + - @0xsequence/account@2.0.12 + - @0xsequence/api@2.0.12 + - @0xsequence/core@2.0.12 + - @0xsequence/indexer@2.0.12 + - @0xsequence/metadata@2.0.12 + - @0xsequence/migration@2.0.12 + - @0xsequence/network@2.0.12 + - @0xsequence/sessions@2.0.12 + - @0xsequence/signhub@2.0.12 + - @0xsequence/utils@2.0.12 + - @0xsequence/wallet@2.0.12 + +## 2.0.11 + +### Patch Changes + +- waas: intents test fix +- api: update bindings +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.11 + - @0xsequence/account@2.0.11 + - @0xsequence/api@2.0.11 + - @0xsequence/core@2.0.11 + - @0xsequence/indexer@2.0.11 + - @0xsequence/metadata@2.0.11 + - @0xsequence/migration@2.0.11 + - @0xsequence/network@2.0.11 + - @0xsequence/sessions@2.0.11 + - @0xsequence/signhub@2.0.11 + - @0xsequence/utils@2.0.11 + - @0xsequence/wallet@2.0.11 + +## 2.0.10 + +### Patch Changes + +- network: soneium minato testnet +- Updated dependencies + - @0xsequence/abi@2.0.10 + - @0xsequence/account@2.0.10 + - @0xsequence/api@2.0.10 + - @0xsequence/core@2.0.10 + - @0xsequence/indexer@2.0.10 + - @0xsequence/metadata@2.0.10 + - @0xsequence/migration@2.0.10 + - @0xsequence/network@2.0.10 + - @0xsequence/sessions@2.0.10 + - @0xsequence/signhub@2.0.10 + - @0xsequence/utils@2.0.10 + - @0xsequence/wallet@2.0.10 + +## 2.0.9 + +### Patch Changes + +- network: fix SKALE network name +- Updated dependencies + - @0xsequence/abi@2.0.9 + - @0xsequence/account@2.0.9 + - @0xsequence/api@2.0.9 + - @0xsequence/core@2.0.9 + - @0xsequence/indexer@2.0.9 + - @0xsequence/metadata@2.0.9 + - @0xsequence/migration@2.0.9 + - @0xsequence/network@2.0.9 + - @0xsequence/sessions@2.0.9 + - @0xsequence/signhub@2.0.9 + - @0xsequence/utils@2.0.9 + - @0xsequence/wallet@2.0.9 + +## 2.0.8 + +### Patch Changes + +- metadata: update bindings +- Updated dependencies + - @0xsequence/abi@2.0.8 + - @0xsequence/account@2.0.8 + - @0xsequence/api@2.0.8 + - @0xsequence/core@2.0.8 + - @0xsequence/indexer@2.0.8 + - @0xsequence/metadata@2.0.8 + - @0xsequence/migration@2.0.8 + - @0xsequence/network@2.0.8 + - @0xsequence/sessions@2.0.8 + - @0xsequence/signhub@2.0.8 + - @0xsequence/utils@2.0.8 + - @0xsequence/wallet@2.0.8 + +## 2.0.7 + +### Patch Changes + +- wallet request handler fix +- Updated dependencies + - @0xsequence/abi@2.0.7 + - @0xsequence/account@2.0.7 + - @0xsequence/api@2.0.7 + - @0xsequence/core@2.0.7 + - @0xsequence/indexer@2.0.7 + - @0xsequence/metadata@2.0.7 + - @0xsequence/migration@2.0.7 + - @0xsequence/network@2.0.7 + - @0xsequence/sessions@2.0.7 + - @0xsequence/signhub@2.0.7 + - @0xsequence/utils@2.0.7 + - @0xsequence/wallet@2.0.7 + +## 2.0.6 + +### Patch Changes + +- network: matic -> pol +- Updated dependencies + - @0xsequence/abi@2.0.6 + - @0xsequence/account@2.0.6 + - @0xsequence/api@2.0.6 + - @0xsequence/core@2.0.6 + - @0xsequence/indexer@2.0.6 + - @0xsequence/metadata@2.0.6 + - @0xsequence/migration@2.0.6 + - @0xsequence/network@2.0.6 + - @0xsequence/sessions@2.0.6 + - @0xsequence/signhub@2.0.6 + - @0xsequence/utils@2.0.6 + - @0xsequence/wallet@2.0.6 + +## 2.0.5 + +### Patch Changes + +- provider: update databeat to 0.9.2 +- Updated dependencies + - @0xsequence/abi@2.0.5 + - @0xsequence/account@2.0.5 + - @0xsequence/api@2.0.5 + - @0xsequence/core@2.0.5 + - @0xsequence/indexer@2.0.5 + - @0xsequence/metadata@2.0.5 + - @0xsequence/migration@2.0.5 + - @0xsequence/network@2.0.5 + - @0xsequence/sessions@2.0.5 + - @0xsequence/signhub@2.0.5 + - @0xsequence/utils@2.0.5 + - @0xsequence/wallet@2.0.5 + +## 2.0.4 + +### Patch Changes + +- network: add skale-nebula-testnet +- Updated dependencies + - @0xsequence/abi@2.0.4 + - @0xsequence/account@2.0.4 + - @0xsequence/api@2.0.4 + - @0xsequence/core@2.0.4 + - @0xsequence/indexer@2.0.4 + - @0xsequence/metadata@2.0.4 + - @0xsequence/migration@2.0.4 + - @0xsequence/network@2.0.4 + - @0xsequence/sessions@2.0.4 + - @0xsequence/signhub@2.0.4 + - @0xsequence/utils@2.0.4 + - @0xsequence/wallet@2.0.4 + +## 2.0.3 + +### Patch Changes + +- waas: check session status in SequenceWaaS.isSignedIn() +- Updated dependencies + - @0xsequence/abi@2.0.3 + - @0xsequence/account@2.0.3 + - @0xsequence/api@2.0.3 + - @0xsequence/core@2.0.3 + - @0xsequence/indexer@2.0.3 + - @0xsequence/metadata@2.0.3 + - @0xsequence/migration@2.0.3 + - @0xsequence/network@2.0.3 + - @0xsequence/sessions@2.0.3 + - @0xsequence/signhub@2.0.3 + - @0xsequence/utils@2.0.3 + - @0xsequence/wallet@2.0.3 + +## 2.0.2 + +### Patch Changes + +- sessions: property convert serialized bignumber hex value to bigint +- Updated dependencies + - @0xsequence/abi@2.0.2 + - @0xsequence/account@2.0.2 + - @0xsequence/api@2.0.2 + - @0xsequence/core@2.0.2 + - @0xsequence/indexer@2.0.2 + - @0xsequence/metadata@2.0.2 + - @0xsequence/migration@2.0.2 + - @0xsequence/network@2.0.2 + - @0xsequence/sessions@2.0.2 + - @0xsequence/signhub@2.0.2 + - @0xsequence/utils@2.0.2 + - @0xsequence/wallet@2.0.2 + +## 2.0.1 + +### Patch Changes + +- waas: http signature check for authenticator requests +- provider: unwrap legacy json rpc responses +- use json replacer and reviver for bigints +- Updated dependencies +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.1 + - @0xsequence/account@2.0.1 + - @0xsequence/api@2.0.1 + - @0xsequence/core@2.0.1 + - @0xsequence/indexer@2.0.1 + - @0xsequence/metadata@2.0.1 + - @0xsequence/migration@2.0.1 + - @0xsequence/network@2.0.1 + - @0xsequence/sessions@2.0.1 + - @0xsequence/signhub@2.0.1 + - @0xsequence/utils@2.0.1 + - @0xsequence/wallet@2.0.1 + +## 2.0.0 + +### Major Changes + +- ethers v6 + +### Patch Changes + +- Updated dependencies + - @0xsequence/abi@2.0.0 + - @0xsequence/account@2.0.0 + - @0xsequence/api@2.0.0 + - @0xsequence/core@2.0.0 + - @0xsequence/indexer@2.0.0 + - @0xsequence/metadata@2.0.0 + - @0xsequence/migration@2.0.0 + - @0xsequence/network@2.0.0 + - @0xsequence/sessions@2.0.0 + - @0xsequence/signhub@2.0.0 + - @0xsequence/utils@2.0.0 + - @0xsequence/wallet@2.0.0 + +## 1.10.15 + +### Patch Changes + +- utils: extractProjectIdFromAccessKey +- Updated dependencies + - @0xsequence/abi@1.10.15 + - @0xsequence/account@1.10.15 + - @0xsequence/api@1.10.15 + - @0xsequence/core@1.10.15 + - @0xsequence/indexer@1.10.15 + - @0xsequence/metadata@1.10.15 + - @0xsequence/migration@1.10.15 + - @0xsequence/network@1.10.15 + - @0xsequence/sessions@1.10.15 + - @0xsequence/signhub@1.10.15 + - @0xsequence/utils@1.10.15 + - @0xsequence/wallet@1.10.15 + ## 1.10.14 ### Patch Changes diff --git a/packages/auth/package.json b/packages/auth/package.json index 7f328ca22..d80ad9556 100644 --- a/packages/auth/package.json +++ b/packages/auth/package.json @@ -1,6 +1,6 @@ { "name": "@0xsequence/auth", - "version": "1.10.14", + "version": "2.2.14", "description": "auth sub-package for Sequence", "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/auth", "source": "src/index.ts", @@ -11,7 +11,7 @@ "scripts": { "test": "pnpm test:concurrently 'pnpm test:run'", "test:run": "pnpm test:file tests/**/*.spec.ts", - "test:file": "NODE_OPTIONS='--import tsx' mocha --timeout 30000", + "test:file": "NODE_OPTIONS='--import tsx' mocha --timeout 60000", "test:concurrently": "concurrently -k --success first 'pnpm start:hardhat > /dev/null' ", "start:hardhat": "hardhat node --port 9546", "typecheck": "tsc --noEmit" @@ -21,7 +21,7 @@ "@0xsequence/account": "workspace:*", "@0xsequence/api": "workspace:*", "@0xsequence/core": "workspace:*", - "@0xsequence/ethauth": "^0.8.1", + "@0xsequence/ethauth": "^1.0.0", "@0xsequence/indexer": "workspace:*", "@0xsequence/metadata": "workspace:*", "@0xsequence/migration": "workspace:*", @@ -32,14 +32,14 @@ "@0xsequence/utils": "workspace:*" }, "peerDependencies": { - "ethers": ">=5.5 < 6" + "ethers": ">=6" }, "devDependencies": { "@0xsequence/tests": "workspace:*", - "@0xsequence/wallet-contracts": "^1.10.0", - "concurrently": "^7.5.0", - "ethers": "^5.7.2", - "hardhat": "^2.20.1", + "@0xsequence/wallet-contracts": "^3.0.1", + "concurrently": "^9.0.1", + "ethers": "6.13.4", + "hardhat": "^2.22.14", "mockttp": "^3.6.0" }, "files": [ diff --git a/packages/auth/src/authorization.ts b/packages/auth/src/authorization.ts index 103c2b2a7..1eacdd7a8 100644 --- a/packages/auth/src/authorization.ts +++ b/packages/auth/src/authorization.ts @@ -35,7 +35,7 @@ export const signAuthorization = async ( chainId: ChainIdLike, options: AuthorizationOptions ): Promise => { - const address = ethers.utils.getAddress(await signer.getAddress()) + const address = ethers.getAddress(await signer.getAddress()) if (!address || address === '' || address === '0x') { throw ErrAccountIsRequired } diff --git a/packages/auth/src/proof.ts b/packages/auth/src/proof.ts index 23051fde6..1753ef5fc 100644 --- a/packages/auth/src/proof.ts +++ b/packages/auth/src/proof.ts @@ -8,7 +8,7 @@ export const ValidateSequenceWalletProof = ( tracker: tracker.ConfigTracker, context: commons.context.WalletContext ): ValidatorFunc => { - return async (_provider: ethers.providers.JsonRpcProvider, chainId: number, proof: Proof): Promise<{ isValid: boolean }> => { + return async (_provider: ethers.JsonRpcProvider, chainId: number, proof: Proof): Promise<{ isValid: boolean }> => { const digest = proof.messageDigest() const isValid = await readerFor(chainId).isValidSignature(proof.address, digest, proof.signature) return { isValid } diff --git a/packages/auth/src/services.ts b/packages/auth/src/services.ts index 6db53a216..fdc4bc9c9 100644 --- a/packages/auth/src/services.ts +++ b/packages/auth/src/services.ts @@ -1,10 +1,10 @@ import { Account } from '@0xsequence/account' import { SequenceAPIClient } from '@0xsequence/api' import { ETHAuth, Proof } from '@0xsequence/ethauth' -import { Indexer, SequenceIndexer } from '@0xsequence/indexer' +import { Indexer, SequenceIndexer, SequenceIndexerGateway } from '@0xsequence/indexer' import { SequenceMetadata } from '@0xsequence/metadata' import { ChainIdLike, findNetworkConfig } from '@0xsequence/network' -import { getEthersConnectionInfo } from '@0xsequence/utils' +import { getFetchRequest } from '@0xsequence/utils' import { ethers } from 'ethers' export type SessionMeta = { @@ -20,6 +20,7 @@ export type ServicesSettings = { sequenceApiUrl: string sequenceApiChainId: ethers.BigNumberish sequenceMetadataUrl: string + sequenceIndexerGatewayUrl: string } export type SessionJWT = { @@ -56,6 +57,7 @@ export class Services { private apiClient: SequenceAPIClient | undefined private metadataClient: SequenceMetadata | undefined private indexerClients: Map = new Map() + private indexerGateway: SequenceIndexerGateway | undefined private projectAccessKey?: string @@ -201,21 +203,21 @@ export class Services { private async isProofStringValid(proofString: string): Promise { try { const ethAuth = new ETHAuth() - const chainId = ethers.BigNumber.from(this.settings.sequenceApiChainId) - const network = findNetworkConfig(this.account.networks, chainId) - if (!network) throw Error('No network found') - ethAuth.chainId = chainId.toNumber() + const chainId = BigInt(this.settings.sequenceApiChainId) + const found = findNetworkConfig(this.account.networks, chainId) + if (!found) { + throw Error('No network found') + } + ethAuth.chainId = Number(chainId) + + const network = new ethers.Network(found.name, chainId) // TODO: Modify ETHAuth so it can take a provider instead of a url // ----- // Can't pass jwt here since this is used for getting the jwt - ethAuth.provider = new ethers.providers.StaticJsonRpcProvider( - getEthersConnectionInfo(network.rpcUrl, this.projectAccessKey), - { - name: '', - chainId: chainId.toNumber() - } - ) + ethAuth.provider = new ethers.JsonRpcProvider(getFetchRequest(found.rpcUrl, this.projectAccessKey), network, { + staticNetwork: network + }) await ethAuth.decodeProof(proofString) @@ -266,6 +268,15 @@ export class Services { return this.indexerClients.get(network.chainId)! } + async getIndexerGateway(tryAuth: boolean = true): Promise { + if (!this.indexerGateway) { + const jwtAuth = (await this.getJWT(tryAuth)).token + this.indexerGateway = new SequenceIndexerGateway(this.settings.sequenceIndexerGatewayUrl, undefined, jwtAuth) + } + + return this.indexerGateway + } + private getProofString(key: string): ProofStringPromise { // check if we already have or are waiting for a proof string if (this.proofStrings.has(key)) { @@ -290,20 +301,21 @@ export class Services { proof.setExpiryIn(this.expiration) const ethAuth = new ETHAuth() - const chainId = ethers.BigNumber.from(this.settings.sequenceApiChainId) - const network = findNetworkConfig(this.account.networks, chainId) - if (!network) throw Error('No network found') - ethAuth.chainId = chainId.toNumber() + const chainId = BigInt(this.settings.sequenceApiChainId) + const found = findNetworkConfig(this.account.networks, chainId) + if (!found) { + throw Error('No network found') + } + ethAuth.chainId = Number(chainId) + + const network = new ethers.Network(found.name, chainId) + // TODO: Modify ETHAuth so it can take a provider instead of a url // ----- // Can't pass jwt here since this is used for getting the jwt - ethAuth.provider = new ethers.providers.StaticJsonRpcProvider( - getEthersConnectionInfo(network.rpcUrl, this.projectAccessKey), - { - name: '', - chainId: chainId.toNumber() - } - ) + ethAuth.provider = new ethers.JsonRpcProvider(getFetchRequest(found.rpcUrl, this.projectAccessKey), network, { + staticNetwork: network + }) const expiration = this.now() + this.expiration - EXPIRATION_JWT_MARGIN diff --git a/packages/auth/src/session.ts b/packages/auth/src/session.ts index 84820df9a..18f08a6e1 100644 --- a/packages/auth/src/session.ts +++ b/packages/auth/src/session.ts @@ -260,7 +260,7 @@ export class Session { // Only update the onchain config if the imageHash has changed if (account.coders.config.imageHashOf(prevConfig) !== account.coders.config.imageHashOf(nextConfig)) { const newConfig = account.coders.config.editConfig(nextConfig, { - checkpoint: account.coders.config.checkpointOf(prevConfig).add(1) + checkpoint: account.coders.config.checkpointOf(prevConfig) + 1n }) await account.updateConfig(newConfig) @@ -321,8 +321,9 @@ export class Session { dump: SessionDumpV1 | SessionDumpV2 editConfigOnMigration: (config: commons.config.Config) => commons.config.Config onMigration?: (account: Account) => Promise + projectAccessKey?: string }): Promise { - const { dump, settings, editConfigOnMigration, onMigration, orchestrator } = args + const { dump, settings, editConfigOnMigration, onMigration, orchestrator, projectAccessKey } = args const { contexts, networks, tracker, services } = { ...SessionSettingsDefault, ...settings } let account: Account @@ -343,7 +344,8 @@ export class Session { networks, contexts, orchestrator, - jwt: jwtExpired ? undefined : dump.jwt?.token + jwt: jwtExpired ? undefined : dump.jwt?.token, + projectAccessKey }) // TODO: This property may not hold if the user adds a new network @@ -370,7 +372,8 @@ export class Session { networks, contexts, orchestrator, - jwt: jwtExpired ? undefined : dump.jwt?.token + jwt: jwtExpired ? undefined : dump.jwt?.token, + projectAccessKey }) } else { throw Error('Invalid dump format') diff --git a/packages/auth/tests/session.spec.ts b/packages/auth/tests/session.spec.ts index 8e0c4091d..bba425b9a 100644 --- a/packages/auth/tests/session.spec.ts +++ b/packages/auth/tests/session.spec.ts @@ -10,7 +10,7 @@ import * as utils from '@0xsequence/tests' import { CallReceiverMock, HookCallerMock } from '@0xsequence/wallet-contracts' import * as chai from 'chai' import chaiAsPromised from 'chai-as-promised' -import { ethers, Signer as AbstractSigner } from 'ethers' +import { ethers } from 'ethers' import * as mockServer from 'mockttp' import { Session, SessionDumpV1, SessionSettings, ValidateSequenceWalletProof } from '../src' import { delay, mockDate } from './utils' @@ -25,14 +25,14 @@ const deterministic = false type EthereumInstance = { chainId?: number providerUrl?: string - provider?: ethers.providers.JsonRpcProvider - signer?: AbstractSigner + provider?: ethers.JsonRpcProvider + signer?: ethers.Signer } -class CountingSigner extends AbstractSigner { +class CountingSigner extends ethers.AbstractSigner { private _signingRequests: number = 0 - constructor(private readonly signer: AbstractSigner) { + constructor(private readonly signer: ethers.Signer) { super() } @@ -44,17 +44,26 @@ class CountingSigner extends AbstractSigner { return this.signer.getAddress() } - signMessage(message: ethers.Bytes | string): Promise { + signMessage(message: ethers.BytesLike): Promise { this._signingRequests++ return this.signer.signMessage(message) } - signTransaction(transaction: ethers.utils.Deferrable): Promise { + signTransaction(transaction: ethers.TransactionRequest): Promise { this._signingRequests++ return this.signer.signTransaction(transaction) } - connect(provider: ethers.providers.Provider): ethers.Signer { + signTypedData( + domain: ethers.TypedDataDomain, + types: Record, + value: Record + ): Promise { + this._signingRequests++ + return this.signer.signTypedData(domain, types, value) + } + + connect(provider: ethers.Provider): ethers.Signer { return this.signer.connect(provider) } } @@ -76,11 +85,11 @@ describe('Wallet integration', function () { before(async () => { // Provider from hardhat without a server instance ethnode.providerUrl = `http://127.0.0.1:9546/` - ethnode.provider = new ethers.providers.JsonRpcProvider(ethnode.providerUrl) + ethnode.provider = new ethers.JsonRpcProvider(ethnode.providerUrl) const chainId = (await ethnode.provider.getNetwork()).chainId - ethnode.signer = ethnode.provider.getSigner() - ethnode.chainId = chainId + ethnode.signer = await ethnode.provider.getSigner() + ethnode.chainId = Number(chainId) // Deploy local relayer relayer = new LocalRelayer(ethnode.signer) @@ -88,7 +97,7 @@ describe('Wallet integration', function () { networks = [ { name: 'local', - chainId, + chainId: Number(chainId), provider: ethnode.provider, isDefaultChain: true, relayer, @@ -108,14 +117,14 @@ describe('Wallet integration', function () { CallReceiverMockArtifact.abi, CallReceiverMockArtifact.bytecode, ethnode.signer - ).deploy()) as CallReceiverMock + ) + .deploy() + .then(tx => tx.waitForDeployment())) as CallReceiverMock // Deploy hook caller mock - hookCaller = (await new ethers.ContractFactory( - HookCallerMockArtifact.abi, - HookCallerMockArtifact.bytecode, - ethnode.signer - ).deploy()) as HookCallerMock + hookCaller = (await new ethers.ContractFactory(HookCallerMockArtifact.abi, HookCallerMockArtifact.bytecode, ethnode.signer) + .deploy() + .then(tx => tx.waitForDeployment())) as HookCallerMock tracker = new trackers.local.LocalConfigTracker(ethnode.provider!) orchestrator = new Orchestrator([]) @@ -152,19 +161,19 @@ describe('Wallet integration', function () { editConfigOnMigration: config => config }) - expect(session.account.address).to.not.equal(ethers.constants.AddressZero) + expect(session.account.address).to.not.equal(ethers.ZeroAddress) const status = await session.account.status(networks[0].chainId) expect(v2.config.isWalletConfig(status.config)).to.equal(true) const configv2 = status.config as v2.config.WalletConfig - expect(ethers.BigNumber.from(configv2.threshold)).to.deep.equal(ethers.BigNumber.from(1)) + expect(BigInt(configv2.threshold)).to.equal(1n) expect(v2.config.isSignerLeaf(configv2.tree)).to.equal(true) const leaf = configv2.tree as v2.config.SignerLeaf expect(leaf.address).to.equal(referenceSigner.address) - expect(ethers.BigNumber.from(leaf.weight)).to.deep.equal(ethers.BigNumber.from(1)) + expect(BigInt(leaf.weight)).to.equal(1n) await session.account.sendTransaction({ to: referenceSigner.address }, networks[0].chainId) }) @@ -231,14 +240,14 @@ describe('Wallet integration', function () { const newConfig = (await session2.account.status(networks[0].chainId).then(s => s.config)) as v2.config.WalletConfig expect(session2.account.address).to.equal(session.account.address) - expect(ethers.BigNumber.from(newConfig.threshold)).to.deep.equal(ethers.BigNumber.from(2)) + expect(BigInt(newConfig.threshold)).to.equal(2n) const newSigners = v2.config.signersOf(newConfig.tree).map(s => s.address) expect(newSigners.length).to.equal(2) expect(newSigners).to.include(newSigner.address) expect(newSigners).to.include(referenceSigner.address) - expect(ethers.BigNumber.from((newConfig.tree as any).left.weight)).to.deep.equal(ethers.BigNumber.from(1)) - expect(ethers.BigNumber.from((newConfig.tree as any).right.weight)).to.deep.equal(ethers.BigNumber.from(1)) + expect(BigInt((newConfig.tree as any).left.weight)).to.equal(1n) + expect(BigInt((newConfig.tree as any).right.weight)).to.equal(1n) }) it('Should create a new account if selectWallet returns undefined', async () => { @@ -563,7 +572,7 @@ describe('Wallet integration', function () { } } - fakeJwt = ethers.utils.hexlify(randomBytes(64, `JWT Auth ${fakeJwtIndex++}`)) + fakeJwt = ethers.hexlify(randomBytes(64, `JWT Auth ${fakeJwtIndex++}`)) server = mockServer.getLocal() server.start(8099) @@ -587,7 +596,7 @@ describe('Wallet integration', function () { try { const proof = await ethauth.decodeProof((await request.body.getJson())!['ewtString']) - proofAddress = ethers.utils.getAddress(proof.address) + proofAddress = ethers.getAddress(proof.address) if (recoverCount[proofAddress]) { recoverCount[proofAddress]++ @@ -1164,7 +1173,7 @@ describe('Wallet integration', function () { const newBaseTime = baseTime + 60 * 60 setDate(newBaseTime) - fakeJwt = ethers.utils.hexlify(randomBytes(96, 'Should request a new JWT after expiration 2')) + fakeJwt = ethers.hexlify(randomBytes(96, 'Should request a new JWT after expiration 2')) await session.services?.getAPIClient() @@ -1337,7 +1346,8 @@ describe('Wallet integration', function () { const session = await Session.singleSigner({ settings: simpleSettings, - signer: signer + signer: signer, + projectAccessKey: '' }) expect(session.account.address).to.not.be.undefined @@ -1358,7 +1368,8 @@ describe('Wallet integration', function () { const session1 = await Session.singleSigner({ settings: simpleSettings, - signer: signer + signer: signer, + projectAccessKey: '' }) const address1 = session1.account.address @@ -1366,7 +1377,8 @@ describe('Wallet integration', function () { const session2 = await Session.singleSigner({ settings: simpleSettings, - signer: signer + signer: signer, + projectAccessKey: '' }) const address2 = session2.account.address @@ -1383,7 +1395,8 @@ describe('Wallet integration', function () { const session = await Session.singleSigner({ settings: simpleSettings, - signer: signer + signer: signer, + projectAccessKey: '' }) const receipt = await session.account.sendTransaction( @@ -1393,7 +1406,7 @@ describe('Wallet integration', function () { networks[0].chainId ) - expect(receipt.hash).to.not.be.undefined + expect(receipt?.hash).to.not.be.undefined }) }) }) @@ -1408,17 +1421,17 @@ function now(): number { } function randomWallet(entropy: number | string): ethers.Wallet { - return new ethers.Wallet(randomBytes(32, entropy)) + return new ethers.Wallet(ethers.hexlify(randomBytes(32, entropy))) } function randomBytes(length: number, entropy: number | string): Uint8Array { if (deterministic) { let bytes = '' while (bytes.length < 2 * length) { - bytes += ethers.utils.id(`${bytes}${entropy}`).slice(2) + bytes += ethers.id(`${bytes}${entropy}`).slice(2) } - return ethers.utils.arrayify(`0x${bytes.slice(0, 2 * length)}`) + return ethers.getBytes(`0x${bytes.slice(0, 2 * length)}`) } else { - return ethers.utils.randomBytes(length) + return ethers.randomBytes(length) } } diff --git a/packages/builder/CHANGELOG.md b/packages/builder/CHANGELOG.md new file mode 100644 index 000000000..979ffb2d6 --- /dev/null +++ b/packages/builder/CHANGELOG.md @@ -0,0 +1,95 @@ +# @0xsequence/builder + +## 2.2.14 + +### Patch Changes + +- Somnia Testnet and Monad Testnet + +## 2.2.13 + +### Patch Changes + +- Add XR1 to all networks + +## 2.2.12 + +### Patch Changes + +- Add XR1 + +## 2.2.11 + +### Patch Changes + +- Relayer updates + +## 2.2.10 + +### Patch Changes + +- Etherlink support + +## 2.2.9 + +### Patch Changes + +- Indexer gateway native token balances + +## 2.2.8 + +### Patch Changes + +- Add Moonbeam and Moonbase Alpha + +## 2.2.7 + +### Patch Changes + +- Update Builder package + +## 2.2.6 + +### Patch Changes + +- Update relayer package + +## 2.2.5 + +### Patch Changes + +- auth: fix sequence indexer gateway url +- account: immutable wallet proxy hook + +## 2.2.4 + +### Patch Changes + +- network: update soneium mainnet block explorer url +- waas: signTypedData intent support + +## 2.2.3 + +### Patch Changes + +- provider: updating initWallet to use connected network configs if they exist + +## 2.2.2 + +### Patch Changes + +- pass projectAccessKey to relayer at all times + +## 2.2.1 + +### Patch Changes + +- waas-ethers: sign typed data + +## 2.2.0 + +### Minor Changes + +- indexer: gateway client +- @0xsequence/builder +- upgrade puppeteer to v23.10.3 diff --git a/packages/builder/README.md b/packages/builder/README.md new file mode 100644 index 000000000..4c74ce616 --- /dev/null +++ b/packages/builder/README.md @@ -0,0 +1,4 @@ +@0xsequence/builder +=================== + +See [0xsequence project page](https://github.com/0xsequence/sequence.js). diff --git a/packages/builder/package.json b/packages/builder/package.json new file mode 100644 index 000000000..b3140cae9 --- /dev/null +++ b/packages/builder/package.json @@ -0,0 +1,22 @@ +{ + "name": "@0xsequence/builder", + "version": "2.2.14", + "description": "builder sub-package for Sequence", + "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/builder", + "source": "src/index.ts", + "main": "dist/0xsequence-builder.cjs.js", + "module": "dist/0xsequence-builder.esm.js", + "author": "Horizon Blockchain Games", + "license": "Apache-2.0", + "scripts": { + "test": "echo", + "typecheck": "tsc --noEmit" + }, + "dependencies": {}, + "peerDependencies": {}, + "devDependencies": {}, + "files": [ + "src", + "dist" + ] +} diff --git a/packages/builder/src/builder.gen.ts b/packages/builder/src/builder.gen.ts new file mode 100644 index 000000000..cb2a6454d --- /dev/null +++ b/packages/builder/src/builder.gen.ts @@ -0,0 +1,714 @@ +/* eslint-disable */ +// NOTE: this is just a subset of the builder api to scope down the +// surface area of the client. +// +// In the future we can include additional interfaces as needed. +export const WebrpcHeader = 'Webrpc' + +export const WebrpcHeaderValue = 'webrpc@v0.22.1;gen-typescript@v0.16.2;sequence-builder@v0.1.0' + +// WebRPC description and code-gen version +export const WebRPCVersion = 'v1' + +// Schema version of your RIDL schema +export const WebRPCSchemaVersion = 'v0.1.0' + +// Schema hash generated from your RIDL schema +export const WebRPCSchemaHash = '461bc324d241f4df14fbf63268fde2cfe4873e3e' + +type WebrpcGenVersions = { + webrpcGenVersion: string + codeGenName: string + codeGenVersion: string + schemaName: string + schemaVersion: string +} + +export function VersionFromHeader(headers: Headers): WebrpcGenVersions { + const headerValue = headers.get(WebrpcHeader) + if (!headerValue) { + return { + webrpcGenVersion: '', + codeGenName: '', + codeGenVersion: '', + schemaName: '', + schemaVersion: '' + } + } + + return parseWebrpcGenVersions(headerValue) +} + +function parseWebrpcGenVersions(header: string): WebrpcGenVersions { + const versions = header.split(';') + if (versions.length < 3) { + return { + webrpcGenVersion: '', + codeGenName: '', + codeGenVersion: '', + schemaName: '', + schemaVersion: '' + } + } + + const [_, webrpcGenVersion] = versions[0].split('@') + const [codeGenName, codeGenVersion] = versions[1].split('@') + const [schemaName, schemaVersion] = versions[2].split('@') + + return { + webrpcGenVersion, + codeGenName, + codeGenVersion, + schemaName, + schemaVersion + } +} + +// +// Types +// + +export interface AudienceContact { + id?: number + audienceId: number + name?: string + address: string + email?: string + userIp?: string + stage?: number + provider?: string + createdAt?: string + updatedAt?: string +} + +export interface AudienceRegistrationStatus { + totalCount: number +} + +export interface WalletProof { + address: string + message: string + signature: string + chainId: number +} + +export interface Builder { + ping(headers?: object, signal?: AbortSignal): Promise + registerAudienceContact( + args: RegisterAudienceContactArgs, + headers?: object, + signal?: AbortSignal + ): Promise + getRegisteredAudienceContact( + args: GetRegisteredAudienceContactArgs, + headers?: object, + signal?: AbortSignal + ): Promise + getAudienceRegistrationPublicStatus( + args: GetAudienceRegistrationPublicStatusArgs, + headers?: object, + signal?: AbortSignal + ): Promise + isAudienceContactRegistered( + args: IsAudienceContactRegisteredArgs, + headers?: object, + signal?: AbortSignal + ): Promise +} + +export interface PingArgs {} + +export interface PingReturn { + status: boolean +} + +export interface RegisterAudienceContactArgs { + projectId: number + audienceId: number + contact: AudienceContact + walletProof: WalletProof +} + +export interface RegisterAudienceContactReturn { + ok: boolean +} +export interface GetRegisteredAudienceContactArgs { + projectId: number + audienceId: number + walletProof: WalletProof +} + +export interface GetRegisteredAudienceContactReturn { + contact: AudienceContact +} +export interface GetAudienceRegistrationPublicStatusArgs { + projectId: number + audienceId: number +} + +export interface GetAudienceRegistrationPublicStatusReturn { + status: AudienceRegistrationStatus +} +export interface IsAudienceContactRegisteredArgs { + projectId: number + audienceId: number + walletAddress: string +} + +export interface IsAudienceContactRegisteredReturn { + registered: boolean +} + +// +// Client +// +export class Builder implements Builder { + protected hostname: string + protected fetch: Fetch + protected path = '/rpc/Builder/' + + constructor(hostname: string, fetch: Fetch) { + this.hostname = hostname.replace(/\/*$/, '') + this.fetch = (input: RequestInfo, init?: RequestInit) => fetch(input, init) + } + + private url(name: string): string { + return this.hostname + this.path + name + } + + ping = (headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('Ping'), createHTTPRequest({}, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + status: _data.status + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + registerAudienceContact = ( + args: RegisterAudienceContactArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('RegisterAudienceContact'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + ok: _data.ok + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + getRegisteredAudienceContact = ( + args: GetRegisteredAudienceContactArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('GetRegisteredAudienceContact'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + contact: _data.contact + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + getAudienceRegistrationPublicStatus = ( + args: GetAudienceRegistrationPublicStatusArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('GetAudienceRegistrationPublicStatus'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + status: _data.status + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + isAudienceContactRegistered = ( + args: IsAudienceContactRegisteredArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('IsAudienceContactRegistered'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + registered: _data.registered + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } +} + +const createHTTPRequest = (body: object = {}, headers: object = {}, signal: AbortSignal | null = null): object => { + const reqHeaders: { [key: string]: string } = { ...headers, 'Content-Type': 'application/json' } + reqHeaders[WebrpcHeader] = WebrpcHeaderValue + + return { + method: 'POST', + headers: reqHeaders, + body: JSON.stringify(body || {}), + signal + } +} + +const buildResponse = (res: Response): Promise => { + return res.text().then(text => { + let data + try { + data = JSON.parse(text) + } catch (error) { + let message = '' + if (error instanceof Error) { + message = error.message + } + throw WebrpcBadResponseError.new({ + status: res.status, + cause: `JSON.parse(): ${message}: response text: ${text}` + }) + } + if (!res.ok) { + const code: number = typeof data.code === 'number' ? data.code : 0 + throw (webrpcErrorByCode[code] || WebrpcError).new(data) + } + return data + }) +} + +// +// Errors +// + +export class WebrpcError extends Error { + name: string + code: number + message: string + status: number + cause?: string + + /** @deprecated Use message instead of msg. Deprecated in webrpc v0.11.0. */ + msg: string + + constructor(name: string, code: number, message: string, status: number, cause?: string) { + super(message) + this.name = name || 'WebrpcError' + this.code = typeof code === 'number' ? code : 0 + this.message = message || `endpoint error ${this.code}` + this.msg = this.message + this.status = typeof status === 'number' ? status : 0 + this.cause = cause + Object.setPrototypeOf(this, WebrpcError.prototype) + } + + static new(payload: any): WebrpcError { + return new this(payload.error, payload.code, payload.message || payload.msg, payload.status, payload.cause) + } +} + +// Webrpc errors + +export class WebrpcEndpointError extends WebrpcError { + constructor( + name: string = 'WebrpcEndpoint', + code: number = 0, + message: string = 'endpoint error', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, WebrpcEndpointError.prototype) + } +} + +export class WebrpcRequestFailedError extends WebrpcError { + constructor( + name: string = 'WebrpcRequestFailed', + code: number = -1, + message: string = 'request failed', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, WebrpcRequestFailedError.prototype) + } +} + +export class WebrpcBadRouteError extends WebrpcError { + constructor( + name: string = 'WebrpcBadRoute', + code: number = -2, + message: string = 'bad route', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, WebrpcBadRouteError.prototype) + } +} + +export class WebrpcBadMethodError extends WebrpcError { + constructor( + name: string = 'WebrpcBadMethod', + code: number = -3, + message: string = 'bad method', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, WebrpcBadMethodError.prototype) + } +} + +export class WebrpcBadRequestError extends WebrpcError { + constructor( + name: string = 'WebrpcBadRequest', + code: number = -4, + message: string = 'bad request', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, WebrpcBadRequestError.prototype) + } +} + +export class WebrpcBadResponseError extends WebrpcError { + constructor( + name: string = 'WebrpcBadResponse', + code: number = -5, + message: string = 'bad response', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, WebrpcBadResponseError.prototype) + } +} + +export class WebrpcServerPanicError extends WebrpcError { + constructor( + name: string = 'WebrpcServerPanic', + code: number = -6, + message: string = 'server panic', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, WebrpcServerPanicError.prototype) + } +} + +export class WebrpcInternalErrorError extends WebrpcError { + constructor( + name: string = 'WebrpcInternalError', + code: number = -7, + message: string = 'internal error', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, WebrpcInternalErrorError.prototype) + } +} + +export class WebrpcClientDisconnectedError extends WebrpcError { + constructor( + name: string = 'WebrpcClientDisconnected', + code: number = -8, + message: string = 'client disconnected', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, WebrpcClientDisconnectedError.prototype) + } +} + +export class WebrpcStreamLostError extends WebrpcError { + constructor( + name: string = 'WebrpcStreamLost', + code: number = -9, + message: string = 'stream lost', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, WebrpcStreamLostError.prototype) + } +} + +export class WebrpcStreamFinishedError extends WebrpcError { + constructor( + name: string = 'WebrpcStreamFinished', + code: number = -10, + message: string = 'stream finished', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, WebrpcStreamFinishedError.prototype) + } +} + +// Schema errors + +export class UnauthorizedError extends WebrpcError { + constructor( + name: string = 'Unauthorized', + code: number = 1000, + message: string = 'Unauthorized access', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, UnauthorizedError.prototype) + } +} + +export class PermissionDeniedError extends WebrpcError { + constructor( + name: string = 'PermissionDenied', + code: number = 1001, + message: string = 'Permission denied', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, PermissionDeniedError.prototype) + } +} + +export class SessionExpiredError extends WebrpcError { + constructor( + name: string = 'SessionExpired', + code: number = 1002, + message: string = 'Session expired', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, SessionExpiredError.prototype) + } +} + +export class MethodNotFoundError extends WebrpcError { + constructor( + name: string = 'MethodNotFound', + code: number = 1003, + message: string = 'Method not found', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, MethodNotFoundError.prototype) + } +} + +export class RequestConflictError extends WebrpcError { + constructor( + name: string = 'RequestConflict', + code: number = 1004, + message: string = 'Conflict with target resource', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, RequestConflictError.prototype) + } +} + +export class ServiceDisabledError extends WebrpcError { + constructor( + name: string = 'ServiceDisabled', + code: number = 1005, + message: string = 'Service disabled', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, ServiceDisabledError.prototype) + } +} + +export class TimeoutError extends WebrpcError { + constructor( + name: string = 'Timeout', + code: number = 2000, + message: string = 'Request timed out', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, TimeoutError.prototype) + } +} + +export class InvalidArgumentError extends WebrpcError { + constructor( + name: string = 'InvalidArgument', + code: number = 2001, + message: string = 'Invalid argument', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, InvalidArgumentError.prototype) + } +} + +export class NotFoundError extends WebrpcError { + constructor( + name: string = 'NotFound', + code: number = 3000, + message: string = 'Resource not found', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, NotFoundError.prototype) + } +} + +export class UserNotFoundError extends WebrpcError { + constructor( + name: string = 'UserNotFound', + code: number = 3001, + message: string = 'User not found', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, UserNotFoundError.prototype) + } +} + +export class ProjectNotFoundError extends WebrpcError { + constructor( + name: string = 'ProjectNotFound', + code: number = 3002, + message: string = 'Project not found', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, ProjectNotFoundError.prototype) + } +} + +export class AlreadyCollaboratorError extends WebrpcError { + constructor( + name: string = 'AlreadyCollaborator', + code: number = 4001, + message: string = 'Already a collaborator', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, AlreadyCollaboratorError.prototype) + } +} + +export enum errors { + WebrpcEndpoint = 'WebrpcEndpoint', + WebrpcRequestFailed = 'WebrpcRequestFailed', + WebrpcBadRoute = 'WebrpcBadRoute', + WebrpcBadMethod = 'WebrpcBadMethod', + WebrpcBadRequest = 'WebrpcBadRequest', + WebrpcBadResponse = 'WebrpcBadResponse', + WebrpcServerPanic = 'WebrpcServerPanic', + WebrpcInternalError = 'WebrpcInternalError', + WebrpcClientDisconnected = 'WebrpcClientDisconnected', + WebrpcStreamLost = 'WebrpcStreamLost', + WebrpcStreamFinished = 'WebrpcStreamFinished', + Unauthorized = 'Unauthorized', + PermissionDenied = 'PermissionDenied', + SessionExpired = 'SessionExpired', + MethodNotFound = 'MethodNotFound', + RequestConflict = 'RequestConflict', + ServiceDisabled = 'ServiceDisabled', + Timeout = 'Timeout', + InvalidArgument = 'InvalidArgument', + NotFound = 'NotFound', + UserNotFound = 'UserNotFound', + ProjectNotFound = 'ProjectNotFound' +} + +export enum WebrpcErrorCodes { + WebrpcEndpoint = 0, + WebrpcRequestFailed = -1, + WebrpcBadRoute = -2, + WebrpcBadMethod = -3, + WebrpcBadRequest = -4, + WebrpcBadResponse = -5, + WebrpcServerPanic = -6, + WebrpcInternalError = -7, + WebrpcClientDisconnected = -8, + WebrpcStreamLost = -9, + WebrpcStreamFinished = -10, + Unauthorized = 1000, + PermissionDenied = 1001, + SessionExpired = 1002, + MethodNotFound = 1003, + RequestConflict = 1004, + ServiceDisabled = 1005, + Timeout = 2000, + InvalidArgument = 2001, + NotFound = 3000, + UserNotFound = 3001, + ProjectNotFound = 3002 +} + +export const webrpcErrorByCode: { [code: number]: any } = { + [0]: WebrpcEndpointError, + [-1]: WebrpcRequestFailedError, + [-2]: WebrpcBadRouteError, + [-3]: WebrpcBadMethodError, + [-4]: WebrpcBadRequestError, + [-5]: WebrpcBadResponseError, + [-6]: WebrpcServerPanicError, + [-7]: WebrpcInternalErrorError, + [-8]: WebrpcClientDisconnectedError, + [-9]: WebrpcStreamLostError, + [-10]: WebrpcStreamFinishedError, + [1000]: UnauthorizedError, + [1001]: PermissionDeniedError, + [1002]: SessionExpiredError, + [1003]: MethodNotFoundError, + [1004]: RequestConflictError, + [1005]: ServiceDisabledError, + [2000]: TimeoutError, + [2001]: InvalidArgumentError, + [3000]: NotFoundError, + [3001]: UserNotFoundError, + [3002]: ProjectNotFoundError +} + +export type Fetch = (input: RequestInfo, init?: RequestInit) => Promise diff --git a/packages/builder/src/index.ts b/packages/builder/src/index.ts new file mode 100644 index 000000000..403e39099 --- /dev/null +++ b/packages/builder/src/index.ts @@ -0,0 +1,30 @@ +export * from './builder.gen' + +import { Builder as BuilderRpc } from './builder.gen' + +export class SequenceBuilderClient extends BuilderRpc { + constructor( + public projectAccessKey: string, + apiUrl?: string + ) { + const hostname = apiUrl ?? 'https://api.sequence.build' + super(hostname.endsWith('/') ? hostname.slice(0, -1) : hostname, fetch) + this.fetch = this._fetch + } + + _fetch = (input: RequestInfo, init?: RequestInit): Promise => { + // automatically include access key auth header to requests + // if its been set on the api client + const headers: { [key: string]: any } = {} + + const projectAccessKey = this.projectAccessKey + if (projectAccessKey && projectAccessKey.length > 0) { + headers['X-Access-Key'] = projectAccessKey + } + + // before the request is made + init!.headers = { ...init!.headers, ...headers } + + return fetch(input, init) + } +} diff --git a/packages/core/CHANGELOG.md b/packages/core/CHANGELOG.md index 754f2884d..712bd76f9 100644 --- a/packages/core/CHANGELOG.md +++ b/packages/core/CHANGELOG.md @@ -1,5 +1,503 @@ # @0xsequence/core +## 2.2.14 + +### Patch Changes + +- Somnia Testnet and Monad Testnet +- Updated dependencies + - @0xsequence/abi@2.2.14 + - @0xsequence/utils@2.2.14 + +## 2.2.13 + +### Patch Changes + +- Add XR1 to all networks +- Updated dependencies + - @0xsequence/abi@2.2.13 + - @0xsequence/utils@2.2.13 + +## 2.2.12 + +### Patch Changes + +- Add XR1 +- Updated dependencies + - @0xsequence/abi@2.2.12 + - @0xsequence/utils@2.2.12 + +## 2.2.11 + +### Patch Changes + +- Relayer updates +- Updated dependencies + - @0xsequence/abi@2.2.11 + - @0xsequence/utils@2.2.11 + +## 2.2.10 + +### Patch Changes + +- Etherlink support +- Updated dependencies + - @0xsequence/abi@2.2.10 + - @0xsequence/utils@2.2.10 + +## 2.2.9 + +### Patch Changes + +- Indexer gateway native token balances +- Updated dependencies + - @0xsequence/abi@2.2.9 + - @0xsequence/utils@2.2.9 + +## 2.2.8 + +### Patch Changes + +- Add Moonbeam and Moonbase Alpha +- Updated dependencies + - @0xsequence/abi@2.2.8 + - @0xsequence/utils@2.2.8 + +## 2.2.7 + +### Patch Changes + +- Update Builder package +- Updated dependencies + - @0xsequence/abi@2.2.7 + - @0xsequence/utils@2.2.7 + +## 2.2.6 + +### Patch Changes + +- Update relayer package +- Updated dependencies + - @0xsequence/abi@2.2.6 + - @0xsequence/utils@2.2.6 + +## 2.2.5 + +### Patch Changes + +- auth: fix sequence indexer gateway url +- account: immutable wallet proxy hook +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.2.5 + - @0xsequence/utils@2.2.5 + +## 2.2.4 + +### Patch Changes + +- network: update soneium mainnet block explorer url +- waas: signTypedData intent support +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.2.4 + - @0xsequence/utils@2.2.4 + +## 2.2.3 + +### Patch Changes + +- provider: updating initWallet to use connected network configs if they exist +- Updated dependencies + - @0xsequence/abi@2.2.3 + - @0xsequence/utils@2.2.3 + +## 2.2.2 + +### Patch Changes + +- pass projectAccessKey to relayer at all times +- Updated dependencies + - @0xsequence/abi@2.2.2 + - @0xsequence/utils@2.2.2 + +## 2.2.1 + +### Patch Changes + +- waas-ethers: sign typed data +- Updated dependencies + - @0xsequence/abi@2.2.1 + - @0xsequence/utils@2.2.1 + +## 2.2.0 + +### Minor Changes + +- indexer: gateway client +- @0xsequence/builder +- upgrade puppeteer to v23.10.3 + +### Patch Changes + +- Updated dependencies +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.2.0 + - @0xsequence/utils@2.2.0 + +## 2.1.8 + +### Patch Changes + +- Add Soneium Mainnet +- Updated dependencies + - @0xsequence/abi@2.1.8 + - @0xsequence/utils@2.1.8 + +## 2.1.7 + +### Patch Changes + +- guard: pass project access key to guard requests +- Updated dependencies + - @0xsequence/abi@2.1.7 + - @0xsequence/utils@2.1.7 + +## 2.1.6 + +### Patch Changes + +- Add LAOS and Telos Testnet chains +- Updated dependencies + - @0xsequence/abi@2.1.6 + - @0xsequence/utils@2.1.6 + +## 2.1.5 + +### Patch Changes + +- account: save presigned configuration with reference chain id 1 +- Updated dependencies + - @0xsequence/abi@2.1.5 + - @0xsequence/utils@2.1.5 + +## 2.1.4 + +### Patch Changes + +- provider: pass projectAccessKey into MuxMessageProvider +- Updated dependencies + - @0xsequence/abi@2.1.4 + - @0xsequence/utils@2.1.4 + +## 2.1.3 + +### Patch Changes + +- waas: time drift date fix due to strange browser quirk +- Updated dependencies + - @0xsequence/abi@2.1.3 + - @0xsequence/utils@2.1.3 + +## 2.1.2 + +### Patch Changes + +- provider: export analytics correctly +- Updated dependencies + - @0xsequence/abi@2.1.2 + - @0xsequence/utils@2.1.2 + +## 2.1.1 + +### Patch Changes + +- Add LAOS chain support +- Updated dependencies + - @0xsequence/abi@2.1.1 + - @0xsequence/utils@2.1.1 + +## 2.1.0 + +### Minor Changes + +- account: forward project access key when estimating fees and sending transactions + +### Patch Changes + +- sessions: save signatures with reference chain id +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.1.0 + - @0xsequence/utils@2.1.0 + +## 2.0.26 + +### Patch Changes + +- account: fix chain id comparison +- Updated dependencies + - @0xsequence/abi@2.0.26 + - @0xsequence/utils@2.0.26 + +## 2.0.25 + +### Patch Changes + +- skale-nebula: deploy gas limit = 10m +- Updated dependencies + - @0xsequence/abi@2.0.25 + - @0xsequence/utils@2.0.25 + +## 2.0.24 + +### Patch Changes + +- sessions: arweave: configurable gateway url +- waas: use /status to get time drift before sending any intents +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.24 + - @0xsequence/utils@2.0.24 + +## 2.0.23 + +### Patch Changes + +- Add The Root Network support +- Updated dependencies + - @0xsequence/abi@2.0.23 + - @0xsequence/utils@2.0.23 + +## 2.0.22 + +### Patch Changes + +- Add SKALE Nebula Mainnet support +- Updated dependencies + - @0xsequence/abi@2.0.22 + - @0xsequence/utils@2.0.22 + +## 2.0.21 + +### Patch Changes + +- account: add publishWitnessFor +- Updated dependencies + - @0xsequence/abi@2.0.21 + - @0xsequence/utils@2.0.21 + +## 2.0.20 + +### Patch Changes + +- upgrade deps, and improve waas session status handling +- Updated dependencies + - @0xsequence/abi@2.0.20 + - @0xsequence/utils@2.0.20 + +## 2.0.19 + +### Patch Changes + +- Add Immutable zkEVM support +- Updated dependencies + - @0xsequence/abi@2.0.19 + - @0xsequence/utils@2.0.19 + +## 2.0.18 + +### Patch Changes + +- waas: new contractCall transaction type +- sessions: add arweave owner +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.18 + - @0xsequence/utils@2.0.18 + +## 2.0.17 + +### Patch Changes + +- update waas auth to clear session before signIn +- Updated dependencies + - @0xsequence/abi@2.0.17 + - @0xsequence/utils@2.0.17 + +## 2.0.16 + +### Patch Changes + +- Removed Astar chains +- Updated dependencies + - @0xsequence/abi@2.0.16 + - @0xsequence/utils@2.0.16 + +## 2.0.15 + +### Patch Changes + +- indexer: update bindings with token balance additions +- Updated dependencies + - @0xsequence/abi@2.0.15 + - @0xsequence/utils@2.0.15 + +## 2.0.14 + +### Patch Changes + +- sessions: arweave config reader +- network: add b3 and apechain mainnet configs +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.14 + - @0xsequence/utils@2.0.14 + +## 2.0.13 + +### Patch Changes + +- network: toy-testnet +- Updated dependencies + - @0xsequence/abi@2.0.13 + - @0xsequence/utils@2.0.13 + +## 2.0.12 + +### Patch Changes + +- api: update bindings +- Updated dependencies + - @0xsequence/abi@2.0.12 + - @0xsequence/utils@2.0.12 + +## 2.0.11 + +### Patch Changes + +- waas: intents test fix +- api: update bindings +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.11 + - @0xsequence/utils@2.0.11 + +## 2.0.10 + +### Patch Changes + +- network: soneium minato testnet +- Updated dependencies + - @0xsequence/abi@2.0.10 + - @0xsequence/utils@2.0.10 + +## 2.0.9 + +### Patch Changes + +- network: fix SKALE network name +- Updated dependencies + - @0xsequence/abi@2.0.9 + - @0xsequence/utils@2.0.9 + +## 2.0.8 + +### Patch Changes + +- metadata: update bindings +- Updated dependencies + - @0xsequence/abi@2.0.8 + - @0xsequence/utils@2.0.8 + +## 2.0.7 + +### Patch Changes + +- wallet request handler fix +- Updated dependencies + - @0xsequence/abi@2.0.7 + - @0xsequence/utils@2.0.7 + +## 2.0.6 + +### Patch Changes + +- network: matic -> pol +- Updated dependencies + - @0xsequence/abi@2.0.6 + - @0xsequence/utils@2.0.6 + +## 2.0.5 + +### Patch Changes + +- provider: update databeat to 0.9.2 +- Updated dependencies + - @0xsequence/abi@2.0.5 + - @0xsequence/utils@2.0.5 + +## 2.0.4 + +### Patch Changes + +- network: add skale-nebula-testnet +- Updated dependencies + - @0xsequence/abi@2.0.4 + - @0xsequence/utils@2.0.4 + +## 2.0.3 + +### Patch Changes + +- waas: check session status in SequenceWaaS.isSignedIn() +- Updated dependencies + - @0xsequence/abi@2.0.3 + - @0xsequence/utils@2.0.3 + +## 2.0.2 + +### Patch Changes + +- sessions: property convert serialized bignumber hex value to bigint +- Updated dependencies + - @0xsequence/abi@2.0.2 + - @0xsequence/utils@2.0.2 + +## 2.0.1 + +### Patch Changes + +- waas: http signature check for authenticator requests +- provider: unwrap legacy json rpc responses +- use json replacer and reviver for bigints +- Updated dependencies +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.1 + - @0xsequence/utils@2.0.1 + +## 2.0.0 + +### Major Changes + +- ethers v6 + +### Patch Changes + +- Updated dependencies + - @0xsequence/abi@2.0.0 + - @0xsequence/utils@2.0.0 + +## 1.10.15 + +### Patch Changes + +- utils: extractProjectIdFromAccessKey +- Updated dependencies + - @0xsequence/abi@1.10.15 + ## 1.10.14 ### Patch Changes diff --git a/packages/core/package.json b/packages/core/package.json index f16bfda0b..461a9b985 100644 --- a/packages/core/package.json +++ b/packages/core/package.json @@ -1,6 +1,6 @@ { "name": "@0xsequence/core", - "version": "1.10.14", + "version": "2.2.14", "description": "core primitives for interacting with the sequence wallet contracts", "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/core", "source": "src/index.ts", @@ -11,13 +11,14 @@ "scripts": { "test": "pnpm test:file tests/**/*.spec.ts", "test:file": "TS_NODE_PROJECT=../../tsconfig.test.json mocha -r ts-node/register --timeout 30000", - "test:coverage": "nyc yarn test" + "test:coverage": "nyc pnpm test" }, "peerDependencies": { - "ethers": ">=5.5" + "ethers": ">=6" }, "devDependencies": { "@istanbuljs/nyc-config-typescript": "^1.0.2", + "ethers": "6.13.4", "nyc": "^15.1.0" }, "files": [ @@ -25,6 +26,7 @@ "dist" ], "dependencies": { + "@0xsequence/utils": "workspace:*", "@0xsequence/abi": "workspace:*" } } diff --git a/packages/core/src/commons/config.ts b/packages/core/src/commons/config.ts index 2529b8f82..6aefb8e8c 100644 --- a/packages/core/src/commons/config.ts +++ b/packages/core/src/commons/config.ts @@ -21,7 +21,7 @@ export interface ConfigCoder { isWalletConfig: (config: Config) => config is T - checkpointOf: (config: T) => ethers.BigNumber + checkpointOf: (config: T) => bigint fromSimple: (config: SimpleConfig) => T diff --git a/packages/core/src/commons/context.ts b/packages/core/src/commons/context.ts index 9868e42a3..72feabc0a 100644 --- a/packages/core/src/commons/context.ts +++ b/packages/core/src/commons/context.ts @@ -12,18 +12,20 @@ export type WalletContext = { guestModule: string walletCreationCode: string + + proxyImplementationHook?: string } export function addressOf(context: WalletContext, imageHash: ethers.BytesLike) { - const codeHash = ethers.utils.keccak256( - ethers.utils.solidityPack(['bytes', 'bytes32'], [context.walletCreationCode, ethers.utils.hexZeroPad(context.mainModule, 32)]) + const codeHash = ethers.keccak256( + ethers.solidityPacked(['bytes', 'bytes32'], [context.walletCreationCode, ethers.zeroPadValue(context.mainModule, 32)]) ) - const hash = ethers.utils.keccak256( - ethers.utils.solidityPack(['bytes1', 'address', 'bytes32', 'bytes32'], ['0xff', context.factory, imageHash, codeHash]) + const hash = ethers.keccak256( + ethers.solidityPacked(['bytes1', 'address', 'bytes32', 'bytes32'], ['0xff', context.factory, imageHash, codeHash]) ) - return ethers.utils.getAddress(ethers.utils.hexDataSlice(hash, 12)) + return ethers.getAddress(ethers.dataSlice(hash, 12)) } export async function isValidCounterfactual( @@ -31,7 +33,7 @@ export async function isValidCounterfactual( digest: ethers.BytesLike, signature: ethers.BytesLike, chainId: ethers.BigNumberish, - provider: ethers.providers.Provider, + provider: ethers.Provider, contexts: { [key: number]: WalletContext } ) { // We don't know the version of the signature @@ -39,13 +41,13 @@ export async function isValidCounterfactual( const res = await Promise.all( allVersions.map(async version => { try { - const decoded = version.signature.SignatureCoder.decode(ethers.utils.hexlify(signature)) + const decoded = version.signature.SignatureCoder.decode(ethers.hexlify(signature)) const recovered1 = await version.signature.SignatureCoder.recover( decoded as any, { address: wallet, - digest: ethers.utils.hexlify(digest), + digest: ethers.hexlify(digest), chainId }, provider @@ -64,7 +66,7 @@ export async function isValidCounterfactual( decoded as any, { address: wallet, - digest: ethers.utils.hexlify(digest), + digest: ethers.hexlify(digest), chainId }, provider diff --git a/packages/core/src/commons/orchestrator.ts b/packages/core/src/commons/orchestrator.ts index cb0d73165..60c374450 100644 --- a/packages/core/src/commons/orchestrator.ts +++ b/packages/core/src/commons/orchestrator.ts @@ -7,7 +7,7 @@ import { Config } from './config' */ export type WalletSignRequestMetadata = { address: string - digest: ethers.utils.BytesLike + digest: ethers.BytesLike chainId: ethers.BigNumberish config: Config @@ -18,7 +18,7 @@ export type WalletSignRequestMetadata = { // how close are we to the threshold. This can be used to display // a progress bar or something similar. - message?: ethers.utils.BytesLike + message?: ethers.BytesLike transactions?: commons.transaction.Transaction[] // This is used only when a Sequence wallet is nested in another Sequence wallet diff --git a/packages/core/src/commons/reader.ts b/packages/core/src/commons/reader.ts index 99af855bc..e548833b0 100644 --- a/packages/core/src/commons/reader.ts +++ b/packages/core/src/commons/reader.ts @@ -1,6 +1,5 @@ import { walletContracts } from '@0xsequence/abi' import { ethers } from 'ethers' -import { commons } from '..' import { validateEIP6492Offchain } from './validateEIP6492' /** @@ -22,7 +21,7 @@ export class OnChainReader implements Reader { // Simple cache to avoid re-fetching the same data private isDeployedCache: Set = new Set() - constructor(public readonly provider: ethers.providers.Provider) {} + constructor(public readonly provider: ethers.Provider) {} private module(address: string) { return new ethers.Contract( @@ -38,7 +37,7 @@ export class OnChainReader implements Reader { return true } - const code = await this.provider.getCode(wallet).then(c => ethers.utils.arrayify(c)) + const code = await this.provider.getCode(wallet).then(c => ethers.getBytes(c)) const isDeployed = code.length !== 0 if (isDeployed) { this.isDeployedCache.add(wallet) @@ -48,15 +47,15 @@ export class OnChainReader implements Reader { } async implementation(wallet: string): Promise { - const position = ethers.utils.defaultAbiCoder.encode(['address'], [wallet]) - const val = await this.provider.getStorageAt(wallet, position).then(c => ethers.utils.arrayify(c)) + const position = ethers.AbiCoder.defaultAbiCoder().encode(['address'], [wallet]) + const val = await this.provider.getStorage(wallet, position).then(c => ethers.getBytes(c)) if (val.length === 20) { - return ethers.utils.getAddress(ethers.utils.hexlify(val)) + return ethers.getAddress(ethers.hexlify(val)) } if (val.length === 32) { - return ethers.utils.defaultAbiCoder.decode(['address'], val)[0] + return ethers.AbiCoder.defaultAbiCoder().decode(['address'], val)[0] } return undefined diff --git a/packages/core/src/commons/signature.ts b/packages/core/src/commons/signature.ts index e54dc4167..29a113d6e 100644 --- a/packages/core/src/commons/signature.ts +++ b/packages/core/src/commons/signature.ts @@ -34,7 +34,7 @@ export interface SignatureCoder< trim: (data: string) => Promise - recover: (data: Z, payload: SignedPayload, provider: ethers.providers.Provider) => Promise + recover: (data: Z, payload: SignedPayload, provider: ethers.Provider) => Promise supportsNoChainId: boolean @@ -45,7 +45,7 @@ export interface SignatureCoder< chainId: ethers.BigNumberish ) => { encoded: string - weight: ethers.BigNumber + weight: bigint } hasEnoughSigningPower: (config: Y, signatures: Map) => boolean @@ -60,7 +60,7 @@ export interface SignatureCoder< } export function subdigestOf(payload: SignedPayload) { - return ethers.utils.solidityKeccak256( + return ethers.solidityPackedKeccak256( ['bytes', 'uint256', 'address', 'bytes32'], ['0x1901', payload.chainId, payload.address, payload.digest] ) diff --git a/packages/core/src/commons/signer.ts b/packages/core/src/commons/signer.ts index 4e146c7a0..c570d77f4 100644 --- a/packages/core/src/commons/signer.ts +++ b/packages/core/src/commons/signer.ts @@ -8,32 +8,32 @@ export enum SigType { } export function canRecover(signature: ethers.BytesLike) { - const bytes = ethers.utils.arrayify(signature) + const bytes = ethers.getBytes(signature) const type = bytes[bytes.length - 1] return type === SigType.EIP712 || type === SigType.ETH_SIGN } export function recoverSigner(digest: ethers.BytesLike, signature: ethers.BytesLike) { - const bytes = ethers.utils.arrayify(signature) - const digestBytes = ethers.utils.arrayify(digest) + const bytes = ethers.getBytes(signature) + const digestBytes = ethers.getBytes(digest) // type is last byte const type = bytes[bytes.length - 1] // Split r:s:v - const r = ethers.utils.hexlify(bytes.slice(0, 32)) - const s = ethers.utils.hexlify(bytes.slice(32, 64)) - const v = ethers.BigNumber.from(bytes.slice(64, 65)).toNumber() + const r = ethers.hexlify(bytes.slice(0, 32)) + const s = ethers.hexlify(bytes.slice(32, 64)) + const v = Number(ethers.hexlify(bytes.slice(64, 65))) const splitSignature = { r, s, v } if (type === SigType.EIP712) { - return ethers.utils.recoverAddress(digestBytes, splitSignature) + return ethers.recoverAddress(digestBytes, splitSignature) } if (type === SigType.ETH_SIGN) { - return ethers.utils.recoverAddress(ethers.utils.hashMessage(digestBytes), splitSignature) + return ethers.recoverAddress(ethers.hashMessage(digestBytes), splitSignature) } throw new Error(`Unsupported signature type: ${type}`) @@ -43,9 +43,9 @@ export function isValidSignature( address: string, digest: ethers.BytesLike, signature: ethers.BytesLike, - provider: ethers.providers.Provider + provider: ethers.Provider ) { - const bytes = ethers.utils.arrayify(signature) + const bytes = ethers.getBytes(signature) // type is last byte const type = bytes[bytes.length - 1] @@ -55,14 +55,14 @@ export function isValidSignature( } if (type === SigType.WALLET_BYTES32) { - return isValidEIP1271Signature(address, ethers.utils.hexlify(digest), bytes.slice(0, -1), provider) + return isValidEIP1271Signature(address, ethers.hexlify(digest), bytes.slice(0, -1), provider) } throw new Error(`Unsupported signature type: ${type}`) } export function tryRecoverSigner(digest: ethers.BytesLike, signature: ethers.BytesLike): string | undefined { - const bytes = ethers.utils.arrayify(signature) + const bytes = ethers.getBytes(signature) if (bytes.length !== 66) return undefined try { diff --git a/packages/core/src/commons/transaction.ts b/packages/core/src/commons/transaction.ts index a8495dab0..de4f2a57f 100644 --- a/packages/core/src/commons/transaction.ts +++ b/packages/core/src/commons/transaction.ts @@ -1,12 +1,13 @@ -import { BigNumberish, BytesLike, ethers } from 'ethers' +import { ethers } from 'ethers' + import { subdigestOf } from './signature' import { walletContracts } from '@0xsequence/abi' export interface Transaction { to: string - value?: BigNumberish - data?: BytesLike - gasLimit?: BigNumberish + value?: ethers.BigNumberish + data?: string + gasLimit?: ethers.BigNumberish delegateCall?: boolean revertOnError?: boolean } @@ -23,30 +24,26 @@ export interface SimulatedTransaction extends Transaction { export interface TransactionEncoded { delegateCall: boolean revertOnError: boolean - gasLimit: BigNumberish + gasLimit: ethers.BigNumberish target: string - value: BigNumberish - data: BytesLike + value: ethers.BigNumberish + data: string } -export type Transactionish = - | ethers.providers.TransactionRequest - | ethers.providers.TransactionRequest[] - | Transaction - | Transaction[] +export type Transactionish = ethers.TransactionRequest | ethers.TransactionRequest[] | Transaction | Transaction[] -export interface TransactionResponse extends ethers.providers.TransactionResponse { +export interface TransactionResponse extends ethers.TransactionResponse { receipt?: R } export type TransactionBundle = { entrypoint: string transactions: Transaction[] - nonce?: BigNumberish + nonce?: ethers.BigNumberish } export type IntendedTransactionBundle = TransactionBundle & { - chainId: BigNumberish + chainId: ethers.BigNumberish intent: { id: string wallet: string @@ -55,7 +52,7 @@ export type IntendedTransactionBundle = TransactionBundle & { export type SignedTransactionBundle = IntendedTransactionBundle & { signature: string - nonce: BigNumberish + nonce: ethers.BigNumberish } export type RelayReadyTransactionBundle = SignedTransactionBundle | IntendedTransactionBundle @@ -72,7 +69,7 @@ export const MetaTransactionsType = `tuple( export function intendTransactionBundle( bundle: TransactionBundle, wallet: string, - chainId: BigNumberish, + chainId: ethers.BigNumberish, id: string ): IntendedTransactionBundle { return { @@ -83,83 +80,89 @@ export function intendTransactionBundle( } export function intendedTransactionID(bundle: IntendedTransactionBundle) { - return ethers.utils.keccak256( - ethers.utils.defaultAbiCoder.encode( + return ethers.keccak256( + ethers.AbiCoder.defaultAbiCoder().encode( ['address', 'uint256', 'bytes32'], [bundle.intent.wallet, bundle.chainId, bundle.intent.id] ) ) } -export function unpackMetaTransactionsData(data: BytesLike): [ethers.BigNumber, TransactionEncoded[]] { - const res = ethers.utils.defaultAbiCoder.decode(['uint256', MetaTransactionsType], data) +export function unpackMetaTransactionsData(data: ethers.BytesLike): [bigint, TransactionEncoded[]] { + const res = ethers.AbiCoder.defaultAbiCoder().decode(['uint256', MetaTransactionsType], data) if (res.length !== 2 || !res[0] || !res[1]) throw new Error('Invalid meta transaction data') return [res[0], res[1]] } export function packMetaTransactionsData(nonce: ethers.BigNumberish, txs: Transaction[]): string { - return ethers.utils.defaultAbiCoder.encode(['uint256', MetaTransactionsType], [nonce, sequenceTxAbiEncode(txs)]) + return ethers.AbiCoder.defaultAbiCoder().encode(['uint256', MetaTransactionsType], [nonce, sequenceTxAbiEncode(txs)]) } -export function digestOfTransactions(nonce: BigNumberish, txs: Transaction[]) { - return ethers.utils.keccak256(packMetaTransactionsData(nonce, txs)) +export function digestOfTransactions(nonce: ethers.BigNumberish, txs: Transaction[]) { + return ethers.keccak256(packMetaTransactionsData(nonce, txs)) } export function subdigestOfTransactions( address: string, - chainId: BigNumberish, + chainId: ethers.BigNumberish, nonce: ethers.BigNumberish, txs: Transaction[] ): string { return subdigestOf({ address, chainId, digest: digestOfTransactions(nonce, txs) }) } -export function subdigestOfGuestModuleTransactions(guestModule: string, chainId: BigNumberish, txs: Transaction[]): string { +export function subdigestOfGuestModuleTransactions( + guestModule: string, + chainId: ethers.BigNumberish, + txs: Transaction[] +): string { return subdigestOf({ address: guestModule, chainId, - digest: ethers.utils.keccak256( - ethers.utils.defaultAbiCoder.encode(['string', MetaTransactionsType], ['guest:', sequenceTxAbiEncode(txs)]) + digest: ethers.keccak256( + ethers.AbiCoder.defaultAbiCoder().encode(['string', MetaTransactionsType], ['guest:', sequenceTxAbiEncode(txs)]) ) }) } export function toSequenceTransactions( wallet: string, - txs: (Transaction | ethers.providers.TransactionRequest)[] + txs: ethers.TransactionRequest[] ): { nonce?: ethers.BigNumberish; transaction: Transaction }[] { return txs.map(tx => toSequenceTransaction(wallet, tx)) } export function toSequenceTransaction( wallet: string, - tx: ethers.providers.TransactionRequest + tx: ethers.TransactionRequest ): { nonce?: ethers.BigNumberish; transaction: Transaction } { - if (tx.to && tx.to !== ethers.constants.AddressZero) { + if (tx.to && tx.to !== ethers.ZeroAddress) { return { - nonce: tx.nonce, + nonce: !isNullish(tx.nonce) ? BigInt(tx.nonce) : undefined, transaction: { delegateCall: false, revertOnError: false, - gasLimit: tx.gasLimit || 0, - to: tx.to, - value: tx.value || 0, + gasLimit: !isNullish(tx.gasLimit) ? BigInt(tx.gasLimit) : undefined, + // XXX: `tx.to` could also be ethers Addressable type which returns a getAddress promise + // Keeping this as is for now so we don't have to change everything to async + to: tx.to as string, + value: BigInt(tx.value || 0), data: tx.data || '0x' } } } else { - const walletInterface = new ethers.utils.Interface(walletContracts.mainModule.abi) - const data = walletInterface.encodeFunctionData(walletInterface.getFunction('createContract'), [tx.data]) + const walletInterface = new ethers.Interface(walletContracts.mainModule.abi) + const data = walletInterface.encodeFunctionData(walletInterface.getFunction('createContract')!, [tx.data]) return { - nonce: tx.nonce, + nonce: typeof tx.nonce === 'number' ? BigInt(tx.nonce) : undefined, transaction: { delegateCall: false, revertOnError: false, - gasLimit: tx.gasLimit, + gasLimit: !isNullish(tx.gasLimit) ? BigInt(tx.gasLimit) : undefined, to: wallet, - value: tx.value || 0, - data: data + value: BigInt(tx.value || 0), + data } } } @@ -175,49 +178,49 @@ export function hasSequenceTransactions(txs: any[]): txs is Transaction[] { // TODO: We may be able to remove this if we make Transaction === TransactionEncoded export function sequenceTxAbiEncode(txs: Transaction[]): TransactionEncoded[] { - return txs.map(t => ({ - delegateCall: t.delegateCall === true, - revertOnError: t.revertOnError === true, - gasLimit: t.gasLimit !== undefined ? t.gasLimit : ethers.constants.Zero, - target: t.to ?? ethers.constants.AddressZero, - value: t.value !== undefined ? t.value : ethers.constants.Zero, - data: t.data !== undefined ? t.data : [] + return txs.map(tx => ({ + delegateCall: tx.delegateCall === true, + revertOnError: tx.revertOnError === true, + gasLimit: !isNullish(tx.gasLimit) ? BigInt(tx.gasLimit) : 0n, + target: tx.to ?? ethers.ZeroAddress, + value: !isNullish(tx.value) ? tx.value : 0n, + data: tx.data || '0x' })) } export function fromTxAbiEncode(txs: TransactionEncoded[]): Transaction[] { - return txs.map(t => ({ - delegateCall: t.delegateCall, - revertOnError: t.revertOnError, - gasLimit: t.gasLimit, - to: t.target, - value: t.value, - data: t.data + return txs.map(tx => ({ + delegateCall: tx.delegateCall, + revertOnError: tx.revertOnError, + gasLimit: tx.gasLimit, + to: tx.target, + value: tx.value, + data: tx.data })) } -// export function appendNonce(txs: Transaction[], nonce: BigNumberish): Transaction[] { +// export function appendNonce(txs: Transaction[], nonce: ethers.BigNumberish): Transaction[] { // return txs.map((t: Transaction) => ({ ...t, nonce })) // } -export function encodeNonce(space: BigNumberish, nonce: BigNumberish): ethers.BigNumber { - const bspace = ethers.BigNumber.from(space) - const bnonce = ethers.BigNumber.from(nonce) +export function encodeNonce(space: ethers.BigNumberish, nonce: ethers.BigNumberish): bigint { + const bspace = BigInt(space) + const bnonce = BigInt(nonce) - const shl = ethers.constants.Two.pow(ethers.BigNumber.from(96)) + const shl = 2n ** 96n - if (!bnonce.div(shl).eq(ethers.constants.Zero)) { + if (bnonce / shl !== 0n) { throw new Error('Space already encoded') } - return bnonce.add(bspace.mul(shl)) + return bnonce + bspace * shl } -export function decodeNonce(nonce: BigNumberish): [ethers.BigNumber, ethers.BigNumber] { - const bnonce = ethers.BigNumber.from(nonce) - const shr = ethers.constants.Two.pow(ethers.BigNumber.from(96)) +export function decodeNonce(nonce: ethers.BigNumberish): [bigint, bigint] { + const bnonce = BigInt(nonce) + const shr = 2n ** 96n - return [bnonce.div(shr), bnonce.mod(shr)] + return [bnonce / shr, bnonce % shr] } export function fromTransactionish(wallet: string, transaction: Transactionish): Transaction[] { @@ -255,9 +258,9 @@ export function isSignedTransactionBundle(cand: any): cand is SignedTransactionB } export function encodeBundleExecData(bundle: TransactionBundle): string { - const walletInterface = new ethers.utils.Interface(walletContracts.mainModule.abi) + const walletInterface = new ethers.Interface(walletContracts.mainModule.abi) return walletInterface.encodeFunctionData( - walletInterface.getFunction('execute'), + walletInterface.getFunction('execute')!, isSignedTransactionBundle(bundle) ? [ // Signed transaction bundle has all 3 parameters @@ -269,7 +272,7 @@ export function encodeBundleExecData(bundle: TransactionBundle): string { // Unsigned bundle may be a GuestModule call, so signature and nonce are missing sequenceTxAbiEncode(bundle.transactions), 0, - [] + new Uint8Array([]) ] ) } @@ -289,15 +292,15 @@ export const selfExecuteAbi = `tuple( export const unwind = (wallet: string, transactions: Transaction[]): Transaction[] => { const unwound: Transaction[] = [] - const walletInterface = new ethers.utils.Interface(walletContracts.mainModule.abi) + const walletInterface = new ethers.Interface(walletContracts.mainModule.abi) for (const tx of transactions) { - const txData = ethers.utils.arrayify(tx.data || '0x') + const txData = ethers.getBytes(tx.data || '0x') - if (tx.to === wallet && ethers.utils.hexlify(txData.slice(0, 4)) === selfExecuteSelector) { + if (tx.to === wallet && ethers.hexlify(txData.slice(0, 4)) === selfExecuteSelector) { // Decode as selfExecute call const data = txData.slice(4) - const decoded = ethers.utils.defaultAbiCoder.decode([selfExecuteAbi], data)[0] + const decoded = ethers.AbiCoder.defaultAbiCoder().decode([selfExecuteAbi], data)[0] unwound.push( ...unwind( tx.to, @@ -306,10 +309,10 @@ export const unwind = (wallet: string, transactions: Transaction[]): Transaction ) } else { try { - const innerTransactions = walletInterface.decodeFunctionData('execute', txData)[0] + const innerTransactions = walletInterface.decodeFunctionData('execute', txData)[0] as ethers.Result const unwoundTransactions = unwind( wallet, - innerTransactions.map((tx: TransactionEncoded) => ({ ...tx, to: tx.target })) + innerTransactions.map((tx: ethers.Result) => ({ ...tx.toObject(), to: tx.target })) ) unwound.push(...unwoundTransactions) } catch { @@ -320,3 +323,5 @@ export const unwind = (wallet: string, transactions: Transaction[]): Transaction return unwound } + +const isNullish = (value: T | null | undefined): value is null | undefined => value === null || value === void 0 diff --git a/packages/core/src/commons/validateEIP1271.ts b/packages/core/src/commons/validateEIP1271.ts index d71049182..fb5fe1031 100644 --- a/packages/core/src/commons/validateEIP1271.ts +++ b/packages/core/src/commons/validateEIP1271.ts @@ -30,7 +30,7 @@ export async function isValidEIP1271Signature( address: string, digest: string, signature: ethers.BytesLike, - provider: ethers.providers.Provider + provider: ethers.Provider ): Promise { const contract = new ethers.Contract(address, EIP1271_ABI, provider) const result = await contract.isValidSignature(digest, signature) diff --git a/packages/core/src/commons/validateEIP6492.ts b/packages/core/src/commons/validateEIP6492.ts index 478c5786d..9f4865242 100644 --- a/packages/core/src/commons/validateEIP6492.ts +++ b/packages/core/src/commons/validateEIP6492.ts @@ -180,18 +180,21 @@ export const EIP_6492_SUFFIX = '0x6492649264926492649264926492649264926492649264 // the contract on some of the popular chains, and calling the contract // if the provider is one of those chains export async function validateEIP6492Offchain( - provider: ethers.providers.Provider, + provider: ethers.Provider, signer: string, - hash: ethers.utils.BytesLike, - signature: ethers.utils.BytesLike + hash: ethers.BytesLike, + signature: ethers.BytesLike ): Promise { - return ( - '0x01' === - (await provider.call({ - data: ethers.utils.concat([ + try { + const result = await provider.call({ + data: ethers.concat([ EIP_6492_OFFCHAIN_DEPLOY_CODE, - new ethers.utils.AbiCoder().encode(['address', 'bytes32', 'bytes'], [signer, hash, signature]) + ethers.AbiCoder.defaultAbiCoder().encode(['address', 'bytes32', 'bytes'], [signer, hash, signature]) ]) - })) - ) + }) + + return result === '0x01' + } catch (err) { + return false + } } diff --git a/packages/core/src/v1/config.ts b/packages/core/src/v1/config.ts index 859474b27..0c1c10f91 100644 --- a/packages/core/src/v1/config.ts +++ b/packages/core/src/v1/config.ts @@ -25,10 +25,10 @@ export const ConfigCoder: commons.config.ConfigCoder = { imageHashOf: (config: WalletConfig): string => { return config.signers.reduce( (imageHash, signer) => - ethers.utils.keccak256( - ethers.utils.defaultAbiCoder.encode(['bytes32', 'uint8', 'address'], [imageHash, signer.weight, signer.address]) + ethers.keccak256( + ethers.AbiCoder.defaultAbiCoder().encode(['bytes32', 'uint8', 'address'], [imageHash, signer.weight, signer.address]) ), - ethers.utils.solidityPack(['uint256'], [config.threshold]) + ethers.solidityPacked(['uint256'], [config.threshold]) ) }, @@ -42,16 +42,16 @@ export const ConfigCoder: commons.config.ConfigCoder = { return true }, - checkpointOf: (_config: WalletConfig): ethers.BigNumber => { - return ethers.BigNumber.from(0) + checkpointOf: (_config: WalletConfig): bigint => { + return 0n }, signersOf: (config: WalletConfig): { address: string; weight: number }[] => { - return config.signers.map(s => ({ address: s.address, weight: ethers.BigNumber.from(s.weight).toNumber() })) + return config.signers.map(s => ({ address: s.address, weight: Number(s.weight) })) }, fromSimple: (config: SimpleConfig): WalletConfig => { - if (!ethers.constants.Zero.eq(config.checkpoint)) { + if (BigInt(config.checkpoint) !== 0n) { throw new Error('v1 wallet config does not support checkpoint') } @@ -75,14 +75,14 @@ export const ConfigCoder: commons.config.ConfigCoder = { context: commons.context.WalletContext, kind?: 'first' | 'later' | undefined ): commons.transaction.TransactionBundle => { - const module = new ethers.utils.Interface([...walletContracts.mainModule.abi, ...walletContracts.mainModuleUpgradable.abi]) + const module = new ethers.Interface([...walletContracts.mainModule.abi, ...walletContracts.mainModuleUpgradable.abi]) const transactions: commons.transaction.Transaction[] = [] if (!kind || kind === 'first') { transactions.push({ to: wallet, - data: module.encodeFunctionData(module.getFunction('updateImplementation'), [context.mainModuleUpgradable]), + data: module.encodeFunctionData(module.getFunction('updateImplementation')!, [context.mainModuleUpgradable]), gasLimit: 0, delegateCall: false, revertOnError: true, @@ -92,7 +92,7 @@ export const ConfigCoder: commons.config.ConfigCoder = { transactions.push({ to: wallet, - data: module.encodeFunctionData(module.getFunction('updateImageHash'), [ConfigCoder.imageHashOf(config)]), + data: module.encodeFunctionData(module.getFunction('updateImageHash')!, [ConfigCoder.imageHashOf(config)]), gasLimit: 0, delegateCall: false, revertOnError: true, @@ -116,14 +116,14 @@ export const ConfigCoder: commons.config.ConfigCoder = { toJSON: function (config: WalletConfig): string { const plainMembers = config.signers.map(signer => { return { - weight: ethers.BigNumber.from(signer.weight).toString(), + weight: BigInt(signer.weight).toString(), address: signer.address } }) return JSON.stringify({ version: config.version, - threshold: ethers.BigNumber.from(config.threshold).toString(), + threshold: BigInt(config.threshold).toString(), signers: plainMembers }) }, @@ -133,14 +133,14 @@ export const ConfigCoder: commons.config.ConfigCoder = { const signers = parsed.signers.map((signer: any) => { return { - weight: ethers.BigNumber.from(signer.weight), + weight: BigInt(signer.weight), address: signer.address } }) return { version: parsed.version, - threshold: ethers.BigNumber.from(parsed.threshold), + threshold: BigInt(parsed.threshold), signers } }, @@ -156,7 +156,7 @@ export const ConfigCoder: commons.config.ConfigCoder = { ): WalletConfig { const newSigners = config.signers.slice() - if (action.checkpoint && !ethers.constants.Zero.eq(action.checkpoint)) { + if (action.checkpoint && BigInt(action.checkpoint) !== 0n) { throw new Error('v1 wallet config does not support checkpoint') } @@ -197,21 +197,21 @@ export const ConfigCoder: commons.config.ConfigCoder = { const { encoded, weight } = encodeSigners(config, parts, [], 0) - if (weight.gte(config.threshold)) { + if (weight >= BigInt(config.threshold)) { return encoded } } const signers = config.signers - for (const { address } of signers.sort(({ weight: a }, { weight: b }) => ethers.BigNumber.from(a).sub(b).toNumber())) { + for (const { address } of signers.sort(({ weight: a }, { weight: b }) => Number(a) - Number(b))) { const signature = '0x4e82f02f388a12b5f9d29eaf2452dd040c0ee5804b4e504b4dd64e396c6c781f2c7624195acba242dd825bfd25a290912e3c230841fd55c9a734c4de8d9899451b02' parts.set(address, { signature, isDynamic: false }) const { encoded, weight } = encodeSigners(config, parts, [], 0) - if (weight.gte(config.threshold)) { + if (weight >= BigInt(config.threshold)) { return encoded } } diff --git a/packages/core/src/v1/context.ts b/packages/core/src/v1/context.ts new file mode 100644 index 000000000..ef801a86c --- /dev/null +++ b/packages/core/src/v1/context.ts @@ -0,0 +1,6 @@ +import { WalletContext as BaseContext } from '../commons/context' + +export type WalletContext = BaseContext & { + version: 1 + multiCallUtils: string +} diff --git a/packages/core/src/v1/index.ts b/packages/core/src/v1/index.ts index 57ae48ed8..cdb17be00 100644 --- a/packages/core/src/v1/index.ts +++ b/packages/core/src/v1/index.ts @@ -1,6 +1,7 @@ import { WalletContext } from '../commons/context' export * as config from './config' +export * as context from './context' export * as signature from './signature' export const version = 1 diff --git a/packages/core/src/v1/signature.ts b/packages/core/src/v1/signature.ts index 628b0c2e6..9bd8219dc 100644 --- a/packages/core/src/v1/signature.ts +++ b/packages/core/src/v1/signature.ts @@ -43,7 +43,7 @@ export function isUnrecoveredSignature(signature: Signature | UnrecoveredSignatu } export function decodeSignature(signature: ethers.BytesLike): UnrecoveredSignature { - const bytes = ethers.utils.arrayify(signature) + const bytes = ethers.getBytes(signature) const threshold = (bytes[0] << 8) | bytes[1] const signers: UnrecoveredMember[] = [] @@ -57,7 +57,7 @@ export function decodeSignature(signature: ethers.BytesLike): UnrecoveredSignatu signers.push({ unrecovered: true, weight, - signature: ethers.utils.hexlify(bytes.slice(i, i + 66)), + signature: ethers.hexlify(bytes.slice(i, i + 66)), isDynamic: false }) i += 66 @@ -66,13 +66,13 @@ export function decodeSignature(signature: ethers.BytesLike): UnrecoveredSignatu case SignaturePartType.Address: signers.push({ weight, - address: ethers.utils.getAddress(ethers.utils.hexlify(bytes.slice(i, i + 20))) + address: ethers.getAddress(ethers.hexlify(bytes.slice(i, i + 20))) }) i += 20 break case SignaturePartType.DynamicSignature: - const address = ethers.utils.getAddress(ethers.utils.hexlify(bytes.slice(i, i + 20))) + const address = ethers.getAddress(ethers.hexlify(bytes.slice(i, i + 20))) i += 20 const size = (bytes[i] << 8) | bytes[i + 1] @@ -81,7 +81,7 @@ export function decodeSignature(signature: ethers.BytesLike): UnrecoveredSignatu signers.push({ unrecovered: true, weight, - signature: ethers.utils.hexlify(bytes.slice(i, i + size)), + signature: ethers.hexlify(bytes.slice(i, i + size)), address, isDynamic: true }) @@ -97,33 +97,35 @@ export function decodeSignature(signature: ethers.BytesLike): UnrecoveredSignatu } export function encodeSignature(signature: Signature | UnrecoveredSignature | ethers.BytesLike): string { - if (ethers.utils.isBytesLike(signature)) return ethers.utils.hexlify(signature) + if (ethers.isBytesLike(signature)) { + return ethers.hexlify(signature) + } const { signers, threshold } = isUnrecoveredSignature(signature) ? signature : signature.config const encodedSigners = signers.map(s => { if (isAddressMember(s)) { - return ethers.utils.solidityPack(['uint8', 'uint8', 'address'], [SignaturePartType.Address, s.weight, s.address]) + return ethers.solidityPacked(['uint8', 'uint8', 'address'], [SignaturePartType.Address, s.weight, s.address]) } if (s.isDynamic) { - const bytes = ethers.utils.arrayify(s.signature) - return ethers.utils.solidityPack( + const bytes = ethers.getBytes(s.signature) + return ethers.solidityPacked( ['uint8', 'uint8', 'address', 'uint16', 'bytes'], [SignaturePartType.DynamicSignature, s.weight, s.address, bytes.length, bytes] ) } - return ethers.utils.solidityPack(['uint8', 'uint8', 'bytes'], [SignaturePartType.EOASignature, s.weight, s.signature]) + return ethers.solidityPacked(['uint8', 'uint8', 'bytes'], [SignaturePartType.EOASignature, s.weight, s.signature]) }) - return ethers.utils.solidityPack(['uint16', ...new Array(encodedSigners.length).fill('bytes')], [threshold, ...encodedSigners]) + return ethers.solidityPacked(['uint16', ...new Array(encodedSigners.length).fill('bytes')], [threshold, ...encodedSigners]) } export async function recoverSignature( data: UnrecoveredSignature, payload: base.SignedPayload, - provider: ethers.providers.Provider + provider: ethers.Provider ): Promise { const subdigest = base.subdigestOf(payload) const signers = await Promise.all( @@ -163,21 +165,21 @@ export function encodeSigners( signatures: Map, subdigests: string[], _: ethers.BigNumberish -): { encoded: string; weight: ethers.BigNumber } { +): { encoded: string; weight: bigint } { if (subdigests.length !== 0) { throw new Error('Explicit subdigests not supported on v1') } - let weight = ethers.BigNumber.from(0) + let weight = 0n const parts = config.signers.map(s => { if (!signatures.has(s.address)) { return s } const signature = signatures.get(s.address)! - const bytes = ethers.utils.arrayify(signature.signature) + const bytes = ethers.getBytes(signature.signature) - weight = weight.add(s.weight) + weight += BigInt(s.weight) if (signature.isDynamic || bytes.length !== 66) { return { @@ -214,7 +216,7 @@ export const SignatureCoder: base.SignatureCoder => { + recover: (data: UnrecoveredSignature, payload: base.SignedPayload, provider: ethers.Provider): Promise => { return recoverSignature(data, payload, provider) }, @@ -225,14 +227,14 @@ export const SignatureCoder: base.SignatureCoder { return encodeSigners(config, signatures, subdigests, chainId) }, hasEnoughSigningPower: (config: WalletConfig, signatures: Map): boolean => { const { weight } = SignatureCoder.encodeSigners(config, signatures, [], 0) - return weight.gte(config.threshold) + return weight >= BigInt(config.threshold) }, chainSignatures: ( diff --git a/packages/core/src/v2/chained.ts b/packages/core/src/v2/chained.ts index 9240aee75..db2734198 100644 --- a/packages/core/src/v2/chained.ts +++ b/packages/core/src/v2/chained.ts @@ -4,18 +4,25 @@ import { ethers } from 'ethers' export const SetImageHashPrefix = '0x8713a7c4465f6fbee2b6e9d6646d1d9f83fec929edfc4baf661f3c865bdd04d1' export function hashSetImageHash(imageHash: string): string { - return ethers.utils.keccak256(messageSetImageHash(imageHash)) + return ethers.keccak256(messageSetImageHash(imageHash)) } export function messageSetImageHash(imageHash: string) { - return ethers.utils.solidityPack(['bytes32', 'bytes32'], [SetImageHashPrefix, imageHash]) + return ethers.solidityPacked(['bytes32', 'bytes32'], [SetImageHashPrefix, imageHash]) } export function decodeMessageSetImageHash(message: ethers.BytesLike): string | undefined { - const arr = ethers.utils.arrayify(message) - if (arr.length !== 64) return undefined - if (ethers.utils.hexlify(arr.slice(0, 32)) !== SetImageHashPrefix) return undefined - return ethers.utils.hexlify(arr.slice(32, 64)) + const arr = ethers.getBytes(message) + + if (arr.length !== 64) { + return undefined + } + + if (ethers.hexlify(arr.slice(0, 32)) !== SetImageHashPrefix) { + return undefined + } + + return ethers.hexlify(arr.slice(32, 64)) } export function isMessageSetImageHash(message: ethers.BytesLike): boolean { diff --git a/packages/core/src/v2/config.ts b/packages/core/src/v2/config.ts index 968e265ea..eab339306 100644 --- a/packages/core/src/v2/config.ts +++ b/packages/core/src/v2/config.ts @@ -51,8 +51,8 @@ export function topologyToJSON(tree: Topology): string { if (isNestedLeaf(tree)) { return JSON.stringify({ - weight: ethers.BigNumber.from(tree.weight).toString(), - threshold: ethers.BigNumber.from(tree.threshold).toString(), + weight: BigInt(tree.weight).toString(), + threshold: BigInt(tree.threshold).toString(), tree: topologyToJSON(tree.tree) }) } @@ -60,7 +60,7 @@ export function topologyToJSON(tree: Topology): string { if (isSignerLeaf(tree)) { return JSON.stringify({ address: tree.address, - weight: ethers.BigNumber.from(tree.weight).toString() + weight: BigInt(tree.weight).toString() }) } @@ -79,8 +79,8 @@ export function topologyFromJSON(json: string | object): Topology { if (parsed.weight !== undefined && parsed.threshold !== undefined && parsed.tree !== undefined) { return { - weight: ethers.BigNumber.from(parsed.weight), - threshold: ethers.BigNumber.from(parsed.threshold), + weight: BigInt(parsed.weight), + threshold: BigInt(parsed.threshold), tree: topologyFromJSON(parsed.tree) } } @@ -88,7 +88,7 @@ export function topologyFromJSON(json: string | object): Topology { if (parsed.address !== undefined && parsed.weight !== undefined) { return { address: parsed.address, - weight: ethers.BigNumber.from(parsed.weight) + weight: BigInt(parsed.weight) } } @@ -131,24 +131,24 @@ export function isTopology(topology: any): topology is Topology { } export function encodeSignerLeaf(leaf: SignerLeaf): string { - return ethers.utils.solidityPack(['uint96', 'address'], [leaf.weight, leaf.address]) + return ethers.solidityPacked(['uint96', 'address'], [leaf.weight, leaf.address]) } export function decodeSignerLeaf(encoded: string): SignerLeaf { - const bytes = ethers.utils.arrayify(encoded) + const bytes = ethers.getBytes(encoded) if (bytes.length !== 32) { throw new Error('Invalid encoded string length') } - const weight = ethers.BigNumber.from(bytes.slice(0, 12)) - const address = ethers.utils.getAddress(ethers.utils.hexlify(bytes.slice(12))) + const weight = BigInt(ethers.hexlify(bytes.slice(0, 12))) + const address = ethers.getAddress(ethers.hexlify(bytes.slice(12))) return { weight, address } } export function isEncodedSignerLeaf(encoded: string): boolean { - const bytes = ethers.utils.arrayify(encoded) + const bytes = ethers.getBytes(encoded) if (bytes.length !== 32) { return false @@ -164,12 +164,12 @@ export function hashNode(node: Node | Leaf): string { } if (isSubdigestLeaf(node)) { - return ethers.utils.solidityKeccak256(['string', 'bytes32'], ['Sequence static digest:\n', node.subdigest]) + return ethers.solidityPackedKeccak256(['string', 'bytes32'], ['Sequence static digest:\n', node.subdigest]) } if (isNestedLeaf(node)) { const nested = hashNode(node.tree) - return ethers.utils.solidityKeccak256( + return ethers.solidityPackedKeccak256( ['string', 'bytes32', 'uint256', 'uint256'], ['Sequence nested config:\n', nested, node.threshold, node.weight] ) @@ -179,7 +179,7 @@ export function hashNode(node: Node | Leaf): string { return node.nodeHash } - return ethers.utils.solidityKeccak256(['bytes32', 'bytes32'], [hashNode(node.left), hashNode(node.right)]) + return ethers.solidityPackedKeccak256(['bytes32', 'bytes32'], [hashNode(node.left), hashNode(node.right)]) } export function leftFace(topology: Topology): Topology[] { @@ -217,9 +217,9 @@ export function isWalletConfig(config: any): config is WalletConfig { } export function imageHash(config: WalletConfig): string { - return ethers.utils.solidityKeccak256( + return ethers.solidityPackedKeccak256( ['bytes32', 'uint256'], - [ethers.utils.solidityKeccak256(['bytes32', 'uint256'], [hashNode(config.tree), config.threshold]), config.checkpoint] + [ethers.solidityPackedKeccak256(['bytes32', 'uint256'], [hashNode(config.tree), config.threshold]), config.checkpoint] ) } @@ -399,7 +399,7 @@ export function signersOf(tree: Topology): { address: string; weight: number }[] stack.push(node.left) stack.push(node.right) } else if (isSignerLeaf(node)) { - signers.add({ address: node.address, weight: ethers.BigNumber.from(node.weight).toNumber() }) + signers.add({ address: node.address, weight: Number(node.weight) }) } } @@ -427,8 +427,8 @@ export const ConfigCoder: commons.config.ConfigCoder = { return hasSubdigest(config.tree, subdigest) }, - checkpointOf: (config: WalletConfig): ethers.BigNumber => { - return ethers.BigNumber.from(config.checkpoint) + checkpointOf: (config: WalletConfig): bigint => { + return BigInt(config.checkpoint) }, signersOf: (config: WalletConfig): { address: string; weight: number }[] => { @@ -463,14 +463,14 @@ export const ConfigCoder: commons.config.ConfigCoder = { _context: commons.context.WalletContext, _kind?: 'first' | 'later' | undefined ): commons.transaction.TransactionBundle => { - const module = new ethers.utils.Interface(walletContracts.mainModuleUpgradable.abi) + const module = new ethers.Interface(walletContracts.mainModuleUpgradable.abi) return { entrypoint: wallet, transactions: [ { to: wallet, - data: module.encodeFunctionData(module.getFunction('updateImageHash'), [ConfigCoder.imageHashOf(config)]), + data: module.encodeFunctionData(module.getFunction('updateImageHash')!, [ConfigCoder.imageHashOf(config)]), gasLimit: 0, delegateCall: false, revertOnError: true, @@ -484,7 +484,7 @@ export const ConfigCoder: commons.config.ConfigCoder = { newImageHash: string kind: 'first' | 'later' | undefined } { - const module = new ethers.utils.Interface(walletContracts.mainModuleUpgradable.abi) + const module = new ethers.Interface(walletContracts.mainModuleUpgradable.abi) if (tx.transactions.length !== 1) { throw new Error('Invalid transaction bundle, expected 1 transaction') @@ -495,7 +495,7 @@ export const ConfigCoder: commons.config.ConfigCoder = { throw new Error('Invalid transaction bundle, expected data') } - const decoded = module.decodeFunctionData(module.getFunction('updateImageHash'), data) + const decoded = module.decodeFunctionData(module.getFunction('updateImageHash')!, data) if (!decoded) { throw new Error('Invalid transaction bundle, expected valid data') } @@ -512,11 +512,11 @@ export const ConfigCoder: commons.config.ConfigCoder = { throw new Error('Invalid transaction bundle, expected revertOnError') } - if (!ethers.constants.Zero.eq(tx.transactions[0]?.value ?? 0)) { + if (BigInt(tx.transactions[0]?.value ?? 0) !== 0n) { throw new Error('Invalid transaction bundle, expected value to be 0') } - if (!ethers.constants.Zero.eq(tx.transactions[0]?.gasLimit ?? 0)) { + if (BigInt(tx.transactions[0]?.gasLimit ?? 0) !== 0n) { throw new Error('Invalid transaction bundle, expected value to be 0') } @@ -531,8 +531,8 @@ export const ConfigCoder: commons.config.ConfigCoder = { toJSON: function (config: WalletConfig): string { return JSON.stringify({ version: config.version, - threshold: ethers.BigNumber.from(config.threshold).toString(), - checkpoint: ethers.BigNumber.from(config.checkpoint).toString(), + threshold: BigInt(config.threshold).toString(), + checkpoint: BigInt(config.checkpoint).toString(), tree: topologyToJSON(config.tree) }) }, @@ -541,8 +541,8 @@ export const ConfigCoder: commons.config.ConfigCoder = { const config = JSON.parse(json) return { version: config.version, - threshold: ethers.BigNumber.from(config.threshold), - checkpoint: ethers.BigNumber.from(config.checkpoint), + threshold: BigInt(config.threshold), + checkpoint: BigInt(config.checkpoint), tree: topologyFromJSON(config.tree) } }, @@ -596,7 +596,7 @@ export const ConfigCoder: commons.config.ConfigCoder = { const { encoded, weight } = encodeSigners(config, parts, [], 0) - if (weight.gte(config.threshold)) { + if (weight >= BigInt(config.threshold)) { return encoded } } @@ -610,7 +610,7 @@ export const ConfigCoder: commons.config.ConfigCoder = { const { encoded, weight } = encodeSigners(config, parts, [], 0) - if (weight.gte(config.threshold)) { + if (weight >= BigInt(config.threshold)) { return encoded } } diff --git a/packages/core/src/v2/context.ts b/packages/core/src/v2/context.ts index 6092201d1..e815e21cc 100644 --- a/packages/core/src/v2/context.ts +++ b/packages/core/src/v2/context.ts @@ -2,4 +2,5 @@ import { WalletContext as BaseContext } from '../commons/context' export type WalletContext = BaseContext & { version: 2 + universalSigValidator: string } diff --git a/packages/core/src/v2/index.ts b/packages/core/src/v2/index.ts index f921265a4..d3b534bd6 100644 --- a/packages/core/src/v2/index.ts +++ b/packages/core/src/v2/index.ts @@ -21,5 +21,6 @@ export const DeployedWalletContext: WalletContext = { guestModule: '0xfea230Ee243f88BC698dD8f1aE93F8301B6cdfaE', mainModule: '0xfBf8f1A5E00034762D928f46d438B947f5d4065d', mainModuleUpgradable: '0x4222dcA3974E39A8b41c411FeDDE9b09Ae14b911', - walletCreationCode: '0x603a600e3d39601a805130553df3363d3d373d3d3d363d30545af43d82803e903d91601857fd5bf3' + walletCreationCode: '0x603a600e3d39601a805130553df3363d3d373d3d3d363d30545af43d82803e903d91601857fd5bf3', + proxyImplementationHook: '0x1f56dbAD5e8319F0DE9a323E24A31b5077dEB1a4' } diff --git a/packages/core/src/v2/signature.ts b/packages/core/src/v2/signature.ts index 2fa5415e5..33aadd5e1 100644 --- a/packages/core/src/v2/signature.ts +++ b/packages/core/src/v2/signature.ts @@ -1,5 +1,6 @@ -import { BigNumberish, ethers } from 'ethers' -import { isValidSignature, recoverSigner, tryRecoverSigner } from '../commons/signer' +import { ethers } from 'ethers' +import { MAX_UINT_256 } from '@0xsequence/utils' +import { isValidSignature, recoverSigner } from '../commons/signer' import { hashNode, isNestedLeaf, @@ -50,8 +51,8 @@ export type UnrecoveredSignatureLeaf = Omit & export type UnrecoveredNestedLeaf = { tree: UnrecoveredTopology - weight: BigNumberish - threshold: BigNumberish + weight: ethers.BigNumberish + threshold: ethers.BigNumberish } export type UnrecoveredLeaf = UnrecoveredNestedLeaf | UnrecoveredSignatureLeaf | Leaf @@ -80,7 +81,7 @@ export function isUnrecoveredSignatureLeaf(leaf: UnrecoveredTopology): leaf is U } export function decodeSignatureTree(body: ethers.BytesLike): UnrecoveredTopology { - let arr = ethers.utils.arrayify(body) + let arr = ethers.getBytes(body) let pointer: undefined | (Omit & Pick, 'right'>) @@ -112,7 +113,7 @@ export function decodeSignatureTree(body: ethers.BytesLike): UnrecoveredTopology case SignaturePartType.Signature: { const weight = arr[0] - const signature = ethers.utils.hexlify(arr.slice(1, SignaturePartTypeLength + 1)) + const signature = ethers.hexlify(arr.slice(1, SignaturePartTypeLength + 1)) pointer = append(pointer, { signature, @@ -127,7 +128,7 @@ export function decodeSignatureTree(body: ethers.BytesLike): UnrecoveredTopology case SignaturePartType.Address: { const weight = arr[0] - const address = ethers.utils.getAddress(ethers.utils.hexlify(arr.slice(1, 21))) + const address = ethers.getAddress(ethers.hexlify(arr.slice(1, 21))) pointer = append(pointer, { address, @@ -140,9 +141,9 @@ export function decodeSignatureTree(body: ethers.BytesLike): UnrecoveredTopology case SignaturePartType.DynamicSignature: { const weight = arr[0] - const address = ethers.utils.getAddress(ethers.utils.hexlify(arr.slice(1, 21))) + const address = ethers.getAddress(ethers.hexlify(arr.slice(1, 21))) const size = (arr[21] << 16) | (arr[22] << 8) | arr[23] - const signature = ethers.utils.hexlify(arr.slice(24, 24 + size)) + const signature = ethers.hexlify(arr.slice(24, 24 + size)) pointer = append(pointer, { address, @@ -157,7 +158,7 @@ export function decodeSignatureTree(body: ethers.BytesLike): UnrecoveredTopology case SignaturePartType.Node: { - const nodeHash = ethers.utils.hexlify(arr.slice(0, 32)) + const nodeHash = ethers.hexlify(arr.slice(0, 32)) pointer = append(pointer, { nodeHash }) arr = arr.slice(32) @@ -176,7 +177,7 @@ export function decodeSignatureTree(body: ethers.BytesLike): UnrecoveredTopology case SignaturePartType.Subdigest: { - const subdigest = ethers.utils.hexlify(arr.slice(0, 32)) + const subdigest = ethers.hexlify(arr.slice(0, 32)) pointer = append(pointer, { subdigest }) arr = arr.slice(32) @@ -201,7 +202,7 @@ export function decodeSignatureTree(body: ethers.BytesLike): UnrecoveredTopology break default: - throw new Error(`Unknown signature part type: ${type}: ${ethers.utils.hexlify(arr)}`) + throw new Error(`Unknown signature part type: ${type}: ${ethers.hexlify(arr)}`) } } @@ -225,7 +226,7 @@ export class InvalidSignatureLeafError extends Error { export async function recoverTopology( unrecovered: UnrecoveredTopology, subdigest: string, - provider: ethers.providers.Provider + provider: ethers.Provider ): Promise { if (isUnrecoveredNode(unrecovered)) { const [left, right] = await Promise.all([ @@ -278,37 +279,37 @@ export async function recoverTopology( // and avoid duplicating this logic export const partEncoder = { concat: (a: ethers.BytesLike, b: ethers.BytesLike) => { - return ethers.utils.solidityPack(['bytes', 'bytes'], [a, b]) + return ethers.solidityPacked(['bytes', 'bytes'], [a, b]) }, node: (nodeHash: ethers.BytesLike): string => { - return ethers.utils.solidityPack(['uint8', 'bytes32'], [SignaturePartType.Node, nodeHash]) + return ethers.solidityPacked(['uint8', 'bytes32'], [SignaturePartType.Node, nodeHash]) }, branch: (tree: ethers.BytesLike): string => { - const arr = ethers.utils.arrayify(tree) - return ethers.utils.solidityPack(['uint8', 'uint24', 'bytes'], [SignaturePartType.Branch, arr.length, arr]) + const arr = ethers.getBytes(tree) + return ethers.solidityPacked(['uint8', 'uint24', 'bytes'], [SignaturePartType.Branch, arr.length, arr]) }, nested: (weight: ethers.BigNumberish, threshold: ethers.BigNumberish, tree: ethers.BytesLike): string => { - const arr = ethers.utils.arrayify(tree) - return ethers.utils.solidityPack( + const arr = ethers.getBytes(tree) + return ethers.solidityPacked( ['uint8', 'uint8', 'uint16', 'uint24', 'bytes'], [SignaturePartType.Nested, weight, threshold, arr.length, arr] ) }, subdigest: (subdigest: ethers.BytesLike): string => { - return ethers.utils.solidityPack(['uint8', 'bytes32'], [SignaturePartType.Subdigest, subdigest]) + return ethers.solidityPacked(['uint8', 'bytes32'], [SignaturePartType.Subdigest, subdigest]) }, signature: (weight: ethers.BigNumberish, signature: ethers.BytesLike): string => { - return ethers.utils.solidityPack(['uint8', 'uint8', 'bytes'], [SignaturePartType.Signature, weight, signature]) + return ethers.solidityPacked(['uint8', 'uint8', 'bytes'], [SignaturePartType.Signature, weight, signature]) }, dynamicSignature: (weight: ethers.BigNumberish, address: ethers.BytesLike, signature: ethers.BytesLike): string => { - const arrSignature = ethers.utils.arrayify(signature) - return ethers.utils.solidityPack( + const arrSignature = ethers.getBytes(signature) + return ethers.solidityPacked( ['uint8', 'uint8', 'address', 'uint24', 'bytes'], [SignaturePartType.DynamicSignature, weight, address, arrSignature.length, arrSignature] ) }, address: (weight: ethers.BigNumberish, address: ethers.BytesLike): string => { - return ethers.utils.solidityPack(['uint8', 'uint8', 'address'], [SignaturePartType.Address, weight, address]) + return ethers.solidityPacked(['uint8', 'uint8', 'address'], [SignaturePartType.Address, weight, address]) } } @@ -325,13 +326,13 @@ export function encodeSigners( options: EncodingOptions = {} ): { encoded: string - weight: ethers.BigNumber + weight: bigint } { const tree = encodeTree(config.tree, parts, subdigests, options) - if (ethers.BigNumber.from(chainId).isZero()) { + if (BigInt(chainId) === 0n) { return { - encoded: ethers.utils.solidityPack( + encoded: ethers.solidityPacked( ['uint8', 'uint16', 'uint32', 'bytes'], [SignatureType.NoChainIdDynamic, config.threshold, config.checkpoint, tree.encoded] ), @@ -339,9 +340,9 @@ export function encodeSigners( } } - if (ethers.BigNumber.from(config.threshold).gt(255)) { + if (BigInt(config.threshold) > 255n) { return { - encoded: ethers.utils.solidityPack( + encoded: ethers.solidityPacked( ['uint8', 'uint16', 'uint32', 'bytes'], [SignatureType.Dynamic, config.threshold, config.checkpoint, tree.encoded] ), @@ -350,7 +351,7 @@ export function encodeSigners( } return { - encoded: ethers.utils.solidityPack( + encoded: ethers.solidityPacked( ['uint8', 'uint8', 'uint32', 'bytes'], [SignatureType.Legacy, config.threshold, config.checkpoint, tree.encoded] ), @@ -365,7 +366,7 @@ export function encodeTree( options: EncodingOptions = {} ): { encoded: string - weight: ethers.BigNumber + weight: bigint } { const trim = !options.disableTrim @@ -376,16 +377,16 @@ export function encodeTree( const isLeftSigner = isSignerLeaf(topology.left) const isRightSigner = isSignerLeaf(topology.right) - if (trim && left.weight.eq(0) && right.weight.eq(0) && !isLeftSigner && !isRightSigner) { + if (trim && left.weight === 0n && right.weight === 0n && !isLeftSigner && !isRightSigner) { return { // We don't need to include anything for this node // just the hash will be enough encoded: partEncoder.node(hashNode(topology)), - weight: ethers.constants.Zero + weight: 0n } } - if (trim && right.weight.eq(0) && !isRightSigner) { + if (trim && right.weight === 0n && !isRightSigner) { return { // The right node doesn't have any weight // but we still need to include the left node encoded @@ -394,7 +395,7 @@ export function encodeTree( } } - if (trim && left.weight.eq(0) && !isLeftSigner) { + if (trim && left.weight === 0n && !isLeftSigner) { return { // The left node doesn't have any weight // we can just append its hash, but for the right node @@ -408,17 +409,17 @@ export function encodeTree( // Both nodes have weight, we need to include both // the right one must be a branch encoded: partEncoder.concat(left.encoded, partEncoder.branch(right.encoded)), - weight: left.weight.add(right.weight) + weight: left.weight + right.weight } } if (isNestedLeaf(topology)) { const tree = encodeTree(topology.tree, parts, subdigests) - if (trim && tree.weight.eq(0)) { + if (trim && tree.weight === 0n) { return { encoded: partEncoder.node(hashNode(topology)), - weight: ethers.constants.Zero + weight: 0n } } @@ -431,7 +432,7 @@ export function encodeTree( if (isNodeLeaf(topology)) { return { encoded: partEncoder.node(hashNode(topology)), - weight: ethers.constants.Zero + weight: 0n } } @@ -439,7 +440,7 @@ export function encodeTree( const include = subdigests.includes(topology.subdigest) return { encoded: partEncoder.subdigest(topology.subdigest), - weight: include ? ethers.constants.MaxUint256 : ethers.constants.Zero + weight: include ? MAX_UINT_256 : 0n } } @@ -453,18 +454,18 @@ export function encodeTree( if (options.forceDynamicEncoding || part.isDynamic) { return { encoded: partEncoder.dynamicSignature(topology.weight, topology.address, signature), - weight: ethers.BigNumber.from(topology.weight) + weight: BigInt(topology.weight) } } else { return { encoded: partEncoder.signature(topology.weight, signature), - weight: ethers.BigNumber.from(topology.weight) + weight: BigInt(topology.weight) } } } else { return { encoded: partEncoder.address(topology.weight, topology.address), - weight: ethers.constants.Zero + weight: 0n } } } @@ -524,7 +525,7 @@ export function isChainedSignature(sig: any): sig is ChainedSignature { } export function decodeSignature(signature: ethers.BytesLike): UnrecoveredSignature | UnrecoveredChainedSignature { - const bytes = ethers.utils.arrayify(signature) + const bytes = ethers.getBytes(signature) const type = bytes[0] switch (type) { @@ -546,7 +547,7 @@ export function decodeSignature(signature: ethers.BytesLike): UnrecoveredSignatu } export function decodeSignatureBody(signature: ethers.BytesLike): UnrecoveredConfig { - const bytes = ethers.utils.arrayify(signature) + const bytes = ethers.getBytes(signature) const threshold = (bytes[0] << 8) | bytes[1] const checkpoint = (bytes[2] << 24) | (bytes[3] << 16) | (bytes[4] << 8) | bytes[5] @@ -557,7 +558,7 @@ export function decodeSignatureBody(signature: ethers.BytesLike): UnrecoveredCon } export function decodeChainedSignature(signature: ethers.BytesLike): UnrecoveredChainedSignature { - const arr = ethers.utils.arrayify(signature) + const arr = ethers.getBytes(signature) const type = arr[0] if (type !== SignatureType.Chained) { @@ -588,16 +589,16 @@ export function decodeChainedSignature(signature: ethers.BytesLike): Unrecovered } export function setImageHashStruct(imageHash: string) { - return ethers.utils.solidityPack( + return ethers.solidityPacked( ['bytes32', 'bytes32'], - [ethers.utils.solidityKeccak256(['string'], ['SetImageHash(bytes32 imageHash)']), imageHash] + [ethers.solidityPackedKeccak256(['string'], ['SetImageHash(bytes32 imageHash)']), imageHash] ) } export async function recoverSignature( signature: UnrecoveredSignature | UnrecoveredChainedSignature, payload: base.SignedPayload | { subdigest: string }, - provider: ethers.providers.Provider + provider: ethers.Provider ): Promise { const signedPayload = (payload as { subdigest: string }).subdigest === undefined ? (payload as base.SignedPayload) : undefined @@ -632,7 +633,7 @@ export async function recoverSignature( mutatedPayload = { ...mutatedPayload, message: nextMessage, - digest: ethers.utils.keccak256(nextMessage) + digest: ethers.keccak256(nextMessage) } } @@ -644,20 +645,17 @@ export async function recoverSignature( export function encodeChain(main: ethers.BytesLike, suffix: ethers.BytesLike[]): string { const allSignatures = [main, ...(suffix || [])] - const encodedMap = allSignatures.map(s => ethers.utils.arrayify(encodeSignature(s))) + const encodedMap = allSignatures.map(s => ethers.getBytes(encodeSignature(s))) - const body = ethers.utils.solidityPack( - encodedMap.map(() => ['uint24', 'bytes']).flat(), - encodedMap.map(s => [s.length, s]).flat() - ) + const body = ethers.solidityPacked(encodedMap.map(() => ['uint24', 'bytes']).flat(), encodedMap.map(s => [s.length, s]).flat()) - return ethers.utils.solidityPack(['uint8', 'bytes'], [SignatureType.Chained, body]) + return ethers.solidityPacked(['uint8', 'bytes'], [SignatureType.Chained, body]) } export function encodeSignature( decoded: UnrecoveredChainedSignature | ChainedSignature | UnrecoveredSignature | Signature | ethers.BytesLike ): string { - if (ethers.utils.isBytesLike(decoded)) return ethers.utils.hexlify(decoded) + if (ethers.isBytesLike(decoded)) return ethers.hexlify(decoded) if (isUnrecoveredChainedSignature(decoded) || isChainedSignature(decoded)) { return encodeChain(encodeSignature(decoded), (decoded.suffix || []).map(encodeSignature)) @@ -667,7 +665,7 @@ export function encodeSignature( switch (decoded.type) { case SignatureType.Legacy: - if (ethers.BigNumber.from(body.threshold).gt(255)) { + if (BigInt(body.threshold) > 255n) { throw new Error(`Legacy signature threshold is too large: ${body.threshold} (max 255)`) } @@ -675,7 +673,7 @@ export function encodeSignature( case SignatureType.NoChainIdDynamic: case SignatureType.Dynamic: - return ethers.utils.solidityPack(['uint8', 'bytes'], [decoded.type, encodeSignatureBody(body)]) + return ethers.solidityPacked(['uint8', 'bytes'], [decoded.type, encodeSignatureBody(body)]) case SignatureType.Chained: throw new Error(`Unreachable code: Chained signature should be handled above`) @@ -686,7 +684,7 @@ export function encodeSignature( } export function encodeSignatureBody(decoded: WalletConfig | UnrecoveredConfig): string { - return ethers.utils.solidityPack( + return ethers.solidityPacked( ['uint16', 'uint32', 'bytes'], [decoded.threshold, decoded.checkpoint, encodeSignatureTree(decoded.tree)] ) @@ -694,53 +692,53 @@ export function encodeSignatureBody(decoded: WalletConfig | UnrecoveredConfig): export function encodeSignatureTree(tree: UnrecoveredTopology | Topology): string { if (isNode(tree) || isUnrecoveredNode(tree)) { - const encodedRight = ethers.utils.arrayify(encodeSignatureTree(tree.right)) - const encodedLeft = ethers.utils.arrayify(encodeSignatureTree(tree.left)) + const encodedRight = ethers.getBytes(encodeSignatureTree(tree.right)) + const encodedLeft = ethers.getBytes(encodeSignatureTree(tree.left)) const isBranching = isNode(tree.right) || isUnrecoveredNode(tree.right) if (isBranching) { - return ethers.utils.solidityPack( + return ethers.solidityPacked( ['bytes', 'uint8', 'uint24', 'bytes'], [encodedLeft, SignaturePartType.Branch, encodedRight.length, encodedRight] ) } else { - return ethers.utils.solidityPack(['bytes', 'bytes'], [encodedLeft, encodedRight]) + return ethers.solidityPacked(['bytes', 'bytes'], [encodedLeft, encodedRight]) } } if (isNestedLeaf(tree) || isUnrecoveredNestedLeaf(tree)) { - const nested = ethers.utils.arrayify(encodeSignatureTree(tree.tree)) + const nested = ethers.getBytes(encodeSignatureTree(tree.tree)) - return ethers.utils.solidityPack( + return ethers.solidityPacked( ['uint8', 'uint8', 'uint16', 'uint24', 'bytes'], [SignaturePartType.Nested, tree.weight, tree.threshold, nested.length, nested] ) } if (isUnrecoveredSignatureLeaf(tree) || (isSignerLeaf(tree) && tree.signature !== undefined)) { - const signature = ethers.utils.arrayify(tree.signature!) + const signature = ethers.getBytes(tree.signature!) if ((tree as { isDynamic?: boolean }).isDynamic || signature.length !== SignaturePartTypeLength) { if (!tree.address) throw new Error(`Dynamic signature leaf must have address`) - return ethers.utils.solidityPack( + return ethers.solidityPacked( ['uint8', 'uint8', 'address', 'uint24', 'bytes'], [SignaturePartType.DynamicSignature, tree.weight, tree.address, signature.length, signature] ) } else { - return ethers.utils.solidityPack(['uint8', 'uint8', 'bytes'], [SignaturePartType.Signature, tree.weight, signature]) + return ethers.solidityPacked(['uint8', 'uint8', 'bytes'], [SignaturePartType.Signature, tree.weight, signature]) } } if (isSignerLeaf(tree)) { - return ethers.utils.solidityPack(['uint8', 'uint8', 'address'], [SignaturePartType.Address, tree.weight, tree.address]) + return ethers.solidityPacked(['uint8', 'uint8', 'address'], [SignaturePartType.Address, tree.weight, tree.address]) } if (isNodeLeaf(tree)) { - return ethers.utils.solidityPack(['uint8', 'bytes32'], [SignaturePartType.Node, tree.nodeHash]) + return ethers.solidityPacked(['uint8', 'bytes32'], [SignaturePartType.Node, tree.nodeHash]) } if (isSubdigestLeaf(tree)) { - return ethers.utils.solidityPack(['uint8', 'bytes32'], [SignaturePartType.Subdigest, tree.subdigest]) + return ethers.solidityPacked(['uint8', 'bytes32'], [SignaturePartType.Subdigest, tree.subdigest]) } throw new Error(`Unknown signature tree type: ${tree}`) @@ -826,7 +824,7 @@ export async function trimUnrecoveredTree( // If both weights are 0 then it means we don't have any signatures yet // because of that, we should be able to "recover" the tree with any subdigest // and still get the valid node hash (there shouldn't be any signatures to verify) - const recovered = await recoverTopology(tree, ethers.constants.HashZero, undefined as any) + const recovered = await recoverTopology(tree, ethers.ZeroHash, undefined as any) return { weight: 0, @@ -856,7 +854,7 @@ export async function trimUnrecoveredTree( try { // If the nested leaf is empty, we can recover it with any subdigest // and still get the valid node hash (there shouldn't be any signatures to verify) - const recovered = await recoverTopology(tree, ethers.constants.HashZero, undefined as any) + const recovered = await recoverTopology(tree, ethers.ZeroHash, undefined as any) return { weight: 0, @@ -893,7 +891,7 @@ export async function trimUnrecoveredTree( if (isUnrecoveredSignatureLeaf(tree) || (isSignerLeaf(tree) && tree.signature !== undefined)) { return { - weight: ethers.BigNumber.from(tree.weight).toNumber(), + weight: Number(tree.weight), trimmed: tree } } @@ -929,7 +927,7 @@ export const SignatureCoder: base.SignatureCoder => { return recoverSignature(data, payload, provider) }, @@ -941,14 +939,14 @@ export const SignatureCoder: base.SignatureCoder { return encodeSigners(config, signatures, subdigests, chainId) }, hasEnoughSigningPower: (config: WalletConfig, signatures: Map): boolean => { const { weight } = SignatureCoder.encodeSigners(config, signatures, [], 0) - return weight.gte(config.threshold) + return weight >= BigInt(config.threshold) }, chainSignatures: ( @@ -958,8 +956,8 @@ export const SignatureCoder: base.SignatureCoder (ethers.utils.isBytesLike(s) ? s : encodeSignature(s))) + const mraw = ethers.isBytesLike(main) ? main : encodeSignature(main) + const sraw = reversed.map(s => (ethers.isBytesLike(s) ? s : encodeSignature(s))) return encodeChain(mraw, sraw) }, diff --git a/packages/core/src/version.ts b/packages/core/src/version.ts index e8e78cfa0..ceab14dec 100644 --- a/packages/core/src/version.ts +++ b/packages/core/src/version.ts @@ -1 +1 @@ -export const VERSION = '1.10.14' +export const VERSION = '2.2.14' diff --git a/packages/core/tests/v2/signature.spec.ts b/packages/core/tests/v2/signature.spec.ts index 1c4ac2d52..f2c424b58 100644 --- a/packages/core/tests/v2/signature.spec.ts +++ b/packages/core/tests/v2/signature.spec.ts @@ -533,7 +533,7 @@ describe('v2 signature utils', () => { }) it('Fail to decode invalid signature part type', () => { - const invalidSignature = ethers.utils.solidityPack( + const invalidSignature = ethers.solidityPacked( ['bytes', 'uint8'], ['0x0001ffffffff', Object.keys(SignaturePartType).length / 2] ) diff --git a/packages/deployer/CHANGELOG.md b/packages/deployer/CHANGELOG.md index 3102b27b3..c3d9da558 100644 --- a/packages/deployer/CHANGELOG.md +++ b/packages/deployer/CHANGELOG.md @@ -1,5 +1,452 @@ # @0xsequence/deployer +## 2.2.14 + +### Patch Changes + +- Somnia Testnet and Monad Testnet +- Updated dependencies + - @0xsequence/utils@2.2.14 + +## 2.2.13 + +### Patch Changes + +- Add XR1 to all networks +- Updated dependencies + - @0xsequence/utils@2.2.13 + +## 2.2.12 + +### Patch Changes + +- Add XR1 +- Updated dependencies + - @0xsequence/utils@2.2.12 + +## 2.2.11 + +### Patch Changes + +- Relayer updates +- Updated dependencies + - @0xsequence/utils@2.2.11 + +## 2.2.10 + +### Patch Changes + +- Etherlink support +- Updated dependencies + - @0xsequence/utils@2.2.10 + +## 2.2.9 + +### Patch Changes + +- Indexer gateway native token balances +- Updated dependencies + - @0xsequence/utils@2.2.9 + +## 2.2.8 + +### Patch Changes + +- Add Moonbeam and Moonbase Alpha +- Updated dependencies + - @0xsequence/utils@2.2.8 + +## 2.2.7 + +### Patch Changes + +- Update Builder package +- Updated dependencies + - @0xsequence/utils@2.2.7 + +## 2.2.6 + +### Patch Changes + +- Update relayer package +- Updated dependencies + - @0xsequence/utils@2.2.6 + +## 2.2.5 + +### Patch Changes + +- auth: fix sequence indexer gateway url +- account: immutable wallet proxy hook +- Updated dependencies +- Updated dependencies + - @0xsequence/utils@2.2.5 + +## 2.2.4 + +### Patch Changes + +- network: update soneium mainnet block explorer url +- waas: signTypedData intent support +- Updated dependencies +- Updated dependencies + - @0xsequence/utils@2.2.4 + +## 2.2.3 + +### Patch Changes + +- provider: updating initWallet to use connected network configs if they exist +- Updated dependencies + - @0xsequence/utils@2.2.3 + +## 2.2.2 + +### Patch Changes + +- pass projectAccessKey to relayer at all times +- Updated dependencies + - @0xsequence/utils@2.2.2 + +## 2.2.1 + +### Patch Changes + +- waas-ethers: sign typed data +- Updated dependencies + - @0xsequence/utils@2.2.1 + +## 2.2.0 + +### Minor Changes + +- indexer: gateway client +- @0xsequence/builder +- upgrade puppeteer to v23.10.3 + +### Patch Changes + +- Updated dependencies +- Updated dependencies +- Updated dependencies + - @0xsequence/utils@2.2.0 + +## 2.1.8 + +### Patch Changes + +- Add Soneium Mainnet +- Updated dependencies + - @0xsequence/utils@2.1.8 + +## 2.1.7 + +### Patch Changes + +- guard: pass project access key to guard requests +- Updated dependencies + - @0xsequence/utils@2.1.7 + +## 2.1.6 + +### Patch Changes + +- Add LAOS and Telos Testnet chains +- Updated dependencies + - @0xsequence/utils@2.1.6 + +## 2.1.5 + +### Patch Changes + +- account: save presigned configuration with reference chain id 1 +- Updated dependencies + - @0xsequence/utils@2.1.5 + +## 2.1.4 + +### Patch Changes + +- provider: pass projectAccessKey into MuxMessageProvider +- Updated dependencies + - @0xsequence/utils@2.1.4 + +## 2.1.3 + +### Patch Changes + +- waas: time drift date fix due to strange browser quirk +- Updated dependencies + - @0xsequence/utils@2.1.3 + +## 2.1.2 + +### Patch Changes + +- provider: export analytics correctly +- Updated dependencies + - @0xsequence/utils@2.1.2 + +## 2.1.1 + +### Patch Changes + +- Add LAOS chain support +- Updated dependencies + - @0xsequence/utils@2.1.1 + +## 2.1.0 + +### Minor Changes + +- account: forward project access key when estimating fees and sending transactions + +### Patch Changes + +- sessions: save signatures with reference chain id +- Updated dependencies +- Updated dependencies + - @0xsequence/utils@2.1.0 + +## 2.0.26 + +### Patch Changes + +- account: fix chain id comparison +- Updated dependencies + - @0xsequence/utils@2.0.26 + +## 2.0.25 + +### Patch Changes + +- skale-nebula: deploy gas limit = 10m +- Updated dependencies + - @0xsequence/utils@2.0.25 + +## 2.0.24 + +### Patch Changes + +- sessions: arweave: configurable gateway url +- waas: use /status to get time drift before sending any intents +- Updated dependencies +- Updated dependencies + - @0xsequence/utils@2.0.24 + +## 2.0.23 + +### Patch Changes + +- Add The Root Network support +- Updated dependencies + - @0xsequence/utils@2.0.23 + +## 2.0.22 + +### Patch Changes + +- Add SKALE Nebula Mainnet support +- Updated dependencies + - @0xsequence/utils@2.0.22 + +## 2.0.21 + +### Patch Changes + +- account: add publishWitnessFor +- Updated dependencies + - @0xsequence/utils@2.0.21 + +## 2.0.20 + +### Patch Changes + +- upgrade deps, and improve waas session status handling +- Updated dependencies + - @0xsequence/utils@2.0.20 + +## 2.0.19 + +### Patch Changes + +- Add Immutable zkEVM support +- Updated dependencies + - @0xsequence/utils@2.0.19 + +## 2.0.18 + +### Patch Changes + +- waas: new contractCall transaction type +- sessions: add arweave owner +- Updated dependencies +- Updated dependencies + - @0xsequence/utils@2.0.18 + +## 2.0.17 + +### Patch Changes + +- update waas auth to clear session before signIn +- Updated dependencies + - @0xsequence/utils@2.0.17 + +## 2.0.16 + +### Patch Changes + +- Removed Astar chains +- Updated dependencies + - @0xsequence/utils@2.0.16 + +## 2.0.15 + +### Patch Changes + +- indexer: update bindings with token balance additions +- Updated dependencies + - @0xsequence/utils@2.0.15 + +## 2.0.14 + +### Patch Changes + +- sessions: arweave config reader +- network: add b3 and apechain mainnet configs +- Updated dependencies +- Updated dependencies + - @0xsequence/utils@2.0.14 + +## 2.0.13 + +### Patch Changes + +- network: toy-testnet +- Updated dependencies + - @0xsequence/utils@2.0.13 + +## 2.0.12 + +### Patch Changes + +- api: update bindings +- Updated dependencies + - @0xsequence/utils@2.0.12 + +## 2.0.11 + +### Patch Changes + +- waas: intents test fix +- api: update bindings +- Updated dependencies +- Updated dependencies + - @0xsequence/utils@2.0.11 + +## 2.0.10 + +### Patch Changes + +- network: soneium minato testnet +- Updated dependencies + - @0xsequence/utils@2.0.10 + +## 2.0.9 + +### Patch Changes + +- network: fix SKALE network name +- Updated dependencies + - @0xsequence/utils@2.0.9 + +## 2.0.8 + +### Patch Changes + +- metadata: update bindings +- Updated dependencies + - @0xsequence/utils@2.0.8 + +## 2.0.7 + +### Patch Changes + +- wallet request handler fix +- Updated dependencies + - @0xsequence/utils@2.0.7 + +## 2.0.6 + +### Patch Changes + +- network: matic -> pol +- Updated dependencies + - @0xsequence/utils@2.0.6 + +## 2.0.5 + +### Patch Changes + +- provider: update databeat to 0.9.2 +- Updated dependencies + - @0xsequence/utils@2.0.5 + +## 2.0.4 + +### Patch Changes + +- network: add skale-nebula-testnet +- Updated dependencies + - @0xsequence/utils@2.0.4 + +## 2.0.3 + +### Patch Changes + +- waas: check session status in SequenceWaaS.isSignedIn() +- Updated dependencies + - @0xsequence/utils@2.0.3 + +## 2.0.2 + +### Patch Changes + +- sessions: property convert serialized bignumber hex value to bigint +- Updated dependencies + - @0xsequence/utils@2.0.2 + +## 2.0.1 + +### Patch Changes + +- waas: http signature check for authenticator requests +- provider: unwrap legacy json rpc responses +- use json replacer and reviver for bigints +- Updated dependencies +- Updated dependencies +- Updated dependencies + - @0xsequence/utils@2.0.1 + +## 2.0.0 + +### Major Changes + +- ethers v6 + +### Patch Changes + +- Updated dependencies + - @0xsequence/utils@2.0.0 + +## 1.10.15 + +### Patch Changes + +- utils: extractProjectIdFromAccessKey +- Updated dependencies + - @0xsequence/utils@1.10.15 + ## 1.10.14 ### Patch Changes diff --git a/packages/deployer/README.md b/packages/deployer/README.md index 1c58d69d4..fc099e7a4 100644 --- a/packages/deployer/README.md +++ b/packages/deployer/README.md @@ -1,5 +1,4 @@ -@0xsequence/deployer -==================== +# @0xsequence/deployer Deploy contracts using a universal deployer via CREATE2, allowing contracts to have the same address on any EVM chain. @@ -10,9 +9,9 @@ For more info, see [0xsequence project page](https://github.com/0xsequence/seque # How to use 1. `yarn add @0xsequence/deployer` -1. Import UniversalDeployer into script -2. Create UniversalDeployer instance -3. Deploy contracts +2. Import UniversalDeployer into script +3. Create UniversalDeployer instance +4. Deploy contracts An `instance` number can be passed if multiple instance of the same contract need to be deployed on the same chain. The default instance number is 0, if none is passed. @@ -45,8 +44,8 @@ You can also pass transaction parameters explicitly : ... const main = async () => { - await universalDeployer.deploy('WalletFactory', FactoryFactory, {gasLimit: 1000000} ) - await universalDeployer.deploy('MainModuleUpgradable', MainModuleUpgradableFactory, {gasPrice: new BigNumber(10).pow(9)}) + await universalDeployer.deploy('WalletFactory', FactoryFactory, { gasLimit: 1000000 }) + await universalDeployer.deploy('MainModuleUpgradable', MainModuleUpgradableFactory, { gasPrice: 10n ** 9n }) } ``` diff --git a/packages/deployer/package.json b/packages/deployer/package.json index 8e3cf8c1b..4683ac570 100644 --- a/packages/deployer/package.json +++ b/packages/deployer/package.json @@ -1,6 +1,6 @@ { "name": "@0xsequence/deployer", - "version": "1.10.14", + "version": "2.2.14", "description": "deployer sub-package for Sequence", "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/deployer", "source": "src/index.ts", @@ -14,24 +14,17 @@ "typecheck": "tsc --noEmit", "build": "rm -rf src/typings && TS_NODE_PROJECT=../../tsconfig.test.json hardhat clean && pnpm compile-contracts && pnpm gen:typings", "compile-contracts": "TS_NODE_PROJECT=../../tsconfig.test.json hardhat --max-memory 4096 compile", - "gen:typings": "rm -rf ./src/typings/contracts/* && typechain --target ethers-v5 --out-dir src/typings/contracts './artifacts/contracts/!(build-info)/**/*[^dbg].json'" + "gen:typings": "rm -rf ./src/typings/contracts/* && typechain --target ethers-v6 --out-dir src/typings/contracts './artifacts/contracts/!(build-info)/**/*[^dbg].json'" + }, + "peerDependencies": { + "ethers": ">=6" }, "dependencies": { "@0xsequence/utils": "workspace:*" }, - "peerDependencies": { - "ethers": ">=5.5 < 6", - "@ethersproject/abi": ">= 5.5", - "@ethersproject/providers": ">= 5.5" - }, "devDependencies": { - "@ethersproject/abi": "^5.7.0", - "@ethersproject/providers": "^5.7.2", - "@nomiclabs/hardhat-ethers": "^2.2.1", - "@nomiclabs/hardhat-web3": "^2.0.0", - "@typechain/ethers-v5": "^10.1.1", "dotenv": "^16.0.3", - "ethers": "^5.7.2", + "ethers": "6.13.4", "typechain": "^8.1.1" }, "files": [ diff --git a/packages/deployer/src/UniversalDeployer.ts b/packages/deployer/src/UniversalDeployer.ts index 598bc4611..0d121e13e 100644 --- a/packages/deployer/src/UniversalDeployer.ts +++ b/packages/deployer/src/UniversalDeployer.ts @@ -1,5 +1,5 @@ import * as fs from 'fs' -import { ethers, ContractFactory, ContractTransaction } from 'ethers' +import { ethers } from 'ethers' import { promisify, isNode } from '@0xsequence/utils' import { UniversalDeployer2__factory } from './typings/contracts' import { @@ -16,60 +16,68 @@ import { createLogger, Logger } from './utils/logger' let prompt: Logger createLogger().then(logger => (prompt = logger)) -ethers.utils.Logger.setLogLevel(ethers.utils.Logger.levels.OFF) - export class UniversalDeployer { private deployedInstances: ContractInstance[] = [] - private signer: ethers.Signer + private signer: Promise constructor( public networkName: string, - public provider: ethers.providers.JsonRpcProvider, + public provider: ethers.JsonRpcProvider, public signerOverride?: ethers.Signer ) { - this.signer = signerOverride || provider.getSigner() + if (signerOverride) { + this.signer = Promise.resolve(signerOverride) + } else { + this.signer = provider.getSigner() + } } - deploy = async ( + deploy = async ( contractAlias: string, contractFactory: new (signer: ethers.Signer) => T, - txParams?: ethers.providers.TransactionRequest, - instance?: number | ethers.BigNumber, + txParams?: ethers.TransactionRequest, + instance?: number | bigint, ...args: Parameters - ): Promise => { + ): Promise => { try { // Deploy universal deployer 2 if not yet deployed on chain_id const universalDeployer2Code = await this.provider.getCode(UNIVERSAL_DEPLOYER_2_ADDRESS) - if (universalDeployer2Code === '0x') await this.deployUniversalDeployer2(txParams) + if (universalDeployer2Code === '0x') { + await this.deployUniversalDeployer2(txParams) + } // Deploying contract prompt.start(`Deploying ${contractAlias}`) - const factory = new contractFactory(this.signer) + const factory = new contractFactory(await this.signer) const deployTx = await factory.getDeployTransaction(...args) // Make sure instance number is specified - const instanceNumber = instance !== undefined ? instance : 0 + const instanceNumber = instance !== undefined ? BigInt(instance) : 0n // Verify if contract already deployed const contractAddress = await this.addressOf(contractFactory, instanceNumber, ...args) const contractCode = await this.provider.getCode(contractAddress) - const deployer = UniversalDeployer2__factory.connect(UNIVERSAL_DEPLOYER_2_ADDRESS, this.signer) + const deployer = UniversalDeployer2__factory.connect(UNIVERSAL_DEPLOYER_2_ADDRESS, await this.signer) if (contractCode === '0x') { // Deploy contract if not already deployed - const tx = (await deployer.functions.deploy(deployTx.data!, instanceNumber, txParams)) as ContractTransaction + const tx = await deployer.deploy(deployTx.data!, instanceNumber, txParams!) await tx.wait() // Verify that the deployment was successful since tx won't revert const postDeployCode = await this.provider.getCode(contractAddress) - postDeployCode === '0x' ? prompt.fail(contractAddress) : prompt.succeed() + if (postDeployCode === '0x') { + prompt.fail(contractAddress) + } else { + prompt.succeed() + } } else { prompt.warn(`ALREADY DEPLOYED: ${contractAlias}`) } const contract = factory.attach(contractAddress) - this.deployedInstances.push({ contractAlias, contract }) + this.deployedInstances.push({ contractAddress, contractAlias, contract }) return contract } catch (error) { @@ -77,25 +85,29 @@ export class UniversalDeployer { } } - deployUniversalDeployer = async (txParams?: ethers.providers.TransactionRequest) => { + deployUniversalDeployer = async (txParams?: ethers.TransactionRequest) => { if ((await this.provider.getBalance(EOA_UNIVERSAL_DEPLOYER_ADDRESS)) < UNIVERSAL_DEPLOYER_FUNDING) { prompt.start("Funding universal deployer's EOA") - const tx = await this.signer.sendTransaction({ + + const signer = await this.signer + + const tx = await signer.sendTransaction({ to: EOA_UNIVERSAL_DEPLOYER_ADDRESS, value: UNIVERSAL_DEPLOYER_FUNDING, ...txParams }) + const receipt = await tx.wait() - if (receipt.status !== 1) { - prompt.fail('txn receipt status failed') - } else { + + if (receipt?.status === 1) { prompt.succeed() + } else { + prompt.fail('txn receipt status failed') } } prompt.start('Deploying universal deployer contract') - const tx2 = await this.provider.sendTransaction(UNIVERSAL_DEPLOYER_TX) - // await tx2.wait() + await this.provider.broadcastTransaction(UNIVERSAL_DEPLOYER_TX) // const universalDeployerCodeCheck = await this.provider.getCode(UNIVERSAL_DEPLOYER_ADDRESS) // if (universalDeployerCodeCheck === '0x') { @@ -107,11 +119,13 @@ export class UniversalDeployer { } // Deploy universal deployer via universal deployer 1 - deployUniversalDeployer2 = async (txParams?: ethers.providers.TransactionRequest) => { + deployUniversalDeployer2 = async (txParams?: ethers.TransactionRequest) => { const universalDeployerCode = await this.provider.getCode(UNIVERSAL_DEPLOYER_ADDRESS) if (universalDeployerCode === '0x') { await this.deployUniversalDeployer(txParams) } else { + // NOTE: already deployed + // eslint-disable-next-line ;('ALREADY DEPLOYED') } @@ -119,12 +133,14 @@ export class UniversalDeployer { // which is emitted from the deployer 1 contract creation logs. This address may change if // the UNIVERSAL_DEPLOYER_2_BYTECODE changes of the deployer -- which should never really happen. + const signer = await this.signer + prompt.start('Deploying universal deployer 2 contract') - const tx = (await this.signer.sendTransaction({ + const tx = await signer.sendTransaction({ to: UNIVERSAL_DEPLOYER_ADDRESS, data: UNIVERSAL_DEPLOYER_2_BYTECODE, ...txParams - })) as ContractTransaction + }) await tx.wait() // const universalDeployer2CodeCheck = await this.provider.getCode(UNIVERSAL_DEPLOYER_2_ADDRESS) @@ -139,27 +155,19 @@ export class UniversalDeployer { getDeployment = () => { return this.deployedInstances.reduce( (list, instance) => { - const { contract, contractAlias } = instance - list[contractAlias] = contract + const { contractAddress, contractAlias } = instance + list[contractAlias] = contractAddress return list }, - {} as { [key: string]: ethers.Contract | { address: string } } + {} as { [key: string]: string } ) } getDeploymentList = () => - this.deployedInstances.map(({ contract, contractAlias }) => { - if (contract as ethers.Contract) { - return { - contractName: contractAlias, - address: contract.address - // abi: contract.interface.abi - } - } else { - return { - contractName: contractAlias, - address: contract.address - } + this.deployedInstances.map(({ contractAddress, contractAlias }) => { + return { + contractName: contractAlias, + contractAddress } }) @@ -175,33 +183,31 @@ export class UniversalDeployer { ) } - manualDeploymentRegistration = (contractAlias: string, address: string) => { + manualDeploymentRegistration = (contractAlias: string, contractAddress: string) => { this.deployedInstances.push({ contractAlias, - contract: { address: address } + contractAddress }) } - addressOf = async ( + addressOf = async ( contractFactory: new (signer: ethers.Signer) => T, - contractInstance: number | ethers.BigNumber, + contractInstance: number | bigint, ...args: Parameters ): Promise => { - const factory = new contractFactory(this.signer) + const factory = new contractFactory(await this.signer) const deployTx = await factory.getDeployTransaction(...args) const deployData = deployTx.data - const codeHash = ethers.utils.keccak256(ethers.utils.solidityPack(['bytes'], [deployData])) + const codeHash = ethers.solidityPackedKeccak256(['bytes'], [deployData]) - const salt = ethers.utils.solidityPack(['uint256'], [contractInstance]) + const salt = ethers.solidityPacked(['uint256'], [contractInstance]) - const hash = ethers.utils.keccak256( - ethers.utils.solidityPack( - ['bytes1', 'address', 'bytes32', 'bytes32'], - ['0xff', UNIVERSAL_DEPLOYER_2_ADDRESS, salt, codeHash] - ) + const hash = ethers.solidityPackedKeccak256( + ['bytes1', 'address', 'bytes32', 'bytes32'], + ['0xff', UNIVERSAL_DEPLOYER_2_ADDRESS, salt, codeHash] ) - return ethers.utils.getAddress(ethers.utils.hexDataSlice(hash, 12)) + return ethers.getAddress(ethers.dataSlice(hash, 12)) } } diff --git a/packages/deployer/src/constants.ts b/packages/deployer/src/constants.ts index 9fded9dcd..44b7c79ab 100644 --- a/packages/deployer/src/constants.ts +++ b/packages/deployer/src/constants.ts @@ -1,9 +1,7 @@ -import { BigNumber } from 'ethers' - export const EOA_UNIVERSAL_DEPLOYER_ADDRESS: string = '0x9c5a87452d4FAC0cbd53BDCA580b20A45526B3AB' export const UNIVERSAL_DEPLOYER_ADDRESS: string = '0x1b926fbb24a9f78dcdd3272f2d86f5d0660e59c0' export const UNIVERSAL_DEPLOYER_2_ADDRESS: string = '0x8a5bc19e22d6ad55a2c763b93a75d09f321fe764' -export const UNIVERSAL_DEPLOYER_FUNDING: BigNumber = BigNumber.from(300).mul(BigNumber.from(10).pow(14)) +export const UNIVERSAL_DEPLOYER_FUNDING: bigint = 300n * 10n ** 14n export const UNIVERSAL_DEPLOYER_TX: string = '0xf9010880852416b84e01830222e08080b8b66080604052348015600f57600080fd5b50609980601d6000396000f3fe60a06020601f369081018290049091028201604052608081815260009260609284918190838280828437600092018290525084519495509392505060208401905034f5604080516001600160a01b0383168152905191935081900360200190a0505000fea26469706673582212205a310755225e3c740b2f013fb6343f4c205e7141fcdf15947f5f0e0e818727fb64736f6c634300060a00331ca01820182018201820182018201820182018201820182018201820182018201820a01820182018201820182018201820182018201820182018201820182018201820' diff --git a/packages/deployer/src/types.ts b/packages/deployer/src/types.ts index 69b31aec4..f53d0629b 100644 --- a/packages/deployer/src/types.ts +++ b/packages/deployer/src/types.ts @@ -1,12 +1,13 @@ -import { Contract } from 'ethers' +import { ethers } from 'ethers' export interface FactoryDeployedContract { address: string } export interface ContractInstance { + contractAddress: string contractAlias: string - contract: Contract | { address: string } + contract?: ethers.BaseContract } export interface ContractInfo { diff --git a/packages/deployer/src/typings/contracts/NanoUniversalDeployer.ts b/packages/deployer/src/typings/contracts/NanoUniversalDeployer.ts index 9f8504028..dc3bdac00 100644 --- a/packages/deployer/src/typings/contracts/NanoUniversalDeployer.ts +++ b/packages/deployer/src/typings/contracts/NanoUniversalDeployer.ts @@ -1,60 +1,73 @@ /* Autogenerated file. Do not edit manually. */ /* tslint:disable */ /* eslint-disable */ -import type { BaseContract, Signer, utils } from 'ethers' -import type { EventFragment } from '@ethersproject/abi' -import type { Listener, Provider } from '@ethersproject/providers' -import type { TypedEventFilter, TypedEvent, TypedListener, OnEvent, PromiseOrValue } from './common' - -export interface NanoUniversalDeployerInterface extends utils.Interface { - functions: {} - - events: { - 'Deploy(address)': EventFragment - } +import type { + BaseContract, + FunctionFragment, + Interface, + EventFragment, + AddressLike, + ContractRunner, + ContractMethod, + Listener +} from 'ethers' +import type { TypedContractEvent, TypedDeferredTopicFilter, TypedEventLog, TypedLogDescription, TypedListener } from './common' +export interface NanoUniversalDeployerInterface extends Interface { getEvent(nameOrSignatureOrTopic: 'Deploy'): EventFragment } -export interface DeployEventObject { - _addr: string +export namespace DeployEvent { + export type InputTuple = [_addr: AddressLike] + export type OutputTuple = [_addr: string] + export interface OutputObject { + _addr: string + } + export type Event = TypedContractEvent + export type Filter = TypedDeferredTopicFilter + export type Log = TypedEventLog + export type LogDescription = TypedLogDescription } -export type DeployEvent = TypedEvent<[string], DeployEventObject> - -export type DeployEventFilter = TypedEventFilter export interface NanoUniversalDeployer extends BaseContract { - connect(signerOrProvider: Signer | Provider | string): this - attach(addressOrName: string): this - deployed(): Promise + connect(runner?: ContractRunner | null): NanoUniversalDeployer + waitForDeployment(): Promise interface: NanoUniversalDeployerInterface - queryFilter( - event: TypedEventFilter, + queryFilter( + event: TCEvent, fromBlockOrBlockhash?: string | number | undefined, toBlock?: string | number | undefined - ): Promise> + ): Promise>> + queryFilter( + filter: TypedDeferredTopicFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>> - listeners(eventFilter?: TypedEventFilter): Array> - listeners(eventName?: string): Array - removeAllListeners(eventFilter: TypedEventFilter): this - removeAllListeners(eventName?: string): this - off: OnEvent - on: OnEvent - once: OnEvent - removeListener: OnEvent + on(event: TCEvent, listener: TypedListener): Promise + on( + filter: TypedDeferredTopicFilter, + listener: TypedListener + ): Promise - functions: {} + once(event: TCEvent, listener: TypedListener): Promise + once( + filter: TypedDeferredTopicFilter, + listener: TypedListener + ): Promise - callStatic: {} + listeners(event: TCEvent): Promise>> + listeners(eventName?: string): Promise> + removeAllListeners(event?: TCEvent): Promise - filters: { - 'Deploy(address)'(_addr?: null): DeployEventFilter - Deploy(_addr?: null): DeployEventFilter - } + getFunction(key: string | FunctionFragment): T - estimateGas: {} + getEvent(key: 'Deploy'): TypedContractEvent - populateTransaction: {} + filters: { + 'Deploy(address)': TypedContractEvent + Deploy: TypedContractEvent + } } diff --git a/packages/deployer/src/typings/contracts/UniversalDeployer2.ts b/packages/deployer/src/typings/contracts/UniversalDeployer2.ts index cf2db74ce..e89a87890 100644 --- a/packages/deployer/src/typings/contracts/UniversalDeployer2.ts +++ b/packages/deployer/src/typings/contracts/UniversalDeployer2.ts @@ -3,107 +3,93 @@ /* eslint-disable */ import type { BaseContract, - BigNumber, BigNumberish, BytesLike, - CallOverrides, - ContractTransaction, - PayableOverrides, - PopulatedTransaction, - Signer, - utils + FunctionFragment, + Result, + Interface, + EventFragment, + AddressLike, + ContractRunner, + ContractMethod, + Listener } from 'ethers' -import type { FunctionFragment, Result, EventFragment } from '@ethersproject/abi' -import type { Listener, Provider } from '@ethersproject/providers' -import type { TypedEventFilter, TypedEvent, TypedListener, OnEvent, PromiseOrValue } from './common' +import type { + TypedContractEvent, + TypedDeferredTopicFilter, + TypedEventLog, + TypedLogDescription, + TypedListener, + TypedContractMethod +} from './common' -export interface UniversalDeployer2Interface extends utils.Interface { - functions: { - 'deploy(bytes,uint256)': FunctionFragment - } +export interface UniversalDeployer2Interface extends Interface { + getFunction(nameOrSignature: 'deploy'): FunctionFragment - getFunction(nameOrSignatureOrTopic: 'deploy'): FunctionFragment + getEvent(nameOrSignatureOrTopic: 'Deploy'): EventFragment - encodeFunctionData(functionFragment: 'deploy', values: [PromiseOrValue, PromiseOrValue]): string + encodeFunctionData(functionFragment: 'deploy', values: [BytesLike, BigNumberish]): string decodeFunctionResult(functionFragment: 'deploy', data: BytesLike): Result - - events: { - 'Deploy(address)': EventFragment - } - - getEvent(nameOrSignatureOrTopic: 'Deploy'): EventFragment } -export interface DeployEventObject { - _addr: string +export namespace DeployEvent { + export type InputTuple = [_addr: AddressLike] + export type OutputTuple = [_addr: string] + export interface OutputObject { + _addr: string + } + export type Event = TypedContractEvent + export type Filter = TypedDeferredTopicFilter + export type Log = TypedEventLog + export type LogDescription = TypedLogDescription } -export type DeployEvent = TypedEvent<[string], DeployEventObject> - -export type DeployEventFilter = TypedEventFilter export interface UniversalDeployer2 extends BaseContract { - connect(signerOrProvider: Signer | Provider | string): this - attach(addressOrName: string): this - deployed(): Promise + connect(runner?: ContractRunner | null): UniversalDeployer2 + waitForDeployment(): Promise interface: UniversalDeployer2Interface - queryFilter( - event: TypedEventFilter, + queryFilter( + event: TCEvent, fromBlockOrBlockhash?: string | number | undefined, toBlock?: string | number | undefined - ): Promise> - - listeners(eventFilter?: TypedEventFilter): Array> - listeners(eventName?: string): Array - removeAllListeners(eventFilter: TypedEventFilter): this - removeAllListeners(eventName?: string): this - off: OnEvent - on: OnEvent - once: OnEvent - removeListener: OnEvent - - functions: { - deploy( - _creationCode: PromiseOrValue, - _instance: PromiseOrValue, - overrides?: PayableOverrides & { from?: PromiseOrValue } - ): Promise - } + ): Promise>> + queryFilter( + filter: TypedDeferredTopicFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>> - deploy( - _creationCode: PromiseOrValue, - _instance: PromiseOrValue, - overrides?: PayableOverrides & { from?: PromiseOrValue } - ): Promise - - callStatic: { - deploy( - _creationCode: PromiseOrValue, - _instance: PromiseOrValue, - overrides?: CallOverrides - ): Promise - } + on(event: TCEvent, listener: TypedListener): Promise + on( + filter: TypedDeferredTopicFilter, + listener: TypedListener + ): Promise - filters: { - 'Deploy(address)'(_addr?: null): DeployEventFilter - Deploy(_addr?: null): DeployEventFilter - } + once(event: TCEvent, listener: TypedListener): Promise + once( + filter: TypedDeferredTopicFilter, + listener: TypedListener + ): Promise - estimateGas: { - deploy( - _creationCode: PromiseOrValue, - _instance: PromiseOrValue, - overrides?: PayableOverrides & { from?: PromiseOrValue } - ): Promise - } + listeners(event: TCEvent): Promise>> + listeners(eventName?: string): Promise> + removeAllListeners(event?: TCEvent): Promise - populateTransaction: { - deploy( - _creationCode: PromiseOrValue, - _instance: PromiseOrValue, - overrides?: PayableOverrides & { from?: PromiseOrValue } - ): Promise + deploy: TypedContractMethod<[_creationCode: BytesLike, _instance: BigNumberish], [void], 'payable'> + + getFunction(key: string | FunctionFragment): T + + getFunction( + nameOrSignature: 'deploy' + ): TypedContractMethod<[_creationCode: BytesLike, _instance: BigNumberish], [void], 'payable'> + + getEvent(key: 'Deploy'): TypedContractEvent + + filters: { + 'Deploy(address)': TypedContractEvent + Deploy: TypedContractEvent } } diff --git a/packages/deployer/src/typings/contracts/common.ts b/packages/deployer/src/typings/contracts/common.ts index 5d37e711b..65ad08ab5 100644 --- a/packages/deployer/src/typings/contracts/common.ts +++ b/packages/deployer/src/typings/contracts/common.ts @@ -1,32 +1,86 @@ /* Autogenerated file. Do not edit manually. */ /* tslint:disable */ /* eslint-disable */ -import type { Listener } from '@ethersproject/providers' -import type { Event, EventFilter } from 'ethers' +import type { + FunctionFragment, + Typed, + EventFragment, + ContractTransaction, + ContractTransactionResponse, + DeferredTopicFilter, + EventLog, + TransactionRequest, + LogDescription +} from 'ethers' -export interface TypedEvent = any, TArgsObject = any> extends Event { - args: TArgsArray & TArgsObject +export interface TypedDeferredTopicFilter<_TCEvent extends TypedContractEvent> extends DeferredTopicFilter {} + +export interface TypedContractEvent< + InputTuple extends Array = any, + OutputTuple extends Array = any, + OutputObject = any +> { + (...args: Partial): TypedDeferredTopicFilter> + name: string + fragment: EventFragment + getFragment(...args: Partial): EventFragment } -export interface TypedEventFilter<_TEvent extends TypedEvent> extends EventFilter {} +type __TypechainAOutputTuple = T extends TypedContractEvent ? W : never +type __TypechainOutputObject = T extends TypedContractEvent ? V : never -export interface TypedListener { - (...listenerArg: [...__TypechainArgsArray, TEvent]): void +export interface TypedEventLog extends Omit { + args: __TypechainAOutputTuple & __TypechainOutputObject } -type __TypechainArgsArray = T extends TypedEvent ? U : never - -export interface OnEvent { - (eventFilter: TypedEventFilter, listener: TypedListener): TRes - (eventName: string, listener: Listener): TRes +export interface TypedLogDescription extends Omit { + args: __TypechainAOutputTuple & __TypechainOutputObject } +export type TypedListener = ( + ...listenerArg: [...__TypechainAOutputTuple, TypedEventLog, ...undefined[]] +) => void + export type MinEthersFactory = { deploy(...a: ARGS[]): Promise } export type GetContractTypeFromFactory = F extends MinEthersFactory ? C : never - export type GetARGsTypeFromFactory = F extends MinEthersFactory ? Parameters : never -export type PromiseOrValue = T | Promise +export type StateMutability = 'nonpayable' | 'payable' | 'view' + +export type BaseOverrides = Omit +export type NonPayableOverrides = Omit +export type PayableOverrides = Omit +export type ViewOverrides = Omit +export type Overrides = S extends 'nonpayable' + ? NonPayableOverrides + : S extends 'payable' + ? PayableOverrides + : ViewOverrides + +export type PostfixOverrides, S extends StateMutability> = A | [...A, Overrides] +export type ContractMethodArgs, S extends StateMutability> = PostfixOverrides< + { [I in keyof A]-?: A[I] | Typed }, + S +> + +export type DefaultReturnType = R extends Array ? R[0] : R + +// export interface ContractMethod = Array, R = any, D extends R | ContractTransactionResponse = R | ContractTransactionResponse> { +export interface TypedContractMethod = Array, R = any, S extends StateMutability = 'payable'> { + (...args: ContractMethodArgs): S extends 'view' ? Promise> : Promise + + name: string + + fragment: FunctionFragment + + getFragment(...args: ContractMethodArgs): FunctionFragment + + populateTransaction(...args: ContractMethodArgs): Promise + staticCall(...args: ContractMethodArgs): Promise> + send(...args: ContractMethodArgs): Promise + estimateGas(...args: ContractMethodArgs): Promise + staticCallResult(...args: ContractMethodArgs): Promise +} diff --git a/packages/deployer/src/typings/contracts/factories/NanoUniversalDeployer__factory.ts b/packages/deployer/src/typings/contracts/factories/NanoUniversalDeployer__factory.ts index bcecf7001..9c4ea940a 100644 --- a/packages/deployer/src/typings/contracts/factories/NanoUniversalDeployer__factory.ts +++ b/packages/deployer/src/typings/contracts/factories/NanoUniversalDeployer__factory.ts @@ -1,9 +1,9 @@ /* Autogenerated file. Do not edit manually. */ /* tslint:disable */ /* eslint-disable */ -import { Signer, utils, Contract, ContractFactory, Overrides } from 'ethers' -import type { Provider, TransactionRequest } from '@ethersproject/providers' -import type { PromiseOrValue } from '../common' +import { Contract, ContractFactory, ContractTransactionResponse, Interface } from 'ethers' +import type { Signer, ContractDeployTransaction, ContractRunner } from 'ethers' +import type { NonPayableOverrides } from '../common' import type { NanoUniversalDeployer, NanoUniversalDeployerInterface } from '../NanoUniversalDeployer' const _abi = [ @@ -24,7 +24,7 @@ const _abi = [ stateMutability: 'payable', type: 'fallback' } -] +] as const const _bytecode = '0x6080604052348015600f57600080fd5b5060a580601d6000396000f3fe60a06020601f3690810182900490910282016040526080818152600092839283918190838280828437600092018290525084519495509392505060208401905034f56040805173ffffffffffffffffffffffffffffffffffffffff83168152905191935081900360200190a0505000fea26469706673582212207457f4b6f392e3ba295b33e363360d55f06ead85ec96165a406e7b0231ab668464736f6c63430007060033' @@ -43,25 +43,26 @@ export class NanoUniversalDeployer__factory extends ContractFactory { } } - override deploy(overrides?: Overrides & { from?: PromiseOrValue }): Promise { - return super.deploy(overrides || {}) as Promise - } - override getDeployTransaction(overrides?: Overrides & { from?: PromiseOrValue }): TransactionRequest { + override getDeployTransaction(overrides?: NonPayableOverrides & { from?: string }): Promise { return super.getDeployTransaction(overrides || {}) } - override attach(address: string): NanoUniversalDeployer { - return super.attach(address) as NanoUniversalDeployer + override deploy(overrides?: NonPayableOverrides & { from?: string }) { + return super.deploy(overrides || {}) as Promise< + NanoUniversalDeployer & { + deploymentTransaction(): ContractTransactionResponse + } + > } - override connect(signer: Signer): NanoUniversalDeployer__factory { - return super.connect(signer) as NanoUniversalDeployer__factory + override connect(runner: ContractRunner | null): NanoUniversalDeployer__factory { + return super.connect(runner) as NanoUniversalDeployer__factory } static readonly bytecode = _bytecode static readonly abi = _abi static createInterface(): NanoUniversalDeployerInterface { - return new utils.Interface(_abi) as NanoUniversalDeployerInterface + return new Interface(_abi) as NanoUniversalDeployerInterface } - static connect(address: string, signerOrProvider: Signer | Provider): NanoUniversalDeployer { - return new Contract(address, _abi, signerOrProvider) as NanoUniversalDeployer + static connect(address: string, runner?: ContractRunner | null): NanoUniversalDeployer { + return new Contract(address, _abi, runner) as unknown as NanoUniversalDeployer } } diff --git a/packages/deployer/src/typings/contracts/factories/UniversalDeployer2__factory.ts b/packages/deployer/src/typings/contracts/factories/UniversalDeployer2__factory.ts index 67cf2eb00..3a7619de1 100644 --- a/packages/deployer/src/typings/contracts/factories/UniversalDeployer2__factory.ts +++ b/packages/deployer/src/typings/contracts/factories/UniversalDeployer2__factory.ts @@ -1,9 +1,9 @@ /* Autogenerated file. Do not edit manually. */ /* tslint:disable */ /* eslint-disable */ -import { Signer, utils, Contract, ContractFactory, Overrides } from 'ethers' -import type { Provider, TransactionRequest } from '@ethersproject/providers' -import type { PromiseOrValue } from '../common' +import { Contract, ContractFactory, ContractTransactionResponse, Interface } from 'ethers' +import type { Signer, ContractDeployTransaction, ContractRunner } from 'ethers' +import type { NonPayableOverrides } from '../common' import type { UniversalDeployer2, UniversalDeployer2Interface } from '../UniversalDeployer2' const _abi = [ @@ -38,7 +38,7 @@ const _abi = [ stateMutability: 'payable', type: 'function' } -] +] as const const _bytecode = '0x608060405234801561001057600080fd5b5061013d806100206000396000f3fe60806040526004361061001e5760003560e01c80639c4ae2d014610023575b600080fd5b6100cb6004803603604081101561003957600080fd5b81019060208101813564010000000081111561005457600080fd5b82018360208201111561006657600080fd5b8035906020019184600183028401116401000000008311171561008857600080fd5b91908080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525092955050913592506100cd915050565b005b60008183516020850134f56040805173ffffffffffffffffffffffffffffffffffffffff83168152905191925081900360200190a050505056fea264697066735822122033609f614f03931b92d88c309d698449bb77efcd517328d341fa4f923c5d8c7964736f6c63430007060033' @@ -57,25 +57,26 @@ export class UniversalDeployer2__factory extends ContractFactory { } } - override deploy(overrides?: Overrides & { from?: PromiseOrValue }): Promise { - return super.deploy(overrides || {}) as Promise - } - override getDeployTransaction(overrides?: Overrides & { from?: PromiseOrValue }): TransactionRequest { + override getDeployTransaction(overrides?: NonPayableOverrides & { from?: string }): Promise { return super.getDeployTransaction(overrides || {}) } - override attach(address: string): UniversalDeployer2 { - return super.attach(address) as UniversalDeployer2 + override deploy(overrides?: NonPayableOverrides & { from?: string }) { + return super.deploy(overrides || {}) as Promise< + UniversalDeployer2 & { + deploymentTransaction(): ContractTransactionResponse + } + > } - override connect(signer: Signer): UniversalDeployer2__factory { - return super.connect(signer) as UniversalDeployer2__factory + override connect(runner: ContractRunner | null): UniversalDeployer2__factory { + return super.connect(runner) as UniversalDeployer2__factory } static readonly bytecode = _bytecode static readonly abi = _abi static createInterface(): UniversalDeployer2Interface { - return new utils.Interface(_abi) as UniversalDeployer2Interface + return new Interface(_abi) as UniversalDeployer2Interface } - static connect(address: string, signerOrProvider: Signer | Provider): UniversalDeployer2 { - return new Contract(address, _abi, signerOrProvider) as UniversalDeployer2 + static connect(address: string, runner?: ContractRunner | null): UniversalDeployer2 { + return new Contract(address, _abi, runner) as unknown as UniversalDeployer2 } } diff --git a/packages/deployer/src/utils/configLoader.ts b/packages/deployer/src/utils/configLoader.ts index 35f67c524..aef2ecf18 100644 --- a/packages/deployer/src/utils/configLoader.ts +++ b/packages/deployer/src/utils/configLoader.ts @@ -11,7 +11,7 @@ export const getEnvConfig = (env: string) => { if (envLoad.error) { console.warn('No config found, using default') - return { ETH_MNEMONIC: ethers.Wallet.createRandom().mnemonic.phrase } + return { ETH_MNEMONIC: ethers.Wallet.createRandom().mnemonic!.phrase } } return envLoad.parsed || {} diff --git a/packages/estimator/CHANGELOG.md b/packages/estimator/CHANGELOG.md deleted file mode 100644 index ef7b839b7..000000000 --- a/packages/estimator/CHANGELOG.md +++ /dev/null @@ -1,2613 +0,0 @@ -# @0xsequence/estimator - -## 1.10.14 - -### Patch Changes - -- network: add borne-testnet to allNetworks -- Updated dependencies - - @0xsequence/abi@1.10.14 - - @0xsequence/core@1.10.14 - - @0xsequence/utils@1.10.14 - -## 1.10.13 - -### Patch Changes - -- network: add borne testnet -- Updated dependencies - - @0xsequence/abi@1.10.13 - - @0xsequence/core@1.10.13 - - @0xsequence/utils@1.10.13 - -## 1.10.12 - -### Patch Changes - -- api: update bindings -- global/window -> globalThis -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.10.12 - - @0xsequence/core@1.10.12 - - @0xsequence/utils@1.10.12 - -## 1.10.11 - -### Patch Changes - -- waas: updated intent.gen without webrpc types, errors exported from authenticator.gen -- Updated dependencies - - @0xsequence/abi@1.10.11 - - @0xsequence/core@1.10.11 - - @0xsequence/utils@1.10.11 - -## 1.10.10 - -### Patch Changes - -- metadata: update bindings with new contract collections api -- Updated dependencies - - @0xsequence/abi@1.10.10 - - @0xsequence/core@1.10.10 - - @0xsequence/utils@1.10.10 - -## 1.10.9 - -### Patch Changes - -- waas minor update -- Updated dependencies - - @0xsequence/abi@1.10.9 - - @0xsequence/core@1.10.9 - - @0xsequence/utils@1.10.9 - -## 1.10.8 - -### Patch Changes - -- update metadata bindings -- Updated dependencies - - @0xsequence/abi@1.10.8 - - @0xsequence/core@1.10.8 - - @0xsequence/utils@1.10.8 - -## 1.10.7 - -### Patch Changes - -- minor fixes to waas client -- Updated dependencies - - @0xsequence/abi@1.10.7 - - @0xsequence/core@1.10.7 - - @0xsequence/utils@1.10.7 - -## 1.10.6 - -### Patch Changes - -- metadata: update bindings -- Updated dependencies - - @0xsequence/abi@1.10.6 - - @0xsequence/core@1.10.6 - - @0xsequence/utils@1.10.6 - -## 1.10.5 - -### Patch Changes - -- network: ape-chain-testnet -> apechain-testnet -- Updated dependencies - - @0xsequence/abi@1.10.5 - - @0xsequence/core@1.10.5 - - @0xsequence/utils@1.10.5 - -## 1.10.4 - -### Patch Changes - -- network: add b3-sepolia, ape-chain-testnet, blast, blast-sepolia -- Updated dependencies - - @0xsequence/abi@1.10.4 - - @0xsequence/core@1.10.4 - - @0xsequence/utils@1.10.4 - -## 1.10.3 - -### Patch Changes - -- typing fix -- Updated dependencies - - @0xsequence/abi@1.10.3 - - @0xsequence/core@1.10.3 - - @0xsequence/utils@1.10.3 - -## 1.10.2 - -### Patch Changes - -- - waas: add getIdToken method - - indexer: update api client -- Updated dependencies - - @0xsequence/abi@1.10.2 - - @0xsequence/core@1.10.2 - - @0xsequence/utils@1.10.2 - -## 1.10.1 - -### Patch Changes - -- metadata: update bindings -- Updated dependencies - - @0xsequence/abi@1.10.1 - - @0xsequence/core@1.10.1 - - @0xsequence/utils@1.10.1 - -## 1.10.0 - -### Minor Changes - -- waas release v1.3.0 - -### Patch Changes - -- Updated dependencies - - @0xsequence/abi@1.10.0 - - @0xsequence/core@1.10.0 - - @0xsequence/utils@1.10.0 - -## 1.9.37 - -### Patch Changes - -- network: adds nativeToken data to NetworkMetadata constants -- Updated dependencies - - @0xsequence/abi@1.9.37 - - @0xsequence/core@1.9.37 - - @0xsequence/utils@1.9.37 - -## 1.9.36 - -### Patch Changes - -- guard: export client -- Updated dependencies - - @0xsequence/abi@1.9.36 - - @0xsequence/core@1.9.36 - - @0xsequence/utils@1.9.36 - -## 1.9.35 - -### Patch Changes - -- guard: update bindings -- Updated dependencies - - @0xsequence/abi@1.9.35 - - @0xsequence/core@1.9.35 - - @0xsequence/utils@1.9.35 - -## 1.9.34 - -### Patch Changes - -- waas: always use lowercase email -- Updated dependencies - - @0xsequence/abi@1.9.34 - - @0xsequence/core@1.9.34 - - @0xsequence/utils@1.9.34 - -## 1.9.33 - -### Patch Changes - -- waas: umd build -- Updated dependencies - - @0xsequence/abi@1.9.33 - - @0xsequence/core@1.9.33 - - @0xsequence/utils@1.9.33 - -## 1.9.32 - -### Patch Changes - -- indexer: update bindings -- Updated dependencies - - @0xsequence/abi@1.9.32 - - @0xsequence/core@1.9.32 - - @0xsequence/utils@1.9.32 - -## 1.9.31 - -### Patch Changes - -- metadata: token directory changes -- Updated dependencies - - @0xsequence/abi@1.9.31 - - @0xsequence/core@1.9.31 - - @0xsequence/utils@1.9.31 - -## 1.9.30 - -### Patch Changes - -- update -- Updated dependencies - - @0xsequence/abi@1.9.30 - - @0xsequence/core@1.9.30 - - @0xsequence/utils@1.9.30 - -## 1.9.29 - -### Patch Changes - -- disable gnosis chain -- Updated dependencies - - @0xsequence/abi@1.9.29 - - @0xsequence/core@1.9.29 - - @0xsequence/utils@1.9.29 - -## 1.9.28 - -### Patch Changes - -- add utils/merkletree -- Updated dependencies - - @0xsequence/abi@1.9.28 - - @0xsequence/core@1.9.28 - - @0xsequence/utils@1.9.28 - -## 1.9.27 - -### Patch Changes - -- network: optimistic -> optimism -- waas: remove defaults -- api, sessions: update bindings -- Updated dependencies -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.9.27 - - @0xsequence/core@1.9.27 - - @0xsequence/utils@1.9.27 - -## 1.9.26 - -### Patch Changes - -- - add backend interfaces for pluggable interfaces - - introduce @0xsequence/react-native - - update pnpm to lockfile v9 -- Updated dependencies - - @0xsequence/abi@1.9.26 - - @0xsequence/core@1.9.26 - - @0xsequence/utils@1.9.26 - -## 1.9.25 - -### Patch Changes - -- update webrpc clients with new error types -- Updated dependencies - - @0xsequence/abi@1.9.25 - - @0xsequence/core@1.9.25 - - @0xsequence/utils@1.9.25 - -## 1.9.24 - -### Patch Changes - -- waas: add memoryStore backend to localStore -- Updated dependencies - - @0xsequence/abi@1.9.24 - - @0xsequence/core@1.9.24 - - @0xsequence/utils@1.9.24 - -## 1.9.23 - -### Patch Changes - -- update api client bindings -- Updated dependencies - - @0xsequence/abi@1.9.23 - - @0xsequence/core@1.9.23 - - @0xsequence/utils@1.9.23 - -## 1.9.22 - -### Patch Changes - -- update metadata client bindings -- Updated dependencies - - @0xsequence/abi@1.9.22 - - @0xsequence/core@1.9.22 - - @0xsequence/utils@1.9.22 - -## 1.9.21 - -### Patch Changes - -- api client bindings -- Updated dependencies - - @0xsequence/abi@1.9.21 - - @0xsequence/core@1.9.21 - - @0xsequence/utils@1.9.21 - -## 1.9.20 - -### Patch Changes - -- api client bindings update -- Updated dependencies - - @0xsequence/abi@1.9.20 - - @0xsequence/core@1.9.20 - - @0xsequence/utils@1.9.20 - -## 1.9.19 - -### Patch Changes - -- waas update -- Updated dependencies - - @0xsequence/abi@1.9.19 - - @0xsequence/core@1.9.19 - - @0xsequence/utils@1.9.19 - -## 1.9.18 - -### Patch Changes - -- provider: prohibit dangerous functions -- Updated dependencies - - @0xsequence/abi@1.9.18 - - @0xsequence/core@1.9.18 - - @0xsequence/utils@1.9.18 - -## 1.9.17 - -### Patch Changes - -- network: add xr-sepolia -- Updated dependencies - - @0xsequence/abi@1.9.17 - - @0xsequence/core@1.9.17 - - @0xsequence/utils@1.9.17 - -## 1.9.16 - -### Patch Changes - -- waas: sequence.feeOptions -- Updated dependencies - - @0xsequence/abi@1.9.16 - - @0xsequence/core@1.9.16 - - @0xsequence/utils@1.9.16 - -## 1.9.15 - -### Patch Changes - -- metadata: collection external_link field name fix -- Updated dependencies - - @0xsequence/abi@1.9.15 - - @0xsequence/core@1.9.15 - - @0xsequence/utils@1.9.15 - -## 1.9.14 - -### Patch Changes - -- network: astar-zkatana -> astar-zkyoto -- network: deprecate polygon mumbai network -- network: add xai and polygon amoy -- Updated dependencies -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.9.14 - - @0xsequence/core@1.9.14 - - @0xsequence/utils@1.9.14 - -## 1.9.13 - -### Patch Changes - -- waas: fix @0xsequence/network dependency -- Updated dependencies - - @0xsequence/abi@1.9.13 - - @0xsequence/core@1.9.13 - - @0xsequence/utils@1.9.13 - -## 1.9.12 - -### Patch Changes - -- indexer: update rpc bindings -- provider: signMessage: Serialize the BytesLike or string message into hexstring before sending -- waas: SessionAuthProof -- Updated dependencies -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.9.12 - - @0xsequence/core@1.9.12 - - @0xsequence/utils@1.9.12 - -## 1.9.11 - -### Patch Changes - -- metdata, update rpc bindings -- Updated dependencies - - @0xsequence/abi@1.9.11 - - @0xsequence/core@1.9.11 - - @0xsequence/utils@1.9.11 - -## 1.9.10 - -### Patch Changes - -- update metadata rpc bindings -- Updated dependencies - - @0xsequence/abi@1.9.10 - - @0xsequence/core@1.9.10 - - @0xsequence/utils@1.9.10 - -## 1.9.9 - -### Patch Changes - -- metadata, add SequenceCollections rpc client -- Updated dependencies - - @0xsequence/abi@1.9.9 - - @0xsequence/core@1.9.9 - - @0xsequence/utils@1.9.9 - -## 1.9.8 - -### Patch Changes - -- waas client update -- Updated dependencies - - @0xsequence/abi@1.9.8 - - @0xsequence/core@1.9.8 - - @0xsequence/utils@1.9.8 - -## 1.9.7 - -### Patch Changes - -- update rpc client bindings for api, metadata and relayer -- Updated dependencies - - @0xsequence/abi@1.9.7 - - @0xsequence/core@1.9.7 - - @0xsequence/utils@1.9.7 - -## 1.9.6 - -### Patch Changes - -- waas package update -- Updated dependencies - - @0xsequence/abi@1.9.6 - - @0xsequence/core@1.9.6 - - @0xsequence/utils@1.9.6 - -## 1.9.5 - -### Patch Changes - -- RpcRelayer prioritize project access key -- Updated dependencies - - @0xsequence/abi@1.9.5 - - @0xsequence/core@1.9.5 - - @0xsequence/utils@1.9.5 - -## 1.9.4 - -### Patch Changes - -- waas: fix network dependency -- Updated dependencies - - @0xsequence/abi@1.9.4 - - @0xsequence/core@1.9.4 - - @0xsequence/utils@1.9.4 - -## 1.9.3 - -### Patch Changes - -- provider: don't append access key to RPC url if user has already provided it -- Updated dependencies - - @0xsequence/abi@1.9.3 - - @0xsequence/core@1.9.3 - - @0xsequence/utils@1.9.3 - -## 1.9.2 - -### Patch Changes - -- network: add xai-sepolia -- Updated dependencies - - @0xsequence/abi@1.9.2 - - @0xsequence/core@1.9.2 - - @0xsequence/utils@1.9.2 - -## 1.9.1 - -### Patch Changes - -- analytics fix -- Updated dependencies - - @0xsequence/abi@1.9.1 - - @0xsequence/core@1.9.1 - - @0xsequence/utils@1.9.1 - -## 1.9.0 - -### Minor Changes - -- waas release - -### Patch Changes - -- Updated dependencies - - @0xsequence/abi@1.9.0 - - @0xsequence/core@1.9.0 - - @0xsequence/utils@1.9.0 - -## 1.8.8 - -### Patch Changes - -- update metadata bindings -- Updated dependencies - - @0xsequence/abi@1.8.8 - - @0xsequence/core@1.8.8 - - @0xsequence/utils@1.8.8 - -## 1.8.7 - -### Patch Changes - -- provider: update databeat to 0.9.1 -- Updated dependencies - - @0xsequence/abi@1.8.7 - - @0xsequence/core@1.8.7 - - @0xsequence/utils@1.8.7 - -## 1.8.6 - -### Patch Changes - -- guard: SignedOwnershipProof -- Updated dependencies - - @0xsequence/abi@1.8.6 - - @0xsequence/core@1.8.6 - - @0xsequence/utils@1.8.6 - -## 1.8.5 - -### Patch Changes - -- guard: signOwnershipProof and isSignedOwnershipProof -- Updated dependencies - - @0xsequence/abi@1.8.5 - - @0xsequence/core@1.8.5 - - @0xsequence/utils@1.8.5 - -## 1.8.4 - -### Patch Changes - -- network: add homeverse to networks list -- Updated dependencies - - @0xsequence/abi@1.8.4 - - @0xsequence/core@1.8.4 - - @0xsequence/utils@1.8.4 - -## 1.8.3 - -### Patch Changes - -- api: introduce basic linked wallet support -- Updated dependencies - - @0xsequence/abi@1.8.3 - - @0xsequence/core@1.8.3 - - @0xsequence/utils@1.8.3 - -## 1.8.2 - -### Patch Changes - -- provider: don't initialize analytics unless explicitly requested -- Updated dependencies - - @0xsequence/abi@1.8.2 - - @0xsequence/core@1.8.2 - - @0xsequence/utils@1.8.2 - -## 1.8.1 - -### Patch Changes - -- update to analytics provider -- Updated dependencies - - @0xsequence/abi@1.8.1 - - @0xsequence/core@1.8.1 - - @0xsequence/utils@1.8.1 - -## 1.8.0 - -### Minor Changes - -- provider: project analytics - -### Patch Changes - -- Updated dependencies - - @0xsequence/abi@1.8.0 - - @0xsequence/core@1.8.0 - - @0xsequence/utils@1.8.0 - -## 1.7.2 - -### Patch Changes - -- 0xsequence: ChainId should not be exported as a type -- account, wallet: fix nonce selection -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.7.2 - - @0xsequence/core@1.7.2 - - @0xsequence/utils@1.7.2 - -## 1.7.1 - -### Patch Changes - -- network: add missing avalanche logoURI -- Updated dependencies - - @0xsequence/abi@1.7.1 - - @0xsequence/core@1.7.1 - - @0xsequence/utils@1.7.1 - -## 1.7.0 - -### Minor Changes - -- provider: projectAccessKey is now required - -### Patch Changes - -- network: add NetworkMetadata.logoURI property for all networks -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.7.0 - - @0xsequence/core@1.7.0 - - @0xsequence/utils@1.7.0 - -## 1.6.3 - -### Patch Changes - -- network list update -- Updated dependencies - - @0xsequence/abi@1.6.3 - - @0xsequence/core@1.6.3 - - @0xsequence/utils@1.6.3 - -## 1.6.2 - -### Patch Changes - -- auth: projectAccessKey option -- wallet: use 12 bytes for random space -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.6.2 - - @0xsequence/core@1.6.2 - - @0xsequence/utils@1.6.2 - -## 1.6.1 - -### Patch Changes - -- core: add simple config from subdigest support -- core: fix encode tree with subdigest -- account: implement buildOnChainSignature on Account -- Updated dependencies -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.6.1 - - @0xsequence/core@1.6.1 - - @0xsequence/utils@1.6.1 - -## 1.6.0 - -### Minor Changes - -- account, wallet: parallel transactions by default - -### Patch Changes - -- provider: emit disconnect on sign out -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.6.0 - - @0xsequence/core@1.6.0 - - @0xsequence/utils@1.6.0 - -## 1.5.0 - -### Minor Changes - -- signhub: add 'signing' signer status - -### Patch Changes - -- auth: Session.open: onAccountAddress callback -- account: allow empty transaction bundles -- Updated dependencies -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.5.0 - - @0xsequence/core@1.5.0 - - @0xsequence/utils@1.5.0 - -## 1.4.9 - -### Patch Changes - -- rename SequenceMetadataClient to SequenceMetadata -- Updated dependencies - - @0xsequence/abi@1.4.9 - - @0xsequence/core@1.4.9 - - @0xsequence/utils@1.4.9 - -## 1.4.8 - -### Patch Changes - -- account: Account.getSigners -- Updated dependencies - - @0xsequence/abi@1.4.8 - - @0xsequence/core@1.4.8 - - @0xsequence/utils@1.4.8 - -## 1.4.7 - -### Patch Changes - -- update indexer client bindings -- Updated dependencies - - @0xsequence/abi@1.4.7 - - @0xsequence/core@1.4.7 - - @0xsequence/utils@1.4.7 - -## 1.4.6 - -### Patch Changes - -- - add sepolia networks, mark goerli as deprecated - - update indexer client bindings -- Updated dependencies - - @0xsequence/abi@1.4.6 - - @0xsequence/core@1.4.6 - - @0xsequence/utils@1.4.6 - -## 1.4.5 - -### Patch Changes - -- indexer/metadata: update client bindings -- auth: selectWallet with new address -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.4.5 - - @0xsequence/core@1.4.5 - - @0xsequence/utils@1.4.5 - -## 1.4.4 - -### Patch Changes - -- indexer: update bindings -- auth: handle jwt expiry -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.4.4 - - @0xsequence/core@1.4.4 - - @0xsequence/utils@1.4.4 - -## 1.4.3 - -### Patch Changes - -- guard: return active status from GuardSigner.getAuthMethods -- Updated dependencies - - @0xsequence/abi@1.4.3 - - @0xsequence/core@1.4.3 - - @0xsequence/utils@1.4.3 - -## 1.4.2 - -### Patch Changes - -- guard: update bindings -- Updated dependencies - - @0xsequence/abi@1.4.2 - - @0xsequence/core@1.4.2 - - @0xsequence/utils@1.4.2 - -## 1.4.1 - -### Patch Changes - -- network: remove unused networks -- signhub: orchestrator interface -- guard: auth methods interface -- guard: update bindings for pin and totp -- guard: no more retry logic -- Updated dependencies -- Updated dependencies -- Updated dependencies -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.4.1 - - @0xsequence/core@1.4.1 - - @0xsequence/utils@1.4.1 - -## 1.4.0 - -### Minor Changes - -- project access key support - -### Patch Changes - -- Updated dependencies - - @0xsequence/abi@1.4.0 - - @0xsequence/core@1.4.0 - - @0xsequence/utils@1.4.0 - -## 1.3.0 - -### Minor Changes - -- signhub: account children - -### Patch Changes - -- guard: do not throw when building deploy transaction -- network: snowtrace.io -> subnets.avax.network/c-chain -- Updated dependencies -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.3.0 - - @0xsequence/core@1.3.0 - - @0xsequence/utils@1.3.0 - -## 1.2.9 - -### Patch Changes - -- account: AccountSigner.sendTransaction simulateForFeeOptions -- relayer: update bindings -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.2.9 - - @0xsequence/core@1.2.9 - - @0xsequence/utils@1.2.9 - -## 1.2.8 - -### Patch Changes - -- rename X-Sequence-Token-Key header to X-Access-Key -- Updated dependencies - - @0xsequence/abi@1.2.8 - - @0xsequence/core@1.2.8 - - @0xsequence/utils@1.2.8 - -## 1.2.7 - -### Patch Changes - -- add x-sequence-token-key to clients -- Updated dependencies - - @0xsequence/abi@1.2.7 - - @0xsequence/core@1.2.7 - - @0xsequence/utils@1.2.7 - -## 1.2.6 - -### Patch Changes - -- Fix bind multicall provider -- Updated dependencies - - @0xsequence/abi@1.2.6 - - @0xsequence/core@1.2.6 - - @0xsequence/utils@1.2.6 - -## 1.2.5 - -### Patch Changes - -- Multicall default configuration fixes -- Updated dependencies - - @0xsequence/abi@1.2.5 - - @0xsequence/core@1.2.5 - - @0xsequence/utils@1.2.5 - -## 1.2.4 - -### Patch Changes - -- provider: Adding missing payment provider types to PaymentProviderOption -- provider: WalletRequestHandler.notifyChainChanged -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.2.4 - - @0xsequence/core@1.2.4 - - @0xsequence/utils@1.2.4 - -## 1.2.3 - -### Patch Changes - -- auth, provider: connect to accept optional authorizeNonce -- Updated dependencies - - @0xsequence/abi@1.2.3 - - @0xsequence/core@1.2.3 - - @0xsequence/utils@1.2.3 - -## 1.2.2 - -### Patch Changes - -- provider: allow createContract calls -- core: check for explicit zero address in contract deployments -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.2.2 - - @0xsequence/core@1.2.2 - - @0xsequence/utils@1.2.2 - -## 1.2.1 - -### Patch Changes - -- auth: use sequence api chain id as reference chain id if available -- Updated dependencies - - @0xsequence/abi@1.2.1 - - @0xsequence/core@1.2.1 - - @0xsequence/utils@1.2.1 - -## 1.2.0 - -### Minor Changes - -- split services from session, better local support - -### Patch Changes - -- Updated dependencies - - @0xsequence/abi@1.2.0 - - @0xsequence/core@1.2.0 - - @0xsequence/utils@1.2.0 - -## 1.1.15 - -### Patch Changes - -- guard: remove error filtering -- Updated dependencies - - @0xsequence/abi@1.1.15 - - @0xsequence/core@1.1.15 - - @0xsequence/utils@1.1.15 - -## 1.1.14 - -### Patch Changes - -- guard: add GuardSigner.onError -- Updated dependencies - - @0xsequence/abi@1.1.14 - - @0xsequence/core@1.1.14 - - @0xsequence/utils@1.1.14 - -## 1.1.13 - -### Patch Changes - -- provider: pass client version with connect options -- provider: removing large from BannerSize -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.1.13 - - @0xsequence/core@1.1.13 - - @0xsequence/utils@1.1.13 - -## 1.1.12 - -### Patch Changes - -- provider: adding bannerSize to ConnectOptions -- Updated dependencies - - @0xsequence/abi@1.1.12 - - @0xsequence/core@1.1.12 - - @0xsequence/utils@1.1.12 - -## 1.1.11 - -### Patch Changes - -- add homeverse configs -- Updated dependencies - - @0xsequence/abi@1.1.11 - - @0xsequence/core@1.1.11 - - @0xsequence/utils@1.1.11 - -## 1.1.10 - -### Patch Changes - -- handle default EIP6492 on send -- Updated dependencies - - @0xsequence/abi@1.1.10 - - @0xsequence/core@1.1.10 - - @0xsequence/utils@1.1.10 - -## 1.1.9 - -### Patch Changes - -- Custom default EIP6492 on client -- Updated dependencies - - @0xsequence/abi@1.1.9 - - @0xsequence/core@1.1.9 - - @0xsequence/utils@1.1.9 - -## 1.1.8 - -### Patch Changes - -- metadata: searchMetadata: add types filter -- Updated dependencies - - @0xsequence/abi@1.1.8 - - @0xsequence/core@1.1.8 - - @0xsequence/utils@1.1.8 - -## 1.1.7 - -### Patch Changes - -- adding signInWith connect settings option to allow dapps to automatically login their users with a certain provider optimizing the normal authentication flow -- Updated dependencies - - @0xsequence/abi@1.1.7 - - @0xsequence/core@1.1.7 - - @0xsequence/utils@1.1.7 - -## 1.1.6 - -### Patch Changes - -- metadata: searchMetadata: add chainID and excludeTokenMetadata filters -- Updated dependencies - - @0xsequence/abi@1.1.6 - - @0xsequence/core@1.1.6 - - @0xsequence/utils@1.1.6 - -## 1.1.5 - -### Patch Changes - -- account: re-compute meta-transaction id for wallet deployment transactions -- Updated dependencies - - @0xsequence/abi@1.1.5 - - @0xsequence/core@1.1.5 - - @0xsequence/utils@1.1.5 - -## 1.1.4 - -### Patch Changes - -- network: rename base-mainnet to base -- provider: override isDefaultChain with ConnectOptions.networkId if provided -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.1.4 - - @0xsequence/core@1.1.4 - - @0xsequence/utils@1.1.4 - -## 1.1.3 - -### Patch Changes - -- provider: use network id from transport session -- provider: sign authorization using ConnectOptions.networkId if provided -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.1.3 - - @0xsequence/core@1.1.3 - - @0xsequence/utils@1.1.3 - -## 1.1.2 - -### Patch Changes - -- provider: jsonrpc chain id fixes -- Updated dependencies - - @0xsequence/abi@1.1.2 - - @0xsequence/core@1.1.2 - - @0xsequence/utils@1.1.2 - -## 1.1.1 - -### Patch Changes - -- network: add base mainnet and sepolia -- provider: reject toxic transaction requests -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.1.1 - - @0xsequence/core@1.1.1 - - @0xsequence/utils@1.1.1 - -## 1.1.0 - -### Minor Changes - -- Refactor dapp facing provider - -### Patch Changes - -- Updated dependencies - - @0xsequence/abi@1.1.0 - - @0xsequence/core@1.1.0 - - @0xsequence/utils@1.1.0 - -## 1.0.5 - -### Patch Changes - -- network: export network constants -- guard: use the correct global for fetch -- network: nova-explorer.arbitrum.io -> nova.arbiscan.io -- Updated dependencies -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.0.5 - - @0xsequence/core@1.0.5 - - @0xsequence/utils@1.0.5 - -## 1.0.4 - -### Patch Changes - -- provider: accept name or number for networkId -- Updated dependencies - - @0xsequence/abi@1.0.4 - - @0xsequence/core@1.0.4 - - @0xsequence/utils@1.0.4 - -## 1.0.3 - -### Patch Changes - -- Simpler isValidSignature helpers -- Updated dependencies - - @0xsequence/abi@1.0.3 - - @0xsequence/core@1.0.3 - - @0xsequence/utils@1.0.3 - -## 1.0.2 - -### Patch Changes - -- add extra signature validation utils methods -- Updated dependencies - - @0xsequence/abi@1.0.2 - - @0xsequence/core@1.0.2 - - @0xsequence/utils@1.0.2 - -## 1.0.1 - -### Patch Changes - -- add homeverse testnet -- Updated dependencies - - @0xsequence/abi@1.0.1 - - @0xsequence/core@1.0.1 - - @0xsequence/utils@1.0.1 - -## 1.0.0 - -### Major Changes - -- https://sequence.xyz/blog/sequence-wallet-light-state-sync-full-merkle-wallets - -### Patch Changes - -- Updated dependencies - - @0xsequence/abi@1.0.0 - - @0xsequence/core@1.0.0 - - @0xsequence/utils@1.0.0 - -## 0.43.34 - -### Patch Changes - -- auth: no jwt for indexer -- Updated dependencies - - @0xsequence/abi@0.43.34 - - @0xsequence/config@0.43.34 - - @0xsequence/network@0.43.34 - - @0xsequence/transactions@0.43.34 - - @0xsequence/utils@0.43.34 - -## 0.43.33 - -### Patch Changes - -- Adding onConnectOptionsChange handler to WalletRequestHandler -- Updated dependencies - - @0xsequence/abi@0.43.33 - - @0xsequence/config@0.43.33 - - @0xsequence/network@0.43.33 - - @0xsequence/transactions@0.43.33 - - @0xsequence/utils@0.43.33 - -## 0.43.32 - -### Patch Changes - -- add Base Goerli network -- Updated dependencies - - @0xsequence/abi@0.43.32 - - @0xsequence/config@0.43.32 - - @0xsequence/network@0.43.32 - - @0xsequence/transactions@0.43.32 - - @0xsequence/utils@0.43.32 - -## 0.43.31 - -### Patch Changes - -- remove AuxDataProvider, add promptSignInConnect -- Updated dependencies - - @0xsequence/abi@0.43.31 - - @0xsequence/config@0.43.31 - - @0xsequence/network@0.43.31 - - @0xsequence/transactions@0.43.31 - - @0xsequence/utils@0.43.31 - -## 0.43.30 - -### Patch Changes - -- add arbitrum goerli testnet -- Updated dependencies - - @0xsequence/abi@0.43.30 - - @0xsequence/config@0.43.30 - - @0xsequence/network@0.43.30 - - @0xsequence/transactions@0.43.30 - - @0xsequence/utils@0.43.30 - -## 0.43.29 - -### Patch Changes - -- provider: check availability of window object -- Updated dependencies - - @0xsequence/abi@0.43.29 - - @0xsequence/config@0.43.29 - - @0xsequence/network@0.43.29 - - @0xsequence/transactions@0.43.29 - - @0xsequence/utils@0.43.29 - -## 0.43.28 - -### Patch Changes - -- update api bindings -- Updated dependencies - - @0xsequence/abi@0.43.28 - - @0xsequence/config@0.43.28 - - @0xsequence/network@0.43.28 - - @0xsequence/transactions@0.43.28 - - @0xsequence/utils@0.43.28 - -## 0.43.27 - -### Patch Changes - -- Add rpc is sequence method -- Updated dependencies - - @0xsequence/abi@0.43.27 - - @0xsequence/config@0.43.27 - - @0xsequence/network@0.43.27 - - @0xsequence/transactions@0.43.27 - - @0xsequence/utils@0.43.27 - -## 0.43.26 - -### Patch Changes - -- add zkevm url to enum -- Updated dependencies - - @0xsequence/abi@0.43.26 - - @0xsequence/config@0.43.26 - - @0xsequence/network@0.43.26 - - @0xsequence/transactions@0.43.26 - - @0xsequence/utils@0.43.26 - -## 0.43.25 - -### Patch Changes - -- added polygon zkevm to mainnet networks -- Updated dependencies - - @0xsequence/abi@0.43.25 - - @0xsequence/config@0.43.25 - - @0xsequence/network@0.43.25 - - @0xsequence/transactions@0.43.25 - - @0xsequence/utils@0.43.25 - -## 0.43.24 - -### Patch Changes - -- name change from zkevm to polygon-zkevm -- Updated dependencies - - @0xsequence/abi@0.43.24 - - @0xsequence/config@0.43.24 - - @0xsequence/network@0.43.24 - - @0xsequence/transactions@0.43.24 - - @0xsequence/utils@0.43.24 - -## 0.43.23 - -### Patch Changes - -- update zkEVM name to Polygon zkEVM -- Updated dependencies - - @0xsequence/abi@0.43.23 - - @0xsequence/config@0.43.23 - - @0xsequence/network@0.43.23 - - @0xsequence/transactions@0.43.23 - - @0xsequence/utils@0.43.23 - -## 0.43.22 - -### Patch Changes - -- add zkevm chain -- Updated dependencies - - @0xsequence/abi@0.43.22 - - @0xsequence/config@0.43.22 - - @0xsequence/network@0.43.22 - - @0xsequence/transactions@0.43.22 - - @0xsequence/utils@0.43.22 - -## 0.43.21 - -### Patch Changes - -- api: update client bindings -- Updated dependencies - - @0xsequence/abi@0.43.21 - - @0xsequence/config@0.43.21 - - @0xsequence/network@0.43.21 - - @0xsequence/transactions@0.43.21 - - @0xsequence/utils@0.43.21 - -## 0.43.20 - -### Patch Changes - -- indexer: update bindings -- Updated dependencies - - @0xsequence/abi@0.43.20 - - @0xsequence/config@0.43.20 - - @0xsequence/network@0.43.20 - - @0xsequence/transactions@0.43.20 - - @0xsequence/utils@0.43.20 - -## 0.43.19 - -### Patch Changes - -- session proof update -- Updated dependencies - - @0xsequence/abi@0.43.19 - - @0xsequence/config@0.43.19 - - @0xsequence/network@0.43.19 - - @0xsequence/transactions@0.43.19 - - @0xsequence/utils@0.43.19 - -## 0.43.18 - -### Patch Changes - -- rpc client global check, hardening -- Updated dependencies - - @0xsequence/abi@0.43.18 - - @0xsequence/config@0.43.18 - - @0xsequence/network@0.43.18 - - @0xsequence/transactions@0.43.18 - - @0xsequence/utils@0.43.18 - -## 0.43.17 - -### Patch Changes - -- rpc clients, check of 'global' is defined -- Updated dependencies - - @0xsequence/abi@0.43.17 - - @0xsequence/config@0.43.17 - - @0xsequence/network@0.43.17 - - @0xsequence/transactions@0.43.17 - - @0xsequence/utils@0.43.17 - -## 0.43.16 - -### Patch Changes - -- ethers peerDep to v5, update rpc client global use -- Updated dependencies - - @0xsequence/abi@0.43.16 - - @0xsequence/config@0.43.16 - - @0xsequence/network@0.43.16 - - @0xsequence/transactions@0.43.16 - - @0xsequence/utils@0.43.16 - -## 0.43.15 - -### Patch Changes - -- - provider: expand receiver type on some util methods -- Updated dependencies - - @0xsequence/abi@0.43.15 - - @0xsequence/config@0.43.15 - - @0xsequence/network@0.43.15 - - @0xsequence/transactions@0.43.15 - - @0xsequence/utils@0.43.15 - -## 0.43.14 - -### Patch Changes - -- bump -- Updated dependencies - - @0xsequence/abi@0.43.14 - - @0xsequence/config@0.43.14 - - @0xsequence/network@0.43.14 - - @0xsequence/transactions@0.43.14 - - @0xsequence/utils@0.43.14 - -## 0.43.13 - -### Patch Changes - -- update rpc bindings -- Updated dependencies - - @0xsequence/abi@0.43.13 - - @0xsequence/config@0.43.13 - - @0xsequence/network@0.43.13 - - @0xsequence/transactions@0.43.13 - - @0xsequence/utils@0.43.13 - -## 0.43.12 - -### Patch Changes - -- provider: single wallet init, and add new unregisterWallet() method -- Updated dependencies - - @0xsequence/abi@0.43.12 - - @0xsequence/config@0.43.12 - - @0xsequence/network@0.43.12 - - @0xsequence/transactions@0.43.12 - - @0xsequence/utils@0.43.12 - -## 0.43.11 - -### Patch Changes - -- fix lockfiles -- re-add mocha type deleter -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@0.43.11 - - @0xsequence/config@0.43.11 - - @0xsequence/network@0.43.11 - - @0xsequence/transactions@0.43.11 - - @0xsequence/utils@0.43.11 - -## 0.43.10 - -### Patch Changes - -- various improvements -- Updated dependencies - - @0xsequence/abi@0.43.10 - - @0xsequence/config@0.43.10 - - @0xsequence/network@0.43.10 - - @0xsequence/transactions@0.43.10 - - @0xsequence/utils@0.43.10 - -## 0.43.9 - -### Patch Changes - -- update deps -- Updated dependencies - - @0xsequence/abi@0.43.9 - - @0xsequence/config@0.43.9 - - @0xsequence/network@0.43.9 - - @0xsequence/transactions@0.43.9 - - @0xsequence/utils@0.43.9 - -## 0.43.8 - -### Patch Changes - -- network: JsonRpcProvider with caching -- Updated dependencies - - @0xsequence/abi@0.43.8 - - @0xsequence/config@0.43.8 - - @0xsequence/network@0.43.8 - - @0xsequence/transactions@0.43.8 - - @0xsequence/utils@0.43.8 - -## 0.43.7 - -### Patch Changes - -- provider: fix wallet network init -- Updated dependencies - - @0xsequence/abi@0.43.7 - - @0xsequence/config@0.43.7 - - @0xsequence/network@0.43.7 - - @0xsequence/transactions@0.43.7 - - @0xsequence/utils@0.43.7 - -## 0.43.6 - -### Patch Changes - -- metadatata: update rpc bindings -- Updated dependencies - - @0xsequence/abi@0.43.6 - - @0xsequence/config@0.43.6 - - @0xsequence/network@0.43.6 - - @0xsequence/transactions@0.43.6 - - @0xsequence/utils@0.43.6 - -## 0.43.5 - -### Patch Changes - -- provider: do not set default network for connect messages -- provider: forward missing error message -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@0.43.5 - - @0xsequence/config@0.43.5 - - @0xsequence/network@0.43.5 - - @0xsequence/transactions@0.43.5 - - @0xsequence/utils@0.43.5 - -## 0.43.4 - -### Patch Changes - -- no-change version bump to fix incorrectly tagged snapshot build -- Updated dependencies - - @0xsequence/abi@0.43.4 - - @0xsequence/config@0.43.4 - - @0xsequence/network@0.43.4 - - @0xsequence/transactions@0.43.4 - - @0xsequence/utils@0.43.4 - -## 0.43.3 - -### Patch Changes - -- metadata: update bindings -- Updated dependencies - - @0xsequence/abi@0.43.3 - - @0xsequence/config@0.43.3 - - @0xsequence/network@0.43.3 - - @0xsequence/transactions@0.43.3 - - @0xsequence/utils@0.43.3 - -## 0.43.2 - -### Patch Changes - -- provider: implement connectUnchecked -- Updated dependencies - - @0xsequence/abi@0.43.2 - - @0xsequence/config@0.43.2 - - @0xsequence/network@0.43.2 - - @0xsequence/transactions@0.43.2 - - @0xsequence/utils@0.43.2 - -## 0.43.1 - -### Patch Changes - -- update to latest ethauth dep -- Updated dependencies - - @0xsequence/abi@0.43.1 - - @0xsequence/config@0.43.1 - - @0xsequence/network@0.43.1 - - @0xsequence/transactions@0.43.1 - - @0xsequence/utils@0.43.1 - -## 0.43.0 - -### Minor Changes - -- move ethers to a peer dependency - -### Patch Changes - -- Updated dependencies - - @0xsequence/abi@0.43.0 - - @0xsequence/config@0.43.0 - - @0xsequence/network@0.43.0 - - @0xsequence/transactions@0.43.0 - - @0xsequence/utils@0.43.0 - -## 0.42.10 - -### Patch Changes - -- add auxDataProvider -- Updated dependencies - - @0xsequence/abi@0.42.10 - - @0xsequence/config@0.42.10 - - @0xsequence/network@0.42.10 - - @0xsequence/transactions@0.42.10 - - @0xsequence/utils@0.42.10 - -## 0.42.9 - -### Patch Changes - -- provider: add eip-191 exceptions -- Updated dependencies - - @0xsequence/abi@0.42.9 - - @0xsequence/config@0.42.9 - - @0xsequence/network@0.42.9 - - @0xsequence/transactions@0.42.9 - - @0xsequence/utils@0.42.9 - -## 0.42.8 - -### Patch Changes - -- provider: skip setting intent origin if we're unity plugin -- Updated dependencies - - @0xsequence/abi@0.42.8 - - @0xsequence/config@0.42.8 - - @0xsequence/network@0.42.8 - - @0xsequence/transactions@0.42.8 - - @0xsequence/utils@0.42.8 - -## 0.42.7 - -### Patch Changes - -- Add sign in options to connection settings -- Updated dependencies - - @0xsequence/abi@0.42.7 - - @0xsequence/config@0.42.7 - - @0xsequence/network@0.42.7 - - @0xsequence/transactions@0.42.7 - - @0xsequence/utils@0.42.7 - -## 0.42.6 - -### Patch Changes - -- api bindings update -- Updated dependencies - - @0xsequence/abi@0.42.6 - - @0xsequence/config@0.42.6 - - @0xsequence/network@0.42.6 - - @0xsequence/transactions@0.42.6 - - @0xsequence/utils@0.42.6 - -## 0.42.5 - -### Patch Changes - -- relayer: don't treat missing receipt as hard failure -- Updated dependencies - - @0xsequence/abi@0.42.5 - - @0xsequence/config@0.42.5 - - @0xsequence/network@0.42.5 - - @0xsequence/transactions@0.42.5 - - @0xsequence/utils@0.42.5 - -## 0.42.4 - -### Patch Changes - -- provider: add custom app protocol to connect options -- Updated dependencies - - @0xsequence/abi@0.42.4 - - @0xsequence/config@0.42.4 - - @0xsequence/network@0.42.4 - - @0xsequence/transactions@0.42.4 - - @0xsequence/utils@0.42.4 - -## 0.42.3 - -### Patch Changes - -- update api bindings -- Updated dependencies - - @0xsequence/abi@0.42.3 - - @0xsequence/config@0.42.3 - - @0xsequence/network@0.42.3 - - @0xsequence/transactions@0.42.3 - - @0xsequence/utils@0.42.3 - -## 0.42.2 - -### Patch Changes - -- disable rinkeby network -- Updated dependencies - - @0xsequence/abi@0.42.2 - - @0xsequence/config@0.42.2 - - @0xsequence/network@0.42.2 - - @0xsequence/transactions@0.42.2 - - @0xsequence/utils@0.42.2 - -## 0.42.1 - -### Patch Changes - -- wallet: optional waitForReceipt parameter -- Updated dependencies - - @0xsequence/abi@0.42.1 - - @0xsequence/config@0.42.1 - - @0xsequence/network@0.42.1 - - @0xsequence/transactions@0.42.1 - - @0xsequence/utils@0.42.1 - -## 0.42.0 - -### Minor Changes - -- relayer: estimateGasLimits -> simulate -- add simulator package - -### Patch Changes - -- transactions: fix flattenAuxTransactions -- provider: only filter nullish values -- provider: re-map transaction 'gas' back to 'gasLimit' -- Updated dependencies -- Updated dependencies -- Updated dependencies -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@0.42.0 - - @0xsequence/config@0.42.0 - - @0xsequence/network@0.42.0 - - @0xsequence/transactions@0.42.0 - - @0xsequence/utils@0.42.0 - -## 0.41.3 - -### Patch Changes - -- api bindings update -- Updated dependencies - - @0xsequence/abi@0.41.3 - - @0xsequence/config@0.41.3 - - @0xsequence/network@0.41.3 - - @0xsequence/transactions@0.41.3 - - @0xsequence/utils@0.41.3 - -## 0.41.2 - -### Patch Changes - -- api bindings update -- Updated dependencies - - @0xsequence/abi@0.41.2 - - @0xsequence/config@0.41.2 - - @0xsequence/network@0.41.2 - - @0xsequence/transactions@0.41.2 - - @0xsequence/utils@0.41.2 - -## 0.41.1 - -### Patch Changes - -- update default networks -- Updated dependencies - - @0xsequence/abi@0.41.1 - - @0xsequence/config@0.41.1 - - @0xsequence/network@0.41.1 - - @0xsequence/transactions@0.41.1 - - @0xsequence/utils@0.41.1 - -## 0.41.0 - -### Minor Changes - -- relayer: fix Relayer.wait() interface - - The interface for calling Relayer.wait() has changed. Instead of a single optional ill-defined timeout/delay parameter, there are three optional parameters, in order: - - - timeout: the maximum time to wait for the transaction receipt - - delay: the polling interval, i.e. the time to wait between requests - - maxFails: the maximum number of hard failures to tolerate before giving up - - Please update your codebase accordingly. - -- relayer: add optional waitForReceipt parameter to Relayer.relay - - The behaviour of Relayer.relay() was not well-defined with respect to whether or not it waited for a receipt. - This change allows the caller to specify whether to wait or not, with the default behaviour being to wait. - -### Patch Changes - -- relayer: wait receipt retry logic -- fix wrapped object error -- provider: forward delegateCall and revertOnError transaction fields -- Updated dependencies -- Updated dependencies -- Updated dependencies -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@0.41.0 - - @0xsequence/config@0.41.0 - - @0xsequence/network@0.41.0 - - @0xsequence/transactions@0.41.0 - - @0xsequence/utils@0.41.0 - -## 0.40.6 - -### Patch Changes - -- add arbitrum-nova chain -- Updated dependencies - - @0xsequence/abi@0.40.6 - - @0xsequence/config@0.40.6 - - @0xsequence/network@0.40.6 - - @0xsequence/transactions@0.40.6 - - @0xsequence/utils@0.40.6 - -## 0.40.5 - -### Patch Changes - -- api: update bindings -- Updated dependencies - - @0xsequence/abi@0.40.5 - - @0xsequence/config@0.40.5 - - @0xsequence/network@0.40.5 - - @0xsequence/transactions@0.40.5 - - @0xsequence/utils@0.40.5 - -## 0.40.4 - -### Patch Changes - -- add unreal transport -- Updated dependencies - - @0xsequence/abi@0.40.4 - - @0xsequence/config@0.40.4 - - @0xsequence/network@0.40.4 - - @0xsequence/transactions@0.40.4 - - @0xsequence/utils@0.40.4 - -## 0.40.3 - -### Patch Changes - -- provider: fix MessageToSign message type -- Updated dependencies - - @0xsequence/abi@0.40.3 - - @0xsequence/config@0.40.3 - - @0xsequence/network@0.40.3 - - @0xsequence/transactions@0.40.3 - - @0xsequence/utils@0.40.3 - -## 0.40.2 - -### Patch Changes - -- Wallet provider, loadSession method -- Updated dependencies - - @0xsequence/abi@0.40.2 - - @0xsequence/config@0.40.2 - - @0xsequence/network@0.40.2 - - @0xsequence/transactions@0.40.2 - - @0xsequence/utils@0.40.2 - -## 0.40.1 - -### Patch Changes - -- export sequence.initWallet and sequence.getWallet -- Updated dependencies - - @0xsequence/abi@0.40.1 - - @0xsequence/config@0.40.1 - - @0xsequence/network@0.40.1 - - @0xsequence/transactions@0.40.1 - - @0xsequence/utils@0.40.1 - -## 0.40.0 - -### Minor Changes - -- add sequence.initWallet(network, config) and sequence.getWallet() helper methods - -### Patch Changes - -- Updated dependencies - - @0xsequence/abi@0.40.0 - - @0xsequence/config@0.40.0 - - @0xsequence/network@0.40.0 - - @0xsequence/transactions@0.40.0 - - @0xsequence/utils@0.40.0 - -## 0.39.6 - -### Patch Changes - -- indexer: update client bindings -- Updated dependencies - - @0xsequence/abi@0.39.6 - - @0xsequence/config@0.39.6 - - @0xsequence/network@0.39.6 - - @0xsequence/transactions@0.39.6 - - @0xsequence/utils@0.39.6 - -## 0.39.5 - -### Patch Changes - -- provider: fix networkRpcUrl config option -- Updated dependencies - - @0xsequence/abi@0.39.5 - - @0xsequence/config@0.39.5 - - @0xsequence/network@0.39.5 - - @0xsequence/transactions@0.39.5 - - @0xsequence/utils@0.39.5 - -## 0.39.4 - -### Patch Changes - -- api: update client bindings -- Updated dependencies - - @0xsequence/abi@0.39.4 - - @0xsequence/config@0.39.4 - - @0xsequence/network@0.39.4 - - @0xsequence/transactions@0.39.4 - - @0xsequence/utils@0.39.4 - -## 0.39.3 - -### Patch Changes - -- add request method on Web3Provider -- Updated dependencies - - @0xsequence/abi@0.39.3 - - @0xsequence/config@0.39.3 - - @0xsequence/network@0.39.3 - - @0xsequence/transactions@0.39.3 - - @0xsequence/utils@0.39.3 - -## 0.39.2 - -### Patch Changes - -- update umd name -- Updated dependencies - - @0xsequence/abi@0.39.2 - - @0xsequence/config@0.39.2 - - @0xsequence/network@0.39.2 - - @0xsequence/transactions@0.39.2 - - @0xsequence/utils@0.39.2 - -## 0.39.1 - -### Patch Changes - -- add Aurora network -- add origin info for accountsChanged event to handle it per dapp -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@0.39.1 - - @0xsequence/config@0.39.1 - - @0xsequence/network@0.39.1 - - @0xsequence/transactions@0.39.1 - - @0xsequence/utils@0.39.1 - -## 0.39.0 - -### Minor Changes - -- abstract window.localStorage to interface type - -### Patch Changes - -- Updated dependencies - - @0xsequence/abi@0.39.0 - - @0xsequence/config@0.39.0 - - @0xsequence/network@0.39.0 - - @0xsequence/transactions@0.39.0 - - @0xsequence/utils@0.39.0 - -## 0.38.2 - -### Patch Changes - -- provider: add Settings.defaultPurchaseAmount -- Updated dependencies - - @0xsequence/abi@0.38.2 - - @0xsequence/config@0.38.2 - - @0xsequence/network@0.38.2 - - @0xsequence/transactions@0.38.2 - - @0xsequence/utils@0.38.2 - -## 0.38.1 - -### Patch Changes - -- update api and metadata rpc bindings -- Updated dependencies - - @0xsequence/abi@0.38.1 - - @0xsequence/config@0.38.1 - - @0xsequence/network@0.38.1 - - @0xsequence/transactions@0.38.1 - - @0xsequence/utils@0.38.1 - -## 0.38.0 - -### Minor Changes - -- api: update bindings, change TokenPrice interface -- bridge: remove @0xsequence/bridge package -- api: update bindings, rename ContractCallArg to TupleComponent - -### Patch Changes - -- Updated dependencies -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@0.38.0 - - @0xsequence/config@0.38.0 - - @0xsequence/network@0.38.0 - - @0xsequence/transactions@0.38.0 - - @0xsequence/utils@0.38.0 - -## 0.37.1 - -### Patch Changes - -- Add back sortNetworks - Removing sorting was a breaking change for dapps on older versions which directly integrate sequence. -- Updated dependencies - - @0xsequence/abi@0.37.1 - - @0xsequence/config@0.37.1 - - @0xsequence/network@0.37.1 - - @0xsequence/transactions@0.37.1 - - @0xsequence/utils@0.37.1 - -## 0.37.0 - -### Minor Changes - -- network related fixes and improvements -- api: bindings: exchange rate lookups - -### Patch Changes - -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@0.37.0 - - @0xsequence/config@0.37.0 - - @0xsequence/network@0.37.0 - - @0xsequence/transactions@0.37.0 - - @0xsequence/utils@0.37.0 - -## 0.36.13 - -### Patch Changes - -- api: update bindings with new price endpoints -- Updated dependencies - - @0xsequence/abi@0.36.13 - - @0xsequence/config@0.36.13 - - @0xsequence/network@0.36.13 - - @0xsequence/transactions@0.36.13 - - @0xsequence/utils@0.36.13 - -## 0.36.12 - -### Patch Changes - -- wallet: skip remote signers if not needed -- auth: check that signature meets threshold before requesting auth token -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@0.36.12 - - @0xsequence/config@0.36.12 - - @0xsequence/network@0.36.12 - - @0xsequence/transactions@0.36.12 - - @0xsequence/utils@0.36.12 - -## 0.36.11 - -### Patch Changes - -- Prefix EIP191 message on wallet-request-handler -- Updated dependencies - - @0xsequence/abi@0.36.11 - - @0xsequence/config@0.36.11 - - @0xsequence/network@0.36.11 - - @0xsequence/transactions@0.36.11 - - @0xsequence/utils@0.36.11 - -## 0.36.10 - -### Patch Changes - -- support bannerUrl on connect -- Updated dependencies - - @0xsequence/abi@0.36.10 - - @0xsequence/config@0.36.10 - - @0xsequence/network@0.36.10 - - @0xsequence/transactions@0.36.10 - - @0xsequence/utils@0.36.10 - -## 0.36.9 - -### Patch Changes - -- minor dev xp improvements -- Updated dependencies - - @0xsequence/abi@0.36.9 - - @0xsequence/config@0.36.9 - - @0xsequence/network@0.36.9 - - @0xsequence/transactions@0.36.9 - - @0xsequence/utils@0.36.9 - -## 0.36.8 - -### Patch Changes - -- more connect options (theme, payment providers, funding currencies) -- Updated dependencies - - @0xsequence/abi@0.36.8 - - @0xsequence/config@0.36.8 - - @0xsequence/network@0.36.8 - - @0xsequence/transactions@0.36.8 - - @0xsequence/utils@0.36.8 - -## 0.36.7 - -### Patch Changes - -- fix missing break -- Updated dependencies - - @0xsequence/abi@0.36.7 - - @0xsequence/config@0.36.7 - - @0xsequence/network@0.36.7 - - @0xsequence/transactions@0.36.7 - - @0xsequence/utils@0.36.7 - -## 0.36.6 - -### Patch Changes - -- wallet_switchEthereumChain support -- Updated dependencies - - @0xsequence/abi@0.36.6 - - @0xsequence/config@0.36.6 - - @0xsequence/network@0.36.6 - - @0xsequence/transactions@0.36.6 - - @0xsequence/utils@0.36.6 - -## 0.36.5 - -### Patch Changes - -- auth: bump ethauth to 0.7.0 - network, wallet: don't assume position of auth network in list - api/indexer/metadata: trim trailing slash on hostname, and add endpoint urls - relayer: Allow to specify local relayer transaction parameters like gas price or gas limit -- Updated dependencies - - @0xsequence/abi@0.36.5 - - @0xsequence/config@0.36.5 - - @0xsequence/network@0.36.5 - - @0xsequence/transactions@0.36.5 - - @0xsequence/utils@0.36.5 - -## 0.36.4 - -### Patch Changes - -- Updating list of chain ids to include other ethereum compatible chains -- Updated dependencies - - @0xsequence/abi@0.36.4 - - @0xsequence/config@0.36.4 - - @0xsequence/network@0.36.4 - - @0xsequence/transactions@0.36.4 - - @0xsequence/utils@0.36.4 - -## 0.36.3 - -### Patch Changes - -- provider: pass connect options to prompter methods -- Updated dependencies - - @0xsequence/abi@0.36.3 - - @0xsequence/config@0.36.3 - - @0xsequence/network@0.36.3 - - @0xsequence/transactions@0.36.3 - - @0xsequence/utils@0.36.3 - -## 0.36.2 - -### Patch Changes - -- transactions: Setting target to 0x0 when empty to during SequenceTxAbiEncode -- Updated dependencies - - @0xsequence/abi@0.36.2 - - @0xsequence/config@0.36.2 - - @0xsequence/network@0.36.2 - - @0xsequence/transactions@0.36.2 - - @0xsequence/utils@0.36.2 - -## 0.36.1 - -### Patch Changes - -- metadata: update client with more fields -- Updated dependencies - - @0xsequence/abi@0.36.1 - - @0xsequence/config@0.36.1 - - @0xsequence/network@0.36.1 - - @0xsequence/transactions@0.36.1 - - @0xsequence/utils@0.36.1 - -## 0.36.0 - -### Minor Changes - -- relayer, wallet: fee quote support - -### Patch Changes - -- Updated dependencies - - @0xsequence/abi@0.36.0 - - @0xsequence/config@0.36.0 - - @0xsequence/network@0.36.0 - - @0xsequence/transactions@0.36.0 - - @0xsequence/utils@0.36.0 - -## 0.35.12 - -### Patch Changes - -- provider: rename wallet.commands to wallet.utils -- Updated dependencies - - @0xsequence/abi@0.35.12 - - @0xsequence/config@0.35.12 - - @0xsequence/network@0.35.12 - - @0xsequence/transactions@0.35.12 - - @0xsequence/utils@0.35.12 - -## 0.35.11 - -### Patch Changes - -- provider/utils: smoother message validation -- Updated dependencies - - @0xsequence/abi@0.35.11 - - @0xsequence/config@0.35.11 - - @0xsequence/network@0.35.11 - - @0xsequence/transactions@0.35.11 - - @0xsequence/utils@0.35.11 - -## 0.35.10 - -### Patch Changes - -- upgrade deps -- Updated dependencies - - @0xsequence/abi@0.35.10 - - @0xsequence/config@0.35.10 - - @0xsequence/network@0.35.10 - - @0xsequence/transactions@0.35.10 - - @0xsequence/utils@0.35.10 - -## 0.35.9 - -### Patch Changes - -- provider: window-transport override event handlers with new wallet instance -- Updated dependencies - - @0xsequence/abi@0.35.9 - - @0xsequence/config@0.35.9 - - @0xsequence/network@0.35.9 - - @0xsequence/transactions@0.35.9 - - @0xsequence/utils@0.35.9 - -## 0.35.8 - -### Patch Changes - -- provider: async wallet sign in improvements -- Updated dependencies - - @0xsequence/abi@0.35.8 - - @0xsequence/config@0.35.8 - - @0xsequence/network@0.35.8 - - @0xsequence/transactions@0.35.8 - - @0xsequence/utils@0.35.8 - -## 0.35.7 - -### Patch Changes - -- config: cache wallet configs -- Updated dependencies - - @0xsequence/abi@0.35.7 - - @0xsequence/config@0.35.7 - - @0xsequence/network@0.35.7 - - @0xsequence/transactions@0.35.7 - - @0xsequence/utils@0.35.7 - -## 0.35.6 - -### Patch Changes - -- provider: support async signin of wallet request handler -- Updated dependencies - - @0xsequence/abi@0.35.6 - - @0xsequence/config@0.35.6 - - @0xsequence/network@0.35.6 - - @0xsequence/transactions@0.35.6 - - @0xsequence/utils@0.35.6 - -## 0.35.5 - -### Patch Changes - -- wallet: skip threshold check during fee estimation -- Updated dependencies - - @0xsequence/abi@0.35.5 - - @0xsequence/config@0.35.5 - - @0xsequence/network@0.35.5 - - @0xsequence/transactions@0.35.5 - - @0xsequence/utils@0.35.5 - -## 0.35.4 - -### Patch Changes - -- - browser extension mode, center window -- Updated dependencies - - @0xsequence/abi@0.35.4 - - @0xsequence/config@0.35.4 - - @0xsequence/network@0.35.4 - - @0xsequence/transactions@0.35.4 - - @0xsequence/utils@0.35.4 - -## 0.35.3 - -### Patch Changes - -- - update window position when in browser extension mode -- Updated dependencies - - @0xsequence/abi@0.35.3 - - @0xsequence/config@0.35.3 - - @0xsequence/network@0.35.3 - - @0xsequence/transactions@0.35.3 - - @0xsequence/utils@0.35.3 - -## 0.35.2 - -### Patch Changes - -- - provider: WindowMessageHandler accept optional windowHref -- Updated dependencies - - @0xsequence/abi@0.35.2 - - @0xsequence/config@0.35.2 - - @0xsequence/network@0.35.2 - - @0xsequence/transactions@0.35.2 - - @0xsequence/utils@0.35.2 - -## 0.35.1 - -### Patch Changes - -- wallet: update config on undeployed too -- Updated dependencies - - @0xsequence/abi@0.35.1 - - @0xsequence/config@0.35.1 - - @0xsequence/network@0.35.1 - - @0xsequence/transactions@0.35.1 - - @0xsequence/utils@0.35.1 - -## 0.35.0 - -### Minor Changes - -- - config: add buildStubSignature - - provider: add checks to signing cases for wallet deployment and config statuses - - provider: add prompt for wallet deployment - - relayer: add BaseRelayer.prependWalletDeploy - - relayer: add Relayer.feeOptions - - relayer: account for wallet deployment in fee estimation - - transactions: add fromTransactionish - - wallet: add Account.prependConfigUpdate - - wallet: add Account.getFeeOptions - -### Patch Changes - -- Updated dependencies - - @0xsequence/abi@0.35.0 - - @0xsequence/config@0.35.0 - - @0xsequence/network@0.35.0 - - @0xsequence/transactions@0.35.0 - - @0xsequence/utils@0.35.0 - -## 0.34.0 - -### Minor Changes - -- - upgrade deps - -### Patch Changes - -- Updated dependencies - - @0xsequence/abi@0.34.0 - - @0xsequence/config@0.34.0 - - @0xsequence/network@0.34.0 - - @0xsequence/transactions@0.34.0 - - @0xsequence/utils@0.34.0 - -## 0.33.2 - -### Patch Changes - -- Updated dependencies - - @0xsequence/transactions@0.33.2 - -## 0.31.0 - -### Minor Changes - -- - upgrading to ethers v5.5 - -### Patch Changes - -- Updated dependencies - - @0xsequence/abi@0.31.0 - - @0xsequence/config@0.31.0 - - @0xsequence/network@0.31.0 - - @0xsequence/transactions@0.31.0 - - @0xsequence/utils@0.31.0 - -## 0.30.0 - -### Minor Changes - -- - upgrade most deps - -### Patch Changes - -- Updated dependencies - - @0xsequence/abi@0.30.0 - - @0xsequence/config@0.30.0 - - @0xsequence/network@0.30.0 - - @0xsequence/transactions@0.30.0 - - @0xsequence/utils@0.30.0 - -## 0.29.8 - -### Patch Changes - -- update api -- Updated dependencies [undefined] - - @0xsequence/abi@0.29.8 - - @0xsequence/config@0.29.8 - - @0xsequence/network@0.29.8 - - @0xsequence/transactions@0.29.8 - - @0xsequence/utils@0.29.8 - -## 0.29.6 - -### Patch Changes - -- Updated dependencies [undefined] - - @0xsequence/network@0.29.6 - - @0xsequence/config@0.29.6 - - @0xsequence/transactions@0.29.6 - -## 0.29.5 - -### Patch Changes - -- Updated dependencies [undefined] - - @0xsequence/config@0.29.5 - -## 0.29.0 - -### Patch Changes - -- Updated dependencies [undefined] - - @0xsequence/config@0.29.0 - - @0xsequence/network@0.29.0 - - @0xsequence/transactions@0.29.0 - - @0xsequence/abi@0.29.0 - - @0xsequence/utils@0.29.0 - -## 0.28.0 - -### Minor Changes - -- extension provider - -### Patch Changes - -- Updated dependencies [undefined] - - @0xsequence/abi@0.28.0 - - @0xsequence/config@0.28.0 - - @0xsequence/network@0.28.0 - - @0xsequence/transactions@0.28.0 - - @0xsequence/utils@0.28.0 - -## 0.27.0 - -### Minor Changes - -- Add requireFreshSigner lib to sessions - -### Patch Changes - -- Updated dependencies [undefined] - - @0xsequence/abi@0.27.0 - - @0xsequence/config@0.27.0 - - @0xsequence/network@0.27.0 - - @0xsequence/transactions@0.27.0 - - @0xsequence/utils@0.27.0 - -## 0.25.1 - -### Patch Changes - -- Fix build typescrypt issue -- Updated dependencies [undefined] - - @0xsequence/abi@0.25.1 - - @0xsequence/config@0.25.1 - - @0xsequence/network@0.25.1 - - @0xsequence/transactions@0.25.1 - - @0xsequence/utils@0.25.1 - -## 0.25.0 - -### Minor Changes - -- 10c8af8: Add estimator package - Fix multicall few calls bug - -### Patch Changes - -- Updated dependencies [10c8af8] - - @0xsequence/abi@0.25.0 - - @0xsequence/config@0.25.0 - - @0xsequence/network@0.25.0 - - @0xsequence/transactions@0.25.0 - - @0xsequence/utils@0.25.0 diff --git a/packages/estimator/package.json b/packages/estimator/package.json deleted file mode 100644 index eda4672cf..000000000 --- a/packages/estimator/package.json +++ /dev/null @@ -1,39 +0,0 @@ -{ - "name": "@0xsequence/estimator", - "version": "1.10.14", - "description": "estimator sub-package for Sequence", - "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/estimator", - "source": "src/index.ts", - "main": "dist/0xsequence-estimator.cjs.js", - "module": "dist/0xsequence-estimator.esm.js", - "author": "Horizon Blockchain Games", - "license": "Apache-2.0", - "scripts": { - "test": "pnpm test:concurrently 'pnpm test:run'", - "test:run": "wait-on -t 120000 http-get://127.0.0.1:10045/ && pnpm test:file tests/**/*.spec.ts", - "test:file": "NODE_OPTIONS='--import tsx' mocha --timeout 30000", - "test:concurrently": "concurrently -k --success first 'pnpm start:geth > /dev/null'", - "start:geth": "docker run --rm -t -p 10045:10045 ethereum/client-go:v1.10.16 --http --http.addr 0.0.0.0 --http.port 10045 --datadir test_chain --dev --rpc.allow-unprotected-txs", - "typecheck": "tsc --noEmit" - }, - "dependencies": { - "@0xsequence/abi": "workspace:*", - "@0xsequence/core": "workspace:*", - "@0xsequence/utils": "workspace:*", - "@0xsequence/wallet-contracts": "^1.10.0" - }, - "peerDependencies": { - "ethers": ">=5.5 < 6" - }, - "devDependencies": { - "@0xsequence/signhub": "workspace:*", - "@0xsequence/tests": "workspace:*", - "@ethersproject/abstract-signer": "^5.7.0", - "@ethersproject/properties": "^5.7.0", - "ethers": "^5.7.2" - }, - "files": [ - "src", - "dist" - ] -} diff --git a/packages/estimator/src/builds/MainModuleGasEstimation.ts b/packages/estimator/src/builds/MainModuleGasEstimation.ts deleted file mode 100644 index 63e4b2fc4..000000000 --- a/packages/estimator/src/builds/MainModuleGasEstimation.ts +++ /dev/null @@ -1,854 +0,0 @@ -export const mainModuleGasEstimation = { - _format: 'hh-sol-artifact-1', - contractName: 'MainModuleGasEstimation', - sourceName: 'contracts/modules/MainModuleGasEstimation.sol', - abi: [ - { - inputs: [ - { - internalType: 'uint256', - name: '_space', - type: 'uint256' - }, - { - internalType: 'uint256', - name: '_provided', - type: 'uint256' - }, - { - internalType: 'uint256', - name: '_current', - type: 'uint256' - } - ], - name: 'BadNonce', - type: 'error' - }, - { - inputs: [ - { - internalType: 'bytes4', - name: '_signature', - type: 'bytes4' - } - ], - name: 'HookAlreadyExists', - type: 'error' - }, - { - inputs: [ - { - internalType: 'bytes4', - name: '_signature', - type: 'bytes4' - } - ], - name: 'HookDoesNotExist', - type: 'error' - }, - { - inputs: [], - name: 'ImageHashIsZero', - type: 'error' - }, - { - inputs: [ - { - internalType: 'address', - name: '_implementation', - type: 'address' - } - ], - name: 'InvalidImplementation', - type: 'error' - }, - { - inputs: [ - { - internalType: 'bytes32', - name: '_hash', - type: 'bytes32' - }, - { - internalType: 'address', - name: '_addr', - type: 'address' - }, - { - internalType: 'bytes', - name: '_signature', - type: 'bytes' - } - ], - name: 'InvalidNestedSignature', - type: 'error' - }, - { - inputs: [ - { - internalType: 'bytes', - name: '_signature', - type: 'bytes' - }, - { - internalType: 'bytes32', - name: '_s', - type: 'bytes32' - } - ], - name: 'InvalidSValue', - type: 'error' - }, - { - inputs: [ - { - internalType: 'bytes32', - name: '_hash', - type: 'bytes32' - }, - { - internalType: 'bytes', - name: '_signature', - type: 'bytes' - } - ], - name: 'InvalidSignature', - type: 'error' - }, - { - inputs: [ - { - internalType: 'uint256', - name: '_flag', - type: 'uint256' - } - ], - name: 'InvalidSignatureFlag', - type: 'error' - }, - { - inputs: [ - { - internalType: 'bytes', - name: '_signature', - type: 'bytes' - } - ], - name: 'InvalidSignatureLength', - type: 'error' - }, - { - inputs: [ - { - internalType: 'bytes1', - name: '_type', - type: 'bytes1' - } - ], - name: 'InvalidSignatureType', - type: 'error' - }, - { - inputs: [ - { - internalType: 'bytes', - name: '_signature', - type: 'bytes' - }, - { - internalType: 'uint256', - name: '_v', - type: 'uint256' - } - ], - name: 'InvalidVValue', - type: 'error' - }, - { - inputs: [ - { - internalType: 'bytes', - name: '_signature', - type: 'bytes' - }, - { - internalType: 'uint256', - name: 'threshold', - type: 'uint256' - }, - { - internalType: 'uint256', - name: '_weight', - type: 'uint256' - } - ], - name: 'LowWeightChainedSignature', - type: 'error' - }, - { - inputs: [ - { - internalType: 'uint256', - name: '_index', - type: 'uint256' - }, - { - internalType: 'uint256', - name: '_requested', - type: 'uint256' - }, - { - internalType: 'uint256', - name: '_available', - type: 'uint256' - } - ], - name: 'NotEnoughGas', - type: 'error' - }, - { - inputs: [ - { - internalType: 'address', - name: '_sender', - type: 'address' - }, - { - internalType: 'address', - name: '_self', - type: 'address' - } - ], - name: 'OnlySelfAuth', - type: 'error' - }, - { - inputs: [ - { - internalType: 'bytes', - name: '_signature', - type: 'bytes' - } - ], - name: 'SignerIsAddress0', - type: 'error' - }, - { - inputs: [ - { - internalType: 'bytes', - name: '_signature', - type: 'bytes' - }, - { - internalType: 'uint256', - name: '_type', - type: 'uint256' - }, - { - internalType: 'bool', - name: '_recoverMode', - type: 'bool' - } - ], - name: 'UnsupportedSignatureType', - type: 'error' - }, - { - inputs: [ - { - internalType: 'uint256', - name: '_current', - type: 'uint256' - }, - { - internalType: 'uint256', - name: '_prev', - type: 'uint256' - } - ], - name: 'WrongChainedCheckpointOrder', - type: 'error' - }, - { - anonymous: false, - inputs: [ - { - indexed: false, - internalType: 'address', - name: '_contract', - type: 'address' - } - ], - name: 'CreatedContract', - type: 'event' - }, - { - anonymous: false, - inputs: [ - { - indexed: false, - internalType: 'bytes32', - name: 'newImageHash', - type: 'bytes32' - } - ], - name: 'ImageHashUpdated', - type: 'event' - }, - { - anonymous: false, - inputs: [ - { - indexed: false, - internalType: 'address', - name: 'newImplementation', - type: 'address' - } - ], - name: 'ImplementationUpdated', - type: 'event' - }, - { - anonymous: false, - inputs: [ - { - indexed: false, - internalType: 'uint256', - name: '_space', - type: 'uint256' - }, - { - indexed: false, - internalType: 'uint256', - name: '_newNonce', - type: 'uint256' - } - ], - name: 'NonceChange', - type: 'event' - }, - { - anonymous: true, - inputs: [ - { - indexed: false, - internalType: 'bytes32', - name: '_tx', - type: 'bytes32' - } - ], - name: 'TxExecuted', - type: 'event' - }, - { - anonymous: false, - inputs: [ - { - indexed: false, - internalType: 'bytes32', - name: '_tx', - type: 'bytes32' - }, - { - indexed: false, - internalType: 'bytes', - name: '_reason', - type: 'bytes' - } - ], - name: 'TxFailed', - type: 'event' - }, - { - stateMutability: 'payable', - type: 'fallback' - }, - { - inputs: [], - name: 'SET_IMAGE_HASH_TYPE_HASH', - outputs: [ - { - internalType: 'bytes32', - name: '', - type: 'bytes32' - } - ], - stateMutability: 'view', - type: 'function' - }, - { - inputs: [ - { - internalType: 'bytes4', - name: '_signature', - type: 'bytes4' - }, - { - internalType: 'address', - name: '_implementation', - type: 'address' - } - ], - name: 'addHook', - outputs: [], - stateMutability: 'nonpayable', - type: 'function' - }, - { - inputs: [ - { - internalType: 'bytes', - name: '_code', - type: 'bytes' - } - ], - name: 'createContract', - outputs: [ - { - internalType: 'address', - name: 'addr', - type: 'address' - } - ], - stateMutability: 'payable', - type: 'function' - }, - { - inputs: [ - { - components: [ - { - internalType: 'bool', - name: 'delegateCall', - type: 'bool' - }, - { - internalType: 'bool', - name: 'revertOnError', - type: 'bool' - }, - { - internalType: 'uint256', - name: 'gasLimit', - type: 'uint256' - }, - { - internalType: 'address', - name: 'target', - type: 'address' - }, - { - internalType: 'uint256', - name: 'value', - type: 'uint256' - }, - { - internalType: 'bytes', - name: 'data', - type: 'bytes' - } - ], - internalType: 'struct IModuleCalls.Transaction[]', - name: '_txs', - type: 'tuple[]' - }, - { - internalType: 'uint256', - name: '_nonce', - type: 'uint256' - }, - { - internalType: 'bytes', - name: '_signature', - type: 'bytes' - } - ], - name: 'execute', - outputs: [], - stateMutability: 'nonpayable', - type: 'function' - }, - { - inputs: [], - name: 'imageHash', - outputs: [ - { - internalType: 'bytes32', - name: '', - type: 'bytes32' - } - ], - stateMutability: 'view', - type: 'function' - }, - { - inputs: [ - { - internalType: 'bytes32', - name: '_hash', - type: 'bytes32' - }, - { - internalType: 'bytes', - name: '_signatures', - type: 'bytes' - } - ], - name: 'isValidSignature', - outputs: [ - { - internalType: 'bytes4', - name: '', - type: 'bytes4' - } - ], - stateMutability: 'view', - type: 'function' - }, - { - inputs: [ - { - internalType: 'bytes', - name: '_data', - type: 'bytes' - }, - { - internalType: 'bytes', - name: '_signatures', - type: 'bytes' - } - ], - name: 'isValidSignature', - outputs: [ - { - internalType: 'bytes4', - name: '', - type: 'bytes4' - } - ], - stateMutability: 'view', - type: 'function' - }, - { - inputs: [], - name: 'nonce', - outputs: [ - { - internalType: 'uint256', - name: '', - type: 'uint256' - } - ], - stateMutability: 'view', - type: 'function' - }, - { - inputs: [ - { - internalType: 'address', - name: '', - type: 'address' - }, - { - internalType: 'address', - name: '', - type: 'address' - }, - { - internalType: 'uint256[]', - name: '', - type: 'uint256[]' - }, - { - internalType: 'uint256[]', - name: '', - type: 'uint256[]' - }, - { - internalType: 'bytes', - name: '', - type: 'bytes' - } - ], - name: 'onERC1155BatchReceived', - outputs: [ - { - internalType: 'bytes4', - name: '', - type: 'bytes4' - } - ], - stateMutability: 'nonpayable', - type: 'function' - }, - { - inputs: [ - { - internalType: 'address', - name: '', - type: 'address' - }, - { - internalType: 'address', - name: '', - type: 'address' - }, - { - internalType: 'uint256', - name: '', - type: 'uint256' - }, - { - internalType: 'uint256', - name: '', - type: 'uint256' - }, - { - internalType: 'bytes', - name: '', - type: 'bytes' - } - ], - name: 'onERC1155Received', - outputs: [ - { - internalType: 'bytes4', - name: '', - type: 'bytes4' - } - ], - stateMutability: 'nonpayable', - type: 'function' - }, - { - inputs: [ - { - internalType: 'address', - name: '', - type: 'address' - }, - { - internalType: 'address', - name: '', - type: 'address' - }, - { - internalType: 'uint256', - name: '', - type: 'uint256' - }, - { - internalType: 'bytes', - name: '', - type: 'bytes' - } - ], - name: 'onERC721Received', - outputs: [ - { - internalType: 'bytes4', - name: '', - type: 'bytes4' - } - ], - stateMutability: 'nonpayable', - type: 'function' - }, - { - inputs: [ - { - internalType: 'bytes4', - name: '_signature', - type: 'bytes4' - } - ], - name: 'readHook', - outputs: [ - { - internalType: 'address', - name: '', - type: 'address' - } - ], - stateMutability: 'view', - type: 'function' - }, - { - inputs: [ - { - internalType: 'uint256', - name: '_space', - type: 'uint256' - } - ], - name: 'readNonce', - outputs: [ - { - internalType: 'uint256', - name: '', - type: 'uint256' - } - ], - stateMutability: 'view', - type: 'function' - }, - { - inputs: [ - { - internalType: 'bytes4', - name: '_signature', - type: 'bytes4' - } - ], - name: 'removeHook', - outputs: [], - stateMutability: 'nonpayable', - type: 'function' - }, - { - inputs: [ - { - components: [ - { - internalType: 'bool', - name: 'delegateCall', - type: 'bool' - }, - { - internalType: 'bool', - name: 'revertOnError', - type: 'bool' - }, - { - internalType: 'uint256', - name: 'gasLimit', - type: 'uint256' - }, - { - internalType: 'address', - name: 'target', - type: 'address' - }, - { - internalType: 'uint256', - name: 'value', - type: 'uint256' - }, - { - internalType: 'bytes', - name: 'data', - type: 'bytes' - } - ], - internalType: 'struct IModuleCalls.Transaction[]', - name: '_txs', - type: 'tuple[]' - } - ], - name: 'selfExecute', - outputs: [], - stateMutability: 'nonpayable', - type: 'function' - }, - { - inputs: [ - { - internalType: 'bytes32', - name: '_digest', - type: 'bytes32' - }, - { - internalType: 'bytes', - name: '_signature', - type: 'bytes' - } - ], - name: 'signatureRecovery', - outputs: [ - { - internalType: 'uint256', - name: 'threshold', - type: 'uint256' - }, - { - internalType: 'uint256', - name: 'weight', - type: 'uint256' - }, - { - internalType: 'bytes32', - name: 'imageHash', - type: 'bytes32' - }, - { - internalType: 'bytes32', - name: 'subDigest', - type: 'bytes32' - }, - { - internalType: 'uint256', - name: 'checkpoint', - type: 'uint256' - } - ], - stateMutability: 'view', - type: 'function' - }, - { - inputs: [ - { - internalType: 'bytes4', - name: '_interfaceID', - type: 'bytes4' - } - ], - name: 'supportsInterface', - outputs: [ - { - internalType: 'bool', - name: '', - type: 'bool' - } - ], - stateMutability: 'pure', - type: 'function' - }, - { - inputs: [ - { - internalType: 'bytes32', - name: '_imageHash', - type: 'bytes32' - } - ], - name: 'updateImageHash', - outputs: [], - stateMutability: 'nonpayable', - type: 'function' - }, - { - inputs: [ - { - internalType: 'address', - name: '_implementation', - type: 'address' - } - ], - name: 'updateImplementation', - outputs: [], - stateMutability: 'nonpayable', - type: 'function' - }, - { - stateMutability: 'payable', - type: 'receive' - } - ], - bytecode: - '0x608060405234801561001057600080fd5b50612daa806100206000396000f3fe6080604052600436106101485760003560e01c806357c56d6b116100c057806390042baf11610074578063b93ea7ad11610059578063b93ea7ad146104da578063bc197c81146104fa578063f23a6e61146105425761014f565b806390042baf146104b2578063affed0e0146104c55761014f565b80637a9a1628116100a55780637a9a16281461042a578063853c50681461044a5780638c3f5563146104925761014f565b806357c56d6b146103d657806361c2926c1461040a5761014f565b80631a9b23371161011757806329561426116100fc57806329561426146103735780634fcf3eca1461039357806351605d80146103b35761014f565b80631a9b23371461030e57806320c13b0b146103535761014f565b806301ffc9a714610223578063025b22bc14610258578063150b7a02146102785780631626ba7e146102ee5761014f565b3661014f57005b600061017e6000357fffffffff0000000000000000000000000000000000000000000000000000000016610588565b905073ffffffffffffffffffffffffffffffffffffffff811615610221576000808273ffffffffffffffffffffffffffffffffffffffff166000366040516101c79291906122da565b600060405180830381855af49150503d8060008114610202576040519150601f19603f3d011682016040523d82523d6000602084013e610207565b606091505b50915091508161021957805160208201fd5b805160208201f35b005b34801561022f57600080fd5b5061024361023e366004612318565b6105dc565b60405190151581526020015b60405180910390f35b34801561026457600080fd5b5061022161027336600461235e565b6105e7565b34801561028457600080fd5b506102bd6102933660046123c2565b7f150b7a020000000000000000000000000000000000000000000000000000000095945050505050565b6040517fffffffff00000000000000000000000000000000000000000000000000000000909116815260200161024f565b3480156102fa57600080fd5b506102bd610309366004612431565b610639565b34801561031a57600080fd5b5061032e610329366004612318565b610686565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161024f565b34801561035f57600080fd5b506102bd61036e36600461247d565b610691565b34801561037f57600080fd5b5061022161038e3660046124e9565b6106f6565b34801561039f57600080fd5b506102216103ae366004612318565b610740565b3480156103bf57600080fd5b506103c861086f565b60405190815260200161024f565b3480156103e257600080fd5b506103c87f8713a7c4465f6fbee2b6e9d6646d1d9f83fec929edfc4baf661f3c865bdd04d181565b34801561041657600080fd5b50610221610425366004612547565b61089e565b34801561043657600080fd5b50610221610445366004612589565b610924565b34801561045657600080fd5b5061046a610465366004612431565b6109ba565b604080519586526020860194909452928401919091526060830152608082015260a00161024f565b34801561049e57600080fd5b506103c86104ad3660046124e9565b610b82565b61032e6104c0366004612621565b610bae565b3480156104d157600080fd5b506103c8610c4a565b3480156104e657600080fd5b506102216104f53660046126f0565b610c56565b34801561050657600080fd5b506102bd610515366004612725565b7fbc197c810000000000000000000000000000000000000000000000000000000098975050505050505050565b34801561054e57600080fd5b506102bd61055d3660046127e0565b7ff23a6e61000000000000000000000000000000000000000000000000000000009695505050505050565b60006105d67fbe27a319efc8734e89e26ba4bc95f5c788584163b959f03fa04e2d7ab4b9a1207fffffffff000000000000000000000000000000000000000000000000000000008416610d9b565b92915050565b60006105d682610df9565b33301461062d576040517fe12588940000000000000000000000000000000000000000000000000000000081523360048201523060248201526044015b60405180910390fd5b61063681610e55565b50565b600080610647858585610f10565b509050801561067957507f1626ba7e00000000000000000000000000000000000000000000000000000000905061067f565b50600090505b9392505050565b60006105d682610588565b6000806106b686866040516106a79291906122da565b60405180910390208585610f10565b50905080156106e857507f20c13b0b0000000000000000000000000000000000000000000000000000000090506106ee565b50600090505b949350505050565b333014610737576040517fe1258894000000000000000000000000000000000000000000000000000000008152336004820152306024820152604401610624565b61063681610f4e565b333014610781576040517fe1258894000000000000000000000000000000000000000000000000000000008152336004820152306024820152604401610624565b600061078c82610588565b73ffffffffffffffffffffffffffffffffffffffff16036107fd576040517f1c3812cc0000000000000000000000000000000000000000000000000000000081527fffffffff0000000000000000000000000000000000000000000000000000000082166004820152602401610624565b604080517fbe27a319efc8734e89e26ba4bc95f5c788584163b959f03fa04e2d7ab4b9a1206020808301919091527fffffffff00000000000000000000000000000000000000000000000000000000841682840152825180830384018152606090920190925280519101206000905550565b60006108997fea7157fa25e3aa17d0ae2d5280fa4e24d421c61842aa85e45194e1145aa72bf85490565b905090565b3330146108df576040517fe1258894000000000000000000000000000000000000000000000000000000008152336004820152306024820152604401610624565b600061091283836040516020016108f7929190612a00565b60405160208183030381529060405280519060200120610fde565b905061091f818484611063565b505050565b61092d836111c1565b60008061096585888860405160200161094893929190612a48565b604051602081830303815290604052805190602001208585610f10565b91509150816109a6578084846040517f8f4a234f00000000000000000000000000000000000000000000000000000000815260040161062493929190612a6b565b6109b1818888611063565b50505050505050565b600080600080600080878760008181106109d6576109d6612a85565b909101357fff00000000000000000000000000000000000000000000000000000000000000169150819050610a2c57610a0e89610fde565b9250610a1b8389896112ca565b92985090965094509150610b779050565b7fff0000000000000000000000000000000000000000000000000000000000000081811601610a6b57610a5e89610fde565b9250610a1b83898961131b565b7ffe000000000000000000000000000000000000000000000000000000000000007fff00000000000000000000000000000000000000000000000000000000000000821601610abd57610a5e89611347565b7ffd000000000000000000000000000000000000000000000000000000000000007fff00000000000000000000000000000000000000000000000000000000000000821601610b2157610b118989896113b4565b9550955095509550955050610b77565b6040517f6085cd820000000000000000000000000000000000000000000000000000000081527fff0000000000000000000000000000000000000000000000000000000000000082166004820152602401610624565b939792965093509350565b60006105d67f8d0bf1fd623d628c741362c1289948e57b3e2905218c676d3e69abee36d6ae2e83610d9b565b6000333014610bf1576040517fe1258894000000000000000000000000000000000000000000000000000000008152336004820152306024820152604401610624565b81516020830134f060405173ffffffffffffffffffffffffffffffffffffffff821681529091507fa506ad4e7f05eceba62a023c3219e5bd98a615f4fa87e2afb08a2da5cf62bf0c9060200160405180910390a1919050565b60006108996000610b82565b333014610c97576040517fe1258894000000000000000000000000000000000000000000000000000000008152336004820152306024820152604401610624565b6000610ca283610588565b73ffffffffffffffffffffffffffffffffffffffff1614610d13576040517f5b4d6d6a0000000000000000000000000000000000000000000000000000000081527fffffffff0000000000000000000000000000000000000000000000000000000083166004820152602401610624565b604080517fbe27a319efc8734e89e26ba4bc95f5c788584163b959f03fa04e2d7ab4b9a1206020808301919091527fffffffff000000000000000000000000000000000000000000000000000000008516828401528251808303840181526060909201909252805191012073ffffffffffffffffffffffffffffffffffffffff821690555050565b6000808383604051602001610dba929190918252602082015260400190565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152919052805160209091012054949350505050565b60007f6ffbd451000000000000000000000000000000000000000000000000000000007fffffffff00000000000000000000000000000000000000000000000000000000831601610e4c57506001919050565b6105d682611531565b73ffffffffffffffffffffffffffffffffffffffff81163b610ebb576040517f0c76093700000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82166004820152602401610624565b610ec3813055565b60405173ffffffffffffffffffffffffffffffffffffffff821681527f310ba5f1d2ed074b51e2eccd052a47ae9ab7c6b800d1fca3db3999d6a592ca03906020015b60405180910390a150565b6000806000806000610f238888886109ba565b50965091945092509050828210801590610f415750610f4181611672565b9450505050935093915050565b80610f85576040517f4294d12700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610fae7fea7157fa25e3aa17d0ae2d5280fa4e24d421c61842aa85e45194e1145aa72bf8829055565b6040518181527f307ed6bd941ee9fc80f369c94af5fa11e25bab5102a6140191756c5474a30bfa90602001610f05565b6040517f190100000000000000000000000000000000000000000000000000000000000060208201524660228201527fffffffffffffffffffffffffffffffffffffffff0000000000000000000000003060601b166042820152605681018290526000906076015b604051602081830303815290604052805190602001209050919050565b8060005b818110156111ba573684848381811061108257611082612a85565b90506020028101906110949190612ab4565b90506040810135805a10156110e95782815a6040517f2bb3e3ba000000000000000000000000000000000000000000000000000000008152600481019390935260248301919091526044820152606401610624565b60006110f86020840184612af2565b1561113757611130611110608085016060860161235e565b831561111c578361111e565b5a5b61112b60a0870187612b0d565b61167d565b9050611172565b61116f61114a608085016060860161235e565b6080850135841561115b578461115d565b5a5b61116a60a0880188612b0d565b611698565b90505b801561118e5760405188815260200160405180910390a06111af565b6111af6111a16040850160208601612af2565b896111aa6116b5565b6116d4565b505050600101611067565b5050505050565b606081901c6bffffffffffffffffffffffff821660006111e083610b82565b90508181141580156111f0575060005b15611238576040517f9b6514f4000000000000000000000000000000000000000000000000000000008152600481018490526024810183905260448101829052606401610624565b604080517f8d0bf1fd623d628c741362c1289948e57b3e2905218c676d3e69abee36d6ae2e60208083019190915281830186905282518083038401815260609092019092528051910120600183019081905560408051858152602081018390527f1f180c27086c7a39ea2a7b25239d1ab92348f07ca7bb59d1438fcf527568f881910160405180910390a15050505050565b60008080806112e5876112e0876006818b612b72565b611720565b6000908152873560f01c6020818152604080842084526002909a013560e01c908190529890912090999198509695509350505050565b600080808061133687611331876001818b612b72565b6112ca565b935093509350935093509350935093565b6040517f190100000000000000000000000000000000000000000000000000000000000060208201526000602282018190527fffffffffffffffffffffffffffffffffffffffff0000000000000000000000003060601b1660428301526056820183905290607601611046565b6000808080806004600188013560e81c826113cf8383612bcb565b90506113e18b61046583868d8f612b72565b939b50919950975095509350878710156114395761140181848b8d612b72565b89896040517fb006aba00000000000000000000000000000000000000000000000000000000081526004016106249493929190612bde565b8092505b888310156115235760038301928a013560e81c915061145c8383612bcb565b9050600061147e61146c88611bb6565b8c8c8790869261046593929190612b72565b939c50919a50985090915050888810156114d65761149e82858c8e612b72565b8a8a6040517fb006aba00000000000000000000000000000000000000000000000000000000081526004016106249493929190612bde565b848110611519576040517f37daf62b0000000000000000000000000000000000000000000000000000000081526004810182905260248101869052604401610624565b935091508161143d565b505050939792965093509350565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167fec6aba500000000000000000000000000000000000000000000000000000000014806115c457507fffffffff0000000000000000000000000000000000000000000000000000000082167f4e2312e000000000000000000000000000000000000000000000000000000000145b8061161057507fffffffff0000000000000000000000000000000000000000000000000000000082167f150b7a0200000000000000000000000000000000000000000000000000000000145b8061165c57507fffffffff0000000000000000000000000000000000000000000000000000000082167fc0ee0b8a00000000000000000000000000000000000000000000000000000000145b1561166957506001919050565b6105d682611bea565b60006105d682611c46565b60006040518284823760008084838989f49695505050505050565b6000604051828482376000808483898b8af1979650505050505050565b60603d604051915060208201818101604052818352816000823e505090565b82156116e257805160208201fd5b7f3dbd1590ea96dd3253a91f24e64e3a502e1225d602a5731357bc12643070ccd78282604051611713929190612c05565b60405180910390a1505050565b60008060005b83811015611bad57600181019085013560f81c7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81016117c757601582019186013560f881901c9060581c73ffffffffffffffffffffffffffffffffffffffff81169074ff0000000000000000000000000000000000000000168117856117ad57806117bc565b60008681526020829052604090205b955050505050611726565b8061185d5760018201918681013560f81c9060430160006117f38a6117ee84888c8e612b72565b611c5f565b60ff841697909701969194508491905060a083901b74ff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff821617866118425780611851565b60008781526020829052604090205b96505050505050611726565b60028103611985576000808784013560f881901c9060581c73ffffffffffffffffffffffffffffffffffffffff16601586019550909250905060008885013560e81c600386018162ffffff1691508096508192505050600081860190506118d68b848c8c8a9086926118d193929190612b72565b611f22565b61191e578a836118e883898d8f612b72565b6040517f9a9462320000000000000000000000000000000000000000000000000000000081526004016106249493929190612c79565b60ff8416979097019694508460a084901b74ff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff841617876119695780611978565b60008881526020829052604090205b9750505050505050611726565b600381036119b8576020820191860135836119a057806119af565b60008481526020829052604090205b93505050611726565b60048103611a04576003808301928781013560e81c91908201016000806119e58b6112e085898d8f612b72565b6000988952602052604090972096909701965090935061172692505050565b60068103611b0c5760008287013560f81c60018401935060ff16905060008784013560f01c60028501945061ffff16905060008885013560e81c600386018162ffffff169150809650819250505060008186019050600080611a728d8d8d8b9087926112e093929190612b72565b93985088939092509050848210611a8857988501985b604080517f53657175656e6365206e657374656420636f6e6669673a0a0000000000000000602080830191909152603882018490526058820188905260788083018a9052835180840390910181526098909201909252805191012089611aee5780611afd565b60008a81526020829052604090205b99505050505050505050611726565b60058103611b78576020820191860135878103611b47577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff94505b6000611b52826120cf565b905084611b5f5780611b6e565b60008581526020829052604090205b9450505050611726565b6040517fb2505f7c00000000000000000000000000000000000000000000000000000000815260048101829052602401610624565b50935093915050565b7f8713a7c4465f6fbee2b6e9d6646d1d9f83fec929edfc4baf661f3c865bdd04d160009081526020829052604081206105d6565b60007ffda4dd44000000000000000000000000000000000000000000000000000000007fffffffff00000000000000000000000000000000000000000000000000000000831601611c3d57506001919050565b6105d68261210a565b6000611c5182612166565b806105d65750600192915050565b600060428214611c9f5782826040517f2ee17a3d000000000000000000000000000000000000000000000000000000008152600401610624929190612cb9565b6000611cb8611caf600185612ccd565b85013560f81c90565b60ff169050604084013560f81c843560208601357f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a0811115611d2c578686826040517fad4aac7600000000000000000000000000000000000000000000000000000000815260040161062493929190612ce0565b8260ff16601b14158015611d4457508260ff16601c14155b15611d81578686846040517fe578897e00000000000000000000000000000000000000000000000000000000815260040161062493929190612d04565b60018403611dee576040805160008152602081018083528a905260ff851691810191909152606081018390526080810182905260019060a0015b6020604051602081039080840390855afa158015611ddd573d6000803e3d6000fd5b505050602060405103519450611ec6565b60028403611e8b576040517f19457468657265756d205369676e6564204d6573736167653a0a3332000000006020820152603c8101899052600190605c01604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120600084529083018083525260ff861690820152606081018490526080810183905260a001611dbb565b86868560016040517f9dfba8520000000000000000000000000000000000000000000000000000000081526004016106249493929190612d2b565b73ffffffffffffffffffffffffffffffffffffffff8516611f175786866040517f6c1719d2000000000000000000000000000000000000000000000000000000008152600401610624929190612cb9565b505050509392505050565b6000808383611f32600182612ccd565b818110611f4157611f41612a85565b919091013560f81c9150506001811480611f5b5750600281145b15611fa0578473ffffffffffffffffffffffffffffffffffffffff16611f82878686611c5f565b73ffffffffffffffffffffffffffffffffffffffff161491506120c6565b6003810361208b5773ffffffffffffffffffffffffffffffffffffffff8516631626ba7e8786600087611fd4600182612ccd565b92611fe193929190612b72565b6040518463ffffffff1660e01b8152600401611fff93929190612a6b565b602060405180830381865afa15801561201c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906120409190612d57565b7fffffffff00000000000000000000000000000000000000000000000000000000167f1626ba7e000000000000000000000000000000000000000000000000000000001491506120c6565b83838260006040517f9dfba8520000000000000000000000000000000000000000000000000000000081526004016106249493929190612d2b565b50949350505050565b6040517f53657175656e636520737461746963206469676573743a0a0000000000000000602082015260388101829052600090605801611046565b60007fe4a77bbc000000000000000000000000000000000000000000000000000000007fffffffff0000000000000000000000000000000000000000000000000000000083160161215d57506001919050565b6105d682612199565b600081158015906105d65750507fea7157fa25e3aa17d0ae2d5280fa4e24d421c61842aa85e45194e1145aa72bf8541490565b60007fae9fa280000000000000000000000000000000000000000000000000000000007fffffffff000000000000000000000000000000000000000000000000000000008316016121ec57506001919050565b6105d68260007fffffffff0000000000000000000000000000000000000000000000000000000082167fac6a444e00000000000000000000000000000000000000000000000000000000148061228357507fffffffff0000000000000000000000000000000000000000000000000000000082167f36e7817500000000000000000000000000000000000000000000000000000000145b1561229057506001919050565b7f01ffc9a7000000000000000000000000000000000000000000000000000000007fffffffff000000000000000000000000000000000000000000000000000000008316146105d6565b8183823760009101908152919050565b7fffffffff000000000000000000000000000000000000000000000000000000008116811461063657600080fd5b60006020828403121561232a57600080fd5b813561067f816122ea565b803573ffffffffffffffffffffffffffffffffffffffff8116811461235957600080fd5b919050565b60006020828403121561237057600080fd5b61067f82612335565b60008083601f84011261238b57600080fd5b50813567ffffffffffffffff8111156123a357600080fd5b6020830191508360208285010111156123bb57600080fd5b9250929050565b6000806000806000608086880312156123da57600080fd5b6123e386612335565b94506123f160208701612335565b935060408601359250606086013567ffffffffffffffff81111561241457600080fd5b61242088828901612379565b969995985093965092949392505050565b60008060006040848603121561244657600080fd5b83359250602084013567ffffffffffffffff81111561246457600080fd5b61247086828701612379565b9497909650939450505050565b6000806000806040858703121561249357600080fd5b843567ffffffffffffffff808211156124ab57600080fd5b6124b788838901612379565b909650945060208701359150808211156124d057600080fd5b506124dd87828801612379565b95989497509550505050565b6000602082840312156124fb57600080fd5b5035919050565b60008083601f84011261251457600080fd5b50813567ffffffffffffffff81111561252c57600080fd5b6020830191508360208260051b85010111156123bb57600080fd5b6000806020838503121561255a57600080fd5b823567ffffffffffffffff81111561257157600080fd5b61257d85828601612502565b90969095509350505050565b6000806000806000606086880312156125a157600080fd5b853567ffffffffffffffff808211156125b957600080fd5b6125c589838a01612502565b90975095506020880135945060408801359150808211156125e557600080fd5b5061242088828901612379565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60006020828403121561263357600080fd5b813567ffffffffffffffff8082111561264b57600080fd5b818401915084601f83011261265f57600080fd5b813581811115612671576126716125f2565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f011681019083821181831017156126b7576126b76125f2565b816040528281528760208487010111156126d057600080fd5b826020860160208301376000928101602001929092525095945050505050565b6000806040838503121561270357600080fd5b823561270e816122ea565b915061271c60208401612335565b90509250929050565b60008060008060008060008060a0898b03121561274157600080fd5b61274a89612335565b975061275860208a01612335565b9650604089013567ffffffffffffffff8082111561277557600080fd5b6127818c838d01612502565b909850965060608b013591508082111561279a57600080fd5b6127a68c838d01612502565b909650945060808b01359150808211156127bf57600080fd5b506127cc8b828c01612379565b999c989b5096995094979396929594505050565b60008060008060008060a087890312156127f957600080fd5b61280287612335565b955061281060208801612335565b94506040870135935060608701359250608087013567ffffffffffffffff81111561283a57600080fd5b61284689828a01612379565b979a9699509497509295939492505050565b8035801515811461235957600080fd5b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b81835260006020808501808196508560051b810191508460005b878110156129f357828403895281357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff4188360301811261290a57600080fd5b870160c061291782612858565b15158652612926878301612858565b15158688015260408281013590870152606073ffffffffffffffffffffffffffffffffffffffff612958828501612335565b16908701526080828101359087015260a080830135368490037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe101811261299e57600080fd5b90920187810192903567ffffffffffffffff8111156129bc57600080fd5b8036038413156129cb57600080fd5b82828901526129dd8389018286612868565b9c89019c975050509286019250506001016128cb565b5091979650505050505050565b60408152600560408201527f73656c663a00000000000000000000000000000000000000000000000000000060608201526080602082015260006106ee6080830184866128b1565b838152604060208201526000612a626040830184866128b1565b95945050505050565b838152604060208201526000612a62604083018486612868565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600082357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff41833603018112612ae857600080fd5b9190910192915050565b600060208284031215612b0457600080fd5b61067f82612858565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112612b4257600080fd5b83018035915067ffffffffffffffff821115612b5d57600080fd5b6020019150368190038213156123bb57600080fd5b60008085851115612b8257600080fd5b83861115612b8f57600080fd5b5050820193919092039150565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b808201808211156105d6576105d6612b9c565b606081526000612bf2606083018688612868565b6020830194909452506040015292915050565b82815260006020604081840152835180604085015260005b81811015612c3957858101830151858201606001528201612c1d565b5060006060828601015260607fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f830116850101925050509392505050565b84815273ffffffffffffffffffffffffffffffffffffffff84166020820152606060408201526000612caf606083018486612868565b9695505050505050565b6020815260006106ee602083018486612868565b818103818111156105d6576105d6612b9c565b604081526000612cf4604083018587612868565b9050826020830152949350505050565b604081526000612d18604083018587612868565b905060ff83166020830152949350505050565b606081526000612d3f606083018688612868565b60208301949094525090151560409091015292915050565b600060208284031215612d6957600080fd5b815161067f816122ea56fea2646970667358221220d1c64e83cb54c2e1824f98a6e0664734329329620cf112737055416b4d68ea6a64736f6c63430008110033', - deployedBytecode: - '0x6080604052600436106101485760003560e01c806357c56d6b116100c057806390042baf11610074578063b93ea7ad11610059578063b93ea7ad146104da578063bc197c81146104fa578063f23a6e61146105425761014f565b806390042baf146104b2578063affed0e0146104c55761014f565b80637a9a1628116100a55780637a9a16281461042a578063853c50681461044a5780638c3f5563146104925761014f565b806357c56d6b146103d657806361c2926c1461040a5761014f565b80631a9b23371161011757806329561426116100fc57806329561426146103735780634fcf3eca1461039357806351605d80146103b35761014f565b80631a9b23371461030e57806320c13b0b146103535761014f565b806301ffc9a714610223578063025b22bc14610258578063150b7a02146102785780631626ba7e146102ee5761014f565b3661014f57005b600061017e6000357fffffffff0000000000000000000000000000000000000000000000000000000016610588565b905073ffffffffffffffffffffffffffffffffffffffff811615610221576000808273ffffffffffffffffffffffffffffffffffffffff166000366040516101c79291906122da565b600060405180830381855af49150503d8060008114610202576040519150601f19603f3d011682016040523d82523d6000602084013e610207565b606091505b50915091508161021957805160208201fd5b805160208201f35b005b34801561022f57600080fd5b5061024361023e366004612318565b6105dc565b60405190151581526020015b60405180910390f35b34801561026457600080fd5b5061022161027336600461235e565b6105e7565b34801561028457600080fd5b506102bd6102933660046123c2565b7f150b7a020000000000000000000000000000000000000000000000000000000095945050505050565b6040517fffffffff00000000000000000000000000000000000000000000000000000000909116815260200161024f565b3480156102fa57600080fd5b506102bd610309366004612431565b610639565b34801561031a57600080fd5b5061032e610329366004612318565b610686565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161024f565b34801561035f57600080fd5b506102bd61036e36600461247d565b610691565b34801561037f57600080fd5b5061022161038e3660046124e9565b6106f6565b34801561039f57600080fd5b506102216103ae366004612318565b610740565b3480156103bf57600080fd5b506103c861086f565b60405190815260200161024f565b3480156103e257600080fd5b506103c87f8713a7c4465f6fbee2b6e9d6646d1d9f83fec929edfc4baf661f3c865bdd04d181565b34801561041657600080fd5b50610221610425366004612547565b61089e565b34801561043657600080fd5b50610221610445366004612589565b610924565b34801561045657600080fd5b5061046a610465366004612431565b6109ba565b604080519586526020860194909452928401919091526060830152608082015260a00161024f565b34801561049e57600080fd5b506103c86104ad3660046124e9565b610b82565b61032e6104c0366004612621565b610bae565b3480156104d157600080fd5b506103c8610c4a565b3480156104e657600080fd5b506102216104f53660046126f0565b610c56565b34801561050657600080fd5b506102bd610515366004612725565b7fbc197c810000000000000000000000000000000000000000000000000000000098975050505050505050565b34801561054e57600080fd5b506102bd61055d3660046127e0565b7ff23a6e61000000000000000000000000000000000000000000000000000000009695505050505050565b60006105d67fbe27a319efc8734e89e26ba4bc95f5c788584163b959f03fa04e2d7ab4b9a1207fffffffff000000000000000000000000000000000000000000000000000000008416610d9b565b92915050565b60006105d682610df9565b33301461062d576040517fe12588940000000000000000000000000000000000000000000000000000000081523360048201523060248201526044015b60405180910390fd5b61063681610e55565b50565b600080610647858585610f10565b509050801561067957507f1626ba7e00000000000000000000000000000000000000000000000000000000905061067f565b50600090505b9392505050565b60006105d682610588565b6000806106b686866040516106a79291906122da565b60405180910390208585610f10565b50905080156106e857507f20c13b0b0000000000000000000000000000000000000000000000000000000090506106ee565b50600090505b949350505050565b333014610737576040517fe1258894000000000000000000000000000000000000000000000000000000008152336004820152306024820152604401610624565b61063681610f4e565b333014610781576040517fe1258894000000000000000000000000000000000000000000000000000000008152336004820152306024820152604401610624565b600061078c82610588565b73ffffffffffffffffffffffffffffffffffffffff16036107fd576040517f1c3812cc0000000000000000000000000000000000000000000000000000000081527fffffffff0000000000000000000000000000000000000000000000000000000082166004820152602401610624565b604080517fbe27a319efc8734e89e26ba4bc95f5c788584163b959f03fa04e2d7ab4b9a1206020808301919091527fffffffff00000000000000000000000000000000000000000000000000000000841682840152825180830384018152606090920190925280519101206000905550565b60006108997fea7157fa25e3aa17d0ae2d5280fa4e24d421c61842aa85e45194e1145aa72bf85490565b905090565b3330146108df576040517fe1258894000000000000000000000000000000000000000000000000000000008152336004820152306024820152604401610624565b600061091283836040516020016108f7929190612a00565b60405160208183030381529060405280519060200120610fde565b905061091f818484611063565b505050565b61092d836111c1565b60008061096585888860405160200161094893929190612a48565b604051602081830303815290604052805190602001208585610f10565b91509150816109a6578084846040517f8f4a234f00000000000000000000000000000000000000000000000000000000815260040161062493929190612a6b565b6109b1818888611063565b50505050505050565b600080600080600080878760008181106109d6576109d6612a85565b909101357fff00000000000000000000000000000000000000000000000000000000000000169150819050610a2c57610a0e89610fde565b9250610a1b8389896112ca565b92985090965094509150610b779050565b7fff0000000000000000000000000000000000000000000000000000000000000081811601610a6b57610a5e89610fde565b9250610a1b83898961131b565b7ffe000000000000000000000000000000000000000000000000000000000000007fff00000000000000000000000000000000000000000000000000000000000000821601610abd57610a5e89611347565b7ffd000000000000000000000000000000000000000000000000000000000000007fff00000000000000000000000000000000000000000000000000000000000000821601610b2157610b118989896113b4565b9550955095509550955050610b77565b6040517f6085cd820000000000000000000000000000000000000000000000000000000081527fff0000000000000000000000000000000000000000000000000000000000000082166004820152602401610624565b939792965093509350565b60006105d67f8d0bf1fd623d628c741362c1289948e57b3e2905218c676d3e69abee36d6ae2e83610d9b565b6000333014610bf1576040517fe1258894000000000000000000000000000000000000000000000000000000008152336004820152306024820152604401610624565b81516020830134f060405173ffffffffffffffffffffffffffffffffffffffff821681529091507fa506ad4e7f05eceba62a023c3219e5bd98a615f4fa87e2afb08a2da5cf62bf0c9060200160405180910390a1919050565b60006108996000610b82565b333014610c97576040517fe1258894000000000000000000000000000000000000000000000000000000008152336004820152306024820152604401610624565b6000610ca283610588565b73ffffffffffffffffffffffffffffffffffffffff1614610d13576040517f5b4d6d6a0000000000000000000000000000000000000000000000000000000081527fffffffff0000000000000000000000000000000000000000000000000000000083166004820152602401610624565b604080517fbe27a319efc8734e89e26ba4bc95f5c788584163b959f03fa04e2d7ab4b9a1206020808301919091527fffffffff000000000000000000000000000000000000000000000000000000008516828401528251808303840181526060909201909252805191012073ffffffffffffffffffffffffffffffffffffffff821690555050565b6000808383604051602001610dba929190918252602082015260400190565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152919052805160209091012054949350505050565b60007f6ffbd451000000000000000000000000000000000000000000000000000000007fffffffff00000000000000000000000000000000000000000000000000000000831601610e4c57506001919050565b6105d682611531565b73ffffffffffffffffffffffffffffffffffffffff81163b610ebb576040517f0c76093700000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82166004820152602401610624565b610ec3813055565b60405173ffffffffffffffffffffffffffffffffffffffff821681527f310ba5f1d2ed074b51e2eccd052a47ae9ab7c6b800d1fca3db3999d6a592ca03906020015b60405180910390a150565b6000806000806000610f238888886109ba565b50965091945092509050828210801590610f415750610f4181611672565b9450505050935093915050565b80610f85576040517f4294d12700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610fae7fea7157fa25e3aa17d0ae2d5280fa4e24d421c61842aa85e45194e1145aa72bf8829055565b6040518181527f307ed6bd941ee9fc80f369c94af5fa11e25bab5102a6140191756c5474a30bfa90602001610f05565b6040517f190100000000000000000000000000000000000000000000000000000000000060208201524660228201527fffffffffffffffffffffffffffffffffffffffff0000000000000000000000003060601b166042820152605681018290526000906076015b604051602081830303815290604052805190602001209050919050565b8060005b818110156111ba573684848381811061108257611082612a85565b90506020028101906110949190612ab4565b90506040810135805a10156110e95782815a6040517f2bb3e3ba000000000000000000000000000000000000000000000000000000008152600481019390935260248301919091526044820152606401610624565b60006110f86020840184612af2565b1561113757611130611110608085016060860161235e565b831561111c578361111e565b5a5b61112b60a0870187612b0d565b61167d565b9050611172565b61116f61114a608085016060860161235e565b6080850135841561115b578461115d565b5a5b61116a60a0880188612b0d565b611698565b90505b801561118e5760405188815260200160405180910390a06111af565b6111af6111a16040850160208601612af2565b896111aa6116b5565b6116d4565b505050600101611067565b5050505050565b606081901c6bffffffffffffffffffffffff821660006111e083610b82565b90508181141580156111f0575060005b15611238576040517f9b6514f4000000000000000000000000000000000000000000000000000000008152600481018490526024810183905260448101829052606401610624565b604080517f8d0bf1fd623d628c741362c1289948e57b3e2905218c676d3e69abee36d6ae2e60208083019190915281830186905282518083038401815260609092019092528051910120600183019081905560408051858152602081018390527f1f180c27086c7a39ea2a7b25239d1ab92348f07ca7bb59d1438fcf527568f881910160405180910390a15050505050565b60008080806112e5876112e0876006818b612b72565b611720565b6000908152873560f01c6020818152604080842084526002909a013560e01c908190529890912090999198509695509350505050565b600080808061133687611331876001818b612b72565b6112ca565b935093509350935093509350935093565b6040517f190100000000000000000000000000000000000000000000000000000000000060208201526000602282018190527fffffffffffffffffffffffffffffffffffffffff0000000000000000000000003060601b1660428301526056820183905290607601611046565b6000808080806004600188013560e81c826113cf8383612bcb565b90506113e18b61046583868d8f612b72565b939b50919950975095509350878710156114395761140181848b8d612b72565b89896040517fb006aba00000000000000000000000000000000000000000000000000000000081526004016106249493929190612bde565b8092505b888310156115235760038301928a013560e81c915061145c8383612bcb565b9050600061147e61146c88611bb6565b8c8c8790869261046593929190612b72565b939c50919a50985090915050888810156114d65761149e82858c8e612b72565b8a8a6040517fb006aba00000000000000000000000000000000000000000000000000000000081526004016106249493929190612bde565b848110611519576040517f37daf62b0000000000000000000000000000000000000000000000000000000081526004810182905260248101869052604401610624565b935091508161143d565b505050939792965093509350565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167fec6aba500000000000000000000000000000000000000000000000000000000014806115c457507fffffffff0000000000000000000000000000000000000000000000000000000082167f4e2312e000000000000000000000000000000000000000000000000000000000145b8061161057507fffffffff0000000000000000000000000000000000000000000000000000000082167f150b7a0200000000000000000000000000000000000000000000000000000000145b8061165c57507fffffffff0000000000000000000000000000000000000000000000000000000082167fc0ee0b8a00000000000000000000000000000000000000000000000000000000145b1561166957506001919050565b6105d682611bea565b60006105d682611c46565b60006040518284823760008084838989f49695505050505050565b6000604051828482376000808483898b8af1979650505050505050565b60603d604051915060208201818101604052818352816000823e505090565b82156116e257805160208201fd5b7f3dbd1590ea96dd3253a91f24e64e3a502e1225d602a5731357bc12643070ccd78282604051611713929190612c05565b60405180910390a1505050565b60008060005b83811015611bad57600181019085013560f81c7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81016117c757601582019186013560f881901c9060581c73ffffffffffffffffffffffffffffffffffffffff81169074ff0000000000000000000000000000000000000000168117856117ad57806117bc565b60008681526020829052604090205b955050505050611726565b8061185d5760018201918681013560f81c9060430160006117f38a6117ee84888c8e612b72565b611c5f565b60ff841697909701969194508491905060a083901b74ff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff821617866118425780611851565b60008781526020829052604090205b96505050505050611726565b60028103611985576000808784013560f881901c9060581c73ffffffffffffffffffffffffffffffffffffffff16601586019550909250905060008885013560e81c600386018162ffffff1691508096508192505050600081860190506118d68b848c8c8a9086926118d193929190612b72565b611f22565b61191e578a836118e883898d8f612b72565b6040517f9a9462320000000000000000000000000000000000000000000000000000000081526004016106249493929190612c79565b60ff8416979097019694508460a084901b74ff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff841617876119695780611978565b60008881526020829052604090205b9750505050505050611726565b600381036119b8576020820191860135836119a057806119af565b60008481526020829052604090205b93505050611726565b60048103611a04576003808301928781013560e81c91908201016000806119e58b6112e085898d8f612b72565b6000988952602052604090972096909701965090935061172692505050565b60068103611b0c5760008287013560f81c60018401935060ff16905060008784013560f01c60028501945061ffff16905060008885013560e81c600386018162ffffff169150809650819250505060008186019050600080611a728d8d8d8b9087926112e093929190612b72565b93985088939092509050848210611a8857988501985b604080517f53657175656e6365206e657374656420636f6e6669673a0a0000000000000000602080830191909152603882018490526058820188905260788083018a9052835180840390910181526098909201909252805191012089611aee5780611afd565b60008a81526020829052604090205b99505050505050505050611726565b60058103611b78576020820191860135878103611b47577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff94505b6000611b52826120cf565b905084611b5f5780611b6e565b60008581526020829052604090205b9450505050611726565b6040517fb2505f7c00000000000000000000000000000000000000000000000000000000815260048101829052602401610624565b50935093915050565b7f8713a7c4465f6fbee2b6e9d6646d1d9f83fec929edfc4baf661f3c865bdd04d160009081526020829052604081206105d6565b60007ffda4dd44000000000000000000000000000000000000000000000000000000007fffffffff00000000000000000000000000000000000000000000000000000000831601611c3d57506001919050565b6105d68261210a565b6000611c5182612166565b806105d65750600192915050565b600060428214611c9f5782826040517f2ee17a3d000000000000000000000000000000000000000000000000000000008152600401610624929190612cb9565b6000611cb8611caf600185612ccd565b85013560f81c90565b60ff169050604084013560f81c843560208601357f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a0811115611d2c578686826040517fad4aac7600000000000000000000000000000000000000000000000000000000815260040161062493929190612ce0565b8260ff16601b14158015611d4457508260ff16601c14155b15611d81578686846040517fe578897e00000000000000000000000000000000000000000000000000000000815260040161062493929190612d04565b60018403611dee576040805160008152602081018083528a905260ff851691810191909152606081018390526080810182905260019060a0015b6020604051602081039080840390855afa158015611ddd573d6000803e3d6000fd5b505050602060405103519450611ec6565b60028403611e8b576040517f19457468657265756d205369676e6564204d6573736167653a0a3332000000006020820152603c8101899052600190605c01604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120600084529083018083525260ff861690820152606081018490526080810183905260a001611dbb565b86868560016040517f9dfba8520000000000000000000000000000000000000000000000000000000081526004016106249493929190612d2b565b73ffffffffffffffffffffffffffffffffffffffff8516611f175786866040517f6c1719d2000000000000000000000000000000000000000000000000000000008152600401610624929190612cb9565b505050509392505050565b6000808383611f32600182612ccd565b818110611f4157611f41612a85565b919091013560f81c9150506001811480611f5b5750600281145b15611fa0578473ffffffffffffffffffffffffffffffffffffffff16611f82878686611c5f565b73ffffffffffffffffffffffffffffffffffffffff161491506120c6565b6003810361208b5773ffffffffffffffffffffffffffffffffffffffff8516631626ba7e8786600087611fd4600182612ccd565b92611fe193929190612b72565b6040518463ffffffff1660e01b8152600401611fff93929190612a6b565b602060405180830381865afa15801561201c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906120409190612d57565b7fffffffff00000000000000000000000000000000000000000000000000000000167f1626ba7e000000000000000000000000000000000000000000000000000000001491506120c6565b83838260006040517f9dfba8520000000000000000000000000000000000000000000000000000000081526004016106249493929190612d2b565b50949350505050565b6040517f53657175656e636520737461746963206469676573743a0a0000000000000000602082015260388101829052600090605801611046565b60007fe4a77bbc000000000000000000000000000000000000000000000000000000007fffffffff0000000000000000000000000000000000000000000000000000000083160161215d57506001919050565b6105d682612199565b600081158015906105d65750507fea7157fa25e3aa17d0ae2d5280fa4e24d421c61842aa85e45194e1145aa72bf8541490565b60007fae9fa280000000000000000000000000000000000000000000000000000000007fffffffff000000000000000000000000000000000000000000000000000000008316016121ec57506001919050565b6105d68260007fffffffff0000000000000000000000000000000000000000000000000000000082167fac6a444e00000000000000000000000000000000000000000000000000000000148061228357507fffffffff0000000000000000000000000000000000000000000000000000000082167f36e7817500000000000000000000000000000000000000000000000000000000145b1561229057506001919050565b7f01ffc9a7000000000000000000000000000000000000000000000000000000007fffffffff000000000000000000000000000000000000000000000000000000008316146105d6565b8183823760009101908152919050565b7fffffffff000000000000000000000000000000000000000000000000000000008116811461063657600080fd5b60006020828403121561232a57600080fd5b813561067f816122ea565b803573ffffffffffffffffffffffffffffffffffffffff8116811461235957600080fd5b919050565b60006020828403121561237057600080fd5b61067f82612335565b60008083601f84011261238b57600080fd5b50813567ffffffffffffffff8111156123a357600080fd5b6020830191508360208285010111156123bb57600080fd5b9250929050565b6000806000806000608086880312156123da57600080fd5b6123e386612335565b94506123f160208701612335565b935060408601359250606086013567ffffffffffffffff81111561241457600080fd5b61242088828901612379565b969995985093965092949392505050565b60008060006040848603121561244657600080fd5b83359250602084013567ffffffffffffffff81111561246457600080fd5b61247086828701612379565b9497909650939450505050565b6000806000806040858703121561249357600080fd5b843567ffffffffffffffff808211156124ab57600080fd5b6124b788838901612379565b909650945060208701359150808211156124d057600080fd5b506124dd87828801612379565b95989497509550505050565b6000602082840312156124fb57600080fd5b5035919050565b60008083601f84011261251457600080fd5b50813567ffffffffffffffff81111561252c57600080fd5b6020830191508360208260051b85010111156123bb57600080fd5b6000806020838503121561255a57600080fd5b823567ffffffffffffffff81111561257157600080fd5b61257d85828601612502565b90969095509350505050565b6000806000806000606086880312156125a157600080fd5b853567ffffffffffffffff808211156125b957600080fd5b6125c589838a01612502565b90975095506020880135945060408801359150808211156125e557600080fd5b5061242088828901612379565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60006020828403121561263357600080fd5b813567ffffffffffffffff8082111561264b57600080fd5b818401915084601f83011261265f57600080fd5b813581811115612671576126716125f2565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f011681019083821181831017156126b7576126b76125f2565b816040528281528760208487010111156126d057600080fd5b826020860160208301376000928101602001929092525095945050505050565b6000806040838503121561270357600080fd5b823561270e816122ea565b915061271c60208401612335565b90509250929050565b60008060008060008060008060a0898b03121561274157600080fd5b61274a89612335565b975061275860208a01612335565b9650604089013567ffffffffffffffff8082111561277557600080fd5b6127818c838d01612502565b909850965060608b013591508082111561279a57600080fd5b6127a68c838d01612502565b909650945060808b01359150808211156127bf57600080fd5b506127cc8b828c01612379565b999c989b5096995094979396929594505050565b60008060008060008060a087890312156127f957600080fd5b61280287612335565b955061281060208801612335565b94506040870135935060608701359250608087013567ffffffffffffffff81111561283a57600080fd5b61284689828a01612379565b979a9699509497509295939492505050565b8035801515811461235957600080fd5b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b81835260006020808501808196508560051b810191508460005b878110156129f357828403895281357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff4188360301811261290a57600080fd5b870160c061291782612858565b15158652612926878301612858565b15158688015260408281013590870152606073ffffffffffffffffffffffffffffffffffffffff612958828501612335565b16908701526080828101359087015260a080830135368490037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe101811261299e57600080fd5b90920187810192903567ffffffffffffffff8111156129bc57600080fd5b8036038413156129cb57600080fd5b82828901526129dd8389018286612868565b9c89019c975050509286019250506001016128cb565b5091979650505050505050565b60408152600560408201527f73656c663a00000000000000000000000000000000000000000000000000000060608201526080602082015260006106ee6080830184866128b1565b838152604060208201526000612a626040830184866128b1565b95945050505050565b838152604060208201526000612a62604083018486612868565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600082357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff41833603018112612ae857600080fd5b9190910192915050565b600060208284031215612b0457600080fd5b61067f82612858565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112612b4257600080fd5b83018035915067ffffffffffffffff821115612b5d57600080fd5b6020019150368190038213156123bb57600080fd5b60008085851115612b8257600080fd5b83861115612b8f57600080fd5b5050820193919092039150565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b808201808211156105d6576105d6612b9c565b606081526000612bf2606083018688612868565b6020830194909452506040015292915050565b82815260006020604081840152835180604085015260005b81811015612c3957858101830151858201606001528201612c1d565b5060006060828601015260607fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f830116850101925050509392505050565b84815273ffffffffffffffffffffffffffffffffffffffff84166020820152606060408201526000612caf606083018486612868565b9695505050505050565b6020815260006106ee602083018486612868565b818103818111156105d6576105d6612b9c565b604081526000612cf4604083018587612868565b9050826020830152949350505050565b604081526000612d18604083018587612868565b905060ff83166020830152949350505050565b606081526000612d3f606083018688612868565b60208301949094525090151560409091015292915050565b600060208284031215612d6957600080fd5b815161067f816122ea56fea2646970667358221220d1c64e83cb54c2e1824f98a6e0664734329329620cf112737055416b4d68ea6a64736f6c63430008110033', - linkReferences: {}, - deployedLinkReferences: {} -} diff --git a/packages/estimator/src/builds/index.ts b/packages/estimator/src/builds/index.ts deleted file mode 100644 index 630bef12c..000000000 --- a/packages/estimator/src/builds/index.ts +++ /dev/null @@ -1 +0,0 @@ -export * from './MainModuleGasEstimation' diff --git a/packages/estimator/src/estimator.ts b/packages/estimator/src/estimator.ts deleted file mode 100644 index 0705cea53..000000000 --- a/packages/estimator/src/estimator.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { ethers } from 'ethers' -import { commons, v2 } from '@0xsequence/core' - -export interface Estimator { - estimateGasLimits( - address: string, - config: v2.config.WalletConfig, - context: commons.context.WalletContext, - nonce: ethers.BigNumberish, - ...transactions: commons.transaction.Transaction[] - ): Promise<{ - transactions: commons.transaction.Transaction[] - total: ethers.BigNumber - }> -} diff --git a/packages/estimator/src/index.ts b/packages/estimator/src/index.ts deleted file mode 100644 index 690fbfbe0..000000000 --- a/packages/estimator/src/index.ts +++ /dev/null @@ -1,3 +0,0 @@ -export * from './overwriter-estimator' -export * from './overwriter-sequence-estimator' -export * from './estimator' diff --git a/packages/estimator/src/overwriter-estimator.ts b/packages/estimator/src/overwriter-estimator.ts deleted file mode 100644 index e442ffe83..000000000 --- a/packages/estimator/src/overwriter-estimator.ts +++ /dev/null @@ -1,137 +0,0 @@ -import { ethers } from 'ethers' -import { getEthersConnectionInfo, isBigNumberish, Optionals } from '@0xsequence/utils' - -const GasEstimator = require('@0xsequence/wallet-contracts/artifacts/contracts/modules/utils/GasEstimator.sol/GasEstimator.json') - -function toQuantity(number: ethers.BigNumberish | string): string { - if (isBigNumberish(number)) { - return ethers.BigNumber.from(number).toHexString() - } - - return number -} - -function tryDecodeError(bytes: ethers.BytesLike): string { - try { - return ethers.utils.toUtf8String('0x' + ethers.utils.hexlify(bytes).substr(138)) - } catch (e) { - return 'UNKNOWN_ERROR' - } -} - -function toHexNumber(number: ethers.BigNumberish): string { - return ethers.BigNumber.from(number).toHexString() -} - -export type OverwriterEstimatorOptions = { - rpc: string | ethers.providers.JsonRpcProvider - dataZeroCost?: number - dataOneCost?: number - baseCost?: number -} - -export const OverwriterEstimatorDefaults: Required> = { - dataZeroCost: 4, - dataOneCost: 16, - baseCost: 21000 -} - -export class OverwriterEstimator { - public provider: ethers.providers.JsonRpcProvider - public options: Required - - constructor(options: OverwriterEstimatorOptions) { - this.provider = - typeof options.rpc === 'string' - ? new ethers.providers.StaticJsonRpcProvider(getEthersConnectionInfo(options.rpc)) - : options.rpc - this.options = { ...OverwriterEstimatorDefaults, ...options } - } - - txBaseCost(data: ethers.BytesLike): number { - const bytes = ethers.utils.arrayify(data) - return bytes - .reduce((p, c) => (c == 0 ? p.add(this.options.dataZeroCost) : p.add(this.options.dataOneCost)), ethers.constants.Zero) - .add(this.options.baseCost) - .toNumber() - } - - async estimate(args: { - to: string - from?: string - data?: ethers.BytesLike - gasPrice?: ethers.BigNumberish - gas?: ethers.BigNumberish - overwrites?: { - [address: string]: { - code?: string - balance?: ethers.BigNumberish - nonce?: ethers.BigNumberish - stateDiff?: { - key: string - value: string - }[] - state?: { - key: string - value: string - }[] - } - } - blockTag?: string | ethers.BigNumberish - }): Promise { - const blockTag = args.blockTag ? toQuantity(args.blockTag) : 'latest' - const data = args.data ? args.data : [] - const from = args.from ? ethers.utils.getAddress(args.from) : ethers.Wallet.createRandom().address - - const gasEstimatorInterface = new ethers.utils.Interface(GasEstimator.abi) - const encodedEstimate = gasEstimatorInterface.encodeFunctionData('estimate', [args.to, data]) - - const providedOverwrites = args.overwrites - ? Object.keys(args.overwrites).reduce((p, a) => { - const address = ethers.utils.getAddress(a) - const o = args.overwrites![a] - - if (address === from) { - throw Error("Can't overwrite from address values") - } - - return { - ...p, - [address]: { - code: o.code ? ethers.utils.hexlify(o.code) : undefined, - nonce: o.nonce ? toHexNumber(o.nonce) : undefined, - balance: o.balance ? toHexNumber(o.balance) : undefined, - state: o.state ? o.state : undefined, - stateDiff: o.stateDiff ? o.stateDiff : undefined - } - } - }, {}) - : {} - - const overwrites = { - ...providedOverwrites, - [from]: { - code: GasEstimator.deployedBytecode - } - } - - const response = await this.provider.send('eth_call', [ - { - to: from, - data: encodedEstimate, - gasPrice: args.gasPrice, - gas: args.gas - }, - blockTag, - overwrites - ]) - - const decoded = gasEstimatorInterface.decodeFunctionResult('estimate', response) - - if (!decoded.success) { - throw Error(`Failed gas estimation with ${tryDecodeError(decoded.result)}`) - } - - return ethers.BigNumber.from(decoded.gas).add(this.txBaseCost(data)) - } -} diff --git a/packages/estimator/src/overwriter-sequence-estimator.ts b/packages/estimator/src/overwriter-sequence-estimator.ts deleted file mode 100644 index 7404de191..000000000 --- a/packages/estimator/src/overwriter-sequence-estimator.ts +++ /dev/null @@ -1,139 +0,0 @@ -import { OverwriterEstimator } from './overwriter-estimator' -import { walletContracts } from '@0xsequence/abi' -import { ethers, utils } from 'ethers' -import { Estimator } from './estimator' -import { commons, v2 } from '@0xsequence/core' -import { mainModuleGasEstimation } from './builds' - -export class OverwriterSequenceEstimator implements Estimator { - constructor(public estimator: OverwriterEstimator) {} - - async estimateGasLimits( - address: string, - config: v2.config.WalletConfig, - context: commons.context.WalletContext, - nonce: ethers.BigNumberish, - ...transactions: commons.transaction.Transaction[] - ): Promise<{ transactions: commons.transaction.Transaction[]; total: ethers.BigNumber }> { - const walletInterface = new utils.Interface(walletContracts.mainModule.abi) - - const allSigners = await Promise.all( - v2.config.signersOf(config.tree).map(async (s, i) => ({ - index: i, - address: s.address, - weight: ethers.BigNumber.from(s.weight), - isEOA: await this.estimator.provider.getCode(s.address).then(c => ethers.utils.arrayify(c).length === 0) - })) - ) - - let totalWeight = 0 - - // Pick NOT EOA signers until we reach the threshold - // if we can't reach the threshold, then we'll use the lowest weight EOA signers - // TODO: if EOAs have the same weight, then we should pick the ones further apart from each other (in the tree) - const designatedSigners = allSigners - .sort((a, b) => { - if (a.isEOA && !b.isEOA) return 1 - if (!a.isEOA && b.isEOA) return -1 - if (a.weight.eq(b.weight)) return a.index - b.index - return a.weight.sub(b.weight).toNumber() - }) - .filter(s => { - if (totalWeight >= (config.threshold as number)) { - return false - } else { - totalWeight += s.weight.toNumber() - return true - } - }) - - // Generate a fake signature, meant to resemble the final signature of the transaction - // this "fake" signature is provided to compute a more accurate gas estimation - const fakeSignatures = new Map() - for (const s of designatedSigners) { - if (s.isEOA) { - fakeSignatures.set(s.address, { - signature: (await ethers.Wallet.createRandom().signMessage('')) + '02', - isDynamic: false - }) - } else { - // Assume a 2/3 nested contract signature - const signer1 = ethers.Wallet.createRandom() - const signer2 = ethers.Wallet.createRandom() - const signer3 = ethers.Wallet.createRandom() - - const nestedSignature = v2.signature.encodeSigners( - v2.config.ConfigCoder.fromSimple({ - threshold: 2, - checkpoint: 0, - signers: [ - { - address: signer1.address, - weight: 1 - }, - { - address: signer2.address, - weight: 1 - }, - { - address: signer3.address, - weight: 1 - } - ] - }), - new Map([ - [signer1.address, { signature: (await signer1.signMessage('')) + '02', isDynamic: false }], - [signer2.address, { signature: (await signer2.signMessage('')) + '02', isDynamic: false }] - ]), - [], - 0 - ) - - fakeSignatures.set(s.address, { - signature: nestedSignature.encoded + '03', - isDynamic: true - }) - } - } - - const stubSignature = v2.signature.encodeSigners(config, fakeSignatures, [], 0).encoded - - // Use the provided nonce - // TODO: Maybe ignore if this fails on the MainModuleGasEstimation - // it could help reduce the edge cases for when the gas estimation fails - const encoded = commons.transaction.sequenceTxAbiEncode(transactions) - - const sequenceOverwrites = { - [context.mainModule]: { - code: mainModuleGasEstimation.deployedBytecode - }, - [context.mainModuleUpgradable]: { - code: mainModuleGasEstimation.deployedBytecode - } - } - - const estimates = await Promise.all([ - ...encoded.map(async (_, i) => { - return this.estimator.estimate({ - to: address, - data: walletInterface.encodeFunctionData(walletInterface.getFunction('execute'), [ - encoded.slice(0, i), - nonce, - stubSignature - ]), - overwrites: sequenceOverwrites - }) - }), - this.estimator.estimate({ - to: address, // Compute full gas estimation with all transaction - data: walletInterface.encodeFunctionData(walletInterface.getFunction('execute'), [encoded, nonce, stubSignature]), - overwrites: sequenceOverwrites - }) - ]) - - return { - transactions: transactions.map((t, i) => ({ ...t, gasLimit: estimates[i + 1].sub(estimates[i]) })), - total: estimates[estimates.length - 1] - } - } -} diff --git a/packages/estimator/tests/estimator.spec.ts b/packages/estimator/tests/estimator.spec.ts deleted file mode 100644 index f9095991d..000000000 --- a/packages/estimator/tests/estimator.spec.ts +++ /dev/null @@ -1,44 +0,0 @@ -import { ethers } from 'ethers' - -import { CallReceiverMock } from '@0xsequence/wallet-contracts' -import { OverwriterEstimator } from '@0xsequence/estimator' -import { encodeData } from '@0xsequence/wallet/tests/utils' -import { expect } from 'chai' - -const CallReceiverMockArtifact = require('@0xsequence/wallet-contracts/artifacts/contracts/mocks/CallReceiverMock.sol/CallReceiverMock.json') - -describe('estimator', function () { - let url: string - let provider: ethers.providers.JsonRpcProvider - let callReceiver: CallReceiverMock - - let estimator: OverwriterEstimator - - before(async () => { - url = 'http://127.0.0.1:10045/' - provider = new ethers.providers.JsonRpcProvider(url) - - callReceiver = (await new ethers.ContractFactory( - CallReceiverMockArtifact.abi, - CallReceiverMockArtifact.bytecode, - provider.getSigner() - ).deploy()) as unknown as CallReceiverMock - - estimator = new OverwriterEstimator({ rpc: url }) - }) - - beforeEach(async () => { - await callReceiver.setRevertFlag(false) - await callReceiver.testCall(0, []) - }) - - it('should estimate the gas of a single call', async () => { - const gas = await estimator.estimate({ - to: callReceiver.address, - data: await encodeData(callReceiver, 'testCall', 1, '0x112233') - }) - const tx = await (await callReceiver.testCall(1, '0x112233')).wait() - expect(gas.toNumber()).to.be.above(tx.gasUsed.toNumber()) - expect(gas.toNumber()).to.be.approximately(tx.gasUsed.toNumber(), 5000) - }) -}) diff --git a/packages/estimator/tests/sequence-estimator.spec.ts b/packages/estimator/tests/sequence-estimator.spec.ts deleted file mode 100644 index 5d447d44c..000000000 --- a/packages/estimator/tests/sequence-estimator.spec.ts +++ /dev/null @@ -1,319 +0,0 @@ -import { CallReceiverMock, HookCallerMock } from '@0xsequence/wallet-contracts' - -import { LocalRelayer } from '@0xsequence/relayer' -import { ethers } from 'ethers' - -import { configureLogger } from '@0xsequence/utils' -import { commons, v2 } from '@0xsequence/core' - -import chaiAsPromised from 'chai-as-promised' -import * as chai from 'chai' - -import { SequenceOrchestratorWrapper, Wallet, WalletV2 } from '@0xsequence/wallet' -import { OverwriterSequenceEstimator } from '../src' -import { OverwriterEstimator } from '../dist/0xsequence-estimator.cjs' -import { encodeData } from '@0xsequence/wallet/tests/utils' -import { context } from '@0xsequence/tests' -import { Orchestrator } from '@0xsequence/signhub' - -const CallReceiverMockArtifact = require('@0xsequence/wallet-contracts/artifacts/contracts/mocks/CallReceiverMock.sol/CallReceiverMock.json') -const HookCallerMockArtifact = require('@0xsequence/wallet-contracts/artifacts/contracts/mocks/HookCallerMock.sol/HookCallerMock.json') - -const { expect } = chai.use(chaiAsPromised) - -configureLogger({ logLevel: 'DEBUG', silence: false }) - -describe('Wallet integration', function () { - let relayer: LocalRelayer - let callReceiver: CallReceiverMock - let hookCaller: HookCallerMock - - let contexts: Awaited> - let provider: ethers.providers.JsonRpcProvider - let signers: ethers.Signer[] - - let estimator: OverwriterSequenceEstimator - - before(async () => { - const url = 'http://127.0.0.1:10045/' - provider = new ethers.providers.JsonRpcProvider(url) - - signers = new Array(8).fill(0).map((_, i) => provider.getSigner(i)) - - contexts = await context.deploySequenceContexts(signers[0]) - relayer = new LocalRelayer(signers[0]) - - // Deploy call receiver mock - callReceiver = (await new ethers.ContractFactory( - CallReceiverMockArtifact.abi, - CallReceiverMockArtifact.bytecode, - signers[0] - ).deploy({ gasLimit: 1000000 })) as CallReceiverMock - - // Deploy hook caller mock - hookCaller = (await new ethers.ContractFactory( - HookCallerMockArtifact.abi, - HookCallerMockArtifact.bytecode, - signers[0] - ).deploy({ gasLimit: 1000000 })) as HookCallerMock - - // Deploy local relayer - relayer = new LocalRelayer({ signer: signers[0] }) - - // Create gas estimator - estimator = new OverwriterSequenceEstimator(new OverwriterEstimator({ rpc: provider })) - }) - - beforeEach(async () => { - await callReceiver.setRevertFlag(false) - await callReceiver.testCall(0, []) - }) - - describe('estimate gas of transactions', () => { - const options = [ - { - name: 'single signer wallet', - getWallet: async () => { - // const pk = ethers.utils.randomBytes(32) - // const wallet = await Wallet.singleOwner(pk, context) - // return wallet.connect(ethnode.provider, relayer) - const signer = ethers.Wallet.createRandom() - const config = v2.config.ConfigCoder.fromSimple({ - threshold: 1, - checkpoint: 0, - signers: [{ weight: 1, address: signer.address }] - }) - - return Wallet.newWallet({ - context: contexts[2], - coders: v2.coders, - config, - provider, - relayer, - orchestrator: new Orchestrator([signer]), - chainId: provider.network.chainId - }) - } - }, - { - name: 'multiple signers wallet', - getWallet: async () => { - const signers = new Array(4).fill(0).map(() => ethers.Wallet.createRandom()) - - const config = v2.config.ConfigCoder.fromSimple({ - threshold: 3, - checkpoint: 100, - signers: signers.map(s => ({ weight: 1, address: s.address })) - }) - - return Wallet.newWallet({ - context: contexts[2], - coders: v2.coders, - config, - provider, - relayer, - orchestrator: new Orchestrator([signers[0], signers[1], signers[2]]), - chainId: provider.network.chainId - }) - } - }, - // TODO: This test fails because the gas estimation uses signers that are packed together - // in the tree, we need to modify the estimator so it picks a sparse set of signers - // { - // name: 'many multiple signers wallet', - // getWallet: async () => { - // const signers = new Array(111).fill(0).map(() => ethers.Wallet.createRandom()) - - // const config = v2.config.ConfigCoder.fromSimple({ - // threshold: 11, - // checkpoint: 100, - // signers: signers.map(s => ({ weight: 1, address: s.address })) - // }) - - // console.log(JSON.stringify(config, null, 2)) - - // return Wallet.newWallet({ - // context: contexts[2], - // coders: v2.coders, - // config, - // provider, - // relayer, - // orchestrator: new Orchestrator(signers.slice(0, 12)), - // chainId: provider.network.chainId - // }) - // } - // }, - { - name: 'nested wallet', - getWallet: async () => { - const EOAsigners = new Array(3).fill(0).map(() => ethers.Wallet.createRandom()) - - const nestedSigners = new Array(3).fill(0).map(() => ethers.Wallet.createRandom()) - const nestedConfig = v2.config.ConfigCoder.fromSimple({ - threshold: 2, - checkpoint: 0, - signers: nestedSigners.map(s => ({ weight: 1, address: s.address })) - }) - - const nestedWallet = Wallet.newWallet({ - context: contexts[2], - coders: v2.coders, - config: nestedConfig, - provider, - relayer, - orchestrator: new Orchestrator([nestedSigners[0], nestedSigners[1]]), - chainId: provider.network.chainId - }) - - await nestedWallet.deploy() - - const signers = [nestedWallet, ...EOAsigners] - - const config = v2.config.ConfigCoder.fromSimple({ - threshold: 3, - checkpoint: 0, - signers: signers.map(s => ({ weight: 1, address: s.address })) - }) - - return Wallet.newWallet({ - context: contexts[2], - coders: v2.coders, - config, - provider, - relayer, - orchestrator: new Orchestrator([new SequenceOrchestratorWrapper(nestedWallet), EOAsigners[0], EOAsigners[1]]), - chainId: provider.network.chainId - }) - } - }, - { - name: 'asymetrical signers wallet', - getWallet: async () => { - const signersA = new Array(5).fill(0).map(() => ethers.Wallet.createRandom()) - const signersB = new Array(6).fill(0).map(() => ethers.Wallet.createRandom()) - - const signers = [...signersA, ...signersB] - - const config = v2.config.ConfigCoder.fromSimple({ - threshold: 5, - checkpoint: 0, - signers: signers.map((s, i) => ({ weight: i <= signersA.length ? 1 : 10, address: s.address })) - }) - - return Wallet.newWallet({ - context: contexts[2], - coders: v2.coders, - config, - provider, - relayer, - orchestrator: new Orchestrator(signersA), - chainId: provider.network.chainId - }) - } - } - ] - - options.map(o => { - describe(`with ${o.name}`, () => { - let wallet: WalletV2 - - beforeEach(async () => { - wallet = await o.getWallet() - }) - - describe('with deployed wallet', () => { - let txs: commons.transaction.Transaction[] - - beforeEach(async () => { - await callReceiver.testCall(0, []) - await wallet.deploy() - }) - - describe('a single transaction', () => { - beforeEach(async () => { - txs = [ - { - delegateCall: false, - revertOnError: false, - gasLimit: 0, - to: callReceiver.address, - value: ethers.constants.Zero, - data: await encodeData(callReceiver, 'testCall', 14442, '0x112233') - } - ] - }) - - it('should use estimated gas for a single transaction', async () => { - const estimation = await estimator.estimateGasLimits(wallet.address, wallet.config, wallet.context, 0, ...txs) - const realTx = await (await wallet.sendTransaction(estimation.transactions)).wait(1) - - expect(realTx.gasUsed.toNumber()).to.be.approximately(estimation.total.toNumber(), 10000) - expect(realTx.gasUsed.toNumber()).to.be.below(estimation.total.toNumber()) - - expect((await callReceiver.lastValA()).toNumber()).to.equal(14442) - }) - - it('should predict gas usage for a single transaction', async () => { - const estimation = await estimator.estimateGasLimits(wallet.address, wallet.config, wallet.context, 0, ...txs) - const realTx = await (await wallet.sendTransaction(txs)).wait(1) - - expect(realTx.gasUsed.toNumber()).to.be.approximately(estimation.total.toNumber(), 10000) - expect(realTx.gasUsed.toNumber()).to.be.below(estimation.total.toNumber()) - - expect((await callReceiver.lastValA()).toNumber()).to.equal(14442) - }) - - it('should use estimated gas for a single failing transaction', async () => { - await callReceiver.setRevertFlag(true) - const estimation = await estimator.estimateGasLimits(wallet.address, wallet.config, wallet.context, 0, ...txs) - const realTx = await (await wallet.sendTransaction(estimation.transactions)).wait(1) - - expect(realTx.gasUsed.toNumber()).to.be.approximately(estimation.total.toNumber(), 10000) - expect(realTx.gasUsed.toNumber()).to.be.below(estimation.total.toNumber()) - - expect((await callReceiver.lastValA()).toNumber()).to.equal(0) - }) - }) - - describe('a batch of transactions', () => { - let valB: Uint8Array - - beforeEach(async () => { - await callReceiver.setRevertFlag(true) - valB = ethers.utils.randomBytes(99) - - txs = [ - { - delegateCall: false, - revertOnError: false, - gasLimit: 0, - to: callReceiver.address, - value: ethers.constants.Zero, - data: await encodeData(callReceiver, 'setRevertFlag', false) - }, - { - delegateCall: false, - revertOnError: true, - gasLimit: 0, - to: callReceiver.address, - value: ethers.constants.Zero, - data: await encodeData(callReceiver, 'testCall', 2, valB) - } - ] - }) - - it('should use estimated gas for a batch of transactions', async () => { - const estimation = await estimator.estimateGasLimits(wallet.address, wallet.config, wallet.context, 0, ...txs) - const realTx = await (await wallet.sendTransaction(estimation.transactions)).wait(1) - - expect(realTx.gasUsed.toNumber()).to.be.approximately(estimation.total.toNumber(), 30000) - expect(realTx.gasUsed.toNumber()).to.be.below(estimation.total.toNumber()) - - expect(ethers.utils.hexlify(await callReceiver.lastValB())).to.equal(ethers.utils.hexlify(valB)) - }) - }) - }) - }) - }) - }) -}) diff --git a/packages/guard/CHANGELOG.md b/packages/guard/CHANGELOG.md index 4bd732e75..35aa8627e 100644 --- a/packages/guard/CHANGELOG.md +++ b/packages/guard/CHANGELOG.md @@ -1,5 +1,608 @@ # @0xsequence/guard +## 2.2.14 + +### Patch Changes + +- Somnia Testnet and Monad Testnet +- Updated dependencies + - @0xsequence/account@2.2.14 + - @0xsequence/core@2.2.14 + - @0xsequence/signhub@2.2.14 + - @0xsequence/utils@2.2.14 + +## 2.2.13 + +### Patch Changes + +- Add XR1 to all networks +- Updated dependencies + - @0xsequence/account@2.2.13 + - @0xsequence/core@2.2.13 + - @0xsequence/signhub@2.2.13 + - @0xsequence/utils@2.2.13 + +## 2.2.12 + +### Patch Changes + +- Add XR1 +- Updated dependencies + - @0xsequence/account@2.2.12 + - @0xsequence/core@2.2.12 + - @0xsequence/signhub@2.2.12 + - @0xsequence/utils@2.2.12 + +## 2.2.11 + +### Patch Changes + +- Relayer updates +- Updated dependencies + - @0xsequence/account@2.2.11 + - @0xsequence/core@2.2.11 + - @0xsequence/signhub@2.2.11 + - @0xsequence/utils@2.2.11 + +## 2.2.10 + +### Patch Changes + +- Etherlink support +- Updated dependencies + - @0xsequence/account@2.2.10 + - @0xsequence/core@2.2.10 + - @0xsequence/signhub@2.2.10 + - @0xsequence/utils@2.2.10 + +## 2.2.9 + +### Patch Changes + +- Indexer gateway native token balances +- Updated dependencies + - @0xsequence/account@2.2.9 + - @0xsequence/core@2.2.9 + - @0xsequence/signhub@2.2.9 + - @0xsequence/utils@2.2.9 + +## 2.2.8 + +### Patch Changes + +- Add Moonbeam and Moonbase Alpha +- Updated dependencies + - @0xsequence/account@2.2.8 + - @0xsequence/core@2.2.8 + - @0xsequence/signhub@2.2.8 + - @0xsequence/utils@2.2.8 + +## 2.2.7 + +### Patch Changes + +- Update Builder package +- Updated dependencies + - @0xsequence/account@2.2.7 + - @0xsequence/core@2.2.7 + - @0xsequence/signhub@2.2.7 + - @0xsequence/utils@2.2.7 + +## 2.2.6 + +### Patch Changes + +- Update relayer package +- Updated dependencies + - @0xsequence/account@2.2.6 + - @0xsequence/core@2.2.6 + - @0xsequence/signhub@2.2.6 + - @0xsequence/utils@2.2.6 + +## 2.2.5 + +### Patch Changes + +- auth: fix sequence indexer gateway url +- account: immutable wallet proxy hook +- Updated dependencies +- Updated dependencies + - @0xsequence/account@2.2.5 + - @0xsequence/core@2.2.5 + - @0xsequence/signhub@2.2.5 + - @0xsequence/utils@2.2.5 + +## 2.2.4 + +### Patch Changes + +- network: update soneium mainnet block explorer url +- waas: signTypedData intent support +- Updated dependencies +- Updated dependencies + - @0xsequence/account@2.2.4 + - @0xsequence/core@2.2.4 + - @0xsequence/signhub@2.2.4 + - @0xsequence/utils@2.2.4 + +## 2.2.3 + +### Patch Changes + +- provider: updating initWallet to use connected network configs if they exist +- Updated dependencies + - @0xsequence/account@2.2.3 + - @0xsequence/core@2.2.3 + - @0xsequence/signhub@2.2.3 + - @0xsequence/utils@2.2.3 + +## 2.2.2 + +### Patch Changes + +- pass projectAccessKey to relayer at all times +- Updated dependencies + - @0xsequence/account@2.2.2 + - @0xsequence/core@2.2.2 + - @0xsequence/signhub@2.2.2 + - @0xsequence/utils@2.2.2 + +## 2.2.1 + +### Patch Changes + +- waas-ethers: sign typed data +- Updated dependencies + - @0xsequence/account@2.2.1 + - @0xsequence/core@2.2.1 + - @0xsequence/signhub@2.2.1 + - @0xsequence/utils@2.2.1 + +## 2.2.0 + +### Minor Changes + +- indexer: gateway client +- @0xsequence/builder +- upgrade puppeteer to v23.10.3 + +### Patch Changes + +- Updated dependencies +- Updated dependencies +- Updated dependencies + - @0xsequence/account@2.2.0 + - @0xsequence/core@2.2.0 + - @0xsequence/signhub@2.2.0 + - @0xsequence/utils@2.2.0 + +## 2.1.8 + +### Patch Changes + +- Add Soneium Mainnet +- Updated dependencies + - @0xsequence/account@2.1.8 + - @0xsequence/core@2.1.8 + - @0xsequence/signhub@2.1.8 + - @0xsequence/utils@2.1.8 + +## 2.1.7 + +### Patch Changes + +- guard: pass project access key to guard requests +- Updated dependencies + - @0xsequence/account@2.1.7 + - @0xsequence/core@2.1.7 + - @0xsequence/signhub@2.1.7 + - @0xsequence/utils@2.1.7 + +## 2.1.6 + +### Patch Changes + +- Add LAOS and Telos Testnet chains +- Updated dependencies + - @0xsequence/account@2.1.6 + - @0xsequence/core@2.1.6 + - @0xsequence/signhub@2.1.6 + - @0xsequence/utils@2.1.6 + +## 2.1.5 + +### Patch Changes + +- account: save presigned configuration with reference chain id 1 +- Updated dependencies + - @0xsequence/account@2.1.5 + - @0xsequence/core@2.1.5 + - @0xsequence/signhub@2.1.5 + - @0xsequence/utils@2.1.5 + +## 2.1.4 + +### Patch Changes + +- provider: pass projectAccessKey into MuxMessageProvider +- Updated dependencies + - @0xsequence/account@2.1.4 + - @0xsequence/core@2.1.4 + - @0xsequence/signhub@2.1.4 + - @0xsequence/utils@2.1.4 + +## 2.1.3 + +### Patch Changes + +- waas: time drift date fix due to strange browser quirk +- Updated dependencies + - @0xsequence/account@2.1.3 + - @0xsequence/core@2.1.3 + - @0xsequence/signhub@2.1.3 + - @0xsequence/utils@2.1.3 + +## 2.1.2 + +### Patch Changes + +- provider: export analytics correctly +- Updated dependencies + - @0xsequence/account@2.1.2 + - @0xsequence/core@2.1.2 + - @0xsequence/signhub@2.1.2 + - @0xsequence/utils@2.1.2 + +## 2.1.1 + +### Patch Changes + +- Add LAOS chain support +- Updated dependencies + - @0xsequence/account@2.1.1 + - @0xsequence/core@2.1.1 + - @0xsequence/signhub@2.1.1 + - @0xsequence/utils@2.1.1 + +## 2.1.0 + +### Minor Changes + +- account: forward project access key when estimating fees and sending transactions + +### Patch Changes + +- sessions: save signatures with reference chain id +- Updated dependencies +- Updated dependencies + - @0xsequence/account@2.1.0 + - @0xsequence/core@2.1.0 + - @0xsequence/signhub@2.1.0 + - @0xsequence/utils@2.1.0 + +## 2.0.26 + +### Patch Changes + +- account: fix chain id comparison +- Updated dependencies + - @0xsequence/account@2.0.26 + - @0xsequence/core@2.0.26 + - @0xsequence/signhub@2.0.26 + - @0xsequence/utils@2.0.26 + +## 2.0.25 + +### Patch Changes + +- skale-nebula: deploy gas limit = 10m +- Updated dependencies + - @0xsequence/account@2.0.25 + - @0xsequence/core@2.0.25 + - @0xsequence/signhub@2.0.25 + - @0xsequence/utils@2.0.25 + +## 2.0.24 + +### Patch Changes + +- sessions: arweave: configurable gateway url +- waas: use /status to get time drift before sending any intents +- Updated dependencies +- Updated dependencies + - @0xsequence/account@2.0.24 + - @0xsequence/core@2.0.24 + - @0xsequence/signhub@2.0.24 + - @0xsequence/utils@2.0.24 + +## 2.0.23 + +### Patch Changes + +- Add The Root Network support +- Updated dependencies + - @0xsequence/account@2.0.23 + - @0xsequence/core@2.0.23 + - @0xsequence/signhub@2.0.23 + - @0xsequence/utils@2.0.23 + +## 2.0.22 + +### Patch Changes + +- Add SKALE Nebula Mainnet support +- Updated dependencies + - @0xsequence/account@2.0.22 + - @0xsequence/core@2.0.22 + - @0xsequence/signhub@2.0.22 + - @0xsequence/utils@2.0.22 + +## 2.0.21 + +### Patch Changes + +- account: add publishWitnessFor +- Updated dependencies + - @0xsequence/account@2.0.21 + - @0xsequence/core@2.0.21 + - @0xsequence/signhub@2.0.21 + - @0xsequence/utils@2.0.21 + +## 2.0.20 + +### Patch Changes + +- upgrade deps, and improve waas session status handling +- Updated dependencies + - @0xsequence/account@2.0.20 + - @0xsequence/core@2.0.20 + - @0xsequence/signhub@2.0.20 + - @0xsequence/utils@2.0.20 + +## 2.0.19 + +### Patch Changes + +- Add Immutable zkEVM support +- Updated dependencies + - @0xsequence/account@2.0.19 + - @0xsequence/core@2.0.19 + - @0xsequence/signhub@2.0.19 + - @0xsequence/utils@2.0.19 + +## 2.0.18 + +### Patch Changes + +- waas: new contractCall transaction type +- sessions: add arweave owner +- Updated dependencies +- Updated dependencies + - @0xsequence/account@2.0.18 + - @0xsequence/core@2.0.18 + - @0xsequence/signhub@2.0.18 + - @0xsequence/utils@2.0.18 + +## 2.0.17 + +### Patch Changes + +- update waas auth to clear session before signIn +- Updated dependencies + - @0xsequence/account@2.0.17 + - @0xsequence/core@2.0.17 + - @0xsequence/signhub@2.0.17 + - @0xsequence/utils@2.0.17 + +## 2.0.16 + +### Patch Changes + +- Removed Astar chains +- Updated dependencies + - @0xsequence/account@2.0.16 + - @0xsequence/core@2.0.16 + - @0xsequence/signhub@2.0.16 + - @0xsequence/utils@2.0.16 + +## 2.0.15 + +### Patch Changes + +- indexer: update bindings with token balance additions +- Updated dependencies + - @0xsequence/account@2.0.15 + - @0xsequence/core@2.0.15 + - @0xsequence/signhub@2.0.15 + - @0xsequence/utils@2.0.15 + +## 2.0.14 + +### Patch Changes + +- sessions: arweave config reader +- network: add b3 and apechain mainnet configs +- Updated dependencies +- Updated dependencies + - @0xsequence/account@2.0.14 + - @0xsequence/core@2.0.14 + - @0xsequence/signhub@2.0.14 + - @0xsequence/utils@2.0.14 + +## 2.0.13 + +### Patch Changes + +- network: toy-testnet +- Updated dependencies + - @0xsequence/account@2.0.13 + - @0xsequence/core@2.0.13 + - @0xsequence/signhub@2.0.13 + - @0xsequence/utils@2.0.13 + +## 2.0.12 + +### Patch Changes + +- api: update bindings +- Updated dependencies + - @0xsequence/account@2.0.12 + - @0xsequence/core@2.0.12 + - @0xsequence/signhub@2.0.12 + - @0xsequence/utils@2.0.12 + +## 2.0.11 + +### Patch Changes + +- waas: intents test fix +- api: update bindings +- Updated dependencies +- Updated dependencies + - @0xsequence/account@2.0.11 + - @0xsequence/core@2.0.11 + - @0xsequence/signhub@2.0.11 + - @0xsequence/utils@2.0.11 + +## 2.0.10 + +### Patch Changes + +- network: soneium minato testnet +- Updated dependencies + - @0xsequence/account@2.0.10 + - @0xsequence/core@2.0.10 + - @0xsequence/signhub@2.0.10 + - @0xsequence/utils@2.0.10 + +## 2.0.9 + +### Patch Changes + +- network: fix SKALE network name +- Updated dependencies + - @0xsequence/account@2.0.9 + - @0xsequence/core@2.0.9 + - @0xsequence/signhub@2.0.9 + - @0xsequence/utils@2.0.9 + +## 2.0.8 + +### Patch Changes + +- metadata: update bindings +- Updated dependencies + - @0xsequence/account@2.0.8 + - @0xsequence/core@2.0.8 + - @0xsequence/signhub@2.0.8 + - @0xsequence/utils@2.0.8 + +## 2.0.7 + +### Patch Changes + +- wallet request handler fix +- Updated dependencies + - @0xsequence/account@2.0.7 + - @0xsequence/core@2.0.7 + - @0xsequence/signhub@2.0.7 + - @0xsequence/utils@2.0.7 + +## 2.0.6 + +### Patch Changes + +- network: matic -> pol +- Updated dependencies + - @0xsequence/account@2.0.6 + - @0xsequence/core@2.0.6 + - @0xsequence/signhub@2.0.6 + - @0xsequence/utils@2.0.6 + +## 2.0.5 + +### Patch Changes + +- provider: update databeat to 0.9.2 +- Updated dependencies + - @0xsequence/account@2.0.5 + - @0xsequence/core@2.0.5 + - @0xsequence/signhub@2.0.5 + - @0xsequence/utils@2.0.5 + +## 2.0.4 + +### Patch Changes + +- network: add skale-nebula-testnet +- Updated dependencies + - @0xsequence/account@2.0.4 + - @0xsequence/core@2.0.4 + - @0xsequence/signhub@2.0.4 + - @0xsequence/utils@2.0.4 + +## 2.0.3 + +### Patch Changes + +- waas: check session status in SequenceWaaS.isSignedIn() +- Updated dependencies + - @0xsequence/account@2.0.3 + - @0xsequence/core@2.0.3 + - @0xsequence/signhub@2.0.3 + - @0xsequence/utils@2.0.3 + +## 2.0.2 + +### Patch Changes + +- sessions: property convert serialized bignumber hex value to bigint +- Updated dependencies + - @0xsequence/account@2.0.2 + - @0xsequence/core@2.0.2 + - @0xsequence/signhub@2.0.2 + - @0xsequence/utils@2.0.2 + +## 2.0.1 + +### Patch Changes + +- waas: http signature check for authenticator requests +- provider: unwrap legacy json rpc responses +- use json replacer and reviver for bigints +- Updated dependencies +- Updated dependencies +- Updated dependencies + - @0xsequence/account@2.0.1 + - @0xsequence/core@2.0.1 + - @0xsequence/signhub@2.0.1 + - @0xsequence/utils@2.0.1 + +## 2.0.0 + +### Major Changes + +- ethers v6 + +### Patch Changes + +- Updated dependencies + - @0xsequence/account@2.0.0 + - @0xsequence/core@2.0.0 + - @0xsequence/signhub@2.0.0 + - @0xsequence/utils@2.0.0 + +## 1.10.15 + +### Patch Changes + +- utils: extractProjectIdFromAccessKey +- Updated dependencies + - @0xsequence/account@1.10.15 + - @0xsequence/core@1.10.15 + - @0xsequence/signhub@1.10.15 + - @0xsequence/utils@1.10.15 + ## 1.10.14 ### Patch Changes diff --git a/packages/guard/package.json b/packages/guard/package.json index 0876998e5..769b4123e 100644 --- a/packages/guard/package.json +++ b/packages/guard/package.json @@ -1,6 +1,6 @@ { "name": "@0xsequence/guard", - "version": "1.10.14", + "version": "2.2.14", "description": "guard sub-package for Sequence", "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/guard", "source": "src/index.ts", @@ -12,12 +12,17 @@ "test": "echo", "typecheck": "tsc --noEmit" }, + "peerDependencies": { + "ethers": ">=6" + }, "dependencies": { "@0xsequence/account": "workspace:*", "@0xsequence/core": "workspace:*", "@0xsequence/signhub": "workspace:*", - "@0xsequence/utils": "workspace:*", - "ethers": "^5.7.2" + "@0xsequence/utils": "workspace:*" + }, + "devDependencies": { + "ethers": "6.13.4" }, "files": [ "src", diff --git a/packages/guard/src/guard.gen.ts b/packages/guard/src/guard.gen.ts index 519740c29..58b4cf54e 100644 --- a/packages/guard/src/guard.gen.ts +++ b/packages/guard/src/guard.gen.ts @@ -1,10 +1,14 @@ /* eslint-disable */ -// sequence-guard v0.4.0 5b203e30a5c79b2b9a37483ce17500a51b94ebe1 +// sequence-guard v0.4.0 d6b4a3c89539b494875af543fff459df65bb7b9e // -- -// Code generated by webrpc-gen@v0.18.6 with typescript generator. DO NOT EDIT. +// Code generated by webrpc-gen@v0.22.0 with typescript generator. DO NOT EDIT. // // webrpc-gen -schema=guard.ridl -target=typescript -client -out=./clients/guard.gen.ts +export const WebrpcHeader = 'Webrpc' + +export const WebrpcHeaderValue = 'webrpc@v0.22.0;gen-typescript@v0.16.1;sequence-guard@v0.4.0' + // WebRPC description and code-gen version export const WebRPCVersion = 'v1' @@ -12,7 +16,55 @@ export const WebRPCVersion = 'v1' export const WebRPCSchemaVersion = 'v0.4.0' // Schema hash generated from your RIDL schema -export const WebRPCSchemaHash = '5b203e30a5c79b2b9a37483ce17500a51b94ebe1' +export const WebRPCSchemaHash = 'd6b4a3c89539b494875af543fff459df65bb7b9e' + +type WebrpcGenVersions = { + webrpcGenVersion: string + codeGenName: string + codeGenVersion: string + schemaName: string + schemaVersion: string +} + +export function VersionFromHeader(headers: Headers): WebrpcGenVersions { + const headerValue = headers.get(WebrpcHeader) + if (!headerValue) { + return { + webrpcGenVersion: '', + codeGenName: '', + codeGenVersion: '', + schemaName: '', + schemaVersion: '' + } + } + + return parseWebrpcGenVersions(headerValue) +} + +function parseWebrpcGenVersions(header: string): WebrpcGenVersions { + const versions = header.split(';') + if (versions.length < 3) { + return { + webrpcGenVersion: '', + codeGenName: '', + codeGenVersion: '', + schemaName: '', + schemaVersion: '' + } + } + + const [_, webrpcGenVersion] = versions[0].split('@') + const [codeGenName, codeGenVersion] = versions[1].split('@') + const [schemaName, schemaVersion] = versions[2].split('@') + + return { + webrpcGenVersion, + codeGenName, + codeGenVersion, + schemaName, + schemaVersion + } +} // // Types @@ -208,7 +260,7 @@ export class Guard implements Guard { protected path = '/rpc/Guard/' constructor(hostname: string, fetch: Fetch) { - this.hostname = hostname + this.hostname = hostname.replace(/\/*$/, '') this.fetch = (input: RequestInfo, init?: RequestInit) => fetch(input, init) } @@ -455,9 +507,12 @@ export class Guard implements Guard { } const createHTTPRequest = (body: object = {}, headers: object = {}, signal: AbortSignal | null = null): object => { + const reqHeaders: { [key: string]: string } = { ...headers, 'Content-Type': 'application/json' } + reqHeaders[WebrpcHeader] = WebrpcHeaderValue + return { method: 'POST', - headers: { ...headers, 'Content-Type': 'application/json' }, + headers: reqHeaders, body: JSON.stringify(body || {}), signal } @@ -676,6 +731,19 @@ export class UnauthorizedError extends WebrpcError { } } +export class PermissionDeniedError extends WebrpcError { + constructor( + name: string = 'PermissionDenied', + code: number = 1001, + message: string = 'Permission denied', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, PermissionDeniedError.prototype) + } +} + export class SessionExpiredError extends WebrpcError { constructor( name: string = 'SessionExpired', @@ -689,6 +757,32 @@ export class SessionExpiredError extends WebrpcError { } } +export class MethodNotFoundError extends WebrpcError { + constructor( + name: string = 'MethodNotFound', + code: number = 1003, + message: string = 'Method not found', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, MethodNotFoundError.prototype) + } +} + +export class RequestConflictError extends WebrpcError { + constructor( + name: string = 'RequestConflict', + code: number = 1004, + message: string = 'Conflict with target resource', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, RequestConflictError.prototype) + } +} + export class AbortedError extends WebrpcError { constructor( name: string = 'Aborted', @@ -702,6 +796,32 @@ export class AbortedError extends WebrpcError { } } +export class GeoblockedError extends WebrpcError { + constructor( + name: string = 'Geoblocked', + code: number = 1006, + message: string = 'Geoblocked region', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, GeoblockedError.prototype) + } +} + +export class RateLimitedError extends WebrpcError { + constructor( + name: string = 'RateLimited', + code: number = 1007, + message: string = 'Rate-limited. Please slow down.', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, RateLimitedError.prototype) + } +} + export class InvalidArgumentError extends WebrpcError { constructor( name: string = 'InvalidArgument', @@ -780,8 +900,13 @@ export enum errors { WebrpcStreamLost = 'WebrpcStreamLost', WebrpcStreamFinished = 'WebrpcStreamFinished', Unauthorized = 'Unauthorized', + PermissionDenied = 'PermissionDenied', SessionExpired = 'SessionExpired', + MethodNotFound = 'MethodNotFound', + RequestConflict = 'RequestConflict', Aborted = 'Aborted', + Geoblocked = 'Geoblocked', + RateLimited = 'RateLimited', InvalidArgument = 'InvalidArgument', Unavailable = 'Unavailable', QueryFailed = 'QueryFailed', @@ -789,7 +914,34 @@ export enum errors { NotFound = 'NotFound' } -const webrpcErrorByCode: { [code: number]: any } = { +export enum WebrpcErrorCodes { + WebrpcEndpoint = 0, + WebrpcRequestFailed = -1, + WebrpcBadRoute = -2, + WebrpcBadMethod = -3, + WebrpcBadRequest = -4, + WebrpcBadResponse = -5, + WebrpcServerPanic = -6, + WebrpcInternalError = -7, + WebrpcClientDisconnected = -8, + WebrpcStreamLost = -9, + WebrpcStreamFinished = -10, + Unauthorized = 1000, + PermissionDenied = 1001, + SessionExpired = 1002, + MethodNotFound = 1003, + RequestConflict = 1004, + Aborted = 1005, + Geoblocked = 1006, + RateLimited = 1007, + InvalidArgument = 2001, + Unavailable = 2002, + QueryFailed = 2003, + ValidationFailed = 2004, + NotFound = 3000 +} + +export const webrpcErrorByCode: { [code: number]: any } = { [0]: WebrpcEndpointError, [-1]: WebrpcRequestFailedError, [-2]: WebrpcBadRouteError, @@ -802,8 +954,13 @@ const webrpcErrorByCode: { [code: number]: any } = { [-9]: WebrpcStreamLostError, [-10]: WebrpcStreamFinishedError, [1000]: UnauthorizedError, + [1001]: PermissionDeniedError, [1002]: SessionExpiredError, + [1003]: MethodNotFoundError, + [1004]: RequestConflictError, [1005]: AbortedError, + [1006]: GeoblockedError, + [1007]: RateLimitedError, [2001]: InvalidArgumentError, [2002]: UnavailableError, [2003]: QueryFailedError, diff --git a/packages/guard/src/signer.ts b/packages/guard/src/signer.ts index b467b68b6..48491e575 100644 --- a/packages/guard/src/signer.ts +++ b/packages/guard/src/signer.ts @@ -2,20 +2,34 @@ import { Account } from '@0xsequence/account' import { commons, universal } from '@0xsequence/core' import { signers, Status } from '@0xsequence/signhub' import { encodeTypedDataDigest, TypedData } from '@0xsequence/utils' -import { BytesLike, ethers, TypedDataDomain } from 'ethers' +import { ethers } from 'ethers' import { AuthMethodsReturn, Guard, RecoveryCode as GuardRecoveryCode } from './guard.gen' -const fetch = globalThis.fetch - export class GuardSigner implements signers.SapientSigner { private guard: Guard constructor( public readonly address: string, public readonly url: string, - public readonly appendSuffix: boolean = false + public readonly appendSuffix: boolean = false, + public readonly projectAccessKey?: string ) { - this.guard = new Guard(url, fetch) + this.guard = new Guard(url, this._fetch) + } + + _fetch = (input: RequestInfo, init?: RequestInit): Promise => { + const headers: { [key: string]: any } = {} + + const projectAccessKey = this.projectAccessKey + + if (projectAccessKey && projectAccessKey.length > 0) { + headers['X-Access-Key'] = projectAccessKey + } + + // before the request is made + init!.headers = { ...init!.headers, ...headers } + + return fetch(input, init) } async getAddress(): Promise { @@ -37,7 +51,7 @@ export class GuardSigner implements signers.SapientSigner { return bundle } - async sign(message: BytesLike, metadata: object): Promise { + async sign(message: ethers.BytesLike, metadata: object): Promise { if (!commons.isWalletSignRequestMetadata(metadata)) { throw new Error('expected sequence signature request metadata') } @@ -53,9 +67,9 @@ export class GuardSigner implements signers.SapientSigner { await this.guard.signWith({ signer: this.address, request: { - msg: ethers.utils.hexlify(message), + msg: ethers.hexlify(message), auxData: this.packMsgAndSig(metadata.address, metadata.digest, encoded, metadata.chainId), - chainId: ethers.BigNumber.from(metadata.chainId).toNumber() + chainId: Number(metadata.chainId) }, token: guardTotpCode ? { id: AuthMethod.TOTP, token: guardTotpCode } : undefined }) @@ -170,12 +184,12 @@ export class GuardSigner implements signers.SapientSigner { return codes } - private packMsgAndSig(address: string, msg: BytesLike, sig: BytesLike, chainId: ethers.BigNumberish): string { - return ethers.utils.defaultAbiCoder.encode(['address', 'uint256', 'bytes', 'bytes'], [address, chainId, msg, sig]) + private packMsgAndSig(address: string, msg: ethers.BytesLike, sig: ethers.BytesLike, chainId: ethers.BigNumberish): string { + return ethers.AbiCoder.defaultAbiCoder().encode(['address', 'uint256', 'bytes', 'bytes'], [address, chainId, msg, sig]) } - suffix(): BytesLike { - return this.appendSuffix ? [3] : [] + suffix(): ethers.BytesLike { + return new Uint8Array(this.appendSuffix ? [3] : []) } } @@ -229,7 +243,7 @@ export async function signOwnershipProof(proof: Exclude pol + +## 2.0.5 + +### Patch Changes + +- provider: update databeat to 0.9.2 + +## 2.0.4 + +### Patch Changes + +- network: add skale-nebula-testnet + +## 2.0.3 + +### Patch Changes + +- waas: check session status in SequenceWaaS.isSignedIn() + +## 2.0.2 + +### Patch Changes + +- sessions: property convert serialized bignumber hex value to bigint + +## 2.0.1 + +### Patch Changes + +- waas: http signature check for authenticator requests +- provider: unwrap legacy json rpc responses +- use json replacer and reviver for bigints + +## 2.0.0 + +### Major Changes + +- ethers v6 + +## 1.10.15 + +### Patch Changes + +- utils: extractProjectIdFromAccessKey + ## 1.10.14 ### Patch Changes diff --git a/packages/indexer/package.json b/packages/indexer/package.json index 1cc1a66ad..6f88eb546 100644 --- a/packages/indexer/package.json +++ b/packages/indexer/package.json @@ -1,6 +1,6 @@ { "name": "@0xsequence/indexer", - "version": "1.10.14", + "version": "2.2.14", "description": "indexer sub-package for Sequence", "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/indexer", "source": "src/index.ts", diff --git a/packages/indexer/src/index.ts b/packages/indexer/src/index.ts index 4c85e86f3..0401f38be 100644 --- a/packages/indexer/src/index.ts +++ b/packages/indexer/src/index.ts @@ -1,8 +1,8 @@ export * from './indexer.gen' +export * as IndexerGateway from './indexergw.gen' import { Indexer as IndexerRpc } from './indexer.gen' - -const fetch = globalThis.fetch +import { IndexerGateway as IndexerGatewayRpc } from './indexergw.gen' export class SequenceIndexer extends IndexerRpc { constructor( @@ -36,3 +36,36 @@ export class SequenceIndexer extends IndexerRpc { return fetch(input, init) } } + +export class SequenceIndexerGateway extends IndexerGatewayRpc { + constructor( + hostname: string, + public projectAccessKey?: string, + public jwtAuth?: string + ) { + super(hostname.endsWith('/') ? hostname.slice(0, -1) : hostname, fetch) + this.fetch = this._fetch + } + + _fetch = (input: RequestInfo, init?: RequestInit): Promise => { + // automatically include jwt and access key auth header to requests + // if its been set on the api client + const headers: { [key: string]: any } = {} + + const jwtAuth = this.jwtAuth + const projectAccessKey = this.projectAccessKey + + if (jwtAuth && jwtAuth.length > 0) { + headers['Authorization'] = `BEARER ${jwtAuth}` + } + + if (projectAccessKey && projectAccessKey.length > 0) { + headers['X-Access-Key'] = projectAccessKey + } + + // before the request is made + init!.headers = { ...init!.headers, ...headers } + + return fetch(input, init) + } +} diff --git a/packages/indexer/src/indexer.gen.ts b/packages/indexer/src/indexer.gen.ts index 4a8dc08e0..e433beee1 100644 --- a/packages/indexer/src/indexer.gen.ts +++ b/packages/indexer/src/indexer.gen.ts @@ -1,9 +1,13 @@ /* eslint-disable */ -// sequence-indexer v0.4.0 9accea267e7db3d66f40d5e0f27db92eb5a29e2f +// sequence-indexer v0.4.0 5be5b8237a5f9ee70f4c98b5bd0a367974e2f785 // -- -// Code generated by webrpc-gen@v0.18.6 with typescript generator. DO NOT EDIT. +// Code generated by webrpc-gen@v0.21.1 with typescript generator. DO NOT EDIT. // -// webrpc-gen -schema=indexer.ridl -target=typescript -client -out=./clients/indexer.gen.ts +// webrpc-gen -schema=indexer.ridl -service=Indexer -target=typescript -client -out=./clients/indexer.gen.ts + +export const WebrpcHeader = 'Webrpc' + +export const WebrpcHeaderValue = 'webrpc@v0.21.1;gen-typescript@v0.15.1;sequence-indexer@v0.4.0' // WebRPC description and code-gen version export const WebRPCVersion = 'v1' @@ -12,12 +16,66 @@ export const WebRPCVersion = 'v1' export const WebRPCSchemaVersion = 'v0.4.0' // Schema hash generated from your RIDL schema -export const WebRPCSchemaHash = '9accea267e7db3d66f40d5e0f27db92eb5a29e2f' +export const WebRPCSchemaHash = '5be5b8237a5f9ee70f4c98b5bd0a367974e2f785' + +type WebrpcGenVersions = { + webrpcGenVersion: string + codeGenName: string + codeGenVersion: string + schemaName: string + schemaVersion: string +} + +export function VersionFromHeader(headers: Headers): WebrpcGenVersions { + const headerValue = headers.get(WebrpcHeader) + if (!headerValue) { + return { + webrpcGenVersion: '', + codeGenName: '', + codeGenVersion: '', + schemaName: '', + schemaVersion: '' + } + } + + return parseWebrpcGenVersions(headerValue) +} + +function parseWebrpcGenVersions(header: string): WebrpcGenVersions { + const versions = header.split(';') + if (versions.length < 3) { + return { + webrpcGenVersion: '', + codeGenName: '', + codeGenVersion: '', + schemaName: '', + schemaVersion: '' + } + } + + const [_, webrpcGenVersion] = versions[0].split('@') + const [codeGenName, codeGenVersion] = versions[1].split('@') + const [schemaName, schemaVersion] = versions[2].split('@') + + return { + webrpcGenVersion, + codeGenName, + codeGenVersion, + schemaName, + schemaVersion + } +} // // Types // +export enum ResourceStatus { + NOT_AVAILABLE = 'NOT_AVAILABLE', + STALE = 'STALE', + AVAILABLE = 'AVAILABLE' +} + export interface ContractInfo { chainId: number address: string @@ -30,12 +88,17 @@ export interface ContractInfo { bytecodeHash: string extensions: ContractInfoExtensions updatedAt: string + notFound: boolean + queuedAt?: string + status: ResourceStatus } export interface ContractInfoExtensions { link: string description: string + categories: Array ogImage: string + ogName: string originChainId: number originAddress: string blacklist: boolean @@ -60,6 +123,9 @@ export interface TokenMetadata { decimals?: number updatedAt?: string assets?: Array + status: ResourceStatus + queuedAt?: string + lastFetched?: string } export interface Asset { @@ -130,6 +196,12 @@ export enum SortOrder { ASC = 'ASC' } +export enum ContractVerificationStatus { + VERIFIED = 'VERIFIED', + UNVERIFIED = 'UNVERIFIED', + ALL = 'ALL' +} + export interface Version { webrpcVersion: string schemaVersion: string @@ -149,6 +221,27 @@ export interface RuntimeStatus { checks: RuntimeChecks } +export interface GatewayBackendResponseTime { + percentiles: { [key: string]: number } + average: number +} + +export interface GatewayBackendRuntimeStatus { + name: string + chainId: number + responseTime: GatewayBackendResponseTime +} + +export interface GatewayRuntimeStatus { + healthOK: boolean + startTime: string + uptime: number + ver: string + branch: string + commitHash: string + backends: Array +} + export interface WALWriterRuntimeStatus { healthOK: boolean startTime: string @@ -207,6 +300,13 @@ export interface EtherBalance { balanceWei: string } +export interface NativeTokenBalance { + accountAddress: string + chainId: number + balance: string + error: string +} + export interface IndexState { chainId: string lastBlockNum: number @@ -260,6 +360,8 @@ export interface TokenBalance { blockHash: string blockNumber: number chainId: number + uniqueCollectibles: string + isSummary: boolean contractInfo?: ContractInfo tokenMetadata?: TokenMetadata } @@ -276,14 +378,20 @@ export interface OrderbookOrder { expiry: string orderStatus: OrderStatus createdBy: string - createdAt: number + blockNumber: number orderbookContractAddress: string + createdAt: number } export interface OrderbookOrderFilter { isListing?: boolean - userAddress?: string + userAddresses?: Array tokenIds: Array + excludeUserAddresses?: Array + afterBlockNumber: number + afterCreatedAt: number + beforeExpiry: number + userAddress?: string excludeUserAddress?: string } @@ -378,6 +486,11 @@ export interface TransactionLog { index: number } +export interface TokenIDRange { + start: string + end: string +} + export interface Page { page?: number column?: string @@ -421,34 +534,98 @@ export interface MetadataOptions { includeContracts?: Array } +export interface TokenBalancesFilter { + accountAddresses: Array + contractStatus?: ContractVerificationStatus + contractWhitelist?: Array + contractBlacklist?: Array + omitNativeBalances: boolean +} + +export interface TokenBalancesByContractFilter { + contractAddresses: Array + accountAddresses?: Array + contractStatus?: ContractVerificationStatus +} + +export interface GatewayEtherBalance { + chainId: number + error: string + result: EtherBalance +} + +export interface GatewayNativeTokenBalance { + chainId: number + error: string + result: NativeTokenBalance +} + +export interface GatewayNativeTokenBalances { + chainId: number + error: string + results: Array +} + +export interface GatewayTokenBalance { + chainId: number + error: string + results: Array +} + export interface Indexer { ping(headers?: object, signal?: AbortSignal): Promise version(headers?: object, signal?: AbortSignal): Promise runtimeStatus(headers?: object, signal?: AbortSignal): Promise getChainID(headers?: object, signal?: AbortSignal): Promise getEtherBalance(args: GetEtherBalanceArgs, headers?: object, signal?: AbortSignal): Promise + getNativeTokenBalance( + args: GetNativeTokenBalanceArgs, + headers?: object, + signal?: AbortSignal + ): Promise + getTokenBalancesSummary( + args: GetTokenBalancesSummaryArgs, + headers?: object, + signal?: AbortSignal + ): Promise + getTokenBalancesDetails( + args: GetTokenBalancesDetailsArgs, + headers?: object, + signal?: AbortSignal + ): Promise + getTokenBalancesByContract( + args: GetTokenBalancesByContractArgs, + headers?: object, + signal?: AbortSignal + ): Promise getTokenBalances(args: GetTokenBalancesArgs, headers?: object, signal?: AbortSignal): Promise getTokenSupplies(args: GetTokenSuppliesArgs, headers?: object, signal?: AbortSignal): Promise getTokenSuppliesMap(args: GetTokenSuppliesMapArgs, headers?: object, signal?: AbortSignal): Promise + getTokenIDs(args: GetTokenIDsArgs, headers?: object, signal?: AbortSignal): Promise + getTokenIDRanges(args: GetTokenIDRangesArgs, headers?: object, signal?: AbortSignal): Promise getBalanceUpdates(args: GetBalanceUpdatesArgs, headers?: object, signal?: AbortSignal): Promise getTransactionHistory( args: GetTransactionHistoryArgs, headers?: object, signal?: AbortSignal ): Promise - syncBalance(args: SyncBalanceArgs, headers?: object, signal?: AbortSignal): Promise fetchTransactionReceipt( args: FetchTransactionReceiptArgs, headers?: object, signal?: AbortSignal ): Promise - getOrderbookOrders(args: GetOrderbookOrdersArgs, headers?: object, signal?: AbortSignal): Promise - getTopOrders(args: GetTopOrdersArgs, headers?: object, signal?: AbortSignal): Promise fetchTransactionReceiptWithFilter( args: FetchTransactionReceiptWithFilterArgs, headers?: object, signal?: AbortSignal ): Promise + subscribeReceipts(args: SubscribeReceiptsArgs, options: WebrpcStreamOptions): Promise + subscribeEvents(args: SubscribeEventsArgs, options: WebrpcStreamOptions): Promise + subscribeBalanceUpdates( + args: SubscribeBalanceUpdatesArgs, + options: WebrpcStreamOptions + ): Promise + syncBalance(args: SyncBalanceArgs, headers?: object, signal?: AbortSignal): Promise getAllWebhookListeners( args: GetAllWebhookListenersArgs, headers?: object, @@ -466,6 +643,11 @@ export interface Indexer { headers?: object, signal?: AbortSignal ): Promise + removeAllWebhookListeners( + args: RemoveAllWebhookListenersArgs, + headers?: object, + signal?: AbortSignal + ): Promise toggleWebhookListener( args: ToggleWebhookListenerArgs, headers?: object, @@ -481,12 +663,8 @@ export interface Indexer { headers?: object, signal?: AbortSignal ): Promise - subscribeReceipts(args: SubscribeReceiptsArgs, options: WebrpcStreamOptions): Promise - subscribeEvents(args: SubscribeEventsArgs, options: WebrpcStreamOptions): Promise - subscribeBalanceUpdates( - args: SubscribeBalanceUpdatesArgs, - options: WebrpcStreamOptions - ): Promise + getOrderbookOrders(args: GetOrderbookOrdersArgs, headers?: object, signal?: AbortSignal): Promise + getTopOrders(args: GetTopOrdersArgs, headers?: object, signal?: AbortSignal): Promise } export interface PingArgs {} @@ -516,6 +694,45 @@ export interface GetEtherBalanceArgs { export interface GetEtherBalanceReturn { balance: EtherBalance } +export interface GetNativeTokenBalanceArgs { + accountAddress?: string +} + +export interface GetNativeTokenBalanceReturn { + balance: NativeTokenBalance +} +export interface GetTokenBalancesSummaryArgs { + filter: TokenBalancesFilter + omitMetadata?: boolean + page?: Page +} + +export interface GetTokenBalancesSummaryReturn { + page: Page + nativeBalances: Array + balances: Array +} +export interface GetTokenBalancesDetailsArgs { + filter: TokenBalancesFilter + omitMetadata?: boolean + page?: Page +} + +export interface GetTokenBalancesDetailsReturn { + page: Page + nativeBalances: Array + balances: Array +} +export interface GetTokenBalancesByContractArgs { + filter: TokenBalancesByContractFilter + omitMetadata?: boolean + page?: Page +} + +export interface GetTokenBalancesByContractReturn { + page: Page + balances: Array +} export interface GetTokenBalancesArgs { accountAddress?: string contractAddress?: string @@ -551,6 +768,25 @@ export interface GetTokenSuppliesMapArgs { export interface GetTokenSuppliesMapReturn { supplies: { [key: string]: Array } } +export interface GetTokenIDsArgs { + contractAddress: string + page?: Page +} + +export interface GetTokenIDsReturn { + page: Page + contractType: ContractType + tokenIDs: Array +} +export interface GetTokenIDRangesArgs { + contractAddress: string +} + +export interface GetTokenIDRangesReturn { + contractType: ContractType + tokenIDRanges: Array + moreRanges: boolean +} export interface GetBalanceUpdatesArgs { contractAddress: string lastBlockNumber: number @@ -573,13 +809,6 @@ export interface GetTransactionHistoryReturn { page: Page transactions: Array } -export interface SyncBalanceArgs { - accountAddress: string - contractAddress: string - tokenID?: string -} - -export interface SyncBalanceReturn {} export interface FetchTransactionReceiptArgs { txnHash: string maxBlockWait?: number @@ -588,41 +817,42 @@ export interface FetchTransactionReceiptArgs { export interface FetchTransactionReceiptReturn { receipt: TransactionReceipt } -export interface GetOrderbookOrdersArgs { - page?: Page - orderbookContractAddress: string - collectionAddress: string - currencyAddresses: Array - filters: Array - orderStatuses: Array - beforeExpiryTimestamp: number +export interface FetchTransactionReceiptWithFilterArgs { + filter: TransactionFilter + maxBlockWait?: number } -export interface GetOrderbookOrdersReturn { - page?: Page - orders: Array +export interface FetchTransactionReceiptWithFilterReturn { + receipt: TransactionReceipt } -export interface GetTopOrdersArgs { - orderbookContractAddress: string - collectionAddress: string - currencyAddresses: Array - tokenIDs: Array - isListing: boolean - priceSort: SortOrder - excludeUser?: string +export interface SubscribeReceiptsArgs { + filter: TransactionFilter } -export interface GetTopOrdersReturn { - orders: Array +export interface SubscribeReceiptsReturn { + receipt: TransactionReceipt } -export interface FetchTransactionReceiptWithFilterArgs { - filter: TransactionFilter - maxBlockWait?: number +export interface SubscribeEventsArgs { + filter: EventFilter } -export interface FetchTransactionReceiptWithFilterReturn { - receipt: TransactionReceipt +export interface SubscribeEventsReturn { + log: EventLog +} +export interface SubscribeBalanceUpdatesArgs { + contractAddress: string +} + +export interface SubscribeBalanceUpdatesReturn { + balance: TokenBalance +} +export interface SyncBalanceArgs { + accountAddress: string + contractAddress: string + tokenID?: string } + +export interface SyncBalanceReturn {} export interface GetAllWebhookListenersArgs { projectId?: number } @@ -664,6 +894,13 @@ export interface RemoveWebhookListenerArgs { export interface RemoveWebhookListenerReturn { status: boolean } +export interface RemoveAllWebhookListenersArgs { + projectId?: number +} + +export interface RemoveAllWebhookListenersReturn { + status: boolean +} export interface ToggleWebhookListenerArgs { id: number projectId?: number @@ -686,26 +923,35 @@ export interface ResumeAllWebhookListenersArgs { export interface ResumeAllWebhookListenersReturn { status: boolean } -export interface SubscribeReceiptsArgs { - filter: TransactionFilter -} - -export interface SubscribeReceiptsReturn { - receipt: TransactionReceipt -} -export interface SubscribeEventsArgs { - filter: EventFilter +export interface GetOrderbookOrdersArgs { + page?: Page + orderbookContractAddress: string + collectionAddress: string + currencyAddresses: Array + filter: OrderbookOrderFilter + orderStatuses: Array + filters: Array + beforeExpiryTimestamp: number + blockNumberAfter: number + createdAtAfter: number } -export interface SubscribeEventsReturn { - log: EventLog +export interface GetOrderbookOrdersReturn { + page?: Page + orders: Array } -export interface SubscribeBalanceUpdatesArgs { - contractAddress: string +export interface GetTopOrdersArgs { + orderbookContractAddress: string + collectionAddress: string + currencyAddresses: Array + tokenIDs: Array + isListing: boolean + priceSort: SortOrder + excludeUser?: string } -export interface SubscribeBalanceUpdatesReturn { - balance: TokenBalance +export interface GetTopOrdersReturn { + orders: Array } // @@ -717,7 +963,7 @@ export class Indexer implements Indexer { protected path = '/rpc/Indexer/' constructor(hostname: string, fetch: Fetch) { - this.hostname = hostname + this.hostname = hostname.replace(/\/*$/, '') this.fetch = (input: RequestInfo, init?: RequestInit) => fetch(input, init) } @@ -800,13 +1046,16 @@ export class Indexer implements Indexer { ) } - getTokenBalances = (args: GetTokenBalancesArgs, headers?: object, signal?: AbortSignal): Promise => { - return this.fetch(this.url('GetTokenBalances'), createHTTPRequest(args, headers, signal)).then( + getNativeTokenBalance = ( + args: GetNativeTokenBalanceArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('GetNativeTokenBalance'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { return { - page: _data.page, - balances: >_data.balances + balance: _data.balance } }) }, @@ -816,14 +1065,18 @@ export class Indexer implements Indexer { ) } - getTokenSupplies = (args: GetTokenSuppliesArgs, headers?: object, signal?: AbortSignal): Promise => { - return this.fetch(this.url('GetTokenSupplies'), createHTTPRequest(args, headers, signal)).then( + getTokenBalancesSummary = ( + args: GetTokenBalancesSummaryArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('GetTokenBalancesSummary'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { return { page: _data.page, - contractType: _data.contractType, - tokenIDs: >_data.tokenIDs + nativeBalances: >_data.nativeBalances, + balances: >_data.balances } }) }, @@ -833,16 +1086,18 @@ export class Indexer implements Indexer { ) } - getTokenSuppliesMap = ( - args: GetTokenSuppliesMapArgs, + getTokenBalancesDetails = ( + args: GetTokenBalancesDetailsArgs, headers?: object, signal?: AbortSignal - ): Promise => { - return this.fetch(this.url('GetTokenSuppliesMap'), createHTTPRequest(args, headers, signal)).then( + ): Promise => { + return this.fetch(this.url('GetTokenBalancesDetails'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { return { - supplies: <{ [key: string]: Array }>_data.supplies + page: _data.page, + nativeBalances: >_data.nativeBalances, + balances: >_data.balances } }) }, @@ -852,8 +1107,12 @@ export class Indexer implements Indexer { ) } - getBalanceUpdates = (args: GetBalanceUpdatesArgs, headers?: object, signal?: AbortSignal): Promise => { - return this.fetch(this.url('GetBalanceUpdates'), createHTTPRequest(args, headers, signal)).then( + getTokenBalancesByContract = ( + args: GetTokenBalancesByContractArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('GetTokenBalancesByContract'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { return { @@ -868,17 +1127,13 @@ export class Indexer implements Indexer { ) } - getTransactionHistory = ( - args: GetTransactionHistoryArgs, - headers?: object, - signal?: AbortSignal - ): Promise => { - return this.fetch(this.url('GetTransactionHistory'), createHTTPRequest(args, headers, signal)).then( + getTokenBalances = (args: GetTokenBalancesArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('GetTokenBalances'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { return { page: _data.page, - transactions: >_data.transactions + balances: >_data.balances } }) }, @@ -888,11 +1143,15 @@ export class Indexer implements Indexer { ) } - syncBalance = (args: SyncBalanceArgs, headers?: object, signal?: AbortSignal): Promise => { - return this.fetch(this.url('SyncBalance'), createHTTPRequest(args, headers, signal)).then( + getTokenSupplies = (args: GetTokenSuppliesArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('GetTokenSupplies'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { - return {} + return { + page: _data.page, + contractType: _data.contractType, + tokenIDs: >_data.tokenIDs + } }) }, error => { @@ -901,16 +1160,16 @@ export class Indexer implements Indexer { ) } - fetchTransactionReceipt = ( - args: FetchTransactionReceiptArgs, + getTokenSuppliesMap = ( + args: GetTokenSuppliesMapArgs, headers?: object, signal?: AbortSignal - ): Promise => { - return this.fetch(this.url('FetchTransactionReceipt'), createHTTPRequest(args, headers, signal)).then( + ): Promise => { + return this.fetch(this.url('GetTokenSuppliesMap'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { return { - receipt: _data.receipt + supplies: <{ [key: string]: Array }>_data.supplies } }) }, @@ -920,17 +1179,67 @@ export class Indexer implements Indexer { ) } - getOrderbookOrders = ( - args: GetOrderbookOrdersArgs, + getTokenIDs = (args: GetTokenIDsArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('GetTokenIDs'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + page: _data.page, + contractType: _data.contractType, + tokenIDs: >_data.tokenIDs + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + getTokenIDRanges = (args: GetTokenIDRangesArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('GetTokenIDRanges'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + contractType: _data.contractType, + tokenIDRanges: >_data.tokenIDRanges, + moreRanges: _data.moreRanges + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + getBalanceUpdates = (args: GetBalanceUpdatesArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('GetBalanceUpdates'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + page: _data.page, + balances: >_data.balances + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + getTransactionHistory = ( + args: GetTransactionHistoryArgs, headers?: object, signal?: AbortSignal - ): Promise => { - return this.fetch(this.url('GetOrderbookOrders'), createHTTPRequest(args, headers, signal)).then( + ): Promise => { + return this.fetch(this.url('GetTransactionHistory'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { return { page: _data.page, - orders: >_data.orders + transactions: >_data.transactions } }) }, @@ -940,12 +1249,16 @@ export class Indexer implements Indexer { ) } - getTopOrders = (args: GetTopOrdersArgs, headers?: object, signal?: AbortSignal): Promise => { - return this.fetch(this.url('GetTopOrders'), createHTTPRequest(args, headers, signal)).then( + fetchTransactionReceipt = ( + args: FetchTransactionReceiptArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('FetchTransactionReceipt'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { return { - orders: >_data.orders + receipt: _data.receipt } }) }, @@ -974,6 +1287,58 @@ export class Indexer implements Indexer { ) } + subscribeReceipts = (args: SubscribeReceiptsArgs, options: WebrpcStreamOptions): Promise => { + const _fetch = () => + this.fetch(this.url('SubscribeReceipts'), createHTTPRequest(args, options.headers, options.signal)).then( + async res => { + await sseResponse(res, options, _fetch) + }, + error => { + options.onError(error, _fetch) + } + ) + return _fetch() + } + subscribeEvents = (args: SubscribeEventsArgs, options: WebrpcStreamOptions): Promise => { + const _fetch = () => + this.fetch(this.url('SubscribeEvents'), createHTTPRequest(args, options.headers, options.signal)).then( + async res => { + await sseResponse(res, options, _fetch) + }, + error => { + options.onError(error, _fetch) + } + ) + return _fetch() + } + subscribeBalanceUpdates = ( + args: SubscribeBalanceUpdatesArgs, + options: WebrpcStreamOptions + ): Promise => { + const _fetch = () => + this.fetch(this.url('SubscribeBalanceUpdates'), createHTTPRequest(args, options.headers, options.signal)).then( + async res => { + await sseResponse(res, options, _fetch) + }, + error => { + options.onError(error, _fetch) + } + ) + return _fetch() + } + syncBalance = (args: SyncBalanceArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('SyncBalance'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return {} + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + getAllWebhookListeners = ( args: GetAllWebhookListenersArgs, headers?: object, @@ -1070,6 +1435,25 @@ export class Indexer implements Indexer { ) } + removeAllWebhookListeners = ( + args: RemoveAllWebhookListenersArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('RemoveAllWebhookListeners'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + status: _data.status + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + toggleWebhookListener = ( args: ToggleWebhookListenerArgs, headers?: object, @@ -1127,44 +1511,39 @@ export class Indexer implements Indexer { ) } - subscribeReceipts = (args: SubscribeReceiptsArgs, options: WebrpcStreamOptions): Promise => { - const _fetch = () => - this.fetch(this.url('SubscribeReceipts'), createHTTPRequest(args, options.headers, options.signal)).then( - async res => { - await sseResponse(res, options, _fetch) - }, - error => { - options.onError(error, _fetch) - } - ) - return _fetch() - } - subscribeEvents = (args: SubscribeEventsArgs, options: WebrpcStreamOptions): Promise => { - const _fetch = () => - this.fetch(this.url('SubscribeEvents'), createHTTPRequest(args, options.headers, options.signal)).then( - async res => { - await sseResponse(res, options, _fetch) - }, - error => { - options.onError(error, _fetch) - } - ) - return _fetch() + getOrderbookOrders = ( + args: GetOrderbookOrdersArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('GetOrderbookOrders'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + page: _data.page, + orders: >_data.orders + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) } - subscribeBalanceUpdates = ( - args: SubscribeBalanceUpdatesArgs, - options: WebrpcStreamOptions - ): Promise => { - const _fetch = () => - this.fetch(this.url('SubscribeBalanceUpdates'), createHTTPRequest(args, options.headers, options.signal)).then( - async res => { - await sseResponse(res, options, _fetch) - }, - error => { - options.onError(error, _fetch) - } - ) - return _fetch() + + getTopOrders = (args: GetTopOrdersArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('GetTopOrders'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + orders: >_data.orders + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) } } @@ -1199,103 +1578,97 @@ const sseResponse = async (res: Response, options: WebrpcStreamOptions, ret let buffer = '' let lastReadTime = Date.now() const timeout = (10 + 1) * 1000 - let intervalId: any - - try { - intervalId = setInterval(() => { - if (Date.now() - lastReadTime > timeout) { - throw WebrpcStreamLostError.new({ cause: 'Stream timed out' }) - } - }, timeout) - - while (true) { - let value - let done - try { - ;({ value, done } = await reader.read()) - lastReadTime = Date.now() - buffer += decoder.decode(value, { stream: true }) - } catch (error) { - let message = '' - if (error instanceof Error) { - message = error.message - } + let timeoutError = false + const intervalId = setInterval(() => { + if (Date.now() - lastReadTime > timeout) { + timeoutError = true + clearInterval(intervalId) + reader.releaseLock() + } + }, timeout) - if (error instanceof DOMException && error.name === 'AbortError') { - onError( - WebrpcRequestFailedError.new({ - message: 'AbortError', - cause: `AbortError: ${message}` - }), - () => { - throw new Error('Abort signal cannot be used to reconnect') - } - ) - } else { - onError( - WebrpcStreamLostError.new({ - cause: `reader.read(): ${message}` - }), - retryFetch - ) - } - return + while (true) { + let value + let done + try { + ;({ value, done } = await reader.read()) + if (timeoutError) throw new Error('Timeout, no data or heartbeat received') + lastReadTime = Date.now() + buffer += decoder.decode(value, { stream: true }) + } catch (error) { + let message = '' + if (error instanceof Error) { + message = error.message } - let lines = buffer.split('\n') - for (let i = 0; i < lines.length - 1; i++) { - if (lines[i].length == 0) { - continue - } - let data: any - try { - data = JSON.parse(lines[i]) - if (data.hasOwnProperty('webrpcError')) { - const error = data.webrpcError - const code: number = typeof error.code === 'number' ? error.code : 0 - onError((webrpcErrorByCode[code] || WebrpcError).new(error), retryFetch) - return + if (error instanceof DOMException && error.name === 'AbortError') { + onError( + WebrpcRequestFailedError.new({ + message: 'AbortError', + cause: `AbortError: ${message}` + }), + () => { + throw new Error('Abort signal cannot be used to reconnect') } - } catch (error) { - if (error instanceof Error && error.message === 'Abort signal cannot be used to reconnect') { - throw error - } - onError( - WebrpcBadResponseError.new({ - status: res.status, - // @ts-ignore - cause: `JSON.parse(): ${error.message}` - }), - retryFetch - ) - } - onMessage(data) + ) + } else { + onError( + WebrpcStreamLostError.new({ + cause: `reader.read(): ${message}` + }), + retryFetch + ) } + return + } - if (!done) { - buffer = lines[lines.length - 1] + let lines = buffer.split('\n') + for (let i = 0; i < lines.length - 1; i++) { + if (lines[i].length == 0) { continue } - - onClose && onClose() - return + let data: any + try { + data = JSON.parse(lines[i]) + if (data.hasOwnProperty('webrpcError')) { + const error = data.webrpcError + const code: number = typeof error.code === 'number' ? error.code : 0 + onError((webrpcErrorByCode[code] || WebrpcError).new(error), retryFetch) + return + } + } catch (error) { + if (error instanceof Error && error.message === 'Abort signal cannot be used to reconnect') { + throw error + } + onError( + WebrpcBadResponseError.new({ + status: res.status, + // @ts-ignore + cause: `JSON.parse(): ${error.message}` + }), + retryFetch + ) + } + onMessage(data) } - } catch (error) { - // @ts-ignore - if (error instanceof WebrpcStreamLostError) { - onError(error, retryFetch) - } else { - throw error + + if (!done) { + buffer = lines[lines.length - 1] + continue } - } finally { - clearInterval(intervalId) + + onClose && onClose() + return } } const createHTTPRequest = (body: object = {}, headers: object = {}, signal: AbortSignal | null = null): object => { + const reqHeaders: { [key: string]: string } = { ...headers, 'Content-Type': 'application/json' } + reqHeaders[WebrpcHeader] = WebrpcHeaderValue + return { method: 'POST', - headers: { ...headers, 'Content-Type': 'application/json' }, + headers: reqHeaders, body: JSON.stringify(body || {}), signal } @@ -1579,10 +1952,179 @@ export class AbortedError extends WebrpcError { } } +export class GeoblockedError extends WebrpcError { + constructor( + name: string = 'Geoblocked', + code: number = 1006, + message: string = 'Geoblocked region', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, GeoblockedError.prototype) + } +} + +export class RateLimitedError extends WebrpcError { + constructor( + name: string = 'RateLimited', + code: number = 1007, + message: string = 'Rate-limited. Please slow down.', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, RateLimitedError.prototype) + } +} + +export class ProjectNotFoundError extends WebrpcError { + constructor( + name: string = 'ProjectNotFound', + code: number = 1100, + message: string = 'Project not found', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, ProjectNotFoundError.prototype) + } +} + +export class AccessKeyNotFoundError extends WebrpcError { + constructor( + name: string = 'AccessKeyNotFound', + code: number = 1101, + message: string = 'Access key not found', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, AccessKeyNotFoundError.prototype) + } +} + +export class AccessKeyMismatchError extends WebrpcError { + constructor( + name: string = 'AccessKeyMismatch', + code: number = 1102, + message: string = 'Access key mismatch', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, AccessKeyMismatchError.prototype) + } +} + +export class InvalidOriginError extends WebrpcError { + constructor( + name: string = 'InvalidOrigin', + code: number = 1103, + message: string = 'Invalid origin for Access Key', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, InvalidOriginError.prototype) + } +} + +export class InvalidServiceError extends WebrpcError { + constructor( + name: string = 'InvalidService', + code: number = 1104, + message: string = 'Service not enabled for Access key', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, InvalidServiceError.prototype) + } +} + +export class UnauthorizedUserError extends WebrpcError { + constructor( + name: string = 'UnauthorizedUser', + code: number = 1105, + message: string = 'Unauthorized user', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, UnauthorizedUserError.prototype) + } +} + +export class QuotaExceededError extends WebrpcError { + constructor( + name: string = 'QuotaExceeded', + code: number = 1200, + message: string = 'Quota exceeded', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, QuotaExceededError.prototype) + } +} + +export class RateLimitError extends WebrpcError { + constructor( + name: string = 'RateLimit', + code: number = 1201, + message: string = 'Rate limit exceeded', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, RateLimitError.prototype) + } +} + +export class NoDefaultKeyError extends WebrpcError { + constructor( + name: string = 'NoDefaultKey', + code: number = 1300, + message: string = 'No default access key found', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, NoDefaultKeyError.prototype) + } +} + +export class MaxAccessKeysError extends WebrpcError { + constructor( + name: string = 'MaxAccessKeys', + code: number = 1301, + message: string = 'Access keys limit reached', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, MaxAccessKeysError.prototype) + } +} + +export class AtLeastOneKeyError extends WebrpcError { + constructor( + name: string = 'AtLeastOneKey', + code: number = 1302, + message: string = 'You need at least one Access Key', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, AtLeastOneKeyError.prototype) + } +} + export class TimeoutError extends WebrpcError { constructor( name: string = 'Timeout', - code: number = 2000, + code: number = 1900, message: string = 'Request timed out', status: number = 0, cause?: string @@ -1657,19 +2199,6 @@ export class NotFoundError extends WebrpcError { } } -export class ProjectNotFoundError extends WebrpcError { - constructor( - name: string = 'ProjectNotFound', - code: number = 3002, - message: string = 'Project not found', - status: number = 0, - cause?: string - ) { - super(name, code, message, status, cause) - Object.setPrototypeOf(this, ProjectNotFoundError.prototype) - } -} - export class MetadataCallFailedError extends WebrpcError { constructor( name: string = 'MetadataCallFailed', @@ -1701,13 +2230,25 @@ export enum errors { MethodNotFound = 'MethodNotFound', RequestConflict = 'RequestConflict', Aborted = 'Aborted', + Geoblocked = 'Geoblocked', + RateLimited = 'RateLimited', + ProjectNotFound = 'ProjectNotFound', + AccessKeyNotFound = 'AccessKeyNotFound', + AccessKeyMismatch = 'AccessKeyMismatch', + InvalidOrigin = 'InvalidOrigin', + InvalidService = 'InvalidService', + UnauthorizedUser = 'UnauthorizedUser', + QuotaExceeded = 'QuotaExceeded', + RateLimit = 'RateLimit', + NoDefaultKey = 'NoDefaultKey', + MaxAccessKeys = 'MaxAccessKeys', + AtLeastOneKey = 'AtLeastOneKey', Timeout = 'Timeout', InvalidArgument = 'InvalidArgument', Unavailable = 'Unavailable', QueryFailed = 'QueryFailed', ResourceExhausted = 'ResourceExhausted', NotFound = 'NotFound', - ProjectNotFound = 'ProjectNotFound', MetadataCallFailed = 'MetadataCallFailed' } @@ -1729,13 +2270,25 @@ const webrpcErrorByCode: { [code: number]: any } = { [1003]: MethodNotFoundError, [1004]: RequestConflictError, [1005]: AbortedError, - [2000]: TimeoutError, + [1006]: GeoblockedError, + [1007]: RateLimitedError, + [1100]: ProjectNotFoundError, + [1101]: AccessKeyNotFoundError, + [1102]: AccessKeyMismatchError, + [1103]: InvalidOriginError, + [1104]: InvalidServiceError, + [1105]: UnauthorizedUserError, + [1200]: QuotaExceededError, + [1201]: RateLimitError, + [1300]: NoDefaultKeyError, + [1301]: MaxAccessKeysError, + [1302]: AtLeastOneKeyError, + [1900]: TimeoutError, [2001]: InvalidArgumentError, [2002]: UnavailableError, [2003]: QueryFailedError, [2004]: ResourceExhaustedError, [3000]: NotFoundError, - [3002]: ProjectNotFoundError, [3003]: MetadataCallFailedError } diff --git a/packages/indexer/src/indexergw.gen.ts b/packages/indexer/src/indexergw.gen.ts new file mode 100644 index 000000000..b29503b2e --- /dev/null +++ b/packages/indexer/src/indexergw.gen.ts @@ -0,0 +1,1501 @@ +/* eslint-disable */ +// sequence-indexer v0.4.0 add72cb0593b5cfe4fe87445d214168af60601d4 +// -- +// Code generated by webrpc-gen@v0.21.1 with typescript generator. DO NOT EDIT. +// +// webrpc-gen -schema=indexer.ridl -service=IndexerGateway -target=typescript -client -out=./clients/indexergw.gen.ts + +export const WebrpcHeader = 'Webrpc' + +export const WebrpcHeaderValue = 'webrpc@v0.21.1;gen-typescript@v0.15.1;sequence-indexer@v0.4.0' + +// WebRPC description and code-gen version +export const WebRPCVersion = 'v1' + +// Schema version of your RIDL schema +export const WebRPCSchemaVersion = 'v0.4.0' + +// Schema hash generated from your RIDL schema +export const WebRPCSchemaHash = 'add72cb0593b5cfe4fe87445d214168af60601d4' + +type WebrpcGenVersions = { + webrpcGenVersion: string + codeGenName: string + codeGenVersion: string + schemaName: string + schemaVersion: string +} + +export function VersionFromHeader(headers: Headers): WebrpcGenVersions { + const headerValue = headers.get(WebrpcHeader) + if (!headerValue) { + return { + webrpcGenVersion: '', + codeGenName: '', + codeGenVersion: '', + schemaName: '', + schemaVersion: '' + } + } + + return parseWebrpcGenVersions(headerValue) +} + +function parseWebrpcGenVersions(header: string): WebrpcGenVersions { + const versions = header.split(';') + if (versions.length < 3) { + return { + webrpcGenVersion: '', + codeGenName: '', + codeGenVersion: '', + schemaName: '', + schemaVersion: '' + } + } + + const [_, webrpcGenVersion] = versions[0].split('@') + const [codeGenName, codeGenVersion] = versions[1].split('@') + const [schemaName, schemaVersion] = versions[2].split('@') + + return { + webrpcGenVersion, + codeGenName, + codeGenVersion, + schemaName, + schemaVersion + } +} + +// +// Types +// + +export enum ResourceStatus { + NOT_AVAILABLE = 'NOT_AVAILABLE', + STALE = 'STALE', + AVAILABLE = 'AVAILABLE' +} + +export interface ContractInfo { + chainId: number + address: string + name: string + type: string + symbol: string + decimals?: number + logoURI: string + deployed: boolean + bytecodeHash: string + extensions: ContractInfoExtensions + updatedAt: string + notFound: boolean + queuedAt?: string + status: ResourceStatus +} + +export interface ContractInfoExtensions { + link: string + description: string + categories: Array + ogImage: string + ogName: string + originChainId: number + originAddress: string + blacklist: boolean + verified: boolean + verifiedBy: string + featured: boolean +} + +export interface TokenMetadata { + tokenId: string + name: string + description?: string + image?: string + video?: string + audio?: string + properties?: { [key: string]: any } + attributes: Array<{ [key: string]: any }> + image_data?: string + external_url?: string + background_color?: string + animation_url?: string + decimals?: number + updatedAt?: string + assets?: Array + status: ResourceStatus + queuedAt?: string + lastFetched?: string +} + +export interface Asset { + id: number + collectionId: number + tokenId?: string + url?: string + metadataField: string + name?: string + filesize?: number + mimeType?: string + width?: number + height?: number + updatedAt?: string +} + +export enum ContractType { + UNKNOWN = 'UNKNOWN', + NATIVE = 'NATIVE', + ERC20 = 'ERC20', + ERC721 = 'ERC721', + ERC1155 = 'ERC1155', + SEQUENCE_WALLET = 'SEQUENCE_WALLET', + ERC20_BRIDGE = 'ERC20_BRIDGE', + ERC721_BRIDGE = 'ERC721_BRIDGE', + ERC1155_BRIDGE = 'ERC1155_BRIDGE', + SEQ_MARKETPLACE = 'SEQ_MARKETPLACE' +} + +export enum EventLogType { + UNKNOWN = 'UNKNOWN', + BLOCK_ADDED = 'BLOCK_ADDED', + BLOCK_REMOVED = 'BLOCK_REMOVED' +} + +export enum EventLogDataType { + EVENT = 'EVENT', + TOKEN_TRANSFER = 'TOKEN_TRANSFER', + NATIVE_TOKEN_TRANSFER = 'NATIVE_TOKEN_TRANSFER', + SEQUENCE_TXN = 'SEQUENCE_TXN' +} + +export enum OrderStatus { + OPEN = 'OPEN', + CLOSED = 'CLOSED', + CANCELLED = 'CANCELLED' +} + +export enum TxnTransferType { + UNKNOWN = 'UNKNOWN', + SEND = 'SEND', + RECEIVE = 'RECEIVE' +} + +export enum TransactionStatus { + FAILED = 'FAILED', + SUCCESSFUL = 'SUCCESSFUL' +} + +export enum TransactionType { + LegacyTxnType = 'LegacyTxnType', + AccessListTxnType = 'AccessListTxnType', + DynamicFeeTxnType = 'DynamicFeeTxnType' +} + +export enum SortOrder { + DESC = 'DESC', + ASC = 'ASC' +} + +export enum ContractVerificationStatus { + VERIFIED = 'VERIFIED', + UNVERIFIED = 'UNVERIFIED', + ALL = 'ALL' +} + +export interface Version { + webrpcVersion: string + schemaVersion: string + schemaHash: string + appVersion: string +} + +export interface RuntimeStatus { + healthOK: boolean + indexerEnabled: boolean + startTime: string + uptime: number + ver: string + branch: string + commitHash: string + chainID: number + checks: RuntimeChecks +} + +export interface GatewayBackendResponseTime { + percentiles: { [key: string]: number } + average: number +} + +export interface GatewayBackendRuntimeStatus { + name: string + chainId: number + responseTime: GatewayBackendResponseTime +} + +export interface GatewayRuntimeStatus { + healthOK: boolean + startTime: string + uptime: number + ver: string + branch: string + commitHash: string + backends: Array +} + +export interface WALWriterRuntimeStatus { + healthOK: boolean + startTime: string + uptime: number + ver: string + branch: string + commitHash: string + chainID: number + percentWALWritten: number +} + +export interface RuntimeChecks { + running: boolean + runnables: any + cgoEnabled: boolean + quotaControlEnabled: boolean + syncMode: string + percentIndexed: number + lastBlockNum: number + lastBlockNumWithState: number + bloomStatus: BloomStatus + bond: Bond + diskUsage: DiskUsage +} + +export interface DiskUsage { + humanReadable: string + used: number + size: number + percent: number + dirs: { [key: string]: string } +} + +export interface Bond { + pebble: PebbleMetrics + estimatedDiskUsagePerTable: any + estimatedDiskUsageTotal: string +} + +export interface PebbleMetrics { + compactionCount: number + compactionEstimatedDebt: number + compactionInProgressBytes: number + compactionNumInProgress: number + compactionMarkedFiles: number +} + +export interface BloomStatus { + enabled: boolean + initialized: boolean + bloomInitElapsedTime: string +} + +export interface EtherBalance { + accountAddress: string + balanceWei: string +} + +export interface NativeTokenBalance { + accountAddress: string + chainId: number + balance: string + error: string +} + +export interface IndexState { + chainId: string + lastBlockNum: number + lastBlockHash: string +} + +export interface IndexedBlock { + blockNumber: number + blockShortHash: string +} + +export interface TxnInfo { + from: string + to: string + value: string +} + +export interface EventLog { + id: number + uid: string + type: EventLogType + blockNumber: number + blockHash: string + parentBlockHash: string + contractAddress: string + contractType: ContractType + txnHash: string + txnIndex: number + txnLogIndex: number + logDataType: EventLogDataType + ts: string + txnInfo?: TxnInfo + rawLog?: { [key: string]: any } + event?: EventDecoded +} + +export interface EventDecoded { + topicHash: string + eventSig: string + types: Array + names: Array + values: Array +} + +export interface TokenBalance { + contractType: ContractType + contractAddress: string + accountAddress: string + tokenID?: string + balance: string + blockHash: string + blockNumber: number + chainId: number + uniqueCollectibles: string + isSummary: boolean + contractInfo?: ContractInfo + tokenMetadata?: TokenMetadata +} + +export interface OrderbookOrder { + orderId: string + tokenContract: string + tokenId: string + isListing: boolean + quantity: string + quantityRemaining: string + currencyAddress: string + pricePerToken: string + expiry: string + orderStatus: OrderStatus + createdBy: string + blockNumber: number + orderbookContractAddress: string + createdAt: number +} + +export interface OrderbookOrderFilter { + isListing?: boolean + userAddresses?: Array + tokenIds: Array + excludeUserAddresses?: Array + afterBlockNumber: number + afterCreatedAt: number + beforeExpiry: number + userAddress?: string + excludeUserAddress?: string +} + +export interface TokenHistory { + blockNumber: number + blockHash: string + accountAddress: string + contractAddress: string + contractType: ContractType + fromAddress: string + toAddress: string + txnHash: string + txnIndex: number + txnLogIndex: number + logData: string + tokenIDs: string + Amounts: string + ts: string +} + +export interface TokenSupply { + tokenID: string + supply: string + chainId: number + contractInfo?: ContractInfo + tokenMetadata?: TokenMetadata +} + +export interface Transaction { + txnHash: string + blockNumber: number + blockHash: string + chainId: number + metaTxnID?: string + transfers?: Array + timestamp: string +} + +export interface TxnTransfer { + transferType: TxnTransferType + contractAddress: string + contractType: ContractType + from: string + to: string + tokenIds?: Array + amounts: Array + logIndex: number + contractInfo?: ContractInfo + tokenMetadata?: { [key: string]: TokenMetadata } +} + +export interface TransactionHistoryFilter { + accountAddress?: string + contractAddress?: string + accountAddresses?: Array + contractAddresses?: Array + transactionHashes?: Array + metaTransactionIDs?: Array + fromBlock?: number + toBlock?: number + tokenID?: string +} + +export interface TransactionFilter { + txnHash?: string + from?: string + to?: string + contractAddress?: string + event?: string +} + +export interface TransactionReceipt { + txnHash: string + txnStatus: TransactionStatus + txnIndex: number + txnType: TransactionType + blockHash: string + blockNumber: number + gasUsed: number + effectiveGasPrice: string + from: string + to: string + logs: Array + final: boolean + reorged: boolean +} + +export interface TransactionLog { + contractAddress: string + topics: Array + data: string + index: number +} + +export interface TokenIDRange { + start: string + end: string +} + +export interface Page { + page?: number + column?: string + before?: any + after?: any + sort?: Array + pageSize?: number + more?: boolean +} + +export interface SortBy { + column: string + order: SortOrder +} + +export interface WebhookListener { + id: number + projectID: number + url: string + filters: EventFilter + name: string + updatedAt: string + active: boolean +} + +export interface EventFilter { + events?: Array + contractAddresses?: Array + accounts?: Array + tokenIDs?: Array +} + +export interface TokenBalanceFilter { + contractAddress: string + sinceBlockNumber: number +} + +export interface MetadataOptions { + verifiedOnly?: boolean + unverifiedOnly?: boolean + includeContracts?: Array +} + +export interface TokenBalancesFilter { + accountAddresses: Array + contractStatus?: ContractVerificationStatus + contractWhitelist?: Array + contractBlacklist?: Array + omitNativeBalances: boolean +} + +export interface TokenBalancesByContractFilter { + contractAddresses: Array + accountAddresses?: Array + contractStatus?: ContractVerificationStatus +} + +export interface GatewayEtherBalance { + chainId: number + error: string + result: EtherBalance +} + +export interface GatewayNativeTokenBalance { + chainId: number + error: string + result: NativeTokenBalance +} + +export interface GatewayNativeTokenBalances { + chainId: number + error: string + results: Array +} + +export interface GatewayTokenBalance { + chainId: number + error: string + results: Array +} + +export interface IndexerGateway { + getNativeTokenBalance( + args: GetNativeTokenBalanceArgs, + headers?: object, + signal?: AbortSignal + ): Promise + getTokenBalances(args: GetTokenBalancesArgs, headers?: object, signal?: AbortSignal): Promise + getTokenBalancesSummary( + args: GetTokenBalancesSummaryArgs, + headers?: object, + signal?: AbortSignal + ): Promise + getTokenBalancesDetails( + args: GetTokenBalancesDetailsArgs, + headers?: object, + signal?: AbortSignal + ): Promise + getTokenBalancesByContract( + args: GetTokenBalancesByContractArgs, + headers?: object, + signal?: AbortSignal + ): Promise + getBalanceUpdates(args: GetBalanceUpdatesArgs, headers?: object, signal?: AbortSignal): Promise + ping(headers?: object, signal?: AbortSignal): Promise + version(headers?: object, signal?: AbortSignal): Promise + runtimeStatus(headers?: object, signal?: AbortSignal): Promise +} + +export interface GetNativeTokenBalanceArgs { + chainIds?: Array + networks?: Array + accountAddress?: string +} + +export interface GetNativeTokenBalanceReturn { + balances: Array +} +export interface GetTokenBalancesArgs { + chainIds?: Array + networks?: Array + accountAddress?: string + contractAddress?: string + tokenID?: string + includeMetadata?: boolean + metadataOptions?: MetadataOptions + includeCollectionTokens?: boolean + page?: Page +} + +export interface GetTokenBalancesReturn { + page: Page + balances: Array +} +export interface GetTokenBalancesSummaryArgs { + chainIds?: Array + networks?: Array + filter: TokenBalancesFilter + omitMetadata?: boolean + page?: Page +} + +export interface GetTokenBalancesSummaryReturn { + page: Page + nativeBalances: Array + balances: Array +} +export interface GetTokenBalancesDetailsArgs { + chainIds?: Array + networks?: Array + filter: TokenBalancesFilter + omitMetadata?: boolean + page?: Page +} + +export interface GetTokenBalancesDetailsReturn { + page: Page + nativeBalances: Array + balances: Array +} +export interface GetTokenBalancesByContractArgs { + chainIds?: Array + networks?: Array + filter: TokenBalancesByContractFilter + omitMetadata?: boolean + page?: Page +} + +export interface GetTokenBalancesByContractReturn { + page: Page + balances: Array +} +export interface GetBalanceUpdatesArgs { + chainIds?: Array + networks?: Array + contractAddress: string + lastBlockNumber: number + lastBlockHash?: string + page?: Page +} + +export interface GetBalanceUpdatesReturn { + page: Page + balances: Array +} +export interface PingArgs {} + +export interface PingReturn { + status: boolean +} +export interface VersionArgs {} + +export interface VersionReturn { + version: Version +} +export interface RuntimeStatusArgs {} + +export interface RuntimeStatusReturn { + status: GatewayRuntimeStatus +} + +// +// Client +// +export class IndexerGateway implements IndexerGateway { + protected hostname: string + protected fetch: Fetch + protected path = '/rpc/IndexerGateway/' + + constructor(hostname: string, fetch: Fetch) { + this.hostname = hostname.replace(/\/*$/, '') + this.fetch = (input: RequestInfo, init?: RequestInit) => fetch(input, init) + } + + private url(name: string): string { + return this.hostname + this.path + name + } + + getNativeTokenBalance = ( + args: GetNativeTokenBalanceArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('GetNativeTokenBalance'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + balances: >_data.balances + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + getTokenBalances = (args: GetTokenBalancesArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('GetTokenBalances'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + page: _data.page, + balances: >_data.balances + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + getTokenBalancesSummary = ( + args: GetTokenBalancesSummaryArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('GetTokenBalancesSummary'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + page: _data.page, + nativeBalances: >_data.nativeBalances, + balances: >_data.balances + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + getTokenBalancesDetails = ( + args: GetTokenBalancesDetailsArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('GetTokenBalancesDetails'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + page: _data.page, + nativeBalances: >_data.nativeBalances, + balances: >_data.balances + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + getTokenBalancesByContract = ( + args: GetTokenBalancesByContractArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('GetTokenBalancesByContract'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + page: _data.page, + balances: >_data.balances + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + getBalanceUpdates = (args: GetBalanceUpdatesArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('GetBalanceUpdates'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + page: _data.page, + balances: >_data.balances + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + ping = (headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('Ping'), createHTTPRequest({}, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + status: _data.status + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + version = (headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('Version'), createHTTPRequest({}, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + version: _data.version + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + runtimeStatus = (headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('RuntimeStatus'), createHTTPRequest({}, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + status: _data.status + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } +} + +const createHTTPRequest = (body: object = {}, headers: object = {}, signal: AbortSignal | null = null): object => { + const reqHeaders: { [key: string]: string } = { ...headers, 'Content-Type': 'application/json' } + reqHeaders[WebrpcHeader] = WebrpcHeaderValue + + return { + method: 'POST', + headers: reqHeaders, + body: JSON.stringify(body || {}), + signal + } +} + +const buildResponse = (res: Response): Promise => { + return res.text().then(text => { + let data + try { + data = JSON.parse(text) + } catch (error) { + let message = '' + if (error instanceof Error) { + message = error.message + } + throw WebrpcBadResponseError.new({ + status: res.status, + cause: `JSON.parse(): ${message}: response text: ${text}` + }) + } + if (!res.ok) { + const code: number = typeof data.code === 'number' ? data.code : 0 + throw (webrpcErrorByCode[code] || WebrpcError).new(data) + } + return data + }) +} + +// +// Errors +// + +export class WebrpcError extends Error { + name: string + code: number + message: string + status: number + cause?: string + + /** @deprecated Use message instead of msg. Deprecated in webrpc v0.11.0. */ + msg: string + + constructor(name: string, code: number, message: string, status: number, cause?: string) { + super(message) + this.name = name || 'WebrpcError' + this.code = typeof code === 'number' ? code : 0 + this.message = message || `endpoint error ${this.code}` + this.msg = this.message + this.status = typeof status === 'number' ? status : 0 + this.cause = cause + Object.setPrototypeOf(this, WebrpcError.prototype) + } + + static new(payload: any): WebrpcError { + return new this(payload.error, payload.code, payload.message || payload.msg, payload.status, payload.cause) + } +} + +// Webrpc errors + +export class WebrpcEndpointError extends WebrpcError { + constructor( + name: string = 'WebrpcEndpoint', + code: number = 0, + message: string = 'endpoint error', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, WebrpcEndpointError.prototype) + } +} + +export class WebrpcRequestFailedError extends WebrpcError { + constructor( + name: string = 'WebrpcRequestFailed', + code: number = -1, + message: string = 'request failed', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, WebrpcRequestFailedError.prototype) + } +} + +export class WebrpcBadRouteError extends WebrpcError { + constructor( + name: string = 'WebrpcBadRoute', + code: number = -2, + message: string = 'bad route', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, WebrpcBadRouteError.prototype) + } +} + +export class WebrpcBadMethodError extends WebrpcError { + constructor( + name: string = 'WebrpcBadMethod', + code: number = -3, + message: string = 'bad method', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, WebrpcBadMethodError.prototype) + } +} + +export class WebrpcBadRequestError extends WebrpcError { + constructor( + name: string = 'WebrpcBadRequest', + code: number = -4, + message: string = 'bad request', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, WebrpcBadRequestError.prototype) + } +} + +export class WebrpcBadResponseError extends WebrpcError { + constructor( + name: string = 'WebrpcBadResponse', + code: number = -5, + message: string = 'bad response', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, WebrpcBadResponseError.prototype) + } +} + +export class WebrpcServerPanicError extends WebrpcError { + constructor( + name: string = 'WebrpcServerPanic', + code: number = -6, + message: string = 'server panic', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, WebrpcServerPanicError.prototype) + } +} + +export class WebrpcInternalErrorError extends WebrpcError { + constructor( + name: string = 'WebrpcInternalError', + code: number = -7, + message: string = 'internal error', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, WebrpcInternalErrorError.prototype) + } +} + +export class WebrpcClientDisconnectedError extends WebrpcError { + constructor( + name: string = 'WebrpcClientDisconnected', + code: number = -8, + message: string = 'client disconnected', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, WebrpcClientDisconnectedError.prototype) + } +} + +export class WebrpcStreamLostError extends WebrpcError { + constructor( + name: string = 'WebrpcStreamLost', + code: number = -9, + message: string = 'stream lost', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, WebrpcStreamLostError.prototype) + } +} + +export class WebrpcStreamFinishedError extends WebrpcError { + constructor( + name: string = 'WebrpcStreamFinished', + code: number = -10, + message: string = 'stream finished', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, WebrpcStreamFinishedError.prototype) + } +} + +// Schema errors + +export class UnauthorizedError extends WebrpcError { + constructor( + name: string = 'Unauthorized', + code: number = 1000, + message: string = 'Unauthorized access', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, UnauthorizedError.prototype) + } +} + +export class PermissionDeniedError extends WebrpcError { + constructor( + name: string = 'PermissionDenied', + code: number = 1001, + message: string = 'Permission denied', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, PermissionDeniedError.prototype) + } +} + +export class SessionExpiredError extends WebrpcError { + constructor( + name: string = 'SessionExpired', + code: number = 1002, + message: string = 'Session expired', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, SessionExpiredError.prototype) + } +} + +export class MethodNotFoundError extends WebrpcError { + constructor( + name: string = 'MethodNotFound', + code: number = 1003, + message: string = 'Method not found', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, MethodNotFoundError.prototype) + } +} + +export class RequestConflictError extends WebrpcError { + constructor( + name: string = 'RequestConflict', + code: number = 1004, + message: string = 'Conflict with target resource', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, RequestConflictError.prototype) + } +} + +export class AbortedError extends WebrpcError { + constructor( + name: string = 'Aborted', + code: number = 1005, + message: string = 'Request aborted', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, AbortedError.prototype) + } +} + +export class GeoblockedError extends WebrpcError { + constructor( + name: string = 'Geoblocked', + code: number = 1006, + message: string = 'Geoblocked region', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, GeoblockedError.prototype) + } +} + +export class RateLimitedError extends WebrpcError { + constructor( + name: string = 'RateLimited', + code: number = 1007, + message: string = 'Rate-limited. Please slow down.', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, RateLimitedError.prototype) + } +} + +export class ProjectNotFoundError extends WebrpcError { + constructor( + name: string = 'ProjectNotFound', + code: number = 1100, + message: string = 'Project not found', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, ProjectNotFoundError.prototype) + } +} + +export class AccessKeyNotFoundError extends WebrpcError { + constructor( + name: string = 'AccessKeyNotFound', + code: number = 1101, + message: string = 'Access key not found', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, AccessKeyNotFoundError.prototype) + } +} + +export class AccessKeyMismatchError extends WebrpcError { + constructor( + name: string = 'AccessKeyMismatch', + code: number = 1102, + message: string = 'Access key mismatch', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, AccessKeyMismatchError.prototype) + } +} + +export class InvalidOriginError extends WebrpcError { + constructor( + name: string = 'InvalidOrigin', + code: number = 1103, + message: string = 'Invalid origin for Access Key', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, InvalidOriginError.prototype) + } +} + +export class InvalidServiceError extends WebrpcError { + constructor( + name: string = 'InvalidService', + code: number = 1104, + message: string = 'Service not enabled for Access key', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, InvalidServiceError.prototype) + } +} + +export class UnauthorizedUserError extends WebrpcError { + constructor( + name: string = 'UnauthorizedUser', + code: number = 1105, + message: string = 'Unauthorized user', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, UnauthorizedUserError.prototype) + } +} + +export class QuotaExceededError extends WebrpcError { + constructor( + name: string = 'QuotaExceeded', + code: number = 1200, + message: string = 'Quota exceeded', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, QuotaExceededError.prototype) + } +} + +export class RateLimitError extends WebrpcError { + constructor( + name: string = 'RateLimit', + code: number = 1201, + message: string = 'Rate limit exceeded', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, RateLimitError.prototype) + } +} + +export class NoDefaultKeyError extends WebrpcError { + constructor( + name: string = 'NoDefaultKey', + code: number = 1300, + message: string = 'No default access key found', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, NoDefaultKeyError.prototype) + } +} + +export class MaxAccessKeysError extends WebrpcError { + constructor( + name: string = 'MaxAccessKeys', + code: number = 1301, + message: string = 'Access keys limit reached', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, MaxAccessKeysError.prototype) + } +} + +export class AtLeastOneKeyError extends WebrpcError { + constructor( + name: string = 'AtLeastOneKey', + code: number = 1302, + message: string = 'You need at least one Access Key', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, AtLeastOneKeyError.prototype) + } +} + +export class TimeoutError extends WebrpcError { + constructor( + name: string = 'Timeout', + code: number = 1900, + message: string = 'Request timed out', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, TimeoutError.prototype) + } +} + +export class InvalidArgumentError extends WebrpcError { + constructor( + name: string = 'InvalidArgument', + code: number = 2001, + message: string = 'Invalid argument', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, InvalidArgumentError.prototype) + } +} + +export class UnavailableError extends WebrpcError { + constructor( + name: string = 'Unavailable', + code: number = 2002, + message: string = 'Unavailable resource', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, UnavailableError.prototype) + } +} + +export class QueryFailedError extends WebrpcError { + constructor( + name: string = 'QueryFailed', + code: number = 2003, + message: string = 'Query failed', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, QueryFailedError.prototype) + } +} + +export class ResourceExhaustedError extends WebrpcError { + constructor( + name: string = 'ResourceExhausted', + code: number = 2004, + message: string = 'Resource exhausted', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, ResourceExhaustedError.prototype) + } +} + +export class NotFoundError extends WebrpcError { + constructor( + name: string = 'NotFound', + code: number = 3000, + message: string = 'Resource not found', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, NotFoundError.prototype) + } +} + +export class MetadataCallFailedError extends WebrpcError { + constructor( + name: string = 'MetadataCallFailed', + code: number = 3003, + message: string = 'Metadata service call failed', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, MetadataCallFailedError.prototype) + } +} + +export enum errors { + WebrpcEndpoint = 'WebrpcEndpoint', + WebrpcRequestFailed = 'WebrpcRequestFailed', + WebrpcBadRoute = 'WebrpcBadRoute', + WebrpcBadMethod = 'WebrpcBadMethod', + WebrpcBadRequest = 'WebrpcBadRequest', + WebrpcBadResponse = 'WebrpcBadResponse', + WebrpcServerPanic = 'WebrpcServerPanic', + WebrpcInternalError = 'WebrpcInternalError', + WebrpcClientDisconnected = 'WebrpcClientDisconnected', + WebrpcStreamLost = 'WebrpcStreamLost', + WebrpcStreamFinished = 'WebrpcStreamFinished', + Unauthorized = 'Unauthorized', + PermissionDenied = 'PermissionDenied', + SessionExpired = 'SessionExpired', + MethodNotFound = 'MethodNotFound', + RequestConflict = 'RequestConflict', + Aborted = 'Aborted', + Geoblocked = 'Geoblocked', + RateLimited = 'RateLimited', + ProjectNotFound = 'ProjectNotFound', + AccessKeyNotFound = 'AccessKeyNotFound', + AccessKeyMismatch = 'AccessKeyMismatch', + InvalidOrigin = 'InvalidOrigin', + InvalidService = 'InvalidService', + UnauthorizedUser = 'UnauthorizedUser', + QuotaExceeded = 'QuotaExceeded', + RateLimit = 'RateLimit', + NoDefaultKey = 'NoDefaultKey', + MaxAccessKeys = 'MaxAccessKeys', + AtLeastOneKey = 'AtLeastOneKey', + Timeout = 'Timeout', + InvalidArgument = 'InvalidArgument', + Unavailable = 'Unavailable', + QueryFailed = 'QueryFailed', + ResourceExhausted = 'ResourceExhausted', + NotFound = 'NotFound', + MetadataCallFailed = 'MetadataCallFailed' +} + +const webrpcErrorByCode: { [code: number]: any } = { + [0]: WebrpcEndpointError, + [-1]: WebrpcRequestFailedError, + [-2]: WebrpcBadRouteError, + [-3]: WebrpcBadMethodError, + [-4]: WebrpcBadRequestError, + [-5]: WebrpcBadResponseError, + [-6]: WebrpcServerPanicError, + [-7]: WebrpcInternalErrorError, + [-8]: WebrpcClientDisconnectedError, + [-9]: WebrpcStreamLostError, + [-10]: WebrpcStreamFinishedError, + [1000]: UnauthorizedError, + [1001]: PermissionDeniedError, + [1002]: SessionExpiredError, + [1003]: MethodNotFoundError, + [1004]: RequestConflictError, + [1005]: AbortedError, + [1006]: GeoblockedError, + [1007]: RateLimitedError, + [1100]: ProjectNotFoundError, + [1101]: AccessKeyNotFoundError, + [1102]: AccessKeyMismatchError, + [1103]: InvalidOriginError, + [1104]: InvalidServiceError, + [1105]: UnauthorizedUserError, + [1200]: QuotaExceededError, + [1201]: RateLimitError, + [1300]: NoDefaultKeyError, + [1301]: MaxAccessKeysError, + [1302]: AtLeastOneKeyError, + [1900]: TimeoutError, + [2001]: InvalidArgumentError, + [2002]: UnavailableError, + [2003]: QueryFailedError, + [2004]: ResourceExhaustedError, + [3000]: NotFoundError, + [3003]: MetadataCallFailedError +} + +export type Fetch = (input: RequestInfo, init?: RequestInit) => Promise diff --git a/packages/marketplace/CHANGELOG.md b/packages/marketplace/CHANGELOG.md new file mode 100644 index 000000000..2161889be --- /dev/null +++ b/packages/marketplace/CHANGELOG.md @@ -0,0 +1,178 @@ +# @0xsequence/marketplace + +## 2.2.14 + +### Patch Changes + +- Somnia Testnet and Monad Testnet + +## 2.2.13 + +### Patch Changes + +- Add XR1 to all networks + +## 2.2.12 + +### Patch Changes + +- Add XR1 + +## 2.2.11 + +### Patch Changes + +- Relayer updates + +## 2.2.10 + +### Patch Changes + +- Etherlink support + +## 2.2.9 + +### Patch Changes + +- Indexer gateway native token balances + +## 2.2.8 + +### Patch Changes + +- Add Moonbeam and Moonbase Alpha + +## 2.2.7 + +### Patch Changes + +- Update Builder package + +## 2.2.6 + +### Patch Changes + +- Update relayer package + +## 2.2.5 + +### Patch Changes + +- auth: fix sequence indexer gateway url +- account: immutable wallet proxy hook + +## 2.2.4 + +### Patch Changes + +- network: update soneium mainnet block explorer url +- waas: signTypedData intent support + +## 2.2.3 + +### Patch Changes + +- provider: updating initWallet to use connected network configs if they exist + +## 2.2.2 + +### Patch Changes + +- pass projectAccessKey to relayer at all times + +## 2.2.1 + +### Patch Changes + +- waas-ethers: sign typed data + +## 2.2.0 + +### Minor Changes + +- indexer: gateway client +- @0xsequence/builder +- upgrade puppeteer to v23.10.3 + +## 2.1.8 + +### Patch Changes + +- Add Soneium Mainnet + +## 2.1.7 + +### Patch Changes + +- guard: pass project access key to guard requests + +## 2.1.6 + +### Patch Changes + +- Add LAOS and Telos Testnet chains + +## 2.1.5 + +### Patch Changes + +- account: save presigned configuration with reference chain id 1 + +## 2.1.4 + +### Patch Changes + +- provider: pass projectAccessKey into MuxMessageProvider + +## 2.1.3 + +### Patch Changes + +- waas: time drift date fix due to strange browser quirk + +## 2.1.2 + +### Patch Changes + +- provider: export analytics correctly + +## 2.1.1 + +### Patch Changes + +- Add LAOS chain support + +## 2.1.0 + +### Minor Changes + +- account: forward project access key when estimating fees and sending transactions + +### Patch Changes + +- sessions: save signatures with reference chain id + +## 2.0.26 + +### Patch Changes + +- account: fix chain id comparison + +## 2.0.25 + +### Patch Changes + +- skale-nebula: deploy gas limit = 10m + +## 2.0.24 + +### Patch Changes + +- sessions: arweave: configurable gateway url +- waas: use /status to get time drift before sending any intents + +## 2.0.23 + +### Patch Changes + +- Add The Root Network support diff --git a/packages/marketplace/README.md b/packages/marketplace/README.md new file mode 100644 index 000000000..aa6a9d87b --- /dev/null +++ b/packages/marketplace/README.md @@ -0,0 +1,3 @@ +# @0xsequence/marketplace + +See [0xsequence project page](https://github.com/0xsequence/sequence.js). diff --git a/packages/marketplace/package.json b/packages/marketplace/package.json new file mode 100644 index 000000000..4f68912d8 --- /dev/null +++ b/packages/marketplace/package.json @@ -0,0 +1,22 @@ +{ + "name": "@0xsequence/marketplace", + "version": "2.2.14", + "description": "marketplace sub-package for Sequence", + "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/marketplace", + "source": "src/index.ts", + "main": "dist/0xsequence-marketplace.cjs.js", + "module": "dist/0xsequence-marketplace.esm.js", + "author": "Horizon Blockchain Games", + "license": "Apache-2.0", + "scripts": { + "test": "echo", + "typecheck": "tsc --noEmit" + }, + "dependencies": {}, + "peerDependencies": {}, + "devDependencies": {}, + "files": [ + "src", + "dist" + ] +} diff --git a/packages/marketplace/src/index.ts b/packages/marketplace/src/index.ts new file mode 100644 index 000000000..4f7cc7837 --- /dev/null +++ b/packages/marketplace/src/index.ts @@ -0,0 +1,36 @@ +export * from './marketplace.gen' + +import { Marketplace as MarketplaceRpc } from './marketplace.gen' + +export class MarketplaceIndexer extends MarketplaceRpc { + constructor( + hostname: string, + public projectAccessKey?: string, + public jwtAuth?: string + ) { + super(hostname.endsWith('/') ? hostname.slice(0, -1) : hostname, fetch) + this.fetch = this._fetch + } + + _fetch = (input: RequestInfo, init?: RequestInit): Promise => { + // automatically include jwt and access key auth header to requests + // if its been set on the api client + const headers: { [key: string]: any } = {} + + const jwtAuth = this.jwtAuth + const projectAccessKey = this.projectAccessKey + + if (jwtAuth && jwtAuth.length > 0) { + headers['Authorization'] = `BEARER ${jwtAuth}` + } + + if (projectAccessKey && projectAccessKey.length > 0) { + headers['X-Access-Key'] = projectAccessKey + } + + // before the request is made + init!.headers = { ...init!.headers, ...headers } + + return fetch(input, init) + } +} diff --git a/packages/marketplace/src/marketplace.gen.ts b/packages/marketplace/src/marketplace.gen.ts new file mode 100644 index 000000000..51ef99079 --- /dev/null +++ b/packages/marketplace/src/marketplace.gen.ts @@ -0,0 +1,2115 @@ +/* eslint-disable */ +// marketplace-api 272a2d3c9208fb21b84c88a2a8cbd9ab8e29964d +// -- +// Code generated by webrpc-gen@v0.21.1 with typescript generator. DO NOT EDIT. +// +// webrpc-gen -schema=marketplace.ridl -target=typescript -client -out=./clients/marketplace.gen.ts + +export const WebrpcHeader = 'Webrpc' + +export const WebrpcHeaderValue = + 'webrpc@v0.21.1;gen-typescript@v0.15.1;marketplace-api@v0.0.0-272a2d3c9208fb21b84c88a2a8cbd9ab8e29964d' + +// WebRPC description and code-gen version +export const WebRPCVersion = 'v1' + +// Schema version of your RIDL schema +export const WebRPCSchemaVersion = '' + +// Schema hash generated from your RIDL schema +export const WebRPCSchemaHash = '272a2d3c9208fb21b84c88a2a8cbd9ab8e29964d' + +type WebrpcGenVersions = { + webrpcGenVersion: string + codeGenName: string + codeGenVersion: string + schemaName: string + schemaVersion: string +} + +export function VersionFromHeader(headers: Headers): WebrpcGenVersions { + const headerValue = headers.get(WebrpcHeader) + if (!headerValue) { + return { + webrpcGenVersion: '', + codeGenName: '', + codeGenVersion: '', + schemaName: '', + schemaVersion: '' + } + } + + return parseWebrpcGenVersions(headerValue) +} + +function parseWebrpcGenVersions(header: string): WebrpcGenVersions { + const versions = header.split(';') + if (versions.length < 3) { + return { + webrpcGenVersion: '', + codeGenName: '', + codeGenVersion: '', + schemaName: '', + schemaVersion: '' + } + } + + const [_, webrpcGenVersion] = versions[0].split('@') + const [codeGenName, codeGenVersion] = versions[1].split('@') + const [schemaName, schemaVersion] = versions[2].split('@') + + return { + webrpcGenVersion, + codeGenName, + codeGenVersion, + schemaName, + schemaVersion + } +} + +// +// Types +// + +export interface TokenMetadata { + tokenId: string + name: string + description?: string + image?: string + video?: string + audio?: string + properties?: { [key: string]: any } + attributes: Array<{ [key: string]: any }> + image_data?: string + external_url?: string + background_color?: string + animation_url?: string + decimals?: number + updatedAt?: string + assets?: Array +} + +export interface Asset { + id: number + collectionId: number + tokenId: string + url?: string + metadataField: string + name?: string + filesize?: number + mimeType?: string + width?: number + height?: number + updatedAt?: string +} + +export enum SortOrder { + DESC = 'DESC', + ASC = 'ASC' +} + +export enum PropertyType { + INT = 'INT', + STRING = 'STRING', + ARRAY = 'ARRAY', + GENERIC = 'GENERIC' +} + +export enum MarketplaceKind { + unknown = 'unknown', + sequence_marketplace_v1 = 'sequence_marketplace_v1', + sequence_marketplace_v2 = 'sequence_marketplace_v2', + opensea = 'opensea', + magic_eden = 'magic_eden', + mintify = 'mintify', + looks_rare = 'looks_rare', + x2y2 = 'x2y2', + sudo_swap = 'sudo_swap', + coinbase = 'coinbase', + rarible = 'rarible', + nftx = 'nftx', + foundation = 'foundation', + manifold = 'manifold', + zora = 'zora', + blur = 'blur', + super_rare = 'super_rare', + okx = 'okx', + element = 'element', + aqua_xyz = 'aqua_xyz', + auranft_co = 'auranft_co' +} + +export enum OrderbookKind { + unknown = 'unknown', + sequence_marketplace_v1 = 'sequence_marketplace_v1', + sequence_marketplace_v2 = 'sequence_marketplace_v2', + blur = 'blur', + opensea = 'opensea', + looks_rare = 'looks_rare', + reservoir = 'reservoir', + x2y2 = 'x2y2' +} + +export enum SourceKind { + unknown = 'unknown', + external = 'external', + sequence_marketplace_v1 = 'sequence_marketplace_v1', + sequence_marketplace_v2 = 'sequence_marketplace_v2' +} + +export enum OrderSide { + unknown = 'unknown', + listing = 'listing', + offer = 'offer' +} + +export enum OrderStatus { + unknown = 'unknown', + active = 'active', + inactive = 'inactive', + expired = 'expired', + cancelled = 'cancelled', + filled = 'filled' +} + +export enum ContractType { + UNKNOWN = 'UNKNOWN', + ERC20 = 'ERC20', + ERC721 = 'ERC721', + ERC1155 = 'ERC1155' +} + +export enum CollectionStatus { + unknown = 'unknown', + created = 'created', + syncing_metadata = 'syncing_metadata', + synced_metadata = 'synced_metadata', + syncing_tokens = 'syncing_tokens', + synced_tokens = 'synced_tokens', + syncing_orders = 'syncing_orders', + active = 'active', + failed = 'failed', + inactive = 'inactive' +} + +export enum ProjectStatus { + unknown = 'unknown', + active = 'active', + inactive = 'inactive' +} + +export enum CollectibleStatus { + unknown = 'unknown', + active = 'active', + inactive = 'inactive' +} + +export enum WalletKind { + unknown = 'unknown', + sequence = 'sequence' +} + +export enum StepType { + unknown = 'unknown', + tokenApproval = 'tokenApproval', + buy = 'buy', + sell = 'sell', + createListing = 'createListing', + createOffer = 'createOffer', + signEIP712 = 'signEIP712', + signEIP191 = 'signEIP191' +} + +export enum TransactionCrypto { + none = 'none', + partially = 'partially', + all = 'all' +} + +export enum TransactionNFTCheckoutProvider { + unknown = 'unknown', + sardine = 'sardine', + transak = 'transak' +} + +export enum TransactionOnRampProvider { + unknown = 'unknown', + sardine = 'sardine', + transak = 'transak' +} + +export enum TransactionSwapProvider { + unknown = 'unknown', + zerox = 'zerox' +} + +export enum ExecuteType { + unknown = 'unknown', + order = 'order' +} + +export interface Page { + page: number + pageSize: number + more?: boolean + sort?: Array +} + +export interface SortBy { + column: string + order: SortOrder +} + +export interface Filter { + text?: string + properties?: Array +} + +export interface PropertyFilter { + name: string + type: PropertyType + min?: number + max?: number + values?: Array +} + +export interface CollectiblesFilter { + includeEmpty: boolean + searchText?: string + properties?: Array + marketplaces?: Array + inAccounts?: Array + notInAccounts?: Array + ordersCreatedBy?: Array + ordersNotCreatedBy?: Array +} + +export interface Order { + orderId: string + marketplace: MarketplaceKind + side: OrderSide + status: OrderStatus + chainId: number + collectionContractAddress: string + tokenId: string + createdBy: string + priceAmount: string + priceAmountFormatted: string + priceAmountNet: string + priceAmountNetFormatted: string + priceCurrencyAddress: string + priceDecimals: number + priceUSD: number + quantityInitial: string + quantityInitialFormatted: string + quantityRemaining: string + quantityRemainingFormatted: string + quantityAvailable: string + quantityAvailableFormatted: string + quantityDecimals: number + feeBps: number + feeBreakdown: Array + validFrom: string + validUntil: string + blockNumber: number + orderCreatedAt?: string + orderUpdatedAt?: string + createdAt: string + updatedAt: string + deletedAt?: string +} + +export interface FeeBreakdown { + kind: string + recipientAddress: string + bps: number +} + +export interface CollectibleOrder { + metadata: TokenMetadata + order?: Order +} + +export interface OrderFilter { + createdBy?: Array + marketplace?: Array + currencies?: Array +} + +export interface Activity { + type: string + fromAddress: string + toAddress: string + txHash: string + timestamp: number + tokenId: string + tokenImage: string + tokenName: string + currency?: Currency +} + +export interface Collection { + status: CollectionStatus + chainId: number + contractAddress: string + contractType: ContractType + tokenQuantityDecimals: number + config: CollectionConfig + createdAt: string + updatedAt: string + deletedAt?: string +} + +export interface CollectionConfig { + lastSynced: { [key: string]: CollectionLastSynced } + collectiblesSynced: string +} + +export interface CollectionLastSynced { + allOrders: string + newOrders: string +} + +export interface Project { + projectId: number + chainId: number + contractAddress: string + status: ProjectStatus + createdAt: string + updatedAt: string + deletedAt?: string +} + +export interface Collectible { + chainId: number + contractAddress: string + status: CollectibleStatus + tokenId: string + createdAt: string + updatedAt: string + deletedAt?: string +} + +export interface Currency { + chainId: number + contractAddress: string + name: string + symbol: string + decimals: number + imageUrl: string + exchangeRate: number + defaultChainCurrency: boolean + nativeCurrency: boolean + createdAt: string + updatedAt: string + deletedAt?: string +} + +export interface OrderData { + orderId: string + quantity: string +} + +export interface AdditionalFee { + amount: string + receiver: string +} + +export interface Step { + id: StepType + data: string + to: string + value: string + signature?: Signature + post?: PostRequest + executeType?: ExecuteType +} + +export interface PostRequest { + endpoint: string + method: string + body: any +} + +export interface CreateReq { + tokenId: string + quantity: string + expiry: string + currencyAddress: string + pricePerToken: string +} + +export interface GetOrdersInput { + contractAddress: string + orderId: string + marketplace: MarketplaceKind +} + +export interface Signature { + domain: Domain + types: any + primaryType: string + value: any +} + +export interface Domain { + name: string + version: string + chainId: number + verifyingContract: string +} + +export interface CheckoutOptionsMarketplaceOrder { + contractAddress: string + orderId: string + marketplace: MarketplaceKind +} + +export interface CheckoutOptionsItem { + tokenId: string + quantity: string +} + +export interface CheckoutOptions { + crypto: TransactionCrypto + swap: Array + nftCheckout: Array + onRamp: Array +} + +export interface Admin { + createCollection(args: CreateCollectionArgs, headers?: object, signal?: AbortSignal): Promise + getCollection(args: GetCollectionArgs, headers?: object, signal?: AbortSignal): Promise + listCollections(args: ListCollectionsArgs, headers?: object, signal?: AbortSignal): Promise + deleteCollection(args: DeleteCollectionArgs, headers?: object, signal?: AbortSignal): Promise + syncCollection(args: SyncCollectionArgs, headers?: object, signal?: AbortSignal): Promise + createCurrency(args: CreateCurrencyArgs, headers?: object, signal?: AbortSignal): Promise + createCurrencies(args: CreateCurrenciesArgs, headers?: object, signal?: AbortSignal): Promise + updateCurrency(args: UpdateCurrencyArgs, headers?: object, signal?: AbortSignal): Promise + listCurrencies(headers?: object, signal?: AbortSignal): Promise + deleteCurrency(args: DeleteCurrencyArgs, headers?: object, signal?: AbortSignal): Promise +} + +export interface CreateCollectionArgs { + projectId: number + contractAddress: string +} + +export interface CreateCollectionReturn { + collection: Collection +} +export interface GetCollectionArgs { + projectId: number + contractAddress: string +} + +export interface GetCollectionReturn { + collection: Collection +} +export interface ListCollectionsArgs { + projectId: number + page?: Page +} + +export interface ListCollectionsReturn { + collections: Array + page?: Page +} +export interface DeleteCollectionArgs { + projectId: number + contractAddress: string +} + +export interface DeleteCollectionReturn { + collection: Collection +} +export interface SyncCollectionArgs { + projectId: number + contractAddress: string +} + +export interface SyncCollectionReturn { + collection: Collection +} +export interface CreateCurrencyArgs { + currency: Currency +} + +export interface CreateCurrencyReturn { + currency: Currency +} +export interface CreateCurrenciesArgs { + currencies: Array +} + +export interface CreateCurrenciesReturn { + currency: { [key: string]: Currency } +} +export interface UpdateCurrencyArgs { + currency: Currency +} + +export interface UpdateCurrencyReturn { + currency: Currency +} +export interface ListCurrenciesArgs {} + +export interface ListCurrenciesReturn { + currencies: Array +} +export interface DeleteCurrencyArgs { + chainId: number + contractAddress: string +} + +export interface DeleteCurrencyReturn { + currency: Currency +} + +export interface Marketplace { + listCurrencies(headers?: object, signal?: AbortSignal): Promise + getCollectible(args: GetCollectibleArgs, headers?: object, signal?: AbortSignal): Promise + getLowestPriceOfferForCollectible( + args: GetLowestPriceOfferForCollectibleArgs, + headers?: object, + signal?: AbortSignal + ): Promise + getHighestPriceOfferForCollectible( + args: GetHighestPriceOfferForCollectibleArgs, + headers?: object, + signal?: AbortSignal + ): Promise + getLowestPriceListingForCollectible( + args: GetLowestPriceListingForCollectibleArgs, + headers?: object, + signal?: AbortSignal + ): Promise + getHighestPriceListingForCollectible( + args: GetHighestPriceListingForCollectibleArgs, + headers?: object, + signal?: AbortSignal + ): Promise + listListingsForCollectible( + args: ListListingsForCollectibleArgs, + headers?: object, + signal?: AbortSignal + ): Promise + listOffersForCollectible( + args: ListOffersForCollectibleArgs, + headers?: object, + signal?: AbortSignal + ): Promise + getCollectibleLowestOffer( + args: GetCollectibleLowestOfferArgs, + headers?: object, + signal?: AbortSignal + ): Promise + getCollectibleHighestOffer( + args: GetCollectibleHighestOfferArgs, + headers?: object, + signal?: AbortSignal + ): Promise + getCollectibleLowestListing( + args: GetCollectibleLowestListingArgs, + headers?: object, + signal?: AbortSignal + ): Promise + getCollectibleHighestListing( + args: GetCollectibleHighestListingArgs, + headers?: object, + signal?: AbortSignal + ): Promise + listCollectibleListings( + args: ListCollectibleListingsArgs, + headers?: object, + signal?: AbortSignal + ): Promise + listCollectibleOffers( + args: ListCollectibleOffersArgs, + headers?: object, + signal?: AbortSignal + ): Promise + generateBuyTransaction( + args: GenerateBuyTransactionArgs, + headers?: object, + signal?: AbortSignal + ): Promise + generateSellTransaction( + args: GenerateSellTransactionArgs, + headers?: object, + signal?: AbortSignal + ): Promise + generateListingTransaction( + args: GenerateListingTransactionArgs, + headers?: object, + signal?: AbortSignal + ): Promise + generateOfferTransaction( + args: GenerateOfferTransactionArgs, + headers?: object, + signal?: AbortSignal + ): Promise + execute(args: ExecuteArgs, headers?: object, signal?: AbortSignal): Promise + listCollectibles(args: ListCollectiblesArgs, headers?: object, signal?: AbortSignal): Promise + getCountOfAllCollectibles( + args: GetCountOfAllCollectiblesArgs, + headers?: object, + signal?: AbortSignal + ): Promise + getCountOfFilteredCollectibles( + args: GetCountOfFilteredCollectiblesArgs, + headers?: object, + signal?: AbortSignal + ): Promise + getFloorOrder(args: GetFloorOrderArgs, headers?: object, signal?: AbortSignal): Promise + listCollectiblesWithLowestListing( + args: ListCollectiblesWithLowestListingArgs, + headers?: object, + signal?: AbortSignal + ): Promise + listCollectiblesWithHighestOffer( + args: ListCollectiblesWithHighestOfferArgs, + headers?: object, + signal?: AbortSignal + ): Promise + syncOrder(args: SyncOrderArgs, headers?: object, signal?: AbortSignal): Promise + syncOrders(args: SyncOrdersArgs, headers?: object, signal?: AbortSignal): Promise + getOrders(args: GetOrdersArgs, headers?: object, signal?: AbortSignal): Promise + checkoutOptionsMarketplace( + args: CheckoutOptionsMarketplaceArgs, + headers?: object, + signal?: AbortSignal + ): Promise + checkoutOptionsSalesContract( + args: CheckoutOptionsSalesContractArgs, + headers?: object, + signal?: AbortSignal + ): Promise +} + +export interface ListCurrenciesArgs {} + +export interface ListCurrenciesReturn { + currencies: Array +} +export interface GetCollectibleArgs { + contractAddress: string + tokenId: string +} + +export interface GetCollectibleReturn { + metadata: TokenMetadata +} +export interface GetLowestPriceOfferForCollectibleArgs { + contractAddress: string + tokenId: string + filter?: OrderFilter +} + +export interface GetLowestPriceOfferForCollectibleReturn { + order: Order +} +export interface GetHighestPriceOfferForCollectibleArgs { + contractAddress: string + tokenId: string + filter?: OrderFilter +} + +export interface GetHighestPriceOfferForCollectibleReturn { + order: Order +} +export interface GetLowestPriceListingForCollectibleArgs { + contractAddress: string + tokenId: string + filter?: OrderFilter +} + +export interface GetLowestPriceListingForCollectibleReturn { + order: Order +} +export interface GetHighestPriceListingForCollectibleArgs { + contractAddress: string + tokenId: string + filter?: OrderFilter +} + +export interface GetHighestPriceListingForCollectibleReturn { + order: Order +} +export interface ListListingsForCollectibleArgs { + contractAddress: string + tokenId: string + filter?: OrderFilter + page?: Page +} + +export interface ListListingsForCollectibleReturn { + listings: Array + page?: Page +} +export interface ListOffersForCollectibleArgs { + contractAddress: string + tokenId: string + filter?: OrderFilter + page?: Page +} + +export interface ListOffersForCollectibleReturn { + offers: Array + page?: Page +} +export interface GetCollectibleLowestOfferArgs { + contractAddress: string + tokenId: string + filter?: OrderFilter +} + +export interface GetCollectibleLowestOfferReturn { + order?: Order +} +export interface GetCollectibleHighestOfferArgs { + contractAddress: string + tokenId: string + filter?: OrderFilter +} + +export interface GetCollectibleHighestOfferReturn { + order?: Order +} +export interface GetCollectibleLowestListingArgs { + contractAddress: string + tokenId: string + filter?: OrderFilter +} + +export interface GetCollectibleLowestListingReturn { + order?: Order +} +export interface GetCollectibleHighestListingArgs { + contractAddress: string + tokenId: string + filter?: OrderFilter +} + +export interface GetCollectibleHighestListingReturn { + order?: Order +} +export interface ListCollectibleListingsArgs { + contractAddress: string + tokenId: string + filter?: OrderFilter + page?: Page +} + +export interface ListCollectibleListingsReturn { + listings: Array + page?: Page +} +export interface ListCollectibleOffersArgs { + contractAddress: string + tokenId: string + filter?: OrderFilter + page?: Page +} + +export interface ListCollectibleOffersReturn { + offers: Array + page?: Page +} +export interface GenerateBuyTransactionArgs { + collectionAddress: string + buyer: string + marketplace: MarketplaceKind + ordersData: Array + additionalFees: Array + walletType?: WalletKind +} + +export interface GenerateBuyTransactionReturn { + steps: Array +} +export interface GenerateSellTransactionArgs { + collectionAddress: string + seller: string + marketplace: MarketplaceKind + ordersData: Array + additionalFees: Array + walletType?: WalletKind +} + +export interface GenerateSellTransactionReturn { + steps: Array +} +export interface GenerateListingTransactionArgs { + collectionAddress: string + owner: string + contractType: ContractType + orderbook: OrderbookKind + listing: CreateReq + walletType?: WalletKind +} + +export interface GenerateListingTransactionReturn { + steps: Array +} +export interface GenerateOfferTransactionArgs { + collectionAddress: string + maker: string + contractType: ContractType + orderbook: OrderbookKind + offer: CreateReq + walletType?: WalletKind +} + +export interface GenerateOfferTransactionReturn { + steps: Array +} +export interface ExecuteArgs { + signature: string + executeType: ExecuteType + body: any +} + +export interface ExecuteReturn { + orderId: string +} +export interface ListCollectiblesArgs { + side: OrderSide + contractAddress: string + filter?: CollectiblesFilter + page?: Page +} + +export interface ListCollectiblesReturn { + collectibles: Array + page?: Page +} +export interface GetCountOfAllCollectiblesArgs { + contractAddress: string +} + +export interface GetCountOfAllCollectiblesReturn { + count: number +} +export interface GetCountOfFilteredCollectiblesArgs { + side: OrderSide + contractAddress: string + filter?: CollectiblesFilter +} + +export interface GetCountOfFilteredCollectiblesReturn { + count: number +} +export interface GetFloorOrderArgs { + contractAddress: string + filter?: CollectiblesFilter +} + +export interface GetFloorOrderReturn { + collectible: CollectibleOrder +} +export interface ListCollectiblesWithLowestListingArgs { + contractAddress: string + filter?: CollectiblesFilter + page?: Page +} + +export interface ListCollectiblesWithLowestListingReturn { + collectibles: Array + page?: Page +} +export interface ListCollectiblesWithHighestOfferArgs { + contractAddress: string + filter?: CollectiblesFilter + page?: Page +} + +export interface ListCollectiblesWithHighestOfferReturn { + collectibles: Array + page?: Page +} +export interface SyncOrderArgs { + order: Order +} + +export interface SyncOrderReturn {} +export interface SyncOrdersArgs { + orders: Array +} + +export interface SyncOrdersReturn {} +export interface GetOrdersArgs { + input: Array + page?: Page +} + +export interface GetOrdersReturn { + orders: Array + page?: Page +} +export interface CheckoutOptionsMarketplaceArgs { + wallet: string + orders: Array + additionalFee: number +} + +export interface CheckoutOptionsMarketplaceReturn { + options: CheckoutOptions +} +export interface CheckoutOptionsSalesContractArgs { + wallet: string + contractAddress: string + collectionAddress: string + items: Array +} + +export interface CheckoutOptionsSalesContractReturn { + options: CheckoutOptions +} + +// +// Client +// +export class Admin implements Admin { + protected hostname: string + protected fetch: Fetch + protected path = '/rpc/Admin/' + + constructor(hostname: string, fetch: Fetch) { + this.hostname = hostname.replace(/\/*$/, '') + this.fetch = (input: RequestInfo, init?: RequestInit) => fetch(input, init) + } + + private url(name: string): string { + return this.hostname + this.path + name + } + + createCollection = (args: CreateCollectionArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('CreateCollection'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + collection: _data.collection + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + getCollection = (args: GetCollectionArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('GetCollection'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + collection: _data.collection + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + listCollections = (args: ListCollectionsArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('ListCollections'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + collections: >_data.collections, + page: _data.page + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + deleteCollection = (args: DeleteCollectionArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('DeleteCollection'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + collection: _data.collection + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + syncCollection = (args: SyncCollectionArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('SyncCollection'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + collection: _data.collection + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + createCurrency = (args: CreateCurrencyArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('CreateCurrency'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + currency: _data.currency + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + createCurrencies = (args: CreateCurrenciesArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('CreateCurrencies'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + currency: <{ [key: string]: Currency }>_data.currency + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + updateCurrency = (args: UpdateCurrencyArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('UpdateCurrency'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + currency: _data.currency + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + listCurrencies = (headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('ListCurrencies'), createHTTPRequest({}, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + currencies: >_data.currencies + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + deleteCurrency = (args: DeleteCurrencyArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('DeleteCurrency'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + currency: _data.currency + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } +} +export class Marketplace implements Marketplace { + protected hostname: string + protected fetch: Fetch + protected path = '/rpc/Marketplace/' + + constructor(hostname: string, fetch: Fetch) { + this.hostname = hostname.replace(/\/*$/, '') + this.fetch = (input: RequestInfo, init?: RequestInit) => fetch(input, init) + } + + private url(name: string): string { + return this.hostname + this.path + name + } + + listCurrencies = (headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('ListCurrencies'), createHTTPRequest({}, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + currencies: >_data.currencies + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + getCollectible = (args: GetCollectibleArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('GetCollectible'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + metadata: _data.metadata + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + getLowestPriceOfferForCollectible = ( + args: GetLowestPriceOfferForCollectibleArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('GetLowestPriceOfferForCollectible'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + order: _data.order + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + getHighestPriceOfferForCollectible = ( + args: GetHighestPriceOfferForCollectibleArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('GetHighestPriceOfferForCollectible'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + order: _data.order + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + getLowestPriceListingForCollectible = ( + args: GetLowestPriceListingForCollectibleArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('GetLowestPriceListingForCollectible'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + order: _data.order + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + getHighestPriceListingForCollectible = ( + args: GetHighestPriceListingForCollectibleArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('GetHighestPriceListingForCollectible'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + order: _data.order + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + listListingsForCollectible = ( + args: ListListingsForCollectibleArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('ListListingsForCollectible'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + listings: >_data.listings, + page: _data.page + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + listOffersForCollectible = ( + args: ListOffersForCollectibleArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('ListOffersForCollectible'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + offers: >_data.offers, + page: _data.page + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + getCollectibleLowestOffer = ( + args: GetCollectibleLowestOfferArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('GetCollectibleLowestOffer'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + order: _data.order + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + getCollectibleHighestOffer = ( + args: GetCollectibleHighestOfferArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('GetCollectibleHighestOffer'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + order: _data.order + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + getCollectibleLowestListing = ( + args: GetCollectibleLowestListingArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('GetCollectibleLowestListing'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + order: _data.order + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + getCollectibleHighestListing = ( + args: GetCollectibleHighestListingArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('GetCollectibleHighestListing'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + order: _data.order + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + listCollectibleListings = ( + args: ListCollectibleListingsArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('ListCollectibleListings'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + listings: >_data.listings, + page: _data.page + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + listCollectibleOffers = ( + args: ListCollectibleOffersArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('ListCollectibleOffers'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + offers: >_data.offers, + page: _data.page + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + generateBuyTransaction = ( + args: GenerateBuyTransactionArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('GenerateBuyTransaction'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + steps: >_data.steps + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + generateSellTransaction = ( + args: GenerateSellTransactionArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('GenerateSellTransaction'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + steps: >_data.steps + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + generateListingTransaction = ( + args: GenerateListingTransactionArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('GenerateListingTransaction'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + steps: >_data.steps + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + generateOfferTransaction = ( + args: GenerateOfferTransactionArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('GenerateOfferTransaction'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + steps: >_data.steps + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + execute = (args: ExecuteArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('Execute'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + orderId: _data.orderId + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + listCollectibles = (args: ListCollectiblesArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('ListCollectibles'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + collectibles: >_data.collectibles, + page: _data.page + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + getCountOfAllCollectibles = ( + args: GetCountOfAllCollectiblesArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('GetCountOfAllCollectibles'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + count: _data.count + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + getCountOfFilteredCollectibles = ( + args: GetCountOfFilteredCollectiblesArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('GetCountOfFilteredCollectibles'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + count: _data.count + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + getFloorOrder = (args: GetFloorOrderArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('GetFloorOrder'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + collectible: _data.collectible + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + listCollectiblesWithLowestListing = ( + args: ListCollectiblesWithLowestListingArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('ListCollectiblesWithLowestListing'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + collectibles: >_data.collectibles, + page: _data.page + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + listCollectiblesWithHighestOffer = ( + args: ListCollectiblesWithHighestOfferArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('ListCollectiblesWithHighestOffer'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + collectibles: >_data.collectibles, + page: _data.page + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + syncOrder = (args: SyncOrderArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('SyncOrder'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return {} + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + syncOrders = (args: SyncOrdersArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('SyncOrders'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return {} + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + getOrders = (args: GetOrdersArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('GetOrders'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + orders: >_data.orders, + page: _data.page + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + checkoutOptionsMarketplace = ( + args: CheckoutOptionsMarketplaceArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('CheckoutOptionsMarketplace'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + options: _data.options + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + checkoutOptionsSalesContract = ( + args: CheckoutOptionsSalesContractArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('CheckoutOptionsSalesContract'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + options: _data.options + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } +} + +const createHTTPRequest = (body: object = {}, headers: object = {}, signal: AbortSignal | null = null): object => { + const reqHeaders: { [key: string]: string } = { ...headers, 'Content-Type': 'application/json' } + reqHeaders[WebrpcHeader] = WebrpcHeaderValue + + return { + method: 'POST', + headers: reqHeaders, + body: JSON.stringify(body || {}), + signal + } +} + +const buildResponse = (res: Response): Promise => { + return res.text().then(text => { + let data + try { + data = JSON.parse(text) + } catch (error) { + let message = '' + if (error instanceof Error) { + message = error.message + } + throw WebrpcBadResponseError.new({ + status: res.status, + cause: `JSON.parse(): ${message}: response text: ${text}` + }) + } + if (!res.ok) { + const code: number = typeof data.code === 'number' ? data.code : 0 + throw (webrpcErrorByCode[code] || WebrpcError).new(data) + } + return data + }) +} + +// +// Errors +// + +export class WebrpcError extends Error { + name: string + code: number + message: string + status: number + cause?: string + + /** @deprecated Use message instead of msg. Deprecated in webrpc v0.11.0. */ + msg: string + + constructor(name: string, code: number, message: string, status: number, cause?: string) { + super(message) + this.name = name || 'WebrpcError' + this.code = typeof code === 'number' ? code : 0 + this.message = message || `endpoint error ${this.code}` + this.msg = this.message + this.status = typeof status === 'number' ? status : 0 + this.cause = cause + Object.setPrototypeOf(this, WebrpcError.prototype) + } + + static new(payload: any): WebrpcError { + return new this(payload.error, payload.code, payload.message || payload.msg, payload.status, payload.cause) + } +} + +// Webrpc errors + +export class WebrpcEndpointError extends WebrpcError { + constructor( + name: string = 'WebrpcEndpoint', + code: number = 0, + message: string = 'endpoint error', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, WebrpcEndpointError.prototype) + } +} + +export class WebrpcRequestFailedError extends WebrpcError { + constructor( + name: string = 'WebrpcRequestFailed', + code: number = -1, + message: string = 'request failed', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, WebrpcRequestFailedError.prototype) + } +} + +export class WebrpcBadRouteError extends WebrpcError { + constructor( + name: string = 'WebrpcBadRoute', + code: number = -2, + message: string = 'bad route', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, WebrpcBadRouteError.prototype) + } +} + +export class WebrpcBadMethodError extends WebrpcError { + constructor( + name: string = 'WebrpcBadMethod', + code: number = -3, + message: string = 'bad method', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, WebrpcBadMethodError.prototype) + } +} + +export class WebrpcBadRequestError extends WebrpcError { + constructor( + name: string = 'WebrpcBadRequest', + code: number = -4, + message: string = 'bad request', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, WebrpcBadRequestError.prototype) + } +} + +export class WebrpcBadResponseError extends WebrpcError { + constructor( + name: string = 'WebrpcBadResponse', + code: number = -5, + message: string = 'bad response', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, WebrpcBadResponseError.prototype) + } +} + +export class WebrpcServerPanicError extends WebrpcError { + constructor( + name: string = 'WebrpcServerPanic', + code: number = -6, + message: string = 'server panic', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, WebrpcServerPanicError.prototype) + } +} + +export class WebrpcInternalErrorError extends WebrpcError { + constructor( + name: string = 'WebrpcInternalError', + code: number = -7, + message: string = 'internal error', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, WebrpcInternalErrorError.prototype) + } +} + +export class WebrpcClientDisconnectedError extends WebrpcError { + constructor( + name: string = 'WebrpcClientDisconnected', + code: number = -8, + message: string = 'client disconnected', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, WebrpcClientDisconnectedError.prototype) + } +} + +export class WebrpcStreamLostError extends WebrpcError { + constructor( + name: string = 'WebrpcStreamLost', + code: number = -9, + message: string = 'stream lost', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, WebrpcStreamLostError.prototype) + } +} + +export class WebrpcStreamFinishedError extends WebrpcError { + constructor( + name: string = 'WebrpcStreamFinished', + code: number = -10, + message: string = 'stream finished', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, WebrpcStreamFinishedError.prototype) + } +} + +// Schema errors + +export class UnauthorizedError extends WebrpcError { + constructor( + name: string = 'Unauthorized', + code: number = 1000, + message: string = 'Unauthorized access', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, UnauthorizedError.prototype) + } +} + +export class PermissionDeniedError extends WebrpcError { + constructor( + name: string = 'PermissionDenied', + code: number = 1001, + message: string = 'Permission denied', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, PermissionDeniedError.prototype) + } +} + +export class SessionExpiredError extends WebrpcError { + constructor( + name: string = 'SessionExpired', + code: number = 1002, + message: string = 'Session expired', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, SessionExpiredError.prototype) + } +} + +export class MethodNotFoundError extends WebrpcError { + constructor( + name: string = 'MethodNotFound', + code: number = 1003, + message: string = 'Method not found', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, MethodNotFoundError.prototype) + } +} + +export class TimeoutError extends WebrpcError { + constructor( + name: string = 'Timeout', + code: number = 2000, + message: string = 'Request timed out', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, TimeoutError.prototype) + } +} + +export class InvalidArgumentError extends WebrpcError { + constructor( + name: string = 'InvalidArgument', + code: number = 2001, + message: string = 'Invalid argument', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, InvalidArgumentError.prototype) + } +} + +export class NotFoundError extends WebrpcError { + constructor( + name: string = 'NotFound', + code: number = 3000, + message: string = 'Resource not found', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, NotFoundError.prototype) + } +} + +export class UserNotFoundError extends WebrpcError { + constructor( + name: string = 'UserNotFound', + code: number = 3001, + message: string = 'User not found', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, UserNotFoundError.prototype) + } +} + +export class ProjectNotFoundError extends WebrpcError { + constructor( + name: string = 'ProjectNotFound', + code: number = 3002, + message: string = 'Project not found', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, ProjectNotFoundError.prototype) + } +} + +export class InvalidTierError extends WebrpcError { + constructor( + name: string = 'InvalidTier', + code: number = 3003, + message: string = 'Invalid subscription tier', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, InvalidTierError.prototype) + } +} + +export class ProjectLimitReachedError extends WebrpcError { + constructor( + name: string = 'ProjectLimitReached', + code: number = 3005, + message: string = 'Project limit reached', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, ProjectLimitReachedError.prototype) + } +} + +export class NotImplementedError extends WebrpcError { + constructor( + name: string = 'NotImplemented', + code: number = 9999, + message: string = 'Not Implemented', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, NotImplementedError.prototype) + } +} + +export enum errors { + WebrpcEndpoint = 'WebrpcEndpoint', + WebrpcRequestFailed = 'WebrpcRequestFailed', + WebrpcBadRoute = 'WebrpcBadRoute', + WebrpcBadMethod = 'WebrpcBadMethod', + WebrpcBadRequest = 'WebrpcBadRequest', + WebrpcBadResponse = 'WebrpcBadResponse', + WebrpcServerPanic = 'WebrpcServerPanic', + WebrpcInternalError = 'WebrpcInternalError', + WebrpcClientDisconnected = 'WebrpcClientDisconnected', + WebrpcStreamLost = 'WebrpcStreamLost', + WebrpcStreamFinished = 'WebrpcStreamFinished', + Unauthorized = 'Unauthorized', + PermissionDenied = 'PermissionDenied', + SessionExpired = 'SessionExpired', + MethodNotFound = 'MethodNotFound', + Timeout = 'Timeout', + InvalidArgument = 'InvalidArgument', + NotFound = 'NotFound', + UserNotFound = 'UserNotFound', + ProjectNotFound = 'ProjectNotFound', + InvalidTier = 'InvalidTier', + ProjectLimitReached = 'ProjectLimitReached', + NotImplemented = 'NotImplemented' +} + +const webrpcErrorByCode: { [code: number]: any } = { + [0]: WebrpcEndpointError, + [-1]: WebrpcRequestFailedError, + [-2]: WebrpcBadRouteError, + [-3]: WebrpcBadMethodError, + [-4]: WebrpcBadRequestError, + [-5]: WebrpcBadResponseError, + [-6]: WebrpcServerPanicError, + [-7]: WebrpcInternalErrorError, + [-8]: WebrpcClientDisconnectedError, + [-9]: WebrpcStreamLostError, + [-10]: WebrpcStreamFinishedError, + [1000]: UnauthorizedError, + [1001]: PermissionDeniedError, + [1002]: SessionExpiredError, + [1003]: MethodNotFoundError, + [2000]: TimeoutError, + [2001]: InvalidArgumentError, + [3000]: NotFoundError, + [3001]: UserNotFoundError, + [3002]: ProjectNotFoundError, + [3003]: InvalidTierError, + [3005]: ProjectLimitReachedError, + [9999]: NotImplementedError +} + +export type Fetch = (input: RequestInfo, init?: RequestInit) => Promise diff --git a/packages/metadata/CHANGELOG.md b/packages/metadata/CHANGELOG.md index 59de86171..91c2620e5 100644 --- a/packages/metadata/CHANGELOG.md +++ b/packages/metadata/CHANGELOG.md @@ -1,5 +1,331 @@ # @0xsequence/metadata +## 2.2.14 + +### Patch Changes + +- Somnia Testnet and Monad Testnet + +## 2.2.13 + +### Patch Changes + +- Add XR1 to all networks + +## 2.2.12 + +### Patch Changes + +- Add XR1 + +## 2.2.11 + +### Patch Changes + +- Relayer updates + +## 2.2.10 + +### Patch Changes + +- Etherlink support + +## 2.2.9 + +### Patch Changes + +- Indexer gateway native token balances + +## 2.2.8 + +### Patch Changes + +- Add Moonbeam and Moonbase Alpha + +## 2.2.7 + +### Patch Changes + +- Update Builder package + +## 2.2.6 + +### Patch Changes + +- Update relayer package + +## 2.2.5 + +### Patch Changes + +- auth: fix sequence indexer gateway url +- account: immutable wallet proxy hook + +## 2.2.4 + +### Patch Changes + +- network: update soneium mainnet block explorer url +- waas: signTypedData intent support + +## 2.2.3 + +### Patch Changes + +- provider: updating initWallet to use connected network configs if they exist + +## 2.2.2 + +### Patch Changes + +- pass projectAccessKey to relayer at all times + +## 2.2.1 + +### Patch Changes + +- waas-ethers: sign typed data + +## 2.2.0 + +### Minor Changes + +- indexer: gateway client +- @0xsequence/builder +- upgrade puppeteer to v23.10.3 + +## 2.1.8 + +### Patch Changes + +- Add Soneium Mainnet + +## 2.1.7 + +### Patch Changes + +- guard: pass project access key to guard requests + +## 2.1.6 + +### Patch Changes + +- Add LAOS and Telos Testnet chains + +## 2.1.5 + +### Patch Changes + +- account: save presigned configuration with reference chain id 1 + +## 2.1.4 + +### Patch Changes + +- provider: pass projectAccessKey into MuxMessageProvider + +## 2.1.3 + +### Patch Changes + +- waas: time drift date fix due to strange browser quirk + +## 2.1.2 + +### Patch Changes + +- provider: export analytics correctly + +## 2.1.1 + +### Patch Changes + +- Add LAOS chain support + +## 2.1.0 + +### Minor Changes + +- account: forward project access key when estimating fees and sending transactions + +### Patch Changes + +- sessions: save signatures with reference chain id + +## 2.0.26 + +### Patch Changes + +- account: fix chain id comparison + +## 2.0.25 + +### Patch Changes + +- skale-nebula: deploy gas limit = 10m + +## 2.0.24 + +### Patch Changes + +- sessions: arweave: configurable gateway url +- waas: use /status to get time drift before sending any intents + +## 2.0.23 + +### Patch Changes + +- Add The Root Network support + +## 2.0.22 + +### Patch Changes + +- Add SKALE Nebula Mainnet support + +## 2.0.21 + +### Patch Changes + +- account: add publishWitnessFor + +## 2.0.20 + +### Patch Changes + +- upgrade deps, and improve waas session status handling + +## 2.0.19 + +### Patch Changes + +- Add Immutable zkEVM support + +## 2.0.18 + +### Patch Changes + +- waas: new contractCall transaction type +- sessions: add arweave owner + +## 2.0.17 + +### Patch Changes + +- update waas auth to clear session before signIn + +## 2.0.16 + +### Patch Changes + +- Removed Astar chains + +## 2.0.15 + +### Patch Changes + +- indexer: update bindings with token balance additions + +## 2.0.14 + +### Patch Changes + +- sessions: arweave config reader +- network: add b3 and apechain mainnet configs + +## 2.0.13 + +### Patch Changes + +- network: toy-testnet + +## 2.0.12 + +### Patch Changes + +- api: update bindings + +## 2.0.11 + +### Patch Changes + +- waas: intents test fix +- api: update bindings + +## 2.0.10 + +### Patch Changes + +- network: soneium minato testnet + +## 2.0.9 + +### Patch Changes + +- network: fix SKALE network name + +## 2.0.8 + +### Patch Changes + +- metadata: update bindings + +## 2.0.7 + +### Patch Changes + +- wallet request handler fix + +## 2.0.6 + +### Patch Changes + +- network: matic -> pol + +## 2.0.5 + +### Patch Changes + +- provider: update databeat to 0.9.2 + +## 2.0.4 + +### Patch Changes + +- network: add skale-nebula-testnet + +## 2.0.3 + +### Patch Changes + +- waas: check session status in SequenceWaaS.isSignedIn() + +## 2.0.2 + +### Patch Changes + +- sessions: property convert serialized bignumber hex value to bigint + +## 2.0.1 + +### Patch Changes + +- waas: http signature check for authenticator requests +- provider: unwrap legacy json rpc responses +- use json replacer and reviver for bigints + +## 2.0.0 + +### Major Changes + +- ethers v6 + +## 1.10.15 + +### Patch Changes + +- utils: extractProjectIdFromAccessKey + ## 1.10.14 ### Patch Changes diff --git a/packages/metadata/package.json b/packages/metadata/package.json index 01bafc193..757231e68 100644 --- a/packages/metadata/package.json +++ b/packages/metadata/package.json @@ -1,6 +1,6 @@ { "name": "@0xsequence/metadata", - "version": "1.10.14", + "version": "2.2.14", "description": "metadata sub-package for Sequence", "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/metadata", "source": "src/index.ts", diff --git a/packages/metadata/src/index.ts b/packages/metadata/src/index.ts index d5d463add..ab01360cd 100644 --- a/packages/metadata/src/index.ts +++ b/packages/metadata/src/index.ts @@ -2,8 +2,6 @@ export * from './metadata.gen' import { Metadata as MetadataRpc, Collections as CollectionsRpc } from './metadata.gen' -const fetch = globalThis.fetch - export class SequenceMetadata extends MetadataRpc { constructor( hostname: string = 'https://metadata.sequence.app', diff --git a/packages/metadata/src/metadata.gen.ts b/packages/metadata/src/metadata.gen.ts index f7928ab1c..5202db29d 100644 --- a/packages/metadata/src/metadata.gen.ts +++ b/packages/metadata/src/metadata.gen.ts @@ -1,10 +1,14 @@ /* eslint-disable */ -// sequence-metadata v0.4.0 7c434e9c7faba707ea4d030621fb145e47531281 +// sequence-metadata v0.4.0 9594f86f8681f364dd514a1bd7cae1c1dc77e3de // -- -// Code generated by webrpc-gen@v0.18.6 with typescript generator. DO NOT EDIT. +// Code generated by webrpc-gen@v0.21.1 with typescript generator. DO NOT EDIT. // // webrpc-gen -schema=metadata.ridl -target=typescript -client -out=./clients/metadata.gen.ts +export const WebrpcHeader = 'Webrpc' + +export const WebrpcHeaderValue = 'webrpc@v0.21.1;gen-typescript@v0.15.1;sequence-metadata@v0.4.0' + // WebRPC description and code-gen version export const WebRPCVersion = 'v1' @@ -12,7 +16,55 @@ export const WebRPCVersion = 'v1' export const WebRPCSchemaVersion = 'v0.4.0' // Schema hash generated from your RIDL schema -export const WebRPCSchemaHash = '7c434e9c7faba707ea4d030621fb145e47531281' +export const WebRPCSchemaHash = '9594f86f8681f364dd514a1bd7cae1c1dc77e3de' + +type WebrpcGenVersions = { + webrpcGenVersion: string + codeGenName: string + codeGenVersion: string + schemaName: string + schemaVersion: string +} + +export function VersionFromHeader(headers: Headers): WebrpcGenVersions { + const headerValue = headers.get(WebrpcHeader) + if (!headerValue) { + return { + webrpcGenVersion: '', + codeGenName: '', + codeGenVersion: '', + schemaName: '', + schemaVersion: '' + } + } + + return parseWebrpcGenVersions(headerValue) +} + +function parseWebrpcGenVersions(header: string): WebrpcGenVersions { + const versions = header.split(';') + if (versions.length < 3) { + return { + webrpcGenVersion: '', + codeGenName: '', + codeGenVersion: '', + schemaName: '', + schemaVersion: '' + } + } + + const [_, webrpcGenVersion] = versions[0].split('@') + const [codeGenName, codeGenVersion] = versions[1].split('@') + const [schemaName, schemaVersion] = versions[2].split('@') + + return { + webrpcGenVersion, + codeGenName, + codeGenVersion, + schemaName, + schemaVersion + } +} // // Types @@ -25,6 +77,29 @@ export enum ContractType { ERC1155 = 'ERC1155' } +export enum Source { + UNKNOWN = 'UNKNOWN', + FETCHER = 'FETCHER', + FETCHER_OPENSEA_API = 'FETCHER_OPENSEA_API', + FETCHER_ENS_API = 'FETCHER_ENS_API', + FETCHER_ON_CHAIN_ERC20_INTERFACE = 'FETCHER_ON_CHAIN_ERC20_INTERFACE', + FETCHER_ON_CHAIN_TOKEN_URI = 'FETCHER_ON_CHAIN_TOKEN_URI', + FETCHER_ON_CHAIN_CONTRACT_URI = 'FETCHER_ON_CHAIN_CONTRACT_URI', + TOKEN_DIRECTORY = 'TOKEN_DIRECTORY', + TOKEN_DIRECTORY_PUBLIC_TOKEN_LIST = 'TOKEN_DIRECTORY_PUBLIC_TOKEN_LIST', + TOKEN_DIRECTORY_3RD_PARTY = 'TOKEN_DIRECTORY_3RD_PARTY', + TOKEN_DIRECTORY_SEQUENCE_GITHUB = 'TOKEN_DIRECTORY_SEQUENCE_GITHUB', + TOKEN_DIRECTORY_SEQUENCE_BUILDER = 'TOKEN_DIRECTORY_SEQUENCE_BUILDER', + SEQUENCE_BUILDER = 'SEQUENCE_BUILDER', + SEQUENCE_BUILDER_COLLECTIONS = 'SEQUENCE_BUILDER_COLLECTIONS' +} + +export enum ResourceStatus { + NOT_AVAILABLE = 'NOT_AVAILABLE', + STALE = 'STALE', + AVAILABLE = 'AVAILABLE' +} + export enum PropertyType { INT = 'INT', STRING = 'STRING', @@ -39,11 +114,10 @@ export enum SwapType { } export enum TaskStatus { - PENDING = 'PENDING', + QUEUED = 'QUEUED', PAUSED = 'PAUSED', FAILED = 'FAILED', - COMPLETED = 'COMPLETED', - DISABLED = 'DISABLED' + COMPLETED = 'COMPLETED' } export interface Version { @@ -57,10 +131,20 @@ export interface RuntimeStatus { healthOK: boolean startTime: string uptime: number + uptimeString: string ver: string branch: string commitHash: string checks: RuntimeChecks + runnable: { [key: string]: RunnableStatus } +} + +export interface RunnableStatus { + running: boolean + restarts: number + startTime: string + endTime?: string + lastError: any } export interface RuntimeChecks {} @@ -69,16 +153,20 @@ export interface ContractIndex { chainId: number address: string type: ContractType + source: Source metadata: { [key: string]: any } contentHash: number deployed: boolean bytecodeHash: string notFound: boolean updatedAt: string + queuedAt?: string + status: ResourceStatus } export interface TokenIndex { key: string + source: Source chainId: number contractAddress: string tokenId: string @@ -87,11 +175,13 @@ export interface TokenIndex { lastFetched?: string fetchCount?: number updatedAt: string + queuedAt?: string } export interface ContractInfo { chainId: number address: string + source: string name: string type: string symbol: string @@ -101,12 +191,17 @@ export interface ContractInfo { bytecodeHash: string extensions: ContractInfoExtensions updatedAt: string + notFound: boolean + queuedAt?: string + status: ResourceStatus } export interface ContractInfoExtensions { link: string description: string + categories: Array ogImage: string + ogName: string originChainId: number originAddress: string blacklist: boolean @@ -117,6 +212,7 @@ export interface ContractInfoExtensions { export interface TokenMetadata { tokenId: string + source: string name: string description?: string image?: string @@ -131,6 +227,9 @@ export interface TokenMetadata { decimals?: number updatedAt?: string assets?: Array + status: ResourceStatus + queuedAt?: string + lastFetched?: string } export interface PropertyFilter { @@ -152,6 +251,7 @@ export interface Collection { metadata: CollectionMetadata private: boolean revealKey?: string + tokenCount?: number createdAt?: string updatedAt?: string deletedAt?: string @@ -245,7 +345,8 @@ export interface Metadata { ping(headers?: object, signal?: AbortSignal): Promise version(headers?: object, signal?: AbortSignal): Promise runtimeStatus(headers?: object, signal?: AbortSignal): Promise - getTokenMetadata(args: GetTokenMetadataArgs, headers?: object, signal?: AbortSignal): Promise + getTask(args: GetTaskArgs, headers?: object, signal?: AbortSignal): Promise + getTaskStatus(args: GetTaskStatusArgs, headers?: object, signal?: AbortSignal): Promise refreshTokenMetadata( args: RefreshTokenMetadataArgs, headers?: object, @@ -267,6 +368,18 @@ export interface Metadata { signal?: AbortSignal ): Promise cancelRefreshJob(args: CancelRefreshJobArgs, headers?: object, signal?: AbortSignal): Promise + refreshContractInfo(args: RefreshContractInfoArgs, headers?: object, signal?: AbortSignal): Promise + refreshContractTokens( + args: RefreshContractTokensArgs, + headers?: object, + signal?: AbortSignal + ): Promise + refreshAllContractTokens( + args: RefreshAllContractTokensArgs, + headers?: object, + signal?: AbortSignal + ): Promise + getTokenMetadata(args: GetTokenMetadataArgs, headers?: object, signal?: AbortSignal): Promise getTokenMetadataBatch( args: GetTokenMetadataBatchArgs, headers?: object, @@ -368,14 +481,19 @@ export interface RuntimeStatusArgs {} export interface RuntimeStatusReturn { status: RuntimeStatus } -export interface GetTokenMetadataArgs { - chainID: string - contractAddress: string - tokenIDs: Array +export interface GetTaskArgs { + taskId: number } -export interface GetTokenMetadataReturn { - tokenMetadata: Array +export interface GetTaskReturn { + task: Task +} +export interface GetTaskStatusArgs { + taskId: number +} + +export interface GetTaskStatusReturn { + status?: TaskStatus } export interface RefreshTokenMetadataArgs { chainID: string @@ -420,6 +538,40 @@ export interface CancelRefreshJobArgs { export interface CancelRefreshJobReturn { ok: boolean } +export interface RefreshContractInfoArgs { + chainHandle: string + contractAddress: string +} + +export interface RefreshContractInfoReturn {} +export interface RefreshContractTokensArgs { + chainHandle: string + contractAddress: string + tokenIDs: Array +} + +export interface RefreshContractTokensReturn { + taskID?: number +} +export interface RefreshAllContractTokensArgs { + chainHandle: string + contractAddress: string +} + +export interface RefreshAllContractTokensReturn { + taskID?: number + retryAfter: number +} +export interface GetTokenMetadataArgs { + chainID: string + contractAddress: string + tokenIDs: Array +} + +export interface GetTokenMetadataReturn { + tokenMetadata: Array + taskID?: number +} export interface GetTokenMetadataBatchArgs { chainID: string contractTokenMap: { [key: string]: Array } @@ -427,6 +579,7 @@ export interface GetTokenMetadataBatchArgs { export interface GetTokenMetadataBatchReturn { contractTokenMetadata: { [key: string]: Array } + taskID?: number } export interface SearchTokenMetadataArgs { chainID: string @@ -465,6 +618,7 @@ export interface GetContractInfoArgs { export interface GetContractInfoReturn { contractInfo: ContractInfo + taskID?: number } export interface GetContractInfoBatchArgs { chainID: string @@ -473,6 +627,7 @@ export interface GetContractInfoBatchArgs { export interface GetContractInfoBatchReturn { contractInfoMap: { [key: string]: ContractInfo } + taskID?: number } export interface SearchContractInfoArgs { contractAddress: string @@ -764,6 +919,7 @@ export interface ListContractCollectionsArgs { export interface ListContractCollectionsReturn { contractCollections: Array + collections: Array page: Page } export interface UpdateContractCollectionArgs { @@ -937,7 +1093,7 @@ export class Metadata implements Metadata { protected path = '/rpc/Metadata/' constructor(hostname: string, fetch: Fetch) { - this.hostname = hostname + this.hostname = hostname.replace(/\/*$/, '') this.fetch = (input: RequestInfo, init?: RequestInit) => fetch(input, init) } @@ -990,12 +1146,27 @@ export class Metadata implements Metadata { ) } - getTokenMetadata = (args: GetTokenMetadataArgs, headers?: object, signal?: AbortSignal): Promise => { - return this.fetch(this.url('GetTokenMetadata'), createHTTPRequest(args, headers, signal)).then( + getTask = (args: GetTaskArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('GetTask'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { return { - tokenMetadata: >_data.tokenMetadata + task: _data.task + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + getTaskStatus = (args: GetTaskStatusArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('GetTaskStatus'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + status: _data.status } }) }, @@ -1098,6 +1269,78 @@ export class Metadata implements Metadata { ) } + refreshContractInfo = ( + args: RefreshContractInfoArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('RefreshContractInfo'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return {} + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + refreshContractTokens = ( + args: RefreshContractTokensArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('RefreshContractTokens'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + taskID: _data.taskID + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + refreshAllContractTokens = ( + args: RefreshAllContractTokensArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('RefreshAllContractTokens'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + taskID: _data.taskID, + retryAfter: _data.retryAfter + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + getTokenMetadata = (args: GetTokenMetadataArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('GetTokenMetadata'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + tokenMetadata: >_data.tokenMetadata, + taskID: _data.taskID + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + getTokenMetadataBatch = ( args: GetTokenMetadataBatchArgs, headers?: object, @@ -1107,7 +1350,8 @@ export class Metadata implements Metadata { res => { return buildResponse(res).then(_data => { return { - contractTokenMetadata: <{ [key: string]: Array }>_data.contractTokenMetadata + contractTokenMetadata: <{ [key: string]: Array }>_data.contractTokenMetadata, + taskID: _data.taskID } }) }, @@ -1177,7 +1421,8 @@ export class Metadata implements Metadata { res => { return buildResponse(res).then(_data => { return { - contractInfo: _data.contractInfo + contractInfo: _data.contractInfo, + taskID: _data.taskID } }) }, @@ -1196,7 +1441,8 @@ export class Metadata implements Metadata { res => { return buildResponse(res).then(_data => { return { - contractInfoMap: <{ [key: string]: ContractInfo }>_data.contractInfoMap + contractInfoMap: <{ [key: string]: ContractInfo }>_data.contractInfoMap, + taskID: _data.taskID } }) }, @@ -1544,7 +1790,7 @@ export class Collections implements Collections { protected path = '/rpc/Collections/' constructor(hostname: string, fetch: Fetch) { - this.hostname = hostname + this.hostname = hostname.replace(/\/*$/, '') this.fetch = (input: RequestInfo, init?: RequestInit) => fetch(input, init) } @@ -1710,6 +1956,7 @@ export class Collections implements Collections { return buildResponse(res).then(_data => { return { contractCollections: >_data.contractCollections, + collections: >_data.collections, page: _data.page } }) @@ -1902,7 +2149,7 @@ export class Admin implements Admin { protected path = '/rpc/Admin/' constructor(hostname: string, fetch: Fetch) { - this.hostname = hostname + this.hostname = hostname.replace(/\/*$/, '') this.fetch = (input: RequestInfo, init?: RequestInit) => fetch(input, init) } @@ -2004,9 +2251,12 @@ export class Admin implements Admin { } const createHTTPRequest = (body: object = {}, headers: object = {}, signal: AbortSignal | null = null): object => { + const reqHeaders: { [key: string]: string } = { ...headers, 'Content-Type': 'application/json' } + reqHeaders[WebrpcHeader] = WebrpcHeaderValue + return { method: 'POST', - headers: { ...headers, 'Content-Type': 'application/json' }, + headers: reqHeaders, body: JSON.stringify(body || {}), signal } diff --git a/packages/migration/CHANGELOG.md b/packages/migration/CHANGELOG.md index 43e8540e8..8fe48eafe 100644 --- a/packages/migration/CHANGELOG.md +++ b/packages/migration/CHANGELOG.md @@ -1,5 +1,556 @@ # @0xsequence/migration +## 2.2.14 + +### Patch Changes + +- Somnia Testnet and Monad Testnet +- Updated dependencies + - @0xsequence/abi@2.2.14 + - @0xsequence/core@2.2.14 + - @0xsequence/wallet@2.2.14 + +## 2.2.13 + +### Patch Changes + +- Add XR1 to all networks +- Updated dependencies + - @0xsequence/abi@2.2.13 + - @0xsequence/core@2.2.13 + - @0xsequence/wallet@2.2.13 + +## 2.2.12 + +### Patch Changes + +- Add XR1 +- Updated dependencies + - @0xsequence/abi@2.2.12 + - @0xsequence/core@2.2.12 + - @0xsequence/wallet@2.2.12 + +## 2.2.11 + +### Patch Changes + +- Relayer updates +- Updated dependencies + - @0xsequence/abi@2.2.11 + - @0xsequence/core@2.2.11 + - @0xsequence/wallet@2.2.11 + +## 2.2.10 + +### Patch Changes + +- Etherlink support +- Updated dependencies + - @0xsequence/abi@2.2.10 + - @0xsequence/core@2.2.10 + - @0xsequence/wallet@2.2.10 + +## 2.2.9 + +### Patch Changes + +- Indexer gateway native token balances +- Updated dependencies + - @0xsequence/abi@2.2.9 + - @0xsequence/core@2.2.9 + - @0xsequence/wallet@2.2.9 + +## 2.2.8 + +### Patch Changes + +- Add Moonbeam and Moonbase Alpha +- Updated dependencies + - @0xsequence/abi@2.2.8 + - @0xsequence/core@2.2.8 + - @0xsequence/wallet@2.2.8 + +## 2.2.7 + +### Patch Changes + +- Update Builder package +- Updated dependencies + - @0xsequence/abi@2.2.7 + - @0xsequence/core@2.2.7 + - @0xsequence/wallet@2.2.7 + +## 2.2.6 + +### Patch Changes + +- Update relayer package +- Updated dependencies + - @0xsequence/abi@2.2.6 + - @0xsequence/core@2.2.6 + - @0xsequence/wallet@2.2.6 + +## 2.2.5 + +### Patch Changes + +- auth: fix sequence indexer gateway url +- account: immutable wallet proxy hook +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.2.5 + - @0xsequence/core@2.2.5 + - @0xsequence/wallet@2.2.5 + +## 2.2.4 + +### Patch Changes + +- network: update soneium mainnet block explorer url +- waas: signTypedData intent support +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.2.4 + - @0xsequence/core@2.2.4 + - @0xsequence/wallet@2.2.4 + +## 2.2.3 + +### Patch Changes + +- provider: updating initWallet to use connected network configs if they exist +- Updated dependencies + - @0xsequence/abi@2.2.3 + - @0xsequence/core@2.2.3 + - @0xsequence/wallet@2.2.3 + +## 2.2.2 + +### Patch Changes + +- pass projectAccessKey to relayer at all times +- Updated dependencies + - @0xsequence/abi@2.2.2 + - @0xsequence/core@2.2.2 + - @0xsequence/wallet@2.2.2 + +## 2.2.1 + +### Patch Changes + +- waas-ethers: sign typed data +- Updated dependencies + - @0xsequence/abi@2.2.1 + - @0xsequence/core@2.2.1 + - @0xsequence/wallet@2.2.1 + +## 2.2.0 + +### Minor Changes + +- indexer: gateway client +- @0xsequence/builder +- upgrade puppeteer to v23.10.3 + +### Patch Changes + +- Updated dependencies +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.2.0 + - @0xsequence/core@2.2.0 + - @0xsequence/wallet@2.2.0 + +## 2.1.8 + +### Patch Changes + +- Add Soneium Mainnet +- Updated dependencies + - @0xsequence/abi@2.1.8 + - @0xsequence/core@2.1.8 + - @0xsequence/wallet@2.1.8 + +## 2.1.7 + +### Patch Changes + +- guard: pass project access key to guard requests +- Updated dependencies + - @0xsequence/abi@2.1.7 + - @0xsequence/core@2.1.7 + - @0xsequence/wallet@2.1.7 + +## 2.1.6 + +### Patch Changes + +- Add LAOS and Telos Testnet chains +- Updated dependencies + - @0xsequence/abi@2.1.6 + - @0xsequence/core@2.1.6 + - @0xsequence/wallet@2.1.6 + +## 2.1.5 + +### Patch Changes + +- account: save presigned configuration with reference chain id 1 +- Updated dependencies + - @0xsequence/abi@2.1.5 + - @0xsequence/core@2.1.5 + - @0xsequence/wallet@2.1.5 + +## 2.1.4 + +### Patch Changes + +- provider: pass projectAccessKey into MuxMessageProvider +- Updated dependencies + - @0xsequence/abi@2.1.4 + - @0xsequence/core@2.1.4 + - @0xsequence/wallet@2.1.4 + +## 2.1.3 + +### Patch Changes + +- waas: time drift date fix due to strange browser quirk +- Updated dependencies + - @0xsequence/abi@2.1.3 + - @0xsequence/core@2.1.3 + - @0xsequence/wallet@2.1.3 + +## 2.1.2 + +### Patch Changes + +- provider: export analytics correctly +- Updated dependencies + - @0xsequence/abi@2.1.2 + - @0xsequence/core@2.1.2 + - @0xsequence/wallet@2.1.2 + +## 2.1.1 + +### Patch Changes + +- Add LAOS chain support +- Updated dependencies + - @0xsequence/abi@2.1.1 + - @0xsequence/core@2.1.1 + - @0xsequence/wallet@2.1.1 + +## 2.1.0 + +### Minor Changes + +- account: forward project access key when estimating fees and sending transactions + +### Patch Changes + +- sessions: save signatures with reference chain id +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.1.0 + - @0xsequence/core@2.1.0 + - @0xsequence/wallet@2.1.0 + +## 2.0.26 + +### Patch Changes + +- account: fix chain id comparison +- Updated dependencies + - @0xsequence/abi@2.0.26 + - @0xsequence/core@2.0.26 + - @0xsequence/wallet@2.0.26 + +## 2.0.25 + +### Patch Changes + +- skale-nebula: deploy gas limit = 10m +- Updated dependencies + - @0xsequence/abi@2.0.25 + - @0xsequence/core@2.0.25 + - @0xsequence/wallet@2.0.25 + +## 2.0.24 + +### Patch Changes + +- sessions: arweave: configurable gateway url +- waas: use /status to get time drift before sending any intents +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.24 + - @0xsequence/core@2.0.24 + - @0xsequence/wallet@2.0.24 + +## 2.0.23 + +### Patch Changes + +- Add The Root Network support +- Updated dependencies + - @0xsequence/abi@2.0.23 + - @0xsequence/core@2.0.23 + - @0xsequence/wallet@2.0.23 + +## 2.0.22 + +### Patch Changes + +- Add SKALE Nebula Mainnet support +- Updated dependencies + - @0xsequence/abi@2.0.22 + - @0xsequence/core@2.0.22 + - @0xsequence/wallet@2.0.22 + +## 2.0.21 + +### Patch Changes + +- account: add publishWitnessFor +- Updated dependencies + - @0xsequence/abi@2.0.21 + - @0xsequence/core@2.0.21 + - @0xsequence/wallet@2.0.21 + +## 2.0.20 + +### Patch Changes + +- upgrade deps, and improve waas session status handling +- Updated dependencies + - @0xsequence/abi@2.0.20 + - @0xsequence/core@2.0.20 + - @0xsequence/wallet@2.0.20 + +## 2.0.19 + +### Patch Changes + +- Add Immutable zkEVM support +- Updated dependencies + - @0xsequence/abi@2.0.19 + - @0xsequence/core@2.0.19 + - @0xsequence/wallet@2.0.19 + +## 2.0.18 + +### Patch Changes + +- waas: new contractCall transaction type +- sessions: add arweave owner +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.18 + - @0xsequence/core@2.0.18 + - @0xsequence/wallet@2.0.18 + +## 2.0.17 + +### Patch Changes + +- update waas auth to clear session before signIn +- Updated dependencies + - @0xsequence/abi@2.0.17 + - @0xsequence/core@2.0.17 + - @0xsequence/wallet@2.0.17 + +## 2.0.16 + +### Patch Changes + +- Removed Astar chains +- Updated dependencies + - @0xsequence/abi@2.0.16 + - @0xsequence/core@2.0.16 + - @0xsequence/wallet@2.0.16 + +## 2.0.15 + +### Patch Changes + +- indexer: update bindings with token balance additions +- Updated dependencies + - @0xsequence/abi@2.0.15 + - @0xsequence/core@2.0.15 + - @0xsequence/wallet@2.0.15 + +## 2.0.14 + +### Patch Changes + +- sessions: arweave config reader +- network: add b3 and apechain mainnet configs +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.14 + - @0xsequence/core@2.0.14 + - @0xsequence/wallet@2.0.14 + +## 2.0.13 + +### Patch Changes + +- network: toy-testnet +- Updated dependencies + - @0xsequence/abi@2.0.13 + - @0xsequence/core@2.0.13 + - @0xsequence/wallet@2.0.13 + +## 2.0.12 + +### Patch Changes + +- api: update bindings +- Updated dependencies + - @0xsequence/abi@2.0.12 + - @0xsequence/core@2.0.12 + - @0xsequence/wallet@2.0.12 + +## 2.0.11 + +### Patch Changes + +- waas: intents test fix +- api: update bindings +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.11 + - @0xsequence/core@2.0.11 + - @0xsequence/wallet@2.0.11 + +## 2.0.10 + +### Patch Changes + +- network: soneium minato testnet +- Updated dependencies + - @0xsequence/abi@2.0.10 + - @0xsequence/core@2.0.10 + - @0xsequence/wallet@2.0.10 + +## 2.0.9 + +### Patch Changes + +- network: fix SKALE network name +- Updated dependencies + - @0xsequence/abi@2.0.9 + - @0xsequence/core@2.0.9 + - @0xsequence/wallet@2.0.9 + +## 2.0.8 + +### Patch Changes + +- metadata: update bindings +- Updated dependencies + - @0xsequence/abi@2.0.8 + - @0xsequence/core@2.0.8 + - @0xsequence/wallet@2.0.8 + +## 2.0.7 + +### Patch Changes + +- wallet request handler fix +- Updated dependencies + - @0xsequence/abi@2.0.7 + - @0xsequence/core@2.0.7 + - @0xsequence/wallet@2.0.7 + +## 2.0.6 + +### Patch Changes + +- network: matic -> pol +- Updated dependencies + - @0xsequence/abi@2.0.6 + - @0xsequence/core@2.0.6 + - @0xsequence/wallet@2.0.6 + +## 2.0.5 + +### Patch Changes + +- provider: update databeat to 0.9.2 +- Updated dependencies + - @0xsequence/abi@2.0.5 + - @0xsequence/core@2.0.5 + - @0xsequence/wallet@2.0.5 + +## 2.0.4 + +### Patch Changes + +- network: add skale-nebula-testnet +- Updated dependencies + - @0xsequence/abi@2.0.4 + - @0xsequence/core@2.0.4 + - @0xsequence/wallet@2.0.4 + +## 2.0.3 + +### Patch Changes + +- waas: check session status in SequenceWaaS.isSignedIn() +- Updated dependencies + - @0xsequence/abi@2.0.3 + - @0xsequence/core@2.0.3 + - @0xsequence/wallet@2.0.3 + +## 2.0.2 + +### Patch Changes + +- sessions: property convert serialized bignumber hex value to bigint +- Updated dependencies + - @0xsequence/abi@2.0.2 + - @0xsequence/core@2.0.2 + - @0xsequence/wallet@2.0.2 + +## 2.0.1 + +### Patch Changes + +- waas: http signature check for authenticator requests +- provider: unwrap legacy json rpc responses +- use json replacer and reviver for bigints +- Updated dependencies +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.1 + - @0xsequence/core@2.0.1 + - @0xsequence/wallet@2.0.1 + +## 2.0.0 + +### Major Changes + +- ethers v6 + +### Patch Changes + +- Updated dependencies + - @0xsequence/abi@2.0.0 + - @0xsequence/core@2.0.0 + - @0xsequence/wallet@2.0.0 + +## 1.10.15 + +### Patch Changes + +- utils: extractProjectIdFromAccessKey +- Updated dependencies + - @0xsequence/abi@1.10.15 + - @0xsequence/core@1.10.15 + - @0xsequence/wallet@1.10.15 + ## 1.10.14 ### Patch Changes diff --git a/packages/migration/package.json b/packages/migration/package.json index 8c2cbcb20..149ee0b5b 100644 --- a/packages/migration/package.json +++ b/packages/migration/package.json @@ -1,6 +1,6 @@ { "name": "@0xsequence/migration", - "version": "1.10.14", + "version": "2.2.14", "description": "tools for migrating sequence wallets to new versions", "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/migration", "source": "src/index.ts", @@ -11,14 +11,17 @@ "scripts": { "test": "echo 'TODO: Migration tests'" }, + "peerDependencies": { + "ethers": ">=6" + }, "dependencies": { "@0xsequence/abi": "workspace:*", "@0xsequence/core": "workspace:*", - "@0xsequence/wallet": "workspace:*", - "ethers": "^5.5.2" + "@0xsequence/wallet": "workspace:*" }, "devDependencies": { "@istanbuljs/nyc-config-typescript": "^1.0.2", + "ethers": "6.13.4", "nyc": "^15.1.0" }, "files": [ diff --git a/packages/migration/src/migrations/migration_01_02.ts b/packages/migration/src/migrations/migration_01_02.ts index cbd7a0701..925d4422e 100644 --- a/packages/migration/src/migrations/migration_01_02.ts +++ b/packages/migration/src/migrations/migration_01_02.ts @@ -28,7 +28,7 @@ export class Migration_v1v2 implements Migration globalThis -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.10.12 - - @0xsequence/network@1.10.12 - - @0xsequence/utils@1.10.12 - -## 1.10.11 - -### Patch Changes - -- waas: updated intent.gen without webrpc types, errors exported from authenticator.gen -- Updated dependencies - - @0xsequence/abi@1.10.11 - - @0xsequence/network@1.10.11 - - @0xsequence/utils@1.10.11 - -## 1.10.10 - -### Patch Changes - -- metadata: update bindings with new contract collections api -- Updated dependencies - - @0xsequence/abi@1.10.10 - - @0xsequence/network@1.10.10 - - @0xsequence/utils@1.10.10 - -## 1.10.9 - -### Patch Changes - -- waas minor update -- Updated dependencies - - @0xsequence/abi@1.10.9 - - @0xsequence/network@1.10.9 - - @0xsequence/utils@1.10.9 - -## 1.10.8 - -### Patch Changes - -- update metadata bindings -- Updated dependencies - - @0xsequence/abi@1.10.8 - - @0xsequence/network@1.10.8 - - @0xsequence/utils@1.10.8 - -## 1.10.7 - -### Patch Changes - -- minor fixes to waas client -- Updated dependencies - - @0xsequence/abi@1.10.7 - - @0xsequence/network@1.10.7 - - @0xsequence/utils@1.10.7 - -## 1.10.6 - -### Patch Changes - -- metadata: update bindings -- Updated dependencies - - @0xsequence/abi@1.10.6 - - @0xsequence/network@1.10.6 - - @0xsequence/utils@1.10.6 - -## 1.10.5 - -### Patch Changes - -- network: ape-chain-testnet -> apechain-testnet -- Updated dependencies - - @0xsequence/abi@1.10.5 - - @0xsequence/network@1.10.5 - - @0xsequence/utils@1.10.5 - -## 1.10.4 - -### Patch Changes - -- network: add b3-sepolia, ape-chain-testnet, blast, blast-sepolia -- Updated dependencies - - @0xsequence/abi@1.10.4 - - @0xsequence/network@1.10.4 - - @0xsequence/utils@1.10.4 - -## 1.10.3 - -### Patch Changes - -- typing fix -- Updated dependencies - - @0xsequence/abi@1.10.3 - - @0xsequence/network@1.10.3 - - @0xsequence/utils@1.10.3 - -## 1.10.2 - -### Patch Changes - -- - waas: add getIdToken method - - indexer: update api client -- Updated dependencies - - @0xsequence/abi@1.10.2 - - @0xsequence/network@1.10.2 - - @0xsequence/utils@1.10.2 - -## 1.10.1 - -### Patch Changes - -- metadata: update bindings -- Updated dependencies - - @0xsequence/abi@1.10.1 - - @0xsequence/network@1.10.1 - - @0xsequence/utils@1.10.1 - -## 1.10.0 - -### Minor Changes - -- waas release v1.3.0 - -### Patch Changes - -- Updated dependencies - - @0xsequence/abi@1.10.0 - - @0xsequence/network@1.10.0 - - @0xsequence/utils@1.10.0 - -## 1.9.37 - -### Patch Changes - -- network: adds nativeToken data to NetworkMetadata constants -- Updated dependencies - - @0xsequence/abi@1.9.37 - - @0xsequence/network@1.9.37 - - @0xsequence/utils@1.9.37 - -## 1.9.36 - -### Patch Changes - -- guard: export client -- Updated dependencies - - @0xsequence/abi@1.9.36 - - @0xsequence/network@1.9.36 - - @0xsequence/utils@1.9.36 - -## 1.9.35 - -### Patch Changes - -- guard: update bindings -- Updated dependencies - - @0xsequence/abi@1.9.35 - - @0xsequence/network@1.9.35 - - @0xsequence/utils@1.9.35 - -## 1.9.34 - -### Patch Changes - -- waas: always use lowercase email -- Updated dependencies - - @0xsequence/abi@1.9.34 - - @0xsequence/network@1.9.34 - - @0xsequence/utils@1.9.34 - -## 1.9.33 - -### Patch Changes - -- waas: umd build -- Updated dependencies - - @0xsequence/abi@1.9.33 - - @0xsequence/network@1.9.33 - - @0xsequence/utils@1.9.33 - -## 1.9.32 - -### Patch Changes - -- indexer: update bindings -- Updated dependencies - - @0xsequence/abi@1.9.32 - - @0xsequence/network@1.9.32 - - @0xsequence/utils@1.9.32 - -## 1.9.31 - -### Patch Changes - -- metadata: token directory changes -- Updated dependencies - - @0xsequence/abi@1.9.31 - - @0xsequence/network@1.9.31 - - @0xsequence/utils@1.9.31 - -## 1.9.30 - -### Patch Changes - -- update -- Updated dependencies - - @0xsequence/abi@1.9.30 - - @0xsequence/network@1.9.30 - - @0xsequence/utils@1.9.30 - -## 1.9.29 - -### Patch Changes - -- disable gnosis chain -- Updated dependencies - - @0xsequence/abi@1.9.29 - - @0xsequence/network@1.9.29 - - @0xsequence/utils@1.9.29 - -## 1.9.28 - -### Patch Changes - -- add utils/merkletree -- Updated dependencies - - @0xsequence/abi@1.9.28 - - @0xsequence/network@1.9.28 - - @0xsequence/utils@1.9.28 - -## 1.9.27 - -### Patch Changes - -- network: optimistic -> optimism -- waas: remove defaults -- api, sessions: update bindings -- Updated dependencies -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.9.27 - - @0xsequence/network@1.9.27 - - @0xsequence/utils@1.9.27 - -## 1.9.26 - -### Patch Changes - -- - add backend interfaces for pluggable interfaces - - introduce @0xsequence/react-native - - update pnpm to lockfile v9 -- Updated dependencies - - @0xsequence/abi@1.9.26 - - @0xsequence/network@1.9.26 - - @0xsequence/utils@1.9.26 - -## 1.9.25 - -### Patch Changes - -- update webrpc clients with new error types -- Updated dependencies - - @0xsequence/abi@1.9.25 - - @0xsequence/network@1.9.25 - - @0xsequence/utils@1.9.25 - -## 1.9.24 - -### Patch Changes - -- waas: add memoryStore backend to localStore -- Updated dependencies - - @0xsequence/abi@1.9.24 - - @0xsequence/network@1.9.24 - - @0xsequence/utils@1.9.24 - -## 1.9.23 - -### Patch Changes - -- update api client bindings -- Updated dependencies - - @0xsequence/abi@1.9.23 - - @0xsequence/network@1.9.23 - - @0xsequence/utils@1.9.23 - -## 1.9.22 - -### Patch Changes - -- update metadata client bindings -- Updated dependencies - - @0xsequence/abi@1.9.22 - - @0xsequence/network@1.9.22 - - @0xsequence/utils@1.9.22 - -## 1.9.21 - -### Patch Changes - -- api client bindings -- Updated dependencies - - @0xsequence/abi@1.9.21 - - @0xsequence/network@1.9.21 - - @0xsequence/utils@1.9.21 - -## 1.9.20 - -### Patch Changes - -- api client bindings update -- Updated dependencies - - @0xsequence/abi@1.9.20 - - @0xsequence/network@1.9.20 - - @0xsequence/utils@1.9.20 - -## 1.9.19 - -### Patch Changes - -- waas update -- Updated dependencies - - @0xsequence/abi@1.9.19 - - @0xsequence/network@1.9.19 - - @0xsequence/utils@1.9.19 - -## 1.9.18 - -### Patch Changes - -- provider: prohibit dangerous functions -- Updated dependencies - - @0xsequence/abi@1.9.18 - - @0xsequence/network@1.9.18 - - @0xsequence/utils@1.9.18 - -## 1.9.17 - -### Patch Changes - -- network: add xr-sepolia -- Updated dependencies - - @0xsequence/network@1.9.17 - - @0xsequence/abi@1.9.17 - - @0xsequence/utils@1.9.17 - -## 1.9.16 - -### Patch Changes - -- waas: sequence.feeOptions -- Updated dependencies - - @0xsequence/abi@1.9.16 - - @0xsequence/network@1.9.16 - - @0xsequence/utils@1.9.16 - -## 1.9.15 - -### Patch Changes - -- metadata: collection external_link field name fix -- Updated dependencies - - @0xsequence/abi@1.9.15 - - @0xsequence/network@1.9.15 - - @0xsequence/utils@1.9.15 - -## 1.9.14 - -### Patch Changes - -- network: astar-zkatana -> astar-zkyoto -- network: deprecate polygon mumbai network -- network: add xai and polygon amoy -- Updated dependencies -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.9.14 - - @0xsequence/network@1.9.14 - - @0xsequence/utils@1.9.14 - -## 1.9.13 - -### Patch Changes - -- waas: fix @0xsequence/network dependency -- Updated dependencies - - @0xsequence/abi@1.9.13 - - @0xsequence/network@1.9.13 - - @0xsequence/utils@1.9.13 - -## 1.9.12 - -### Patch Changes - -- indexer: update rpc bindings -- provider: signMessage: Serialize the BytesLike or string message into hexstring before sending -- waas: SessionAuthProof -- Updated dependencies -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.9.12 - - @0xsequence/network@1.9.12 - - @0xsequence/utils@1.9.12 - -## 1.9.11 - -### Patch Changes - -- metdata, update rpc bindings -- Updated dependencies - - @0xsequence/abi@1.9.11 - - @0xsequence/network@1.9.11 - - @0xsequence/utils@1.9.11 - -## 1.9.10 - -### Patch Changes - -- update metadata rpc bindings -- Updated dependencies - - @0xsequence/abi@1.9.10 - - @0xsequence/network@1.9.10 - - @0xsequence/utils@1.9.10 - -## 1.9.9 - -### Patch Changes - -- metadata, add SequenceCollections rpc client -- Updated dependencies - - @0xsequence/abi@1.9.9 - - @0xsequence/network@1.9.9 - - @0xsequence/utils@1.9.9 - -## 1.9.8 - -### Patch Changes - -- waas client update -- Updated dependencies - - @0xsequence/abi@1.9.8 - - @0xsequence/network@1.9.8 - - @0xsequence/utils@1.9.8 - -## 1.9.7 - -### Patch Changes - -- update rpc client bindings for api, metadata and relayer -- Updated dependencies - - @0xsequence/abi@1.9.7 - - @0xsequence/network@1.9.7 - - @0xsequence/utils@1.9.7 - -## 1.9.6 - -### Patch Changes - -- waas package update -- Updated dependencies - - @0xsequence/abi@1.9.6 - - @0xsequence/network@1.9.6 - - @0xsequence/utils@1.9.6 - -## 1.9.5 - -### Patch Changes - -- RpcRelayer prioritize project access key -- Updated dependencies - - @0xsequence/abi@1.9.5 - - @0xsequence/network@1.9.5 - - @0xsequence/utils@1.9.5 - -## 1.9.4 - -### Patch Changes - -- waas: fix network dependency -- Updated dependencies - - @0xsequence/abi@1.9.4 - - @0xsequence/network@1.9.4 - - @0xsequence/utils@1.9.4 - -## 1.9.3 - -### Patch Changes - -- provider: don't append access key to RPC url if user has already provided it -- Updated dependencies - - @0xsequence/abi@1.9.3 - - @0xsequence/network@1.9.3 - - @0xsequence/utils@1.9.3 - -## 1.9.2 - -### Patch Changes - -- network: add xai-sepolia -- Updated dependencies - - @0xsequence/abi@1.9.2 - - @0xsequence/network@1.9.2 - - @0xsequence/utils@1.9.2 - -## 1.9.1 - -### Patch Changes - -- analytics fix -- Updated dependencies - - @0xsequence/abi@1.9.1 - - @0xsequence/network@1.9.1 - - @0xsequence/utils@1.9.1 - -## 1.9.0 - -### Minor Changes - -- waas release - -### Patch Changes - -- Updated dependencies - - @0xsequence/abi@1.9.0 - - @0xsequence/network@1.9.0 - - @0xsequence/utils@1.9.0 - -## 1.8.8 - -### Patch Changes - -- update metadata bindings -- Updated dependencies - - @0xsequence/abi@1.8.8 - - @0xsequence/network@1.8.8 - - @0xsequence/utils@1.8.8 - -## 1.8.7 - -### Patch Changes - -- provider: update databeat to 0.9.1 -- Updated dependencies - - @0xsequence/abi@1.8.7 - - @0xsequence/network@1.8.7 - - @0xsequence/utils@1.8.7 - -## 1.8.6 - -### Patch Changes - -- guard: SignedOwnershipProof -- Updated dependencies - - @0xsequence/abi@1.8.6 - - @0xsequence/network@1.8.6 - - @0xsequence/utils@1.8.6 - -## 1.8.5 - -### Patch Changes - -- guard: signOwnershipProof and isSignedOwnershipProof -- Updated dependencies - - @0xsequence/abi@1.8.5 - - @0xsequence/network@1.8.5 - - @0xsequence/utils@1.8.5 - -## 1.8.4 - -### Patch Changes - -- network: add homeverse to networks list -- Updated dependencies - - @0xsequence/abi@1.8.4 - - @0xsequence/network@1.8.4 - - @0xsequence/utils@1.8.4 - -## 1.8.3 - -### Patch Changes - -- api: introduce basic linked wallet support -- Updated dependencies - - @0xsequence/abi@1.8.3 - - @0xsequence/network@1.8.3 - - @0xsequence/utils@1.8.3 - -## 1.8.2 - -### Patch Changes - -- provider: don't initialize analytics unless explicitly requested -- Updated dependencies - - @0xsequence/abi@1.8.2 - - @0xsequence/network@1.8.2 - - @0xsequence/utils@1.8.2 - -## 1.8.1 - -### Patch Changes - -- update to analytics provider -- Updated dependencies - - @0xsequence/abi@1.8.1 - - @0xsequence/network@1.8.1 - - @0xsequence/utils@1.8.1 - -## 1.8.0 - -### Minor Changes - -- provider: project analytics - -### Patch Changes - -- Updated dependencies - - @0xsequence/abi@1.8.0 - - @0xsequence/network@1.8.0 - - @0xsequence/utils@1.8.0 - -## 1.7.2 - -### Patch Changes - -- 0xsequence: ChainId should not be exported as a type -- account, wallet: fix nonce selection -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.7.2 - - @0xsequence/network@1.7.2 - - @0xsequence/utils@1.7.2 - -## 1.7.1 - -### Patch Changes - -- network: add missing avalanche logoURI -- Updated dependencies - - @0xsequence/abi@1.7.1 - - @0xsequence/network@1.7.1 - - @0xsequence/utils@1.7.1 - -## 1.7.0 - -### Minor Changes - -- provider: projectAccessKey is now required - -### Patch Changes - -- network: add NetworkMetadata.logoURI property for all networks -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.7.0 - - @0xsequence/network@1.7.0 - - @0xsequence/utils@1.7.0 - -## 1.6.3 - -### Patch Changes - -- network list update -- Updated dependencies - - @0xsequence/abi@1.6.3 - - @0xsequence/network@1.6.3 - - @0xsequence/utils@1.6.3 - -## 1.6.2 - -### Patch Changes - -- auth: projectAccessKey option -- wallet: use 12 bytes for random space -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.6.2 - - @0xsequence/network@1.6.2 - - @0xsequence/utils@1.6.2 - -## 1.6.1 - -### Patch Changes - -- core: add simple config from subdigest support -- core: fix encode tree with subdigest -- account: implement buildOnChainSignature on Account -- Updated dependencies -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.6.1 - - @0xsequence/network@1.6.1 - - @0xsequence/utils@1.6.1 - -## 1.6.0 - -### Minor Changes - -- account, wallet: parallel transactions by default - -### Patch Changes - -- provider: emit disconnect on sign out -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.6.0 - - @0xsequence/network@1.6.0 - - @0xsequence/utils@1.6.0 - -## 1.5.0 - -### Minor Changes - -- signhub: add 'signing' signer status - -### Patch Changes - -- auth: Session.open: onAccountAddress callback -- account: allow empty transaction bundles -- Updated dependencies -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.5.0 - - @0xsequence/network@1.5.0 - - @0xsequence/utils@1.5.0 - -## 1.4.9 - -### Patch Changes - -- rename SequenceMetadataClient to SequenceMetadata -- Updated dependencies - - @0xsequence/abi@1.4.9 - - @0xsequence/network@1.4.9 - - @0xsequence/utils@1.4.9 - -## 1.4.8 - -### Patch Changes - -- account: Account.getSigners -- Updated dependencies - - @0xsequence/abi@1.4.8 - - @0xsequence/network@1.4.8 - - @0xsequence/utils@1.4.8 - -## 1.4.7 - -### Patch Changes - -- update indexer client bindings -- Updated dependencies - - @0xsequence/abi@1.4.7 - - @0xsequence/network@1.4.7 - - @0xsequence/utils@1.4.7 - -## 1.4.6 - -### Patch Changes - -- - add sepolia networks, mark goerli as deprecated - - update indexer client bindings -- Updated dependencies - - @0xsequence/abi@1.4.6 - - @0xsequence/network@1.4.6 - - @0xsequence/utils@1.4.6 - -## 1.4.5 - -### Patch Changes - -- indexer/metadata: update client bindings -- auth: selectWallet with new address -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.4.5 - - @0xsequence/network@1.4.5 - - @0xsequence/utils@1.4.5 - -## 1.4.4 - -### Patch Changes - -- indexer: update bindings -- auth: handle jwt expiry -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.4.4 - - @0xsequence/network@1.4.4 - - @0xsequence/utils@1.4.4 - -## 1.4.3 - -### Patch Changes - -- guard: return active status from GuardSigner.getAuthMethods -- Updated dependencies - - @0xsequence/abi@1.4.3 - - @0xsequence/network@1.4.3 - - @0xsequence/utils@1.4.3 - -## 1.4.2 - -### Patch Changes - -- guard: update bindings -- Updated dependencies - - @0xsequence/abi@1.4.2 - - @0xsequence/network@1.4.2 - - @0xsequence/utils@1.4.2 - -## 1.4.1 - -### Patch Changes - -- network: remove unused networks -- signhub: orchestrator interface -- guard: auth methods interface -- guard: update bindings for pin and totp -- guard: no more retry logic -- Updated dependencies -- Updated dependencies -- Updated dependencies -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.4.1 - - @0xsequence/network@1.4.1 - - @0xsequence/utils@1.4.1 - -## 1.4.0 - -### Minor Changes - -- project access key support - -### Patch Changes - -- Updated dependencies - - @0xsequence/abi@1.4.0 - - @0xsequence/network@1.4.0 - - @0xsequence/utils@1.4.0 - -## 1.3.0 - -### Minor Changes - -- signhub: account children - -### Patch Changes - -- guard: do not throw when building deploy transaction -- network: snowtrace.io -> subnets.avax.network/c-chain -- Updated dependencies -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.3.0 - - @0xsequence/network@1.3.0 - - @0xsequence/utils@1.3.0 - -## 1.2.9 - -### Patch Changes - -- account: AccountSigner.sendTransaction simulateForFeeOptions -- relayer: update bindings -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.2.9 - - @0xsequence/network@1.2.9 - - @0xsequence/utils@1.2.9 - -## 1.2.8 - -### Patch Changes - -- rename X-Sequence-Token-Key header to X-Access-Key -- Updated dependencies - - @0xsequence/abi@1.2.8 - - @0xsequence/network@1.2.8 - - @0xsequence/utils@1.2.8 - -## 1.2.7 - -### Patch Changes - -- add x-sequence-token-key to clients -- Updated dependencies - - @0xsequence/abi@1.2.7 - - @0xsequence/network@1.2.7 - - @0xsequence/utils@1.2.7 - -## 1.2.6 - -### Patch Changes - -- Fix bind multicall provider -- Updated dependencies - - @0xsequence/abi@1.2.6 - - @0xsequence/network@1.2.6 - - @0xsequence/utils@1.2.6 - -## 1.2.5 - -### Patch Changes - -- Multicall default configuration fixes -- Updated dependencies - - @0xsequence/abi@1.2.5 - - @0xsequence/network@1.2.5 - - @0xsequence/utils@1.2.5 - -## 1.2.4 - -### Patch Changes - -- provider: Adding missing payment provider types to PaymentProviderOption -- provider: WalletRequestHandler.notifyChainChanged -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.2.4 - - @0xsequence/network@1.2.4 - - @0xsequence/utils@1.2.4 - -## 1.2.3 - -### Patch Changes - -- auth, provider: connect to accept optional authorizeNonce -- Updated dependencies - - @0xsequence/abi@1.2.3 - - @0xsequence/network@1.2.3 - - @0xsequence/utils@1.2.3 - -## 1.2.2 - -### Patch Changes - -- provider: allow createContract calls -- core: check for explicit zero address in contract deployments -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.2.2 - - @0xsequence/network@1.2.2 - - @0xsequence/utils@1.2.2 - -## 1.2.1 - -### Patch Changes - -- auth: use sequence api chain id as reference chain id if available -- Updated dependencies - - @0xsequence/abi@1.2.1 - - @0xsequence/network@1.2.1 - - @0xsequence/utils@1.2.1 - -## 1.2.0 - -### Minor Changes - -- split services from session, better local support - -### Patch Changes - -- Updated dependencies - - @0xsequence/abi@1.2.0 - - @0xsequence/network@1.2.0 - - @0xsequence/utils@1.2.0 - -## 1.1.15 - -### Patch Changes - -- guard: remove error filtering -- Updated dependencies - - @0xsequence/abi@1.1.15 - - @0xsequence/network@1.1.15 - - @0xsequence/utils@1.1.15 - -## 1.1.14 - -### Patch Changes - -- guard: add GuardSigner.onError -- Updated dependencies - - @0xsequence/abi@1.1.14 - - @0xsequence/network@1.1.14 - - @0xsequence/utils@1.1.14 - -## 1.1.13 - -### Patch Changes - -- provider: pass client version with connect options -- provider: removing large from BannerSize -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.1.13 - - @0xsequence/network@1.1.13 - - @0xsequence/utils@1.1.13 - -## 1.1.12 - -### Patch Changes - -- provider: adding bannerSize to ConnectOptions -- Updated dependencies - - @0xsequence/abi@1.1.12 - - @0xsequence/network@1.1.12 - - @0xsequence/utils@1.1.12 - -## 1.1.11 - -### Patch Changes - -- add homeverse configs -- Updated dependencies - - @0xsequence/abi@1.1.11 - - @0xsequence/network@1.1.11 - - @0xsequence/utils@1.1.11 - -## 1.1.10 - -### Patch Changes - -- handle default EIP6492 on send -- Updated dependencies - - @0xsequence/abi@1.1.10 - - @0xsequence/network@1.1.10 - - @0xsequence/utils@1.1.10 - -## 1.1.9 - -### Patch Changes - -- Custom default EIP6492 on client -- Updated dependencies - - @0xsequence/abi@1.1.9 - - @0xsequence/network@1.1.9 - - @0xsequence/utils@1.1.9 - -## 1.1.8 - -### Patch Changes - -- metadata: searchMetadata: add types filter -- Updated dependencies - - @0xsequence/abi@1.1.8 - - @0xsequence/network@1.1.8 - - @0xsequence/utils@1.1.8 - -## 1.1.7 - -### Patch Changes - -- adding signInWith connect settings option to allow dapps to automatically login their users with a certain provider optimizing the normal authentication flow -- Updated dependencies - - @0xsequence/abi@1.1.7 - - @0xsequence/network@1.1.7 - - @0xsequence/utils@1.1.7 - -## 1.1.6 - -### Patch Changes - -- metadata: searchMetadata: add chainID and excludeTokenMetadata filters -- Updated dependencies - - @0xsequence/abi@1.1.6 - - @0xsequence/network@1.1.6 - - @0xsequence/utils@1.1.6 - -## 1.1.5 - -### Patch Changes - -- account: re-compute meta-transaction id for wallet deployment transactions -- Updated dependencies - - @0xsequence/abi@1.1.5 - - @0xsequence/network@1.1.5 - - @0xsequence/utils@1.1.5 - -## 1.1.4 - -### Patch Changes - -- network: rename base-mainnet to base -- provider: override isDefaultChain with ConnectOptions.networkId if provided -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.1.4 - - @0xsequence/network@1.1.4 - - @0xsequence/utils@1.1.4 - -## 1.1.3 - -### Patch Changes - -- provider: use network id from transport session -- provider: sign authorization using ConnectOptions.networkId if provided -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.1.3 - - @0xsequence/network@1.1.3 - - @0xsequence/utils@1.1.3 - -## 1.1.2 - -### Patch Changes - -- provider: jsonrpc chain id fixes -- Updated dependencies - - @0xsequence/abi@1.1.2 - - @0xsequence/network@1.1.2 - - @0xsequence/utils@1.1.2 - -## 1.1.1 - -### Patch Changes - -- network: add base mainnet and sepolia -- provider: reject toxic transaction requests -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.1.1 - - @0xsequence/network@1.1.1 - - @0xsequence/utils@1.1.1 - -## 1.1.0 - -### Minor Changes - -- Refactor dapp facing provider - -### Patch Changes - -- Updated dependencies - - @0xsequence/abi@1.1.0 - - @0xsequence/network@1.1.0 - - @0xsequence/utils@1.1.0 - -## 1.0.5 - -### Patch Changes - -- network: export network constants -- guard: use the correct global for fetch -- network: nova-explorer.arbitrum.io -> nova.arbiscan.io -- Updated dependencies -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@1.0.5 - - @0xsequence/network@1.0.5 - - @0xsequence/utils@1.0.5 - -## 1.0.4 - -### Patch Changes - -- provider: accept name or number for networkId -- Updated dependencies - - @0xsequence/abi@1.0.4 - - @0xsequence/network@1.0.4 - - @0xsequence/utils@1.0.4 - -## 1.0.3 - -### Patch Changes - -- Simpler isValidSignature helpers -- Updated dependencies - - @0xsequence/abi@1.0.3 - - @0xsequence/network@1.0.3 - - @0xsequence/utils@1.0.3 - -## 1.0.2 - -### Patch Changes - -- add extra signature validation utils methods -- Updated dependencies - - @0xsequence/abi@1.0.2 - - @0xsequence/network@1.0.2 - - @0xsequence/utils@1.0.2 - -## 1.0.1 - -### Patch Changes - -- add homeverse testnet -- Updated dependencies - - @0xsequence/abi@1.0.1 - - @0xsequence/network@1.0.1 - - @0xsequence/utils@1.0.1 - -## 1.0.0 - -### Major Changes - -- https://sequence.xyz/blog/sequence-wallet-light-state-sync-full-merkle-wallets - -### Patch Changes - -- Updated dependencies - - @0xsequence/abi@1.0.0 - - @0xsequence/network@1.0.0 - - @0xsequence/utils@1.0.0 - -## 0.43.34 - -### Patch Changes - -- auth: no jwt for indexer -- Updated dependencies - - @0xsequence/abi@0.43.34 - - @0xsequence/network@0.43.34 - - @0xsequence/utils@0.43.34 - -## 0.43.33 - -### Patch Changes - -- Adding onConnectOptionsChange handler to WalletRequestHandler -- Updated dependencies - - @0xsequence/abi@0.43.33 - - @0xsequence/network@0.43.33 - - @0xsequence/utils@0.43.33 - -## 0.43.32 - -### Patch Changes - -- add Base Goerli network -- Updated dependencies - - @0xsequence/abi@0.43.32 - - @0xsequence/network@0.43.32 - - @0xsequence/utils@0.43.32 - -## 0.43.31 - -### Patch Changes - -- remove AuxDataProvider, add promptSignInConnect -- Updated dependencies - - @0xsequence/abi@0.43.31 - - @0xsequence/network@0.43.31 - - @0xsequence/utils@0.43.31 - -## 0.43.30 - -### Patch Changes - -- add arbitrum goerli testnet -- Updated dependencies - - @0xsequence/abi@0.43.30 - - @0xsequence/network@0.43.30 - - @0xsequence/utils@0.43.30 - -## 0.43.29 - -### Patch Changes - -- provider: check availability of window object -- Updated dependencies - - @0xsequence/abi@0.43.29 - - @0xsequence/network@0.43.29 - - @0xsequence/utils@0.43.29 - -## 0.43.28 - -### Patch Changes - -- update api bindings -- Updated dependencies - - @0xsequence/abi@0.43.28 - - @0xsequence/network@0.43.28 - - @0xsequence/utils@0.43.28 - -## 0.43.27 - -### Patch Changes - -- Add rpc is sequence method -- Updated dependencies - - @0xsequence/abi@0.43.27 - - @0xsequence/network@0.43.27 - - @0xsequence/utils@0.43.27 - -## 0.43.26 - -### Patch Changes - -- add zkevm url to enum -- Updated dependencies - - @0xsequence/abi@0.43.26 - - @0xsequence/network@0.43.26 - - @0xsequence/utils@0.43.26 - -## 0.43.25 - -### Patch Changes - -- added polygon zkevm to mainnet networks -- Updated dependencies - - @0xsequence/abi@0.43.25 - - @0xsequence/network@0.43.25 - - @0xsequence/utils@0.43.25 - -## 0.43.24 - -### Patch Changes - -- name change from zkevm to polygon-zkevm -- Updated dependencies - - @0xsequence/abi@0.43.24 - - @0xsequence/network@0.43.24 - - @0xsequence/utils@0.43.24 - -## 0.43.23 - -### Patch Changes - -- update zkEVM name to Polygon zkEVM -- Updated dependencies - - @0xsequence/abi@0.43.23 - - @0xsequence/network@0.43.23 - - @0xsequence/utils@0.43.23 - -## 0.43.22 - -### Patch Changes - -- add zkevm chain -- Updated dependencies - - @0xsequence/abi@0.43.22 - - @0xsequence/network@0.43.22 - - @0xsequence/utils@0.43.22 - -## 0.43.21 - -### Patch Changes - -- api: update client bindings -- Updated dependencies - - @0xsequence/abi@0.43.21 - - @0xsequence/network@0.43.21 - - @0xsequence/utils@0.43.21 - -## 0.43.20 - -### Patch Changes - -- indexer: update bindings -- Updated dependencies - - @0xsequence/abi@0.43.20 - - @0xsequence/network@0.43.20 - - @0xsequence/utils@0.43.20 - -## 0.43.19 - -### Patch Changes - -- session proof update -- Updated dependencies - - @0xsequence/abi@0.43.19 - - @0xsequence/network@0.43.19 - - @0xsequence/utils@0.43.19 - -## 0.43.18 - -### Patch Changes - -- rpc client global check, hardening -- Updated dependencies - - @0xsequence/abi@0.43.18 - - @0xsequence/network@0.43.18 - - @0xsequence/utils@0.43.18 - -## 0.43.17 - -### Patch Changes - -- rpc clients, check of 'global' is defined -- Updated dependencies - - @0xsequence/abi@0.43.17 - - @0xsequence/network@0.43.17 - - @0xsequence/utils@0.43.17 - -## 0.43.16 - -### Patch Changes - -- ethers peerDep to v5, update rpc client global use -- Updated dependencies - - @0xsequence/abi@0.43.16 - - @0xsequence/network@0.43.16 - - @0xsequence/utils@0.43.16 - -## 0.43.15 - -### Patch Changes - -- - provider: expand receiver type on some util methods -- Updated dependencies - - @0xsequence/abi@0.43.15 - - @0xsequence/network@0.43.15 - - @0xsequence/utils@0.43.15 - -## 0.43.14 - -### Patch Changes - -- bump -- Updated dependencies - - @0xsequence/abi@0.43.14 - - @0xsequence/network@0.43.14 - - @0xsequence/utils@0.43.14 - -## 0.43.13 - -### Patch Changes - -- update rpc bindings -- Updated dependencies - - @0xsequence/abi@0.43.13 - - @0xsequence/network@0.43.13 - - @0xsequence/utils@0.43.13 - -## 0.43.12 - -### Patch Changes - -- provider: single wallet init, and add new unregisterWallet() method -- Updated dependencies - - @0xsequence/abi@0.43.12 - - @0xsequence/network@0.43.12 - - @0xsequence/utils@0.43.12 - -## 0.43.11 - -### Patch Changes - -- fix lockfiles -- re-add mocha type deleter -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@0.43.11 - - @0xsequence/network@0.43.11 - - @0xsequence/utils@0.43.11 - -## 0.43.10 - -### Patch Changes - -- various improvements -- Updated dependencies - - @0xsequence/abi@0.43.10 - - @0xsequence/network@0.43.10 - - @0xsequence/utils@0.43.10 - -## 0.43.9 - -### Patch Changes - -- update deps -- Updated dependencies - - @0xsequence/abi@0.43.9 - - @0xsequence/network@0.43.9 - - @0xsequence/utils@0.43.9 - -## 0.43.8 - -### Patch Changes - -- network: JsonRpcProvider with caching -- Updated dependencies - - @0xsequence/abi@0.43.8 - - @0xsequence/network@0.43.8 - - @0xsequence/utils@0.43.8 - -## 0.43.7 - -### Patch Changes - -- provider: fix wallet network init -- Updated dependencies - - @0xsequence/abi@0.43.7 - - @0xsequence/network@0.43.7 - - @0xsequence/utils@0.43.7 - -## 0.43.6 - -### Patch Changes - -- metadatata: update rpc bindings -- Updated dependencies - - @0xsequence/abi@0.43.6 - - @0xsequence/network@0.43.6 - - @0xsequence/utils@0.43.6 - -## 0.43.5 - -### Patch Changes - -- provider: do not set default network for connect messages -- provider: forward missing error message -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@0.43.5 - - @0xsequence/network@0.43.5 - - @0xsequence/utils@0.43.5 - -## 0.43.4 - -### Patch Changes - -- no-change version bump to fix incorrectly tagged snapshot build -- Updated dependencies - - @0xsequence/abi@0.43.4 - - @0xsequence/network@0.43.4 - - @0xsequence/utils@0.43.4 - -## 0.43.3 - -### Patch Changes - -- metadata: update bindings -- Updated dependencies - - @0xsequence/abi@0.43.3 - - @0xsequence/network@0.43.3 - - @0xsequence/utils@0.43.3 - -## 0.43.2 - -### Patch Changes - -- provider: implement connectUnchecked -- Updated dependencies - - @0xsequence/abi@0.43.2 - - @0xsequence/network@0.43.2 - - @0xsequence/utils@0.43.2 - -## 0.43.1 - -### Patch Changes - -- update to latest ethauth dep -- Updated dependencies - - @0xsequence/abi@0.43.1 - - @0xsequence/network@0.43.1 - - @0xsequence/utils@0.43.1 - -## 0.43.0 - -### Minor Changes - -- move ethers to a peer dependency - -### Patch Changes - -- Updated dependencies - - @0xsequence/abi@0.43.0 - - @0xsequence/network@0.43.0 - - @0xsequence/utils@0.43.0 - -## 0.42.10 - -### Patch Changes - -- add auxDataProvider -- Updated dependencies - - @0xsequence/abi@0.42.10 - - @0xsequence/network@0.42.10 - - @0xsequence/utils@0.42.10 - -## 0.42.9 - -### Patch Changes - -- provider: add eip-191 exceptions -- Updated dependencies - - @0xsequence/abi@0.42.9 - - @0xsequence/network@0.42.9 - - @0xsequence/utils@0.42.9 - -## 0.42.8 - -### Patch Changes - -- provider: skip setting intent origin if we're unity plugin -- Updated dependencies - - @0xsequence/abi@0.42.8 - - @0xsequence/network@0.42.8 - - @0xsequence/utils@0.42.8 - -## 0.42.7 - -### Patch Changes - -- Add sign in options to connection settings -- Updated dependencies - - @0xsequence/abi@0.42.7 - - @0xsequence/network@0.42.7 - - @0xsequence/utils@0.42.7 - -## 0.42.6 - -### Patch Changes - -- api bindings update -- Updated dependencies - - @0xsequence/abi@0.42.6 - - @0xsequence/network@0.42.6 - - @0xsequence/utils@0.42.6 - -## 0.42.5 - -### Patch Changes - -- relayer: don't treat missing receipt as hard failure -- Updated dependencies - - @0xsequence/abi@0.42.5 - - @0xsequence/network@0.42.5 - - @0xsequence/utils@0.42.5 - -## 0.42.4 - -### Patch Changes - -- provider: add custom app protocol to connect options -- Updated dependencies - - @0xsequence/abi@0.42.4 - - @0xsequence/network@0.42.4 - - @0xsequence/utils@0.42.4 - -## 0.42.3 - -### Patch Changes - -- update api bindings -- Updated dependencies - - @0xsequence/abi@0.42.3 - - @0xsequence/network@0.42.3 - - @0xsequence/utils@0.42.3 - -## 0.42.2 - -### Patch Changes - -- disable rinkeby network -- Updated dependencies - - @0xsequence/abi@0.42.2 - - @0xsequence/network@0.42.2 - - @0xsequence/utils@0.42.2 - -## 0.42.1 - -### Patch Changes - -- wallet: optional waitForReceipt parameter -- Updated dependencies - - @0xsequence/abi@0.42.1 - - @0xsequence/network@0.42.1 - - @0xsequence/utils@0.42.1 - -## 0.42.0 - -### Minor Changes - -- relayer: estimateGasLimits -> simulate -- add simulator package - -### Patch Changes - -- transactions: fix flattenAuxTransactions -- provider: only filter nullish values -- provider: re-map transaction 'gas' back to 'gasLimit' -- Updated dependencies -- Updated dependencies -- Updated dependencies -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@0.42.0 - - @0xsequence/network@0.42.0 - - @0xsequence/utils@0.42.0 - -## 0.41.3 - -### Patch Changes - -- api bindings update -- Updated dependencies - - @0xsequence/abi@0.41.3 - - @0xsequence/network@0.41.3 - - @0xsequence/utils@0.41.3 - -## 0.41.2 - -### Patch Changes - -- api bindings update -- Updated dependencies - - @0xsequence/abi@0.41.2 - - @0xsequence/network@0.41.2 - - @0xsequence/utils@0.41.2 - -## 0.41.1 - -### Patch Changes - -- update default networks -- Updated dependencies - - @0xsequence/abi@0.41.1 - - @0xsequence/network@0.41.1 - - @0xsequence/utils@0.41.1 - -## 0.41.0 - -### Minor Changes - -- relayer: fix Relayer.wait() interface - - The interface for calling Relayer.wait() has changed. Instead of a single optional ill-defined timeout/delay parameter, there are three optional parameters, in order: - - - timeout: the maximum time to wait for the transaction receipt - - delay: the polling interval, i.e. the time to wait between requests - - maxFails: the maximum number of hard failures to tolerate before giving up - - Please update your codebase accordingly. - -- relayer: add optional waitForReceipt parameter to Relayer.relay - - The behaviour of Relayer.relay() was not well-defined with respect to whether or not it waited for a receipt. - This change allows the caller to specify whether to wait or not, with the default behaviour being to wait. - -### Patch Changes - -- relayer: wait receipt retry logic -- fix wrapped object error -- provider: forward delegateCall and revertOnError transaction fields -- Updated dependencies -- Updated dependencies -- Updated dependencies -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@0.41.0 - - @0xsequence/network@0.41.0 - - @0xsequence/utils@0.41.0 - -## 0.40.6 - -### Patch Changes - -- add arbitrum-nova chain -- Updated dependencies - - @0xsequence/abi@0.40.6 - - @0xsequence/network@0.40.6 - - @0xsequence/utils@0.40.6 - -## 0.40.5 - -### Patch Changes - -- api: update bindings -- Updated dependencies - - @0xsequence/abi@0.40.5 - - @0xsequence/network@0.40.5 - - @0xsequence/utils@0.40.5 - -## 0.40.4 - -### Patch Changes - -- add unreal transport -- Updated dependencies - - @0xsequence/abi@0.40.4 - - @0xsequence/network@0.40.4 - - @0xsequence/utils@0.40.4 - -## 0.40.3 - -### Patch Changes - -- provider: fix MessageToSign message type -- Updated dependencies - - @0xsequence/abi@0.40.3 - - @0xsequence/network@0.40.3 - - @0xsequence/utils@0.40.3 - -## 0.40.2 - -### Patch Changes - -- Wallet provider, loadSession method -- Updated dependencies - - @0xsequence/abi@0.40.2 - - @0xsequence/network@0.40.2 - - @0xsequence/utils@0.40.2 - -## 0.40.1 - -### Patch Changes - -- export sequence.initWallet and sequence.getWallet -- Updated dependencies - - @0xsequence/abi@0.40.1 - - @0xsequence/network@0.40.1 - - @0xsequence/utils@0.40.1 - -## 0.40.0 - -### Minor Changes - -- add sequence.initWallet(network, config) and sequence.getWallet() helper methods - -### Patch Changes - -- Updated dependencies - - @0xsequence/abi@0.40.0 - - @0xsequence/network@0.40.0 - - @0xsequence/utils@0.40.0 - -## 0.39.6 - -### Patch Changes - -- indexer: update client bindings -- Updated dependencies - - @0xsequence/abi@0.39.6 - - @0xsequence/network@0.39.6 - - @0xsequence/utils@0.39.6 - -## 0.39.5 - -### Patch Changes - -- provider: fix networkRpcUrl config option -- Updated dependencies - - @0xsequence/abi@0.39.5 - - @0xsequence/network@0.39.5 - - @0xsequence/utils@0.39.5 - -## 0.39.4 - -### Patch Changes - -- api: update client bindings -- Updated dependencies - - @0xsequence/abi@0.39.4 - - @0xsequence/network@0.39.4 - - @0xsequence/utils@0.39.4 - -## 0.39.3 - -### Patch Changes - -- add request method on Web3Provider -- Updated dependencies - - @0xsequence/abi@0.39.3 - - @0xsequence/network@0.39.3 - - @0xsequence/utils@0.39.3 - -## 0.39.2 - -### Patch Changes - -- update umd name -- Updated dependencies - - @0xsequence/abi@0.39.2 - - @0xsequence/network@0.39.2 - - @0xsequence/utils@0.39.2 - -## 0.39.1 - -### Patch Changes - -- add Aurora network -- add origin info for accountsChanged event to handle it per dapp -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@0.39.1 - - @0xsequence/network@0.39.1 - - @0xsequence/utils@0.39.1 - -## 0.39.0 - -### Minor Changes - -- abstract window.localStorage to interface type - -### Patch Changes - -- Updated dependencies - - @0xsequence/abi@0.39.0 - - @0xsequence/network@0.39.0 - - @0xsequence/utils@0.39.0 - -## 0.38.2 - -### Patch Changes - -- provider: add Settings.defaultPurchaseAmount -- Updated dependencies - - @0xsequence/abi@0.38.2 - - @0xsequence/network@0.38.2 - - @0xsequence/utils@0.38.2 - -## 0.38.1 - -### Patch Changes - -- update api and metadata rpc bindings -- Updated dependencies - - @0xsequence/abi@0.38.1 - - @0xsequence/network@0.38.1 - - @0xsequence/utils@0.38.1 - -## 0.38.0 - -### Minor Changes - -- api: update bindings, change TokenPrice interface -- bridge: remove @0xsequence/bridge package -- api: update bindings, rename ContractCallArg to TupleComponent - -### Patch Changes - -- Updated dependencies -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@0.38.0 - - @0xsequence/network@0.38.0 - - @0xsequence/utils@0.38.0 - -## 0.37.1 - -### Patch Changes - -- Add back sortNetworks - Removing sorting was a breaking change for dapps on older versions which directly integrate sequence. -- Updated dependencies - - @0xsequence/abi@0.37.1 - - @0xsequence/network@0.37.1 - - @0xsequence/utils@0.37.1 - -## 0.37.0 - -### Minor Changes - -- network related fixes and improvements -- api: bindings: exchange rate lookups - -### Patch Changes - -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@0.37.0 - - @0xsequence/network@0.37.0 - - @0xsequence/utils@0.37.0 - -## 0.36.13 - -### Patch Changes - -- api: update bindings with new price endpoints -- Updated dependencies - - @0xsequence/abi@0.36.13 - - @0xsequence/network@0.36.13 - - @0xsequence/utils@0.36.13 - -## 0.36.12 - -### Patch Changes - -- wallet: skip remote signers if not needed -- auth: check that signature meets threshold before requesting auth token -- Updated dependencies -- Updated dependencies - - @0xsequence/abi@0.36.12 - - @0xsequence/network@0.36.12 - - @0xsequence/utils@0.36.12 - -## 0.36.11 - -### Patch Changes - -- Prefix EIP191 message on wallet-request-handler -- Updated dependencies - - @0xsequence/abi@0.36.11 - - @0xsequence/network@0.36.11 - - @0xsequence/utils@0.36.11 - -## 0.36.10 - -### Patch Changes - -- support bannerUrl on connect -- Updated dependencies - - @0xsequence/abi@0.36.10 - - @0xsequence/network@0.36.10 - - @0xsequence/utils@0.36.10 - -## 0.36.9 - -### Patch Changes - -- minor dev xp improvements -- Updated dependencies - - @0xsequence/abi@0.36.9 - - @0xsequence/network@0.36.9 - - @0xsequence/utils@0.36.9 - -## 0.36.8 - -### Patch Changes - -- more connect options (theme, payment providers, funding currencies) -- Updated dependencies - - @0xsequence/abi@0.36.8 - - @0xsequence/network@0.36.8 - - @0xsequence/utils@0.36.8 - -## 0.36.7 - -### Patch Changes - -- fix missing break -- Updated dependencies - - @0xsequence/abi@0.36.7 - - @0xsequence/network@0.36.7 - - @0xsequence/utils@0.36.7 - -## 0.36.6 - -### Patch Changes - -- wallet_switchEthereumChain support -- Updated dependencies - - @0xsequence/abi@0.36.6 - - @0xsequence/network@0.36.6 - - @0xsequence/utils@0.36.6 - -## 0.36.5 - -### Patch Changes - -- auth: bump ethauth to 0.7.0 - network, wallet: don't assume position of auth network in list - api/indexer/metadata: trim trailing slash on hostname, and add endpoint urls - relayer: Allow to specify local relayer transaction parameters like gas price or gas limit -- Updated dependencies - - @0xsequence/abi@0.36.5 - - @0xsequence/network@0.36.5 - - @0xsequence/utils@0.36.5 - -## 0.36.4 - -### Patch Changes - -- Updating list of chain ids to include other ethereum compatible chains -- Updated dependencies - - @0xsequence/abi@0.36.4 - - @0xsequence/network@0.36.4 - - @0xsequence/utils@0.36.4 - -## 0.36.3 - -### Patch Changes - -- provider: pass connect options to prompter methods -- Updated dependencies - - @0xsequence/abi@0.36.3 - - @0xsequence/network@0.36.3 - - @0xsequence/utils@0.36.3 - -## 0.36.2 - -### Patch Changes - -- transactions: Setting target to 0x0 when empty to during SequenceTxAbiEncode -- Updated dependencies - - @0xsequence/abi@0.36.2 - - @0xsequence/network@0.36.2 - - @0xsequence/utils@0.36.2 - -## 0.36.1 - -### Patch Changes - -- metadata: update client with more fields -- Updated dependencies - - @0xsequence/abi@0.36.1 - - @0xsequence/network@0.36.1 - - @0xsequence/utils@0.36.1 - -## 0.36.0 - -### Minor Changes - -- relayer, wallet: fee quote support - -### Patch Changes - -- Updated dependencies - - @0xsequence/abi@0.36.0 - - @0xsequence/network@0.36.0 - - @0xsequence/utils@0.36.0 - -## 0.35.12 - -### Patch Changes - -- provider: rename wallet.commands to wallet.utils -- Updated dependencies - - @0xsequence/abi@0.35.12 - - @0xsequence/network@0.35.12 - - @0xsequence/utils@0.35.12 - -## 0.35.11 - -### Patch Changes - -- provider/utils: smoother message validation -- Updated dependencies - - @0xsequence/abi@0.35.11 - - @0xsequence/network@0.35.11 - - @0xsequence/utils@0.35.11 - -## 0.35.10 - -### Patch Changes - -- upgrade deps -- Updated dependencies - - @0xsequence/abi@0.35.10 - - @0xsequence/network@0.35.10 - - @0xsequence/utils@0.35.10 - -## 0.35.9 - -### Patch Changes - -- provider: window-transport override event handlers with new wallet instance -- Updated dependencies - - @0xsequence/abi@0.35.9 - - @0xsequence/network@0.35.9 - - @0xsequence/utils@0.35.9 - -## 0.35.8 - -### Patch Changes - -- provider: async wallet sign in improvements -- Updated dependencies - - @0xsequence/abi@0.35.8 - - @0xsequence/network@0.35.8 - - @0xsequence/utils@0.35.8 - -## 0.35.7 - -### Patch Changes - -- config: cache wallet configs -- Updated dependencies - - @0xsequence/abi@0.35.7 - - @0xsequence/network@0.35.7 - - @0xsequence/utils@0.35.7 - -## 0.35.6 - -### Patch Changes - -- provider: support async signin of wallet request handler -- Updated dependencies - - @0xsequence/abi@0.35.6 - - @0xsequence/network@0.35.6 - - @0xsequence/utils@0.35.6 - -## 0.35.5 - -### Patch Changes - -- wallet: skip threshold check during fee estimation -- Updated dependencies - - @0xsequence/abi@0.35.5 - - @0xsequence/network@0.35.5 - - @0xsequence/utils@0.35.5 - -## 0.35.4 - -### Patch Changes - -- - browser extension mode, center window -- Updated dependencies - - @0xsequence/abi@0.35.4 - - @0xsequence/network@0.35.4 - - @0xsequence/utils@0.35.4 - -## 0.35.3 - -### Patch Changes - -- - update window position when in browser extension mode -- Updated dependencies - - @0xsequence/abi@0.35.3 - - @0xsequence/network@0.35.3 - - @0xsequence/utils@0.35.3 - -## 0.35.2 - -### Patch Changes - -- - provider: WindowMessageHandler accept optional windowHref -- Updated dependencies - - @0xsequence/abi@0.35.2 - - @0xsequence/network@0.35.2 - - @0xsequence/utils@0.35.2 - -## 0.35.1 - -### Patch Changes - -- wallet: update config on undeployed too -- Updated dependencies - - @0xsequence/abi@0.35.1 - - @0xsequence/network@0.35.1 - - @0xsequence/utils@0.35.1 - -## 0.35.0 - -### Minor Changes - -- - config: add buildStubSignature - - provider: add checks to signing cases for wallet deployment and config statuses - - provider: add prompt for wallet deployment - - relayer: add BaseRelayer.prependWalletDeploy - - relayer: add Relayer.feeOptions - - relayer: account for wallet deployment in fee estimation - - transactions: add fromTransactionish - - wallet: add Account.prependConfigUpdate - - wallet: add Account.getFeeOptions - -### Patch Changes - -- Updated dependencies - - @0xsequence/abi@0.35.0 - - @0xsequence/network@0.35.0 - - @0xsequence/utils@0.35.0 - -## 0.34.0 - -### Minor Changes - -- - upgrade deps - -### Patch Changes - -- Updated dependencies - - @0xsequence/abi@0.34.0 - - @0xsequence/network@0.34.0 - - @0xsequence/utils@0.34.0 - -## 0.31.0 - -### Minor Changes - -- - upgrading to ethers v5.5 - -### Patch Changes - -- Updated dependencies - - @0xsequence/abi@0.31.0 - - @0xsequence/network@0.31.0 - - @0xsequence/utils@0.31.0 - -## 0.30.0 - -### Minor Changes - -- - upgrade most deps - -### Patch Changes - -- Updated dependencies - - @0xsequence/abi@0.30.0 - - @0xsequence/network@0.30.0 - - @0xsequence/utils@0.30.0 - -## 0.29.8 - -### Patch Changes - -- update api -- Updated dependencies [undefined] - - @0xsequence/abi@0.29.8 - - @0xsequence/network@0.29.8 - - @0xsequence/utils@0.29.8 - -## 0.29.6 - -### Patch Changes - -- Updated dependencies [undefined] - - @0xsequence/network@0.29.6 - -## 0.29.0 - -### Minor Changes - -- major architectural changes in Sequence design - - - only one API instance, API is no longer a per-chain service - - separate per-chain indexer service, API no longer handles indexing - - single contract metadata service, API no longer serves metadata - - chaind package has been removed, indexer and metadata packages have been added - - stronger typing with new explicit ChainId type - - multicall fixes and improvements - - forbid "wait" transactions in sendTransactionBatch calls - -### Patch Changes - -- Updated dependencies [undefined] - - @0xsequence/network@0.29.0 - - @0xsequence/abi@0.29.0 - - @0xsequence/utils@0.29.0 - -## 0.28.0 - -### Minor Changes - -- extension provider - -### Patch Changes - -- Updated dependencies [undefined] - - @0xsequence/abi@0.28.0 - - @0xsequence/network@0.28.0 - - @0xsequence/utils@0.28.0 - -## 0.27.0 - -### Minor Changes - -- Add requireFreshSigner lib to sessions - -### Patch Changes - -- Updated dependencies [undefined] - - @0xsequence/abi@0.27.0 - - @0xsequence/network@0.27.0 - - @0xsequence/utils@0.27.0 - -## 0.25.1 - -### Patch Changes - -- Fix build typescrypt issue -- Updated dependencies [undefined] - - @0xsequence/abi@0.25.1 - - @0xsequence/network@0.25.1 - - @0xsequence/utils@0.25.1 - -## 0.25.0 - -### Minor Changes - -- 10c8af8: Add estimator package - Fix multicall few calls bug - -### Patch Changes - -- Updated dependencies [10c8af8] - - @0xsequence/abi@0.25.0 - - @0xsequence/network@0.25.0 - - @0xsequence/utils@0.25.0 - -## 0.23.0 - -### Minor Changes - -- - relayer: offer variety of gas fee options from the relayer service" - -### Patch Changes - -- Updated dependencies [undefined] - - @0xsequence/abi@0.23.0 - - @0xsequence/network@0.23.0 - - @0xsequence/utils@0.23.0 - -## 0.22.2 - -### Patch Changes - -- e1c109e: Fix authProof on expired sessions -- Updated dependencies [e1c109e] - - @0xsequence/abi@0.22.2 - - @0xsequence/network@0.22.2 - - @0xsequence/utils@0.22.2 - -## 0.22.1 - -### Patch Changes - -- transport session cache -- Updated dependencies [undefined] - - @0xsequence/abi@0.22.1 - - @0xsequence/network@0.22.1 - - @0xsequence/utils@0.22.1 - -## 0.22.0 - -### Minor Changes - -- e667b65: Expose all relayer options on networks - -### Patch Changes - -- Updated dependencies [e667b65] - - @0xsequence/abi@0.22.0 - - @0xsequence/network@0.22.0 - - @0xsequence/utils@0.22.0 - -## 0.21.5 - -### Patch Changes - -- Give priority to metaTxnId returned by relayer -- Updated dependencies [undefined] - - @0xsequence/abi@0.21.5 - - @0xsequence/network@0.21.5 - - @0xsequence/utils@0.21.5 - -## 0.21.4 - -### Patch Changes - -- Add has enough signers method -- Updated dependencies [undefined] - - @0xsequence/abi@0.21.4 - - @0xsequence/network@0.21.4 - - @0xsequence/utils@0.21.4 - -## 0.21.3 - -### Patch Changes - -- add window session cache -- Updated dependencies [undefined] - - @0xsequence/abi@0.21.3 - - @0xsequence/network@0.21.3 - - @0xsequence/utils@0.21.3 - -## 0.21.2 - -### Patch Changes - -- exception handlind in relayer -- Updated dependencies [undefined] - - @0xsequence/abi@0.21.2 - - @0xsequence/network@0.21.2 - - @0xsequence/utils@0.21.2 - -## 0.21.0 - -### Minor Changes - -- - fix gas estimation on wallets with large number of signers - - update to session handling and wallet config construction upon auth - -### Patch Changes - -- Updated dependencies [undefined] - - @0xsequence/abi@0.21.0 - - @0xsequence/network@0.21.0 - - @0xsequence/utils@0.21.0 - -## 0.19.3 - -### Patch Changes - -- jwtAuth visibility, package version sync -- Updated dependencies [undefined] - - @0xsequence/abi@0.19.3 - - @0xsequence/network@0.19.3 - - @0xsequence/utils@0.19.3 - -## 0.19.2 - -### Patch Changes - -- Updated dependencies [undefined] - - @0xsequence/abi@0.19.2 - -## 0.19.0 - -### Minor Changes - -- - provider, improve dapp / wallet transport io - -### Patch Changes - -- Updated dependencies [undefined] - - @0xsequence/abi@0.19.0 - - @0xsequence/network@0.19.0 - - @0xsequence/utils@0.19.0 - -## 0.18.0 - -### Minor Changes - -- relayer improvements and pending transaction handling - -### Patch Changes - -- Updated dependencies [undefined] - - @0xsequence/abi@0.18.0 - - @0xsequence/network@0.18.0 - - @0xsequence/utils@0.18.0 - -## 0.16.0 - -### Minor Changes - -- relayer as its own service separate from chaind - -### Patch Changes - -- Updated dependencies [undefined] - - @0xsequence/abi@0.16.0 - - @0xsequence/network@0.16.0 - - @0xsequence/utils@0.16.0 - -## 0.15.1 - -### Patch Changes - -- update api clients -- Updated dependencies [undefined] - - @0xsequence/abi@0.15.1 - - @0xsequence/network@0.15.1 - - @0xsequence/utils@0.15.1 - -## 0.14.3 - -### Patch Changes - -- Fix 0xSequence relayer dependencies -- Updated dependencies [undefined] - - @0xsequence/abi@0.14.3 - - @0xsequence/network@0.14.3 - - @0xsequence/utils@0.14.3 - -## 0.14.2 - -### Patch Changes - -- Add debug logs to rpc-relayer -- Updated dependencies [undefined] - - @0xsequence/abi@0.14.2 - - @0xsequence/network@0.14.2 - - @0xsequence/utils@0.14.2 - -## 0.14.0 - -### Minor Changes - -- update sequence utils finder which includes optimization - -### Patch Changes - -- Updated dependencies [undefined] - - @0xsequence/abi@0.14.0 - - @0xsequence/network@0.14.0 - - @0xsequence/utils@0.14.0 - -## 0.13.0 - -### Minor Changes - -- Update SequenceUtils deployed contract - -### Patch Changes - -- Updated dependencies [undefined] - - @0xsequence/abi@0.13.0 - - @0xsequence/network@0.13.0 - - @0xsequence/utils@0.13.0 - -## 0.12.1 - -### Patch Changes - -- npm bump -- Updated dependencies [undefined] - - @0xsequence/abi@0.12.1 - - @0xsequence/network@0.12.1 - - @0xsequence/utils@0.12.1 - -## 0.12.0 - -### Minor Changes - -- provider: improvements to window transport - -### Patch Changes - -- Updated dependencies [undefined] - - @0xsequence/abi@0.12.0 - - @0xsequence/network@0.12.0 - - @0xsequence/utils@0.12.0 - -## 0.11.4 - -### Patch Changes - -- update api client -- Updated dependencies [undefined] - - @0xsequence/abi@0.11.4 - - @0xsequence/network@0.11.4 - - @0xsequence/utils@0.11.4 - -## 0.11.3 - -### Patch Changes - -- improve openWindow state options handling -- Updated dependencies [undefined] - - @0xsequence/abi@0.11.3 - - @0xsequence/network@0.11.3 - - @0xsequence/utils@0.11.3 - -## 0.11.2 - -### Patch Changes - -- Fix multicall proxy scopes -- Updated dependencies [undefined] - - @0xsequence/abi@0.11.2 - - @0xsequence/network@0.11.2 - - @0xsequence/utils@0.11.2 - -## 0.11.1 - -### Patch Changes - -- Add support for dynamic and nested signatures -- Updated dependencies [undefined] - - @0xsequence/abi@0.11.1 - - @0xsequence/network@0.11.1 - - @0xsequence/utils@0.11.1 - -## 0.11.0 - -### Minor Changes - -- Update wallet context to 1.7 contracts - -### Patch Changes - -- Updated dependencies [undefined] - - @0xsequence/abi@0.11.0 - - @0xsequence/network@0.11.0 - - @0xsequence/utils@0.11.0 - -## 0.10.9 - -### Patch Changes - -- add support for public addresses as signers in session.open -- Updated dependencies [undefined] - - @0xsequence/abi@0.10.9 - - @0xsequence/network@0.10.9 - - @0xsequence/utils@0.10.9 - -## 0.10.8 - -### Patch Changes - -- Multicall production configuration -- Updated dependencies [undefined] - - @0xsequence/abi@0.10.8 - - @0xsequence/network@0.10.8 - - @0xsequence/utils@0.10.8 - -## 0.10.7 - -### Patch Changes - -- allow provider transport to force disconnect -- Updated dependencies [undefined] - - @0xsequence/abi@0.10.7 - - @0xsequence/network@0.10.7 - - @0xsequence/utils@0.10.7 - -## 0.10.6 - -### Patch Changes - -- - fix getWalletState method -- Updated dependencies [undefined] - - @0xsequence/abi@0.10.6 - - @0xsequence/network@0.10.6 - - @0xsequence/utils@0.10.6 - -## 0.10.5 - -### Patch Changes - -- update relayer gas refund options -- Updated dependencies [undefined] - - @0xsequence/abi@0.10.5 - - @0xsequence/network@0.10.5 - - @0xsequence/utils@0.10.5 - -## 0.10.4 - -### Patch Changes - -- Update api proto -- Updated dependencies [undefined] - - @0xsequence/abi@0.10.4 - - @0xsequence/network@0.10.4 - - @0xsequence/utils@0.10.4 - -## 0.10.3 - -### Patch Changes - -- Fix loading config cross-chain -- Updated dependencies [undefined] - - @0xsequence/abi@0.10.3 - - @0xsequence/network@0.10.3 - - @0xsequence/utils@0.10.3 - -## 0.10.2 - -### Patch Changes - -- - message digest fix -- Updated dependencies [undefined] - - @0xsequence/abi@0.10.2 - - @0xsequence/network@0.10.2 - - @0xsequence/utils@0.10.2 - -## 0.10.1 - -### Patch Changes - -- upgrade deps -- Updated dependencies [undefined] - - @0xsequence/abi@0.10.1 - - @0xsequence/network@0.10.1 - - @0xsequence/utils@0.10.1 - -## 0.10.0 - -### Minor Changes - -- Deployed new contracts with ERC1271 signer support - -### Patch Changes - -- Updated dependencies [undefined] - - @0xsequence/abi@0.10.0 - - @0xsequence/network@0.10.0 - - @0xsequence/utils@0.10.0 - -## 0.9.6 - -### Patch Changes - -- Update ABIs for latest sequence contracts -- Updated dependencies [undefined] - - @0xsequence/network@0.9.6 - - @0xsequence/utils@0.9.6 - - @0xsequence/abi@0.9.6 - -## 0.9.5 - -### Patch Changes - -- Implemented session class -- Updated dependencies [undefined] - - @0xsequence/network@0.9.5 - - @0xsequence/utils@0.9.5 - -## 0.9.3 - -### Patch Changes - -- - minor improvements -- Updated dependencies [undefined] - - @0xsequence/abi@0.9.3 - - @0xsequence/network@0.9.3 - - @0xsequence/utils@0.9.3 - -## 0.9.1 - -### Patch Changes - -- - patch bump -- Updated dependencies [undefined] - - @0xsequence/abi@0.9.1 - - @0xsequence/network@0.9.1 - - @0xsequence/utils@0.9.1 - -## 0.9.0 - -### Minor Changes - -- - provider transport hardening - -### Patch Changes - -- Updated dependencies [undefined] - - @0xsequence/abi@0.9.0 - - @0xsequence/network@0.9.0 - - @0xsequence/utils@0.9.0 - -## 0.8.5 - -### Patch Changes - -- - use latest wallet-contracts -- Updated dependencies [undefined] - - @0xsequence/abi@0.8.5 - - @0xsequence/network@0.8.5 - - @0xsequence/utils@0.8.5 - -## 0.8.4 - -### Patch Changes - -- - minor improvements, name updates and comments -- Updated dependencies [undefined] - - @0xsequence/abi@0.8.4 - - @0xsequence/network@0.8.4 - - @0xsequence/utils@0.8.4 - -## 0.8.3 - -### Patch Changes - -- - refinements - - - normalize signer address in config - - - provider: getWalletState() method to WalletProvider - -- Updated dependencies [undefined] - - @0xsequence/abi@0.8.3 - - @0xsequence/network@0.8.3 - - @0xsequence/utils@0.8.3 - -## 0.8.2 - -### Patch Changes - -- - field rename and ethauth dependency bump -- Updated dependencies [undefined] - - @0xsequence/abi@0.8.2 - - @0xsequence/network@0.8.2 - - @0xsequence/utils@0.8.2 - -## 0.8.1 - -### Patch Changes - -- - variety of optimizations -- Updated dependencies [undefined] - - @0xsequence/abi@0.8.1 - - @0xsequence/network@0.8.1 - - @0xsequence/utils@0.8.1 - -## 0.8.0 - -### Minor Changes - -- - changeset fix - -### Patch Changes - -- Updated dependencies [undefined] - - @0xsequence/abi@0.8.0 - - @0xsequence/network@0.8.0 - - @0xsequence/utils@0.8.0 - -## 0.7.2 - -### Patch Changes - -- package.json fix - -## 0.7.0 - -### Patch Changes - -- 6f11ed7: sequence.js, init release -- Updated dependencies [6f11ed7] - - @0xsequence/abi@0.7.0 - - @0xsequence/network@0.7.0 - - @0xsequence/utils@0.7.0 diff --git a/packages/multicall/README.md b/packages/multicall/README.md deleted file mode 100644 index 7a16973da..000000000 --- a/packages/multicall/README.md +++ /dev/null @@ -1,169 +0,0 @@ -@0xsequence/multicall -===================== - -An Ethereum provider wrapper that aggregates multiple operations in one, reducing the network load -on clients and servers. The project aims to be plug-and-play with existing ether.js integrations. - -For more info see [0xsequence project page](https://github.com/0xsequence/sequence.js). - -Inspired by MakerDAO [Multicall.js](https://github.com/makerdao/multicall.js). - -## Installation - -`yarn add @0xsequence/multicall` - -or - -`npm install --save @0xsequence/multicall` - -## Usage - -Sequence Multicall works by implementing `ethers.Provider` and wrapping an existing `ethers.Provider`; this -wrapped provider can transparently aggregate supported JSON-RPC calls. - -```ts -import { providers } from '@0xsequence/multicall' -import { providers as ethersProviders } from 'ethers' - -// MulticallProvider can wrap and extend with multicall functionality -// any ethers.js provider, it's not limited to JsonRpcProvider -const provider = new providers.MulticallProvider(new ethersProviders.JsonRpcProvider("https://cloudflare-eth.com/")) -``` - -### Making aggregated calls - -Multicall leverages RPC calls' asynchronous nature to perform the aggregation; it implements a buffer -with a configurable 50ms delay and aggregates all operations received within that window. - -Explicit usage of the functionality can be forced by making multiple calls using `Promise.all`. - -```ts -// Both requests are aggregated into a single RPC call -const [balance, supply] = await Promise.all([ - provider.getBalance("0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2"), - dai.totalSupply() -]) -``` - -Methods can also be aggregated without using `Promise.all`, as long as there are no `await` in between calls. - -```ts -// DON'T -const balance = await provider.getBalance("0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2") -const supply = await dai.totalSupply() - -// DO -const balancePromise = provider.getBalance("0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2") -const supplyPromise = dai.totalSupply() - -const balance = await balancePromise -const supply = await supplyPromise -``` - -## Using the provider - -The `MulticallProvider` instance can be used in any context where an ethers.Provider is expected, including -contract interfaces, middlewares, or libraries; all calls to the same provider are candidates for aggregation. - -```ts -// Uses a single JSON-RPC call - -const abi = [ - "function balanceOf(address owner) view returns (uint256)", - "function totalSupply() view returns (uint256)", - "function symbol() view returns (string)", -] - -const uni = new ethers.Contract("0x1f9840a85d5aF5bf1D1762F925BDADdC4201F984", abi, provider) -const dai = new ethers.Contract("0x6B175474E89094C44Da98b954EedeAC495271d0F", abi, provider) - -const uniTotalSupplyPromise = uni.totalSupply() - -const [totalSupply, balance, daiSymbol, uniSymbol] = await Promise.all([ - dai.totalSupply(), - dai.balanceOf("0xAb5801a7D398351b8bE11C439e05C5B3259aeC9B"), - dai.symbol(), - uni.symbol() -]) - -const uniTotalSupply = await uniTotalSupplyPromise -``` - - -### Supported methods - -The following JSON-RPC methods are supported for call aggregation: - --------------------------------------------------------------------------------------------------------------------- -| Method | Supported | Implemented | Notes | -|-----------------|-----------|-------------|----------------------------------------------------------------------| -| eth_call | Yes | Yes | Requests containing `from`, `gasPrice` or `value` aren't aggregated. | -| eth_getBalance | Yes | Yes | | -| eth_getCode | Yes | Yes | | -| eth_blockNumber | Yes | No | | --------------------------------------------------------------------------------------------------------------------- - -All other RPC methods that are part of the standard are forwarded to the parent provider without any modifications. - -> ⚠️ Using mixed blocktags will make some calls skip aggregation. - - -### Error handling - -The multicall wrapper is designed to work with any exiting ether.js integration transparently; this includes error -handling for cases when multicall fails, is wrongly configured, or the contract does not support it. - -JSON-RPC Calls are forwarded to the parent provider on any of the following cases: -- Multicall contract is not deployed on the given network -- Individual call fails (only failed calls are forwarded) -- Batch call fails (all calls are forwarded) -- Invalid RPC Call (invalid address, etc.) -- Mixed blocktags within a batch -- Unsupported special parameters (see supported methods) -- Unsupported method - - -## Configuration - -The MulticallProvider comes with a pre-defined configuration; it's ready to work out-of-the-box on -the networks: Mainnet, Ropsten, Kovan, Rinkeby, Görli, and Matic (Mainnet). - -```ts -DEFAULT_CONF = { - batchSize: 50, - timeWindow: 50, // ms - contract: "0xd130B43062D875a4B7aF3f8fc036Bc6e9D3E1B3E" -} -``` --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- -| Parameter | Required | Description | -|------------|----------|------------------------------------------------------------------------------------------------------------------------------------------------------| -| batchSize | Yes | Defines the maximum number of calls to batch into a single JSON-RPC call. | -| timeWindow | Yes | Defines the time each call is held on buffer waiting for subsequent calls before aggregation, use 0 for "next js tick". | -| contract | Yes | Instance of MultiCallUtils contract, see: https://github.com/0xsequence/wallet-contracts/blob/master/src/contracts/modules/utils/MultiCallUtils.sol | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- - - -### Supported networks - -The utility contract is `0xd130B43062D875a4B7aF3f8fc036Bc6e9D3E1B3E`, it has been deployed using an [Universal Deployer](https://gist.github.com/Agusx1211/de05dabf918d448d315aa018e2572031) and it uses the same address on all networks. It can be used on any of these chains without configuration changes. - ------------------------------------------------------------------------------------- -| Network | Address | Deployed | -|:-------------------------|:-------------------------------------------|:---------| -| Mainnet | 0xd130B43062D875a4B7aF3f8fc036Bc6e9D3E1B3E | Yes | -| Görli | 0xd130B43062D875a4B7aF3f8fc036Bc6e9D3E1B3E | Yes | -| Ropsten | 0xd130B43062D875a4B7aF3f8fc036Bc6e9D3E1B3E | Yes | -| Rinkeby | 0xd130B43062D875a4B7aF3f8fc036Bc6e9D3E1B3E | Yes | -| Kovan | 0xd130B43062D875a4B7aF3f8fc036Bc6e9D3E1B3E | Yes | -| Polygon | 0xd130B43062D875a4B7aF3f8fc036Bc6e9D3E1B3E | Yes | -| Mumbai (Polygon testnet) | 0xd130B43062D875a4B7aF3f8fc036Bc6e9D3E1B3E | Yes | -| Arbitrum One | 0xd130B43062D875a4B7aF3f8fc036Bc6e9D3E1B3E | Yes | -| Arbitrum testnet | 0xd130B43062D875a4B7aF3f8fc036Bc6e9D3E1B3E | Yes | -| Arbitrum Görli testnet | 0xd130B43062D875a4B7aF3f8fc036Bc6e9D3E1B3E | Yes | -| Avalanche | 0xd130B43062D875a4B7aF3f8fc036Bc6e9D3E1B3E | Yes | -| BSC | 0xd130B43062D875a4B7aF3f8fc036Bc6e9D3E1B3E | Yes | ------------------------------------------------------------------------------------- - -It can be deployed on any network that supports the `CREATE2` opcode. See https://blockscan.com/address/0xd130B43062D875a4B7aF3f8fc036Bc6e9D3E1B3E for live list. - diff --git a/packages/multicall/package.json b/packages/multicall/package.json deleted file mode 100644 index c2910d253..000000000 --- a/packages/multicall/package.json +++ /dev/null @@ -1,39 +0,0 @@ -{ - "name": "@0xsequence/multicall", - "version": "1.10.14", - "description": "multicall sub-package for Sequence", - "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/multicall", - "source": "src/index.ts", - "main": "dist/0xsequence-multicall.cjs.js", - "module": "dist/0xsequence-multicall.esm.js", - "author": "Horizon Blockchain Games", - "license": "Apache-2.0", - "scripts": { - "test": "echo 'note, run local-test script instead, as test command is flakey'", - "local-test": "NODE_OPTIONS='--import tsx' mocha --timeout 10000 tests/**/*.spec.ts", - "typecheck": "tsc --noEmit" - }, - "dependencies": { - "@0xsequence/abi": "workspace:*", - "@0xsequence/network": "workspace:*", - "@0xsequence/utils": "workspace:*" - }, - "peerDependencies": { - "ethers": ">=5.5 < 6" - }, - "devDependencies": { - "@0xsequence/wallet-contracts": "^2.0.0", - "@ethersproject/providers": "^5.7.2", - "@types/web3-provider-engine": "^14.0.1", - "eth-json-rpc-middleware": "^9.0.1", - "ethers": "^5.7.2", - "ganache": "^7.5.0", - "json-rpc-engine": "^6.1.0", - "web3": "^1.8.1", - "web3-provider-engine": "^16.0.4" - }, - "files": [ - "src", - "dist" - ] -} diff --git a/packages/multicall/src/constants.ts b/packages/multicall/src/constants.ts deleted file mode 100644 index 624c345ed..000000000 --- a/packages/multicall/src/constants.ts +++ /dev/null @@ -1,5 +0,0 @@ -export enum JsonRpcMethod { - ethCall = 'eth_call', - ethGetBalance = 'eth_getBalance', - ethGetCode = 'eth_getCode' -} diff --git a/packages/multicall/src/index.ts b/packages/multicall/src/index.ts deleted file mode 100644 index a8b96096c..000000000 --- a/packages/multicall/src/index.ts +++ /dev/null @@ -1,2 +0,0 @@ -export { Multicall } from './multicall' -export * as providers from './providers' diff --git a/packages/multicall/src/multicall.ts b/packages/multicall/src/multicall.ts deleted file mode 100644 index be217f950..000000000 --- a/packages/multicall/src/multicall.ts +++ /dev/null @@ -1,321 +0,0 @@ -import { BigNumber, ethers } from 'ethers' -import { walletContracts } from '@0xsequence/abi' -import { JsonRpcMethod } from './constants' -import { BlockTag, eqBlockTag, parseBlockTag, partition, safeSolve } from './utils' -import { promisify, getRandomInt } from '@0xsequence/utils' -import { JsonRpcVersion, JsonRpcRequest, JsonRpcResponseCallback, JsonRpcHandlerFunc } from '@0xsequence/network' - -export type MulticallOptions = { - // number of calls to enqueue before calling. - batchSize: number - - // number of calls to batch within a time window (in milliseconds). If 0, will disable timeWindow. - timeWindow: number - - // contract is the address of the Sequence MultiCallUtils smart contract where - // the batched multicall is sent to an Ethereum node. - contract: string - - // logs details about aggregated calls - verbose: boolean -} - -type QueueEntry = { - request: JsonRpcRequest - callback: JsonRpcResponseCallback - next: JsonRpcHandlerFunc - error?: boolean - result?: JsonRpcResponseCallback -} - -const DefaultMulticallOptions = { - batchSize: 50, - timeWindow: 50, - // SequenceUtils: v2 - contract: '0xdbbFa3cB3B087B64F4ef5E3D20Dda2488AA244e6', - verbose: false -} - -export class Multicall { - public static DefaultOptions = { ...DefaultMulticallOptions } - - readonly batchableJsonRpcMethods = [JsonRpcMethod.ethCall, JsonRpcMethod.ethGetCode, JsonRpcMethod.ethGetBalance] - - readonly multicallInterface = new ethers.utils.Interface(walletContracts.sequenceUtils.abi) - - public options: MulticallOptions - - constructor(options?: Partial) { - this.options = options ? { ...Multicall.DefaultOptions, ...options } : Multicall.DefaultOptions - if (this.options.batchSize <= 0) throw new Error(`Invalid batch size of ${this.options.batchSize}`) - } - - private timeout: NodeJS.Timeout | undefined - private queue = [] as QueueEntry[] - - scheduleExecution = () => { - if (this.queue.length > 0) { - if (this.timeout) clearTimeout(this.timeout) - this.timeout = setTimeout(this.run, this.options.timeWindow) - } - } - - handle = (next: JsonRpcHandlerFunc, request: JsonRpcRequest, callback: JsonRpcResponseCallback) => { - // Schedule for batching and return - if (this.batchableJsonRpcMethods.find(m => m === request.method)) { - this.queue.push({ - request: request, - callback: callback, - next: next - }) - if (this.options.verbose) console.log('Scheduling call', request.method) - this.scheduleExecution() - return - } - - if (this.options.verbose) console.log('Forwarded call', request.method) - - // Move to next handler - return next(request, callback) - } - - run = async () => { - /* eslint-disable no-var */ - if (this.options.verbose) console.log('Processing multicall') - - // Read items from queue - const limit = Math.min(this.options.batchSize, this.queue.length) - if (limit === 0) { - if (this.options.verbose) console.log('Skip multicall, empty queue') - return - } - - // Skip multicall on single item - if (limit === 1) { - this.forward(this.queue[0]) - this.queue = [] - if (this.options.verbose) console.log('Skip multicall, single item') - return - } - - if (this.options.verbose) console.log('Resolving', limit) - - // Get batch from queue - var items = this.queue.slice(0, limit) - - // Update queue - this.queue = limit === this.queue.length ? [] : this.queue.slice(limit) - if (this.options.verbose) console.log('Updated queue', this.queue.length) - - if (this.queue.length !== 0) { - if (this.options.verbose) console.log('Scheduling next batch') - this.scheduleExecution() - } - - // Get next candidate - const next = items[0].next as JsonRpcHandlerFunc - let blockTag: BlockTag | undefined - - // Partition incompatible calls - var [items, discartItems] = partition(items, item => { - try { - // Mixed next callbacks - if (item.next !== next) return false - - switch (item.request.method) { - case JsonRpcMethod.ethCall: - // Unsupported eth_call parameters - if (item.request.params![0].from || item.request.params![0].gasPrice || item.request.params![0].value) { - return false - } - case JsonRpcMethod.ethGetBalance: - case JsonRpcMethod.ethGetCode: - // Mixed blockTags - const itemBlockTag = parseBlockTag(item.request.params![1]) - if (blockTag === undefined) blockTag = itemBlockTag - if (!eqBlockTag(itemBlockTag, blockTag)) return false - } - - return true - } catch { - return false - } - }) - - // Forward discarted items - // end execution if no items remain - if (discartItems.length !== 0) { - if (this.options.verbose) console.log('Forwarding incompatible calls', discartItems.length) - this.forward(discartItems) - if (items.length === 0) { - if (this.options.verbose) console.log('Skip multicall, all calls are incompatible') - return - } - } - - // Aggregate all calls - let callParams = items.map(v => { - try { - switch (v.request.method) { - case JsonRpcMethod.ethCall: - return { - delegateCall: false, - revertOnError: false, - target: v.request.params![0].to, - data: v.request.params![0].data, - gasLimit: v.request.params![0].gas ? v.request.params![0].gas : 0, - value: 0 - } - case JsonRpcMethod.ethGetCode: - return { - delegateCall: false, - revertOnError: false, - target: this.options.contract, - gasLimit: 0, - value: 0, - data: this.multicallInterface.encodeFunctionData(this.multicallInterface.getFunction('callCode'), [ - v.request.params![0] - ]) - } - case JsonRpcMethod.ethGetBalance: - return { - delegateCall: false, - revertOnError: false, - target: this.options.contract, - gasLimit: 0, - value: 0, - data: this.multicallInterface.encodeFunctionData(this.multicallInterface.getFunction('callBalanceOf'), [ - v.request.params![0] - ]) - } - default: - return null - } - } catch { - return null - } - }) - - // Filter calls with enconding errors and forward items - var [items, discartItems] = partition(items, (_, i: number) => callParams[i] !== undefined) - callParams = callParams.filter(c => c) - - if (discartItems.length !== 0) { - if (this.options.verbose) console.log('Forwarding calls on error', discartItems.length) - this.forward(discartItems) - if (items.length === 0) { - if (this.options.verbose) console.log('Skip multicall, all calls had encoding errors') - return - } - } - - // Encode multicall - let encodedCall: string - try { - if (this.options.verbose) console.log('Encoding multicall') - encodedCall = this.multicallInterface.encodeFunctionData(this.multicallInterface.getFunction('multiCall'), [callParams]) - } catch (err) { - if (this.options.verbose) console.warn('Error encoding multicall, forwarding one by one', err) - this.forward(items) - return - } - - // Forward single multicall rpc call - const reqId = getRandomInt() - - // TODO: fix types below.. - - const res = await safeSolve( - // @ts-ignore - promisify(next)({ - id: reqId!, - jsonrpc: JsonRpcVersion!, - method: JsonRpcMethod.ethCall!, - params: [ - { - to: this.options.contract!, - value: 0, - data: encodedCall! - }, - BigNumber.isBigNumber(blockTag) ? blockTag.toNumber() : blockTag - ] - // @ts-ignore - }), - e => ({ - jsonrpc: JsonRpcVersion!, - id: reqId!, - result: undefined, - error: e! - }) - ) - - // Error calling multicall - // Forward all calls to middleware - // @ts-ignore - if (res.error) { - if (this.options.verbose) console.warn('Error calling multicall, forwarding one by one', res.error) - return this.forward(items) - } - - // Decode result from multicall - let decoded: ethers.utils.Result - try { - // @ts-ignore - decoded = this.multicallInterface.decodeFunctionResult(this.multicallInterface.getFunction('multiCall'), res.result) - } catch (err) { - if (this.options.verbose) console.warn('Error decoding multicall result, forwarding one by one', err) - this.forward(items) - return - } - - // Send results for each request - // errors fallback through the middleware - if (this.options.verbose) console.log('Got response for', items.length) - items.forEach((item, index) => { - if (!decoded[0][index]) { - if (this.options.verbose) console.warn(`Multicall error for ${item.request.method} not found`) - this.forward(item) - } else { - switch (item.request.method) { - case JsonRpcMethod.ethCall: - item.callback(undefined, { - jsonrpc: item.request.jsonrpc!, - id: item.request.id!, - result: decoded[1][index] - }) - break - case JsonRpcMethod.ethGetCode: - item.callback(undefined, { - jsonrpc: item.request.jsonrpc!, - id: item.request.id!, - result: ethers.utils.defaultAbiCoder.decode(['bytes'], decoded[1][index])[0] - }) - break - case JsonRpcMethod.ethGetBalance: - item.callback(undefined, { - jsonrpc: item.request.jsonrpc!, - id: item.request.id!, - result: ethers.utils.defaultAbiCoder.decode(['uint256'], decoded[1][index])[0] - }) - break - } - } - }) - } - - private forward(entries: QueueEntry[] | QueueEntry) { - if (Array.isArray(entries)) { - entries.forEach(e => e.next(e.request, e.callback)) - } else { - entries.next(entries.request, entries.callback) - } - } - - static isMulticall(cand: any): cand is Multicall { - return cand && cand.handle !== undefined && cand.conf !== undefined && Multicall.isMulticallOptions(cand.options) - } - - static isMulticallOptions(cand: any): cand is MulticallOptions { - return cand !== undefined && cand.batchSize !== undefined && cand.timeWindow !== undefined && cand.contract !== undefined - } -} diff --git a/packages/multicall/src/providers/external-provider.ts b/packages/multicall/src/providers/external-provider.ts deleted file mode 100644 index e9390369d..000000000 --- a/packages/multicall/src/providers/external-provider.ts +++ /dev/null @@ -1,44 +0,0 @@ -import { providers } from 'ethers' -import { Multicall, MulticallOptions } from '../multicall' -import { JsonRpcRequest, JsonRpcResponseCallback } from '@0xsequence/network' - -type ExternalProvider = providers.ExternalProvider - -export class MulticallExternalProvider implements ExternalProvider { - private multicall: Multicall - - constructor( - private provider: providers.ExternalProvider, - multicall?: Multicall | Partial - ) { - this.multicall = Multicall.isMulticall(multicall) ? multicall : new Multicall(multicall!) - - if (provider.send) { - const next = async (req: JsonRpcRequest, callback: JsonRpcResponseCallback) => { - provider.send!(req, callback) - } - - ;(this as any).send = (request: JsonRpcRequest, callback: JsonRpcResponseCallback) => { - this.multicall.handle(next, request, callback) - } - } - - if (provider.sendAsync) { - const next = async (req: JsonRpcRequest, callback: JsonRpcResponseCallback) => { - provider.sendAsync!(req, callback) - } - - ;(this as any).sendAsync = (request: JsonRpcRequest, callback: JsonRpcResponseCallback) => { - this.multicall.handle(next, request, callback) - } - } - } - - public get isMetaMask() { - return this.provider.isMetaMask - } - - public get isStatus() { - return this.provider.isStatus - } -} diff --git a/packages/multicall/src/providers/index.ts b/packages/multicall/src/providers/index.ts deleted file mode 100644 index 45ab3938e..000000000 --- a/packages/multicall/src/providers/index.ts +++ /dev/null @@ -1,3 +0,0 @@ -export * from './provider' -export * from './external-provider' -export * from './provider-middleware' diff --git a/packages/multicall/src/providers/provider-middleware.ts b/packages/multicall/src/providers/provider-middleware.ts deleted file mode 100644 index 0bda937aa..000000000 --- a/packages/multicall/src/providers/provider-middleware.ts +++ /dev/null @@ -1,11 +0,0 @@ -import { Multicall, MulticallOptions } from '../multicall' -import { JsonRpcRequest, JsonRpcResponseCallback, JsonRpcHandlerFunc, JsonRpcMiddleware } from '@0xsequence/network' - -export const multicallMiddleware = - (multicall?: Multicall | Partial): JsonRpcMiddleware => - (next: JsonRpcHandlerFunc) => { - const lib = Multicall.isMulticall(multicall) ? multicall : new Multicall(multicall!) - return (request: JsonRpcRequest, callback: JsonRpcResponseCallback) => { - return lib.handle(next, request, callback) - } - } diff --git a/packages/multicall/src/providers/provider.ts b/packages/multicall/src/providers/provider.ts deleted file mode 100644 index 199ddf5d4..000000000 --- a/packages/multicall/src/providers/provider.ts +++ /dev/null @@ -1,119 +0,0 @@ -import { ethers, BigNumber, utils } from 'ethers' -import { promisify, getRandomInt } from '@0xsequence/utils' -import { Multicall, MulticallOptions } from '../multicall' -import { JsonRpcMethod } from '../constants' -import { JsonRpcVersion, JsonRpcRequest, JsonRpcResponseCallback } from '@0xsequence/network' - -export const ProxyMethods = [ - 'getNetwork', - 'getBlockNumber', - 'getGasPrice', - 'getTransactionCount', - 'getStorageAt', - 'sendTransaction', - 'estimateGas', - 'getBlock', - 'getTransaction', - 'getTransactionReceipt', - 'getLogs', - 'emit', - 'litenerCount', - 'addListener', - 'removeListener', - 'waitForTransaction', - 'detectNetwork', - 'getBlockWithTransactions' -] - -export class MulticallProvider extends ethers.providers.BaseProvider { - private multicall: Multicall - - constructor( - private provider: ethers.providers.Provider, - multicall?: Multicall | Partial - ) { - super(provider.getNetwork()) - - this.listenerCount = provider.listenerCount.bind(provider) - this.multicall = Multicall.isMulticall(multicall) ? multicall : new Multicall(multicall) - - ProxyMethods.forEach(m => { - if ((provider as any)[m] !== undefined) { - ;(this as any)[m] = (...args: any) => (provider as any)[m](...args) - } - }) - } - - getResolver = async (name: string | Promise) => { - const provider = this.provider as ethers.providers.BaseProvider - - if (provider.getResolver) { - const ogResolver = await provider.getResolver(await name) - if (!ogResolver) return null - return new ethers.providers.Resolver(this as any, ogResolver.address, ogResolver.name) - } - - return provider.getResolver(await name) - } - - next = async (req: JsonRpcRequest, callback: JsonRpcResponseCallback) => { - try { - switch (req.method) { - case JsonRpcMethod.ethCall: - this.callback(req, callback, await this.provider.call(req.params![0], req.params![1])) - break - - case JsonRpcMethod.ethGetCode: - this.callback(req, callback, await this.provider.getCode(req.params![0], req.params![1])) - break - - case JsonRpcMethod.ethGetBalance: - this.callback(req, callback, await this.provider.getBalance(req.params![0], req.params![1])) - break - } - } catch (e) { - this.callback(req, callback, undefined, e) - } - } - - private callback(req: JsonRpcRequest, callback: JsonRpcResponseCallback, resp: any, err?: any) { - callback(err, { - jsonrpc: JsonRpcVersion, - id: req.id!, - result: resp, - error: err - }) - } - - async call( - transaction: utils.Deferrable, - blockTag?: string | number | Promise - ): Promise { - return this.rpcCall(JsonRpcMethod.ethCall, transaction, blockTag) - } - - async getCode( - addressOrName: string | Promise, - blockTag?: string | number | Promise - ): Promise { - return this.rpcCall(JsonRpcMethod.ethGetCode, addressOrName, blockTag) - } - - async getBalance( - addressOrName: string | Promise, - blockTag?: string | number | Promise - ): Promise { - return this.rpcCall(JsonRpcMethod.ethGetBalance, addressOrName, blockTag) - } - - async rpcCall(method: string, ...params: any[]): Promise { - const reqId = getRandomInt() - const resp = await promisify(this.multicall.handle)(this.next, { - jsonrpc: JsonRpcVersion, - id: reqId, - method: method, - params: params - }) - return resp!.result - } -} diff --git a/packages/multicall/src/types.ts b/packages/multicall/src/types.ts deleted file mode 100644 index 7d665bb12..000000000 --- a/packages/multicall/src/types.ts +++ /dev/null @@ -1,8 +0,0 @@ -export type Call = () => Promise - -export type CallResult = { - call: Call - success: boolean - result: Array - outputs?: Array -} diff --git a/packages/multicall/src/utils.ts b/packages/multicall/src/utils.ts deleted file mode 100644 index 48557bbc5..000000000 --- a/packages/multicall/src/utils.ts +++ /dev/null @@ -1,47 +0,0 @@ -import { BigNumber, BigNumberish } from 'ethers' - -export async function safeSolve(promise: Promise, def: T | ((e: any) => T)): Promise { - try { - return await promise - } catch (e) { - const d = def instanceof Function ? def(e) : def - return d - } -} - -export function partition(array: T[], callback: (v: T, i: number) => boolean): [T[], T[]] { - return array.reduce( - function (result, element, i) { - callback(element, i) ? result[0].push(element) : result[1].push(element) - return result - }, - [[] as any[], [] as any[]] - ) -} - -export type BlockTag = 'earliest' | 'latest' | 'pending' | BigNumber - -export function parseBlockTag(cand: string | BigNumberish | undefined): BlockTag { - if (cand === undefined) return 'latest' - - switch (cand) { - case 'earliest': - case 'latest': - case 'pending': - return cand - } - - return BigNumber.from(cand) -} - -export function eqBlockTag(a: BlockTag, b: BlockTag): boolean { - if (a === b) return true - - if (BigNumber.isBigNumber(a)) { - if (BigNumber.isBigNumber(b)) return a.eq(b) - return false - } - - if (BigNumber.isBigNumber(b)) return false - return a === b -} diff --git a/packages/multicall/tests/multicall.spec.ts b/packages/multicall/tests/multicall.spec.ts deleted file mode 100644 index 0a00f9767..000000000 --- a/packages/multicall/tests/multicall.spec.ts +++ /dev/null @@ -1,600 +0,0 @@ -import { ethers, providers, Signer } from 'ethers' -import * as Ganache from 'ganache' -import { CallReceiverMock } from '@0xsequence/wallet-contracts' -import { JsonRpcRouter, JsonRpcExternalProvider } from '@0xsequence/network' - -import chaiAsPromised from 'chai-as-promised' -import * as chai from 'chai' -import { MulticallExternalProvider, multicallMiddleware, MulticallProvider } from '../src/providers' -import { SpyProxy } from './utils' -import { getRandomInt } from '@0xsequence/utils' -import { JsonRpcMethod } from '../src/constants' -import { MulticallOptions, Multicall } from '../src/multicall' - -const { JsonRpcEngine } = require('json-rpc-engine') - -const { providerAsMiddleware, providerFromEngine } = require('eth-json-rpc-middleware') - -const CallReceiverMockArtifact = require('@0xsequence/wallet-contracts/artifacts/contracts/mocks/CallReceiverMock.sol/CallReceiverMock.json') -const SequenceUtilsArtifact = require('@0xsequence/wallet-contracts/artifacts/contracts/modules/utils/SequenceUtils.sol/SequenceUtils.json') - -import Web3 from 'web3' -const { expect } = chai.use(chaiAsPromised) - -const GANACHE_PORT = 38546 - -type GanacheInstance = { - server?: any - serverUri?: string - provider?: providers.JsonRpcProvider - spyProxy?: providers.JsonRpcProvider - signer?: Signer - chainId?: number -} - -describe('Multicall integration', function () { - const ganache: GanacheInstance = {} - let provider: ethers.providers.Provider - let brokenProvider: ethers.providers.Provider - - let callMock: CallReceiverMock - - let utilsContract: ethers.Contract - - let callCounter = 0 - let accounts: { account: ethers.Wallet; secretKey: string; balance: string }[] - - before(async () => { - accounts = Array(5) - .fill(0) - .map(() => { - const account = ethers.Wallet.createRandom() - return { - account: account, - secretKey: account.privateKey, - balance: ethers.utils.hexlify(ethers.utils.randomBytes(9)) - } - }) - - // Deploy Ganache test env - ganache.chainId = 1337 - ganache.server = Ganache.server({ - chain: { - chainId: ganache.chainId, - networkId: ganache.chainId - }, - mnemonic: 'ripple axis someone ridge uniform wrist prosper there frog rate olympic knee', - accounts: accounts, - logging: { - verbose: false, - debug: false, - logger: undefined - } - }) - - // TODO: use hardhat instead like in wallet/wallet.spec.ts - - await ganache.server.listen(GANACHE_PORT) - ganache.serverUri = `http://127.0.0.1:${GANACHE_PORT}/` - ganache.provider = new providers.JsonRpcProvider(ganache.serverUri) - ganache.signer = ganache.provider.getSigner() - - utilsContract = await new ethers.ContractFactory( - SequenceUtilsArtifact.abi, - SequenceUtilsArtifact.bytecode, - ganache.signer - ).deploy(ethers.constants.AddressZero, ethers.constants.AddressZero) - - // Create provider - ganache.spyProxy = SpyProxy( - ganache.provider, - { - prop: 'call', - func: ganache.provider.call, - callback: () => { - callCounter++ - } - }, - { - prop: 'getCode', - func: ganache.provider.getCode, - callback: () => { - callCounter++ - } - }, - { - prop: 'getBalance', - func: ganache.provider.getBalance, - callback: () => { - callCounter++ - } - }, - { - prop: 'send', - func: ganache.provider.send, - callback: (method: string, _: any[]) => { - switch (method) { - case JsonRpcMethod.ethCall: - case JsonRpcMethod.ethGetCode: - case JsonRpcMethod.ethGetBalance: - callCounter++ - } - } - } - ) - - callMock = await createCallMock() - }) - - async function createCallMock() { - return (await new ethers.ContractFactory( - CallReceiverMockArtifact.abi, - CallReceiverMockArtifact.bytecode, - ganache.signer - ).deploy()) as unknown as CallReceiverMock - } - - const options = [ - { - name: 'Ether.js provider wrapper', - provider: (options?: Partial) => new MulticallProvider(ganache.spyProxy!, options) - }, - { - name: 'Json Rpc Router (Sequence)', - provider: (options?: Partial) => - new providers.Web3Provider( - new JsonRpcRouter([multicallMiddleware(options)], new JsonRpcExternalProvider(ganache.spyProxy!)) - ) - }, - { - name: 'Ether.js external provider wrapper', - provider: (conf?: Partial) => - new providers.Web3Provider(new MulticallExternalProvider(new JsonRpcExternalProvider(ganache.spyProxy!), conf)) - }, - { - name: 'Provider Engine (json-rpc-engine)', - provider: (conf?: Partial) => { - const engine = new JsonRpcEngine() - - engine.push(providerAsMiddleware(new MulticallExternalProvider(new JsonRpcExternalProvider(ganache.spyProxy!), conf))) - - return new ethers.providers.Web3Provider(providerFromEngine(engine)) - } - }, - { - name: 'Web3 external provider wrapper', - provider: (conf?: Partial) => { - const web3HttpProvider = new Web3.providers.HttpProvider(ganache.serverUri!) - const spyHttpProvider = SpyProxy(web3HttpProvider, { - prop: 'send', - func: web3HttpProvider.send, - callback: (p: any) => { - switch (p.method) { - case JsonRpcMethod.ethCall: - case JsonRpcMethod.ethGetCode: - case JsonRpcMethod.ethGetBalance: - callCounter++ - } - } - }) - return new providers.Web3Provider(new MulticallExternalProvider(spyHttpProvider as any, conf)) - } - }, - { - name: 'Ether.js provider wrapper (without proxy)', - provider: (options?: Partial) => new MulticallProvider(ganache.provider!, options), - ignoreCount: true - }, - { - name: 'Json Rpc Router (Sequence) (without proxy)', - provider: (options?: Partial) => - new providers.Web3Provider( - new JsonRpcRouter([multicallMiddleware(options)], new JsonRpcExternalProvider(ganache.provider!)) - ), - ignoreCount: true - }, - { - name: 'Ether.js external provider wrapper (without proxy)', - provider: (conf?: Partial) => - new providers.Web3Provider(new MulticallExternalProvider(new JsonRpcExternalProvider(ganache.provider!), conf)), - ignoreCount: true - }, - { - name: 'Provider Engine (json-rpc-engine) (without proxy)', - provider: (conf?: Partial) => { - const engine = new JsonRpcEngine() - - engine.push(providerAsMiddleware(new MulticallExternalProvider(new JsonRpcExternalProvider(ganache.provider!), conf))) - - return new ethers.providers.Web3Provider(providerFromEngine(engine)) - }, - ignoreCount: true - }, - { - name: 'Web3 external provider wrapper (without proxy)', - provider: (conf?: Partial) => { - const web3HttpProvider = new Web3.providers.HttpProvider(ganache.serverUri!) - const spyHttpProvider = SpyProxy(web3HttpProvider, { - prop: 'send', - func: web3HttpProvider.send, - callback: (p: any) => { - switch (p.method) { - case JsonRpcMethod.ethCall: - case JsonRpcMethod.ethGetCode: - case JsonRpcMethod.ethGetBalance: - callCounter++ - } - } - }) - return new providers.Web3Provider(new MulticallExternalProvider(web3HttpProvider as any, conf)) - }, - ignoreCount: true - } - ] - - beforeEach(() => { - callCounter = 0 - }) - - after(async () => { - ganache.server.close() - }) - - options.map(option => { - context(option.name, () => { - beforeEach(() => { - provider = option.provider({ contract: utilsContract.address, timeWindow: 500 }) - }) - - describe('Aggregate calls', async () => { - it('Should aggregate two calls', async () => { - await callMock.testCall(848487868126387, '0x001122') - - const multiCallMock = callMock.connect(provider) - const promiseA = multiCallMock.lastValA() - const promiseB = multiCallMock.lastValB() - - expect((await promiseA).toString()).to.equal('848487868126387') - expect(await promiseB).to.equal('0x001122') - - if (option.ignoreCount) return - expect(callCounter).to.equal(1) - }) - it('Should aggregate three calls', async () => { - const callMockB = await createCallMock() - - const randomData1 = ethers.utils.hexlify(ethers.utils.randomBytes(33)) - const randomData2 = ethers.utils.hexlify(ethers.utils.randomBytes(42)) - - await callMock.testCall(55122, randomData1) - await callMockB.testCall(2, randomData2) - - const multiCallMock = callMock.connect(provider) - const multiCallMockB = callMockB.connect(provider) - - const promiseA = multiCallMock.lastValA() - - const [valB, valC] = await Promise.all([multiCallMock.lastValB(), multiCallMockB.lastValB()]) - - expect((await promiseA).toString()).to.equal('55122') - expect(valB).to.equal(randomData1) - expect(valC).to.equal(randomData2) - - if (option.ignoreCount) return - expect(callCounter).to.equal(1) - }) - it('Should aggregate 62 calls in two batches', async () => { - const callMocks = await Promise.all( - Array(62) - .fill(0) - .map(() => createCallMock()) - ) - - const randomValues = Array(62) - .fill(0) - .map(() => ethers.utils.hexlify(ethers.utils.randomBytes(getRandomInt(0, 41)))) - await Promise.all(randomValues.map((v, i) => callMocks[i].testCall(0, v))) - - const values = await Promise.all(callMocks.map(c => c.connect(provider).lastValB())) - values.forEach((v, i) => expect(v).to.equal(randomValues[i])) - - if (option.ignoreCount) return - expect(callCounter).to.equal(2) - }) - it('Should aggregate in three batches :: queue > batch after first run', async () => { - const numberOfCalls = Multicall.DefaultOptions.batchSize * 2 + 2 - const mid = numberOfCalls / 2 // Split Promise.all to not break RPC calls - - let callMocks = await Promise.all( - Array(mid) - .fill(0) - .map(() => createCallMock()) - ) - callMocks = [ - ...callMocks, - ...(await Promise.all( - Array(mid) - .fill(0) - .map(() => createCallMock()) - )) - ] - - const randomValues = Array(numberOfCalls) - .fill(0) - .map(() => ethers.utils.hexlify(ethers.utils.randomBytes(getRandomInt(0, 41)))) - await Promise.all(randomValues.slice(0, mid).map((v, i) => callMocks[i].testCall(0, v))) - await Promise.all(randomValues.slice(mid).map((v, i) => callMocks[i + mid].testCall(0, v))) - - const values = await Promise.all(callMocks.map(c => c.connect(provider).lastValB())) - values.forEach((v, i) => expect(v).to.equal(randomValues[i])) - - if (option.ignoreCount) return - expect(callCounter).to.equal(3) - }) - it('Should call eth_getCode', async () => { - const code = await Promise.all([provider.getCode(callMock.address), provider.getCode(utilsContract.address)]) - - if (!option.ignoreCount) expect(callCounter).to.equal(1) - - const rawCode = await Promise.all([ - ganache.provider!.getCode(callMock.address), - ganache.provider!.getCode(utilsContract.address) - ]) - - expect(rawCode[0]).to.equal(code[0]) - expect(rawCode[1]).to.equal(code[1]) - }) - it('Should mix eth_getCode and eth_call', async () => { - await callMock.testCall(0, '0x9952') - - const multiCallMock = callMock.connect(provider) - const promiseA = provider.getCode(callMock.address) - const promiseB = multiCallMock.lastValB() - - expect(await promiseA).to.equal(await ganache.provider!.getCode(callMock.address)) - expect(await promiseB).to.equal('0x9952') - - if (option.ignoreCount) return - expect(callCounter).to.equal(1) - }) - it('Should call eth_getBalance', async () => { - const randomAddress = ethers.Wallet.createRandom().address - - const balances = await Promise.all([ - provider.getBalance(accounts[2].account.address), - provider.getBalance(accounts[1].account.address), - provider.getBalance(accounts[2].account.address), - provider.getBalance(randomAddress) - ]) - - if (!option.ignoreCount) expect(callCounter).to.equal(1) - - // expect(callCounter).to.equal(1) - const rawBalances = await Promise.all([ - ganache.provider!.getBalance(accounts[2].account.address), - ganache.provider!.getBalance(accounts[1].account.address), - ganache.provider!.getBalance(accounts[2].account.address), - ganache.provider!.getBalance(randomAddress) - ]) - - rawBalances.forEach((bal, i) => { - expect(balances[i].toHexString()).to.equal(bal.toHexString()) - }) - }) - it('Should call eth_getBalance and eth_getCode', async () => { - const promiseA = provider.getCode(callMock.address) - const promiseB = await provider.getBalance(accounts[3].account.address) - - expect(await promiseA).to.equal(await ganache.provider!.getCode(callMock.address)) - expect(promiseB.toHexString()).to.equal((await ganache.provider!.getBalance(accounts[3].account.address)).toHexString()) - - if (option.ignoreCount) return - expect(callCounter).to.equal(1) - }) - }) - describe('Handle errors', async () => { - it('Should not retry after failing to execute single call (not multicalled)', async () => { - const callMockB = await createCallMock() - - await callMockB.setRevertFlag(true) - - const multiCallMockB = callMockB.connect(provider) - - // await expect(multiCallMockB.callStatic.testCall(1, "0x1122")).to.be.rejectedWith('VM Exception while processing transaction: revert CallReceiverMock#testCall: REVERT_FLAG') - await expect(multiCallMockB.callStatic.testCall(1, '0x1122')).to.be.rejectedWith(/Transaction reverted/) - - if (option.ignoreCount) return - expect(callCounter).to.equal(1) - }) - it('Should retry after failing to execute using batch', async () => { - const callMockB = await createCallMock() - - await callMockB.setRevertFlag(true) - - const multiCallMockB = callMockB.connect(provider) - - // await expect(Promise.all([ - // multiCallMockB.callStatic.testCall(1, "0x1122"), - // multiCallMockB.callStatic.testCall(2, "0x1122") - // ])).to.be.rejectedWith('VM Exception while processing transaction: revert CallReceiverMock#testCall: REVERT_FLAG') - await expect( - Promise.all([multiCallMockB.callStatic.testCall(1, '0x1122'), multiCallMockB.callStatic.testCall(2, '0x1122')]) - ).to.be.rejectedWith(/Transaction reverted/) - - if (option.ignoreCount) return - expect(callCounter).to.equal(3) - }) - - it('Should call getStorageAt', async () => { - const random = ethers.utils.hexlify(ethers.utils.randomBytes(32)) - await callMock.testCall(random, '0x00') - const storageAt = ethers.utils.hexZeroPad(await provider.getStorageAt(callMock.address, 0), 32) - expect(storageAt).to.equal(ethers.utils.defaultAbiCoder.encode(['bytes32'], [random])) - }) - - it('Should call getStorageAt with padding', async () => { - const val = '0x001a6077bf4f6eae0b4d9158b68bc770c97e5ef19efffcfa28aec2bce13cae24' - await callMock.testCall(val, '0x00') - const storageAt = ethers.utils.hexZeroPad(await provider.getStorageAt(callMock.address, 0), 32) - expect(storageAt).to.equal(ethers.utils.defaultAbiCoder.encode(['bytes32'], [val])) - }) - - it('Should detect network', async () => { - const net = await (provider as ethers.providers.BaseProvider).detectNetwork() - expect(net.chainId).to.equal(1337) - }) - - // TODO: fix this test, its breaking on macOS node v15.12.0 - /*it("Should execute batch with errors on it", async () => { - const callMockB = await createCallMock() - - callMockB.testCall(1, "0x1122") - - await callMockB.setRevertFlag(true) - - const multiCallMockB = callMockB.connect(provider) - - const errorPromise = multiCallMockB.callStatic.testCall(1, "0x1122") - - const res = await Promise.all([ - provider.getCode(multiCallMockB.address), - multiCallMockB.lastValB() - ]) - - await expect(errorPromise).to.be.rejected - - expect(res[0].length).to.not.equal(0) - expect(res[1]).to.equal("0x1122") - expect(callCounter).to.equal(2) - })*/ - - const brokenProviderOptions = [ - { - name: 'non-deployed util contract', - overhead: 0, - brokenProvider: (getProvider: (options?: Partial) => providers.Provider) => - getProvider({ - contract: '' - }) - }, - { - name: 'EOA address as util contract', - overhead: 1, - brokenProvider: (getProvider: (options?: Partial) => providers.Provider) => - getProvider({ - contract: ethers.Wallet.createRandom().address - }) - }, - { - name: 'Broken contract as util contract', - overhead: 1, - brokenProvider: (getProvider: (options?: Partial) => providers.Provider) => - getProvider({ - contract: callMock.address - }) - }, - { - name: 'invalid address as util contract', - overhead: 0, - brokenProvider: (getProvider: (options?: Partial) => providers.Provider) => - getProvider({ - contract: 'This is not a valid address' - }) - } - ] - - brokenProviderOptions.map(brokenOption => - context(brokenOption.name, () => { - beforeEach(() => { - brokenProvider = brokenOption.brokenProvider(option.provider) - }) - - it('Should fallback to provider if multicall fails eth_getCode', async () => { - const code = await Promise.all([ - brokenProvider.getCode(callMock.address), - brokenProvider.getCode(utilsContract.address) - ]) - - if (!option.ignoreCount) expect(callCounter).to.equal(2 + brokenOption.overhead) - const rawCode = await Promise.all([ - ganache.provider!.getCode(callMock.address), - ganache.provider!.getCode(utilsContract.address) - ]) - - expect(rawCode[0]).to.equal(code[0]) - expect(rawCode[1]).to.equal(code[1]) - }) - - it('Should fallback to provider if multicall fails eth_call', async () => { - await callMock.testCall(848487868126387, '0x001122') - - const multiCallMock = callMock.connect(brokenProvider) - const promiseA = multiCallMock.lastValA() - const promiseB = multiCallMock.lastValB() - - expect((await promiseA).toString()).to.equal('848487868126387') - expect(await promiseB).to.equal('0x001122') - - if (option.ignoreCount) return - expect(callCounter).to.equal(3) - }) - - it('Should fallback to provider if multicall fails eth_call and eth_getCode', async () => { - await callMock.testCall(848487868126387, '0x001122') - - const multiCallMock = callMock.connect(brokenProvider) - const promiseA = multiCallMock.lastValA() - const promiseB = multiCallMock.lastValB() - const promiseC = brokenProvider.getCode(callMock.address) - - expect((await promiseA).toString()).to.equal('848487868126387') - expect(await promiseB).to.equal('0x001122') - expect(await promiseC).to.equal(await provider.getCode(callMock.address)) - - if (option.ignoreCount) return - expect(callCounter).to.equal(4 + brokenOption.overhead) - }) - - it('Should fallback to provider if multicall fails eth_getBalance', async () => { - const randomAddress = ethers.Wallet.createRandom().address - - const balances = await Promise.all([ - brokenProvider.getBalance(accounts[2].account.address), - brokenProvider.getBalance(accounts[1].account.address), - brokenProvider.getBalance(accounts[2].account.address), - brokenProvider.getBalance(randomAddress) - ]) - - if (!option.ignoreCount) expect(callCounter).to.equal(4 + brokenOption.overhead) - - // expect(callCounter).to.equal(1) - const rawBalances = await Promise.all([ - ganache.provider!.getBalance(accounts[2].account.address), - ganache.provider!.getBalance(accounts[1].account.address), - ganache.provider!.getBalance(accounts[2].account.address), - ganache.provider!.getBalance(randomAddress) - ]) - - rawBalances.forEach((bal, i) => { - expect(balances[i].toHexString()).to.equal(bal.toHexString()) - }) - }) - - it('Should fallback to provider if multicall fails eth_getBalance and eth_getCode', async () => { - const promiseA = brokenProvider.getCode(callMock.address) - const promiseB = await brokenProvider.getBalance(accounts[3].account.address) - - expect(await promiseA).to.equal(await ganache.provider!.getCode(callMock.address)) - expect(promiseB.toHexString()).to.equal( - (await ganache.provider!.getBalance(accounts[3].account.address)).toHexString() - ) - - if (option.ignoreCount) return - expect(callCounter).to.equal(2 + brokenOption.overhead) - }) - }) - ) - }) - }) - }) -}) diff --git a/packages/multicall/tests/utils/index.ts b/packages/multicall/tests/utils/index.ts deleted file mode 100644 index be4c722d7..000000000 --- a/packages/multicall/tests/utils/index.ts +++ /dev/null @@ -1,33 +0,0 @@ -export type SpyProxyHooks any> = { - prop: keyof K - func: T - callback: (...params: Parameters) => boolean | void -} - -export const SpyProxy = (obj: T, ...hooks: SpyProxyHooks any>[]): T => { - const handler = { - get: function (target: T, prop: keyof T, receiver: any) { - if (target[prop] instanceof Function) { - return (...p: any): any => { - if ( - !hooks - .filter(h => h.prop === prop) - .map(f => f.callback(...p)) - .reduce((p, c) => p || c, false) - ) { - return (obj[prop] as unknown as Function)(...p) - } - } - } - - if (Object.getPrototypeOf(obj)[prop] !== null) { - return obj[prop] - } - - return Reflect.get(target, prop, receiver) - } - } - - // @ts-ignore - return new Proxy(obj, handler) -} diff --git a/packages/network/CHANGELOG.md b/packages/network/CHANGELOG.md index 27b470634..4333928f2 100644 --- a/packages/network/CHANGELOG.md +++ b/packages/network/CHANGELOG.md @@ -1,5 +1,608 @@ # @0xsequence/network +## 2.2.14 + +### Patch Changes + +- Somnia Testnet and Monad Testnet +- Updated dependencies + - @0xsequence/core@2.2.14 + - @0xsequence/indexer@2.2.14 + - @0xsequence/relayer@2.2.14 + - @0xsequence/utils@2.2.14 + +## 2.2.13 + +### Patch Changes + +- Add XR1 to all networks +- Updated dependencies + - @0xsequence/core@2.2.13 + - @0xsequence/indexer@2.2.13 + - @0xsequence/relayer@2.2.13 + - @0xsequence/utils@2.2.13 + +## 2.2.12 + +### Patch Changes + +- Add XR1 +- Updated dependencies + - @0xsequence/core@2.2.12 + - @0xsequence/indexer@2.2.12 + - @0xsequence/relayer@2.2.12 + - @0xsequence/utils@2.2.12 + +## 2.2.11 + +### Patch Changes + +- Relayer updates +- Updated dependencies + - @0xsequence/core@2.2.11 + - @0xsequence/indexer@2.2.11 + - @0xsequence/relayer@2.2.11 + - @0xsequence/utils@2.2.11 + +## 2.2.10 + +### Patch Changes + +- Etherlink support +- Updated dependencies + - @0xsequence/core@2.2.10 + - @0xsequence/indexer@2.2.10 + - @0xsequence/relayer@2.2.10 + - @0xsequence/utils@2.2.10 + +## 2.2.9 + +### Patch Changes + +- Indexer gateway native token balances +- Updated dependencies + - @0xsequence/core@2.2.9 + - @0xsequence/indexer@2.2.9 + - @0xsequence/relayer@2.2.9 + - @0xsequence/utils@2.2.9 + +## 2.2.8 + +### Patch Changes + +- Add Moonbeam and Moonbase Alpha +- Updated dependencies + - @0xsequence/core@2.2.8 + - @0xsequence/indexer@2.2.8 + - @0xsequence/relayer@2.2.8 + - @0xsequence/utils@2.2.8 + +## 2.2.7 + +### Patch Changes + +- Update Builder package +- Updated dependencies + - @0xsequence/core@2.2.7 + - @0xsequence/indexer@2.2.7 + - @0xsequence/relayer@2.2.7 + - @0xsequence/utils@2.2.7 + +## 2.2.6 + +### Patch Changes + +- Update relayer package +- Updated dependencies + - @0xsequence/core@2.2.6 + - @0xsequence/indexer@2.2.6 + - @0xsequence/relayer@2.2.6 + - @0xsequence/utils@2.2.6 + +## 2.2.5 + +### Patch Changes + +- auth: fix sequence indexer gateway url +- account: immutable wallet proxy hook +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.2.5 + - @0xsequence/indexer@2.2.5 + - @0xsequence/relayer@2.2.5 + - @0xsequence/utils@2.2.5 + +## 2.2.4 + +### Patch Changes + +- network: update soneium mainnet block explorer url +- waas: signTypedData intent support +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.2.4 + - @0xsequence/indexer@2.2.4 + - @0xsequence/relayer@2.2.4 + - @0xsequence/utils@2.2.4 + +## 2.2.3 + +### Patch Changes + +- provider: updating initWallet to use connected network configs if they exist +- Updated dependencies + - @0xsequence/core@2.2.3 + - @0xsequence/indexer@2.2.3 + - @0xsequence/relayer@2.2.3 + - @0xsequence/utils@2.2.3 + +## 2.2.2 + +### Patch Changes + +- pass projectAccessKey to relayer at all times +- Updated dependencies + - @0xsequence/core@2.2.2 + - @0xsequence/indexer@2.2.2 + - @0xsequence/relayer@2.2.2 + - @0xsequence/utils@2.2.2 + +## 2.2.1 + +### Patch Changes + +- waas-ethers: sign typed data +- Updated dependencies + - @0xsequence/core@2.2.1 + - @0xsequence/indexer@2.2.1 + - @0xsequence/relayer@2.2.1 + - @0xsequence/utils@2.2.1 + +## 2.2.0 + +### Minor Changes + +- indexer: gateway client +- @0xsequence/builder +- upgrade puppeteer to v23.10.3 + +### Patch Changes + +- Updated dependencies +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.2.0 + - @0xsequence/indexer@2.2.0 + - @0xsequence/relayer@2.2.0 + - @0xsequence/utils@2.2.0 + +## 2.1.8 + +### Patch Changes + +- Add Soneium Mainnet +- Updated dependencies + - @0xsequence/core@2.1.8 + - @0xsequence/indexer@2.1.8 + - @0xsequence/relayer@2.1.8 + - @0xsequence/utils@2.1.8 + +## 2.1.7 + +### Patch Changes + +- guard: pass project access key to guard requests +- Updated dependencies + - @0xsequence/core@2.1.7 + - @0xsequence/indexer@2.1.7 + - @0xsequence/relayer@2.1.7 + - @0xsequence/utils@2.1.7 + +## 2.1.6 + +### Patch Changes + +- Add LAOS and Telos Testnet chains +- Updated dependencies + - @0xsequence/core@2.1.6 + - @0xsequence/indexer@2.1.6 + - @0xsequence/relayer@2.1.6 + - @0xsequence/utils@2.1.6 + +## 2.1.5 + +### Patch Changes + +- account: save presigned configuration with reference chain id 1 +- Updated dependencies + - @0xsequence/core@2.1.5 + - @0xsequence/indexer@2.1.5 + - @0xsequence/relayer@2.1.5 + - @0xsequence/utils@2.1.5 + +## 2.1.4 + +### Patch Changes + +- provider: pass projectAccessKey into MuxMessageProvider +- Updated dependencies + - @0xsequence/core@2.1.4 + - @0xsequence/indexer@2.1.4 + - @0xsequence/relayer@2.1.4 + - @0xsequence/utils@2.1.4 + +## 2.1.3 + +### Patch Changes + +- waas: time drift date fix due to strange browser quirk +- Updated dependencies + - @0xsequence/core@2.1.3 + - @0xsequence/indexer@2.1.3 + - @0xsequence/relayer@2.1.3 + - @0xsequence/utils@2.1.3 + +## 2.1.2 + +### Patch Changes + +- provider: export analytics correctly +- Updated dependencies + - @0xsequence/core@2.1.2 + - @0xsequence/indexer@2.1.2 + - @0xsequence/relayer@2.1.2 + - @0xsequence/utils@2.1.2 + +## 2.1.1 + +### Patch Changes + +- Add LAOS chain support +- Updated dependencies + - @0xsequence/core@2.1.1 + - @0xsequence/indexer@2.1.1 + - @0xsequence/relayer@2.1.1 + - @0xsequence/utils@2.1.1 + +## 2.1.0 + +### Minor Changes + +- account: forward project access key when estimating fees and sending transactions + +### Patch Changes + +- sessions: save signatures with reference chain id +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.1.0 + - @0xsequence/indexer@2.1.0 + - @0xsequence/relayer@2.1.0 + - @0xsequence/utils@2.1.0 + +## 2.0.26 + +### Patch Changes + +- account: fix chain id comparison +- Updated dependencies + - @0xsequence/core@2.0.26 + - @0xsequence/indexer@2.0.26 + - @0xsequence/relayer@2.0.26 + - @0xsequence/utils@2.0.26 + +## 2.0.25 + +### Patch Changes + +- skale-nebula: deploy gas limit = 10m +- Updated dependencies + - @0xsequence/core@2.0.25 + - @0xsequence/indexer@2.0.25 + - @0xsequence/relayer@2.0.25 + - @0xsequence/utils@2.0.25 + +## 2.0.24 + +### Patch Changes + +- sessions: arweave: configurable gateway url +- waas: use /status to get time drift before sending any intents +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.0.24 + - @0xsequence/indexer@2.0.24 + - @0xsequence/relayer@2.0.24 + - @0xsequence/utils@2.0.24 + +## 2.0.23 + +### Patch Changes + +- Add The Root Network support +- Updated dependencies + - @0xsequence/core@2.0.23 + - @0xsequence/indexer@2.0.23 + - @0xsequence/relayer@2.0.23 + - @0xsequence/utils@2.0.23 + +## 2.0.22 + +### Patch Changes + +- Add SKALE Nebula Mainnet support +- Updated dependencies + - @0xsequence/core@2.0.22 + - @0xsequence/indexer@2.0.22 + - @0xsequence/relayer@2.0.22 + - @0xsequence/utils@2.0.22 + +## 2.0.21 + +### Patch Changes + +- account: add publishWitnessFor +- Updated dependencies + - @0xsequence/core@2.0.21 + - @0xsequence/indexer@2.0.21 + - @0xsequence/relayer@2.0.21 + - @0xsequence/utils@2.0.21 + +## 2.0.20 + +### Patch Changes + +- upgrade deps, and improve waas session status handling +- Updated dependencies + - @0xsequence/core@2.0.20 + - @0xsequence/indexer@2.0.20 + - @0xsequence/relayer@2.0.20 + - @0xsequence/utils@2.0.20 + +## 2.0.19 + +### Patch Changes + +- Add Immutable zkEVM support +- Updated dependencies + - @0xsequence/core@2.0.19 + - @0xsequence/indexer@2.0.19 + - @0xsequence/relayer@2.0.19 + - @0xsequence/utils@2.0.19 + +## 2.0.18 + +### Patch Changes + +- waas: new contractCall transaction type +- sessions: add arweave owner +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.0.18 + - @0xsequence/indexer@2.0.18 + - @0xsequence/relayer@2.0.18 + - @0xsequence/utils@2.0.18 + +## 2.0.17 + +### Patch Changes + +- update waas auth to clear session before signIn +- Updated dependencies + - @0xsequence/core@2.0.17 + - @0xsequence/indexer@2.0.17 + - @0xsequence/relayer@2.0.17 + - @0xsequence/utils@2.0.17 + +## 2.0.16 + +### Patch Changes + +- Removed Astar chains +- Updated dependencies + - @0xsequence/core@2.0.16 + - @0xsequence/indexer@2.0.16 + - @0xsequence/relayer@2.0.16 + - @0xsequence/utils@2.0.16 + +## 2.0.15 + +### Patch Changes + +- indexer: update bindings with token balance additions +- Updated dependencies + - @0xsequence/core@2.0.15 + - @0xsequence/indexer@2.0.15 + - @0xsequence/relayer@2.0.15 + - @0xsequence/utils@2.0.15 + +## 2.0.14 + +### Patch Changes + +- sessions: arweave config reader +- network: add b3 and apechain mainnet configs +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.0.14 + - @0xsequence/indexer@2.0.14 + - @0xsequence/relayer@2.0.14 + - @0xsequence/utils@2.0.14 + +## 2.0.13 + +### Patch Changes + +- network: toy-testnet +- Updated dependencies + - @0xsequence/core@2.0.13 + - @0xsequence/indexer@2.0.13 + - @0xsequence/relayer@2.0.13 + - @0xsequence/utils@2.0.13 + +## 2.0.12 + +### Patch Changes + +- api: update bindings +- Updated dependencies + - @0xsequence/core@2.0.12 + - @0xsequence/indexer@2.0.12 + - @0xsequence/relayer@2.0.12 + - @0xsequence/utils@2.0.12 + +## 2.0.11 + +### Patch Changes + +- waas: intents test fix +- api: update bindings +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.0.11 + - @0xsequence/indexer@2.0.11 + - @0xsequence/relayer@2.0.11 + - @0xsequence/utils@2.0.11 + +## 2.0.10 + +### Patch Changes + +- network: soneium minato testnet +- Updated dependencies + - @0xsequence/core@2.0.10 + - @0xsequence/indexer@2.0.10 + - @0xsequence/relayer@2.0.10 + - @0xsequence/utils@2.0.10 + +## 2.0.9 + +### Patch Changes + +- network: fix SKALE network name +- Updated dependencies + - @0xsequence/core@2.0.9 + - @0xsequence/indexer@2.0.9 + - @0xsequence/relayer@2.0.9 + - @0xsequence/utils@2.0.9 + +## 2.0.8 + +### Patch Changes + +- metadata: update bindings +- Updated dependencies + - @0xsequence/core@2.0.8 + - @0xsequence/indexer@2.0.8 + - @0xsequence/relayer@2.0.8 + - @0xsequence/utils@2.0.8 + +## 2.0.7 + +### Patch Changes + +- wallet request handler fix +- Updated dependencies + - @0xsequence/core@2.0.7 + - @0xsequence/indexer@2.0.7 + - @0xsequence/relayer@2.0.7 + - @0xsequence/utils@2.0.7 + +## 2.0.6 + +### Patch Changes + +- network: matic -> pol +- Updated dependencies + - @0xsequence/core@2.0.6 + - @0xsequence/indexer@2.0.6 + - @0xsequence/relayer@2.0.6 + - @0xsequence/utils@2.0.6 + +## 2.0.5 + +### Patch Changes + +- provider: update databeat to 0.9.2 +- Updated dependencies + - @0xsequence/core@2.0.5 + - @0xsequence/indexer@2.0.5 + - @0xsequence/relayer@2.0.5 + - @0xsequence/utils@2.0.5 + +## 2.0.4 + +### Patch Changes + +- network: add skale-nebula-testnet +- Updated dependencies + - @0xsequence/core@2.0.4 + - @0xsequence/indexer@2.0.4 + - @0xsequence/relayer@2.0.4 + - @0xsequence/utils@2.0.4 + +## 2.0.3 + +### Patch Changes + +- waas: check session status in SequenceWaaS.isSignedIn() +- Updated dependencies + - @0xsequence/core@2.0.3 + - @0xsequence/indexer@2.0.3 + - @0xsequence/relayer@2.0.3 + - @0xsequence/utils@2.0.3 + +## 2.0.2 + +### Patch Changes + +- sessions: property convert serialized bignumber hex value to bigint +- Updated dependencies + - @0xsequence/core@2.0.2 + - @0xsequence/indexer@2.0.2 + - @0xsequence/relayer@2.0.2 + - @0xsequence/utils@2.0.2 + +## 2.0.1 + +### Patch Changes + +- waas: http signature check for authenticator requests +- provider: unwrap legacy json rpc responses +- use json replacer and reviver for bigints +- Updated dependencies +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.0.1 + - @0xsequence/indexer@2.0.1 + - @0xsequence/relayer@2.0.1 + - @0xsequence/utils@2.0.1 + +## 2.0.0 + +### Major Changes + +- ethers v6 + +### Patch Changes + +- Updated dependencies + - @0xsequence/core@2.0.0 + - @0xsequence/indexer@2.0.0 + - @0xsequence/relayer@2.0.0 + - @0xsequence/utils@2.0.0 + +## 1.10.15 + +### Patch Changes + +- utils: extractProjectIdFromAccessKey +- Updated dependencies + - @0xsequence/core@1.10.15 + - @0xsequence/indexer@1.10.15 + - @0xsequence/relayer@1.10.15 + - @0xsequence/utils@1.10.15 + ## 1.10.14 ### Patch Changes diff --git a/packages/network/package.json b/packages/network/package.json index f499bcb63..833989816 100644 --- a/packages/network/package.json +++ b/packages/network/package.json @@ -1,6 +1,6 @@ { "name": "@0xsequence/network", - "version": "1.10.14", + "version": "2.2.14", "description": "network sub-package for Sequence", "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/network", "source": "src/index.ts", @@ -12,17 +12,17 @@ "test": "echo", "typecheck": "tsc --noEmit" }, + "peerDependencies": { + "ethers": ">=6" + }, "dependencies": { "@0xsequence/core": "workspace:*", "@0xsequence/indexer": "workspace:*", "@0xsequence/relayer": "workspace:*", "@0xsequence/utils": "workspace:*" }, - "peerDependencies": { - "ethers": ">=5.5 < 6" - }, "devDependencies": { - "ethers": "^5.7.2" + "ethers": "6.13.4" }, "files": [ "src", diff --git a/packages/network/src/config.ts b/packages/network/src/config.ts index d19c63440..21e3ffdf4 100644 --- a/packages/network/src/config.ts +++ b/packages/network/src/config.ts @@ -1,4 +1,4 @@ -import { BigNumberish, ethers, providers } from 'ethers' +import { ethers } from 'ethers' import { Indexer } from '@0xsequence/indexer' import { Relayer, RpcRelayerOptions } from '@0xsequence/relayer' import { findNetworkConfig, stringTemplate, validateAndSortNetworks } from './utils' @@ -7,7 +7,7 @@ import { ChainId, NetworkMetadata, networks } from './constants' export type NetworkConfig = NetworkMetadata & { rpcUrl: string - provider?: providers.Provider + provider?: ethers.Provider indexerUrl?: string indexer?: Indexer relayer?: Relayer | RpcRelayerOptions @@ -30,18 +30,18 @@ export function findSupportedNetwork(chainIdOrName: string | ChainIdLike): Netwo return findNetworkConfig(allNetworks, chainIdOrName) } -export type ChainIdLike = NetworkConfig | BigNumberish +export type ChainIdLike = NetworkConfig | ethers.BigNumberish -export function toChainIdNumber(chainIdLike: ChainIdLike): ethers.BigNumber { - if (ethers.BigNumber.isBigNumber(chainIdLike)) { +export function toChainIdNumber(chainIdLike: ChainIdLike): bigint { + if (typeof chainIdLike === 'bigint') { return chainIdLike } if (isBigNumberish(chainIdLike)) { - return ethers.BigNumber.from(chainIdLike) + return BigInt(chainIdLike) } - return ethers.BigNumber.from(chainIdLike.chainId) + return BigInt(chainIdLike.chainId) } const createNetworkConfig = (chainId: ChainId, options?: { disabled?: boolean }): NetworkConfig => { @@ -115,14 +115,33 @@ export const allNetworks = validateAndSortNetworks([ createNetworkConfig(ChainId.XAI), createNetworkConfig(ChainId.XAI_SEPOLIA), createNetworkConfig(ChainId.AVALANCHE_TESTNET), - createNetworkConfig(ChainId.ASTAR_ZKEVM), - createNetworkConfig(ChainId.ASTAR_ZKYOTO), + createNetworkConfig(ChainId.XR1), createNetworkConfig(ChainId.XR_SEPOLIA), + createNetworkConfig(ChainId.B3), createNetworkConfig(ChainId.B3_SEPOLIA), + createNetworkConfig(ChainId.APECHAIN), createNetworkConfig(ChainId.APECHAIN_TESTNET), createNetworkConfig(ChainId.BLAST), createNetworkConfig(ChainId.BLAST_SEPOLIA), createNetworkConfig(ChainId.TELOS), + createNetworkConfig(ChainId.TELOS_TESTNET), createNetworkConfig(ChainId.BORNE_TESTNET), + createNetworkConfig(ChainId.SKALE_NEBULA), + createNetworkConfig(ChainId.SKALE_NEBULA_TESTNET), + createNetworkConfig(ChainId.SONEIUM), + createNetworkConfig(ChainId.SONEIUM_MINATO), + createNetworkConfig(ChainId.TOY_TESTNET), + createNetworkConfig(ChainId.IMMUTABLE_ZKEVM), + createNetworkConfig(ChainId.IMMUTABLE_ZKEVM_TESTNET), + createNetworkConfig(ChainId.ROOT_NETWORK), + createNetworkConfig(ChainId.ROOT_NETWORK_PORCINI), + createNetworkConfig(ChainId.LAOS), + createNetworkConfig(ChainId.LAOS_SIGMA_TESTNET), + createNetworkConfig(ChainId.MOONBEAM), + createNetworkConfig(ChainId.MOONBASE_ALPHA), + createNetworkConfig(ChainId.ETHERLINK), + createNetworkConfig(ChainId.ETHERLINK_TESTNET), + createNetworkConfig(ChainId.SOMNIA_TESTNET), + createNetworkConfig(ChainId.MONAD_TESTNET), ...hardhatNetworks ]) diff --git a/packages/network/src/constants.ts b/packages/network/src/constants.ts index 953921c51..a524cf596 100644 --- a/packages/network/src/constants.ts +++ b/packages/network/src/constants.ts @@ -1,3 +1,32 @@ +export enum NetworkType { + MAINNET = 'mainnet', + TESTNET = 'testnet' +} + +export type BlockExplorerConfig = { + name?: string + rootUrl: string + addressUrl?: string + txnHashUrl?: string +} + +export interface NetworkMetadata { + chainId: ChainId + type?: NetworkType + name: string + title?: string + logoURI?: string + blockExplorer?: BlockExplorerConfig + ensAddress?: string + testnet?: boolean // Deprecated field, use type instead + deprecated?: boolean // The actual network is deprecated + nativeToken: { + symbol: string + name: string + decimals: number + } +} + export enum ChainId { // Ethereum MAINNET = 1, @@ -51,20 +80,20 @@ export enum ChainId { XAI = 660279, XAI_SEPOLIA = 37714555429, - // Astar - ASTAR_ZKEVM = 3776, - ASTAR_ZKYOTO = 6038361, - // XR + XR1 = 273, XR_SEPOLIA = 2730, // TELOS TELOS = 40, + TELOS_TESTNET = 41, // B3 Sepolia + B3 = 8333, B3_SEPOLIA = 1993, // APE Chain + APECHAIN = 33139, APECHAIN_TESTNET = 33111, // Blast @@ -74,38 +103,46 @@ export enum ChainId { // Borne BORNE_TESTNET = 94984, + // SKALE Nebula + SKALE_NEBULA = 1482601649, + SKALE_NEBULA_TESTNET = 37084624, + + // Soneium Minato + SONEIUM_MINATO = 1946, + SONEIUM = 1868, + + // TOY Testnet + TOY_TESTNET = 21000000, + + // Immutable zkEVM + IMMUTABLE_ZKEVM = 13371, + IMMUTABLE_ZKEVM_TESTNET = 13473, + + // The Root Network + ROOT_NETWORK = 7668, + ROOT_NETWORK_PORCINI = 7672, + // HARDHAT TESTNETS HARDHAT = 31337, - HARDHAT_2 = 31338 -} + HARDHAT_2 = 31338, -export enum NetworkType { - MAINNET = 'mainnet', - TESTNET = 'testnet' -} + // LAOS + LAOS = 6283, + LAOS_SIGMA_TESTNET = 62850, -export type BlockExplorerConfig = { - name?: string - rootUrl: string - addressUrl?: string - txnHashUrl?: string -} + //ETHERLINK + ETHERLINK = 42793, + ETHERLINK_TESTNET = 128123, -export interface NetworkMetadata { - chainId: ChainId - type?: NetworkType - name: string - title?: string - logoURI?: string - blockExplorer?: BlockExplorerConfig - ensAddress?: string - testnet?: boolean // Deprecated field, use type instead - deprecated?: boolean // The actual network is deprecated - nativeToken: { - symbol: string - name: string - decimals: number - } + // MOONBEAM + MOONBEAM = 1284, + MOONBASE_ALPHA = 1287, + + //MONAD_TESTNET + MONAD_TESTNET = 10143, + + //SOMNIA_TESTNET + SOMNIA_TESTNET = 50312 } export const networks: Record = { @@ -229,8 +266,8 @@ export const networks: Record = { rootUrl: 'https://polygonscan.com/' }, nativeToken: { - symbol: 'MATIC', - name: 'Polygon', + symbol: 'POL', + name: 'POL', decimals: 18 } }, @@ -264,8 +301,8 @@ export const networks: Record = { rootUrl: 'https://www.oklink.com/amoy/' }, nativeToken: { - symbol: 'aMATIC', - name: 'Amoy Polygon', + symbol: 'aPOL', + name: 'Amoy POL', decimals: 18 } }, @@ -620,36 +657,20 @@ export const networks: Record = { decimals: 18 } }, - [ChainId.ASTAR_ZKEVM]: { - chainId: ChainId.ASTAR_ZKEVM, + [ChainId.XR1]: { + chainId: ChainId.XR1, type: NetworkType.MAINNET, - name: 'astar-zkevm', - title: 'Astar zkEVM', - logoURI: `https://assets.sequence.info/images/networks/medium/${ChainId.ASTAR_ZKEVM}.webp`, - blockExplorer: { - name: 'Astar zkEVM Explorer', - rootUrl: 'https://astar-zkevm.explorer.startale.com/' - }, - nativeToken: { - symbol: 'ETH', - name: 'Ether', - decimals: 18 - } - }, - [ChainId.ASTAR_ZKYOTO]: { - chainId: ChainId.ASTAR_ZKYOTO, - type: NetworkType.TESTNET, - name: 'astar-zkyoto', - title: 'Astar zKyoto Testnet', - logoURI: `https://assets.sequence.info/images/networks/medium/${ChainId.ASTAR_ZKYOTO}.webp`, + name: 'xr1', + title: 'XR1', + logoURI: `https://assets.sequence.info/images/networks/medium/${ChainId.XR1}.webp`, testnet: true, blockExplorer: { - name: 'Astar zKyoto Explorer', - rootUrl: 'https://astar-zkyoto.blockscout.com/' + name: 'XR1 Explorer', + rootUrl: 'https://xr1.calderaexplorer.xyz/' }, nativeToken: { - symbol: 'ETH', - name: 'Ether', + symbol: 'XR1', + name: 'XR1', decimals: 18 } }, @@ -670,6 +691,23 @@ export const networks: Record = { decimals: 18 } }, + [ChainId.B3]: { + chainId: ChainId.B3, + type: NetworkType.MAINNET, + name: 'b3', + title: 'B3', + logoURI: `https://assets.sequence.info/images/networks/medium/${ChainId.B3}.webp`, + testnet: false, + blockExplorer: { + name: 'B3 Explorer', + rootUrl: 'https://explorer.b3.fun/' + }, + nativeToken: { + symbol: 'ETH', + name: 'Ether', + decimals: 18 + } + }, [ChainId.B3_SEPOLIA]: { chainId: ChainId.B3_SEPOLIA, type: NetworkType.TESTNET, @@ -687,6 +725,23 @@ export const networks: Record = { decimals: 18 } }, + [ChainId.APECHAIN]: { + chainId: ChainId.APECHAIN, + type: NetworkType.MAINNET, + name: 'apechain', + title: 'APE Chain', + logoURI: `https://assets.sequence.info/images/networks/medium/${ChainId.APECHAIN}.webp`, + testnet: false, + blockExplorer: { + name: 'APE Chain Explorer', + rootUrl: 'https://apechain.calderaexplorer.xyz/' + }, + nativeToken: { + symbol: 'APE', + name: 'ApeCoin', + decimals: 18 + } + }, [ChainId.APECHAIN_TESTNET]: { chainId: ChainId.APECHAIN_TESTNET, type: NetworkType.TESTNET, @@ -753,6 +808,22 @@ export const networks: Record = { decimals: 18 } }, + [ChainId.TELOS_TESTNET]: { + chainId: ChainId.TELOS_TESTNET, + type: NetworkType.TESTNET, + name: 'telos-testnet', + title: 'Telos Testnet', + logoURI: `https://assets.sequence.info/images/networks/medium/${ChainId.TELOS_TESTNET}.webp`, + blockExplorer: { + name: 'Telos Testnet Explorer', + rootUrl: 'https://explorer-test.telos.net/network' + }, + nativeToken: { + symbol: 'TLOS', + name: 'TLOS', + decimals: 18 + } + }, [ChainId.BORNE_TESTNET]: { chainId: ChainId.BORNE_TESTNET, type: NetworkType.TESTNET, @@ -770,6 +841,159 @@ export const networks: Record = { decimals: 18 } }, + [ChainId.SKALE_NEBULA]: { + chainId: ChainId.SKALE_NEBULA, + type: NetworkType.MAINNET, + name: 'skale-nebula', + title: 'SKALE Nebula Gaming Hub', + logoURI: `https://assets.sequence.info/images/networks/medium/${ChainId.SKALE_NEBULA}.webp`, + testnet: false, + blockExplorer: { + name: 'SKALE Nebula Gaming Hub Explorer', + rootUrl: 'https://green-giddy-denebola.explorer.mainnet.skalenodes.com/' + }, + nativeToken: { + symbol: 'sFUEL', + name: 'SKALE Fuel', + decimals: 18 + } + }, + [ChainId.SKALE_NEBULA_TESTNET]: { + chainId: ChainId.SKALE_NEBULA_TESTNET, + type: NetworkType.TESTNET, + name: 'skale-nebula-testnet', + title: 'SKALE Nebula Gaming Hub Testnet', + logoURI: `https://assets.sequence.info/images/networks/medium/${ChainId.SKALE_NEBULA_TESTNET}.webp`, + testnet: true, + blockExplorer: { + name: 'SKALE Nebula Gaming Hub Testnet Explorer', + rootUrl: 'https://lanky-ill-funny-testnet.explorer.testnet.skalenodes.com/' + }, + nativeToken: { + symbol: 'sFUEL', + name: 'SKALE Fuel', + decimals: 18 + } + }, + [ChainId.SONEIUM]: { + chainId: ChainId.SONEIUM, + type: NetworkType.MAINNET, + name: 'soneium', + title: 'Soneium', + logoURI: `https://assets.sequence.info/images/networks/medium/${ChainId.SONEIUM}.webp`, + testnet: false, + blockExplorer: { + name: 'Soneium Explorer', + rootUrl: 'https://soneium.blockscout.com/' + }, + nativeToken: { + symbol: 'ETH', + name: 'Ether', + decimals: 18 + } + }, + [ChainId.SONEIUM_MINATO]: { + chainId: ChainId.SONEIUM_MINATO, + type: NetworkType.TESTNET, + name: 'soneium-minato', + title: 'Soneium Minato (Testnet)', + logoURI: `https://assets.sequence.info/images/networks/medium/${ChainId.SONEIUM_MINATO}.webp`, + testnet: true, + blockExplorer: { + name: 'Soneium Minato Explorer', + rootUrl: 'https://explorer-testnet.soneium.org/' + }, + nativeToken: { + symbol: 'ETH', + name: 'Ether', + decimals: 18 + } + }, + [ChainId.TOY_TESTNET]: { + chainId: ChainId.TOY_TESTNET, + type: NetworkType.TESTNET, + name: 'toy-testnet', + title: 'TOY (Testnet)', + logoURI: `https://assets.sequence.info/images/networks/medium/${ChainId.TOY_TESTNET}.webp`, + testnet: true, + blockExplorer: { + name: 'TOY Testnet Explorer', + rootUrl: 'https://toy-chain-testnet.explorer.caldera.xyz/' + }, + nativeToken: { + symbol: 'TOY', + name: 'TOY', + decimals: 18 + } + }, + [ChainId.IMMUTABLE_ZKEVM]: { + chainId: ChainId.IMMUTABLE_ZKEVM, + type: NetworkType.MAINNET, + name: 'immutable-zkevm', + title: 'Immutable zkEVM', + logoURI: `https://assets.sequence.info/images/networks/medium/${ChainId.IMMUTABLE_ZKEVM}.webp`, + testnet: false, + blockExplorer: { + name: 'Immutable zkEVM Explorer', + rootUrl: 'https://explorer.immutable.com/' + }, + nativeToken: { + symbol: 'IMX', + name: 'IMX', + decimals: 18 + } + }, + [ChainId.IMMUTABLE_ZKEVM_TESTNET]: { + chainId: ChainId.IMMUTABLE_ZKEVM_TESTNET, + type: NetworkType.TESTNET, + name: 'immutable-zkevm-testnet', + title: 'Immutable zkEVM Testnet', + logoURI: `https://assets.sequence.info/images/networks/medium/${ChainId.IMMUTABLE_ZKEVM_TESTNET}.webp`, + testnet: true, + blockExplorer: { + name: 'Immutable zkEVM Testnet Explorer', + rootUrl: 'https://explorer.testnet.immutable.com/' + }, + nativeToken: { + symbol: 'IMX', + name: 'IMX', + decimals: 18 + } + }, + [ChainId.ROOT_NETWORK]: { + chainId: ChainId.ROOT_NETWORK, + type: NetworkType.MAINNET, + name: 'rootnet', + title: 'The Root Network', + logoURI: `https://assets.sequence.info/images/networks/medium/${ChainId.ROOT_NETWORK}.webp`, + testnet: false, + blockExplorer: { + name: 'The Root Network Explorer', + rootUrl: 'https://rootscan.io/' + }, + nativeToken: { + symbol: 'XRP', + name: 'XRP', + decimals: 18 + } + }, + [ChainId.ROOT_NETWORK_PORCINI]: { + chainId: ChainId.ROOT_NETWORK_PORCINI, + type: NetworkType.TESTNET, + name: 'rootnet-porcini', + title: 'The Root Network Porcini Testnet', + logoURI: `https://assets.sequence.info/images/networks/medium/${ChainId.ROOT_NETWORK_PORCINI}.webp`, + testnet: true, + blockExplorer: { + name: 'The Root Network Porcini Testnet Explorer', + rootUrl: 'https://porcini.rootscan.io/' + }, + nativeToken: { + symbol: 'XRP', + name: 'XRP', + decimals: 18 + } + }, [ChainId.HARDHAT]: { chainId: ChainId.HARDHAT, name: 'hardhat', @@ -789,5 +1013,151 @@ export const networks: Record = { name: 'Ether', decimals: 18 } + }, + [ChainId.LAOS]: { + chainId: ChainId.LAOS, + type: NetworkType.MAINNET, + name: 'laos', + title: 'LAOS', + logoURI: `https://assets.sequence.info/images/networks/medium/${ChainId.LAOS}.webp`, + testnet: false, + blockExplorer: { + name: 'LAOS Explorer', + rootUrl: 'https://blockscout.laos.laosfoundation.io/' + }, + nativeToken: { + symbol: 'LAOS', + name: 'LAOS', + decimals: 18 + } + }, + [ChainId.LAOS_SIGMA_TESTNET]: { + chainId: ChainId.LAOS_SIGMA_TESTNET, + type: NetworkType.TESTNET, + name: 'laos-sigma-testnet', + title: 'LAOS Sigma Testnet', + logoURI: `https://assets.sequence.info/images/networks/medium/${ChainId.LAOS_SIGMA_TESTNET}.webp`, + testnet: true, + blockExplorer: { + name: 'LAOS Sigma Testnet Explorer', + rootUrl: 'https://sigma.explorer.laosnetwork.io/' + }, + nativeToken: { + symbol: 'SIGMA', + name: 'SIGMA', + decimals: 18 + } + }, + [ChainId.MOONBEAM]: { + chainId: ChainId.MOONBEAM, + type: NetworkType.MAINNET, + name: 'moonbeam', + title: 'Moonbeam', + logoURI: `https://assets.sequence.info/images/networks/medium/${ChainId.MOONBEAM}.webp`, + testnet: false, + blockExplorer: { + name: 'Moonscan', + rootUrl: 'https://moonscan.io/' + }, + nativeToken: { + symbol: 'GLMR', + name: 'GLMR', + decimals: 18 + } + }, + [ChainId.MOONBASE_ALPHA]: { + chainId: ChainId.MOONBASE_ALPHA, + type: NetworkType.TESTNET, + name: 'moonbase-alpha', + title: 'Moonbase Alpha', + logoURI: `https://assets.sequence.info/images/networks/medium/${ChainId.MOONBASE_ALPHA}.webp`, + testnet: true, + blockExplorer: { + name: 'Moonscan (Moonbase Alpha)', + rootUrl: 'https://moonbase.moonscan.io/' + }, + nativeToken: { + symbol: 'GLMR', + name: 'GLMR', + decimals: 18 + } + }, + [ChainId.ETHERLINK]: { + chainId: ChainId.ETHERLINK, + type: NetworkType.MAINNET, + name: 'etherlink', + title: 'ETHERLINK', + logoURI: `https://assets.sequence.info/images/networks/medium/${ChainId.ETHERLINK}.webp`, + testnet: false, + blockExplorer: { + name: 'ETHERLINK Explorer', + rootUrl: 'https://explorer.etherlink.com/' + }, + nativeToken: { + symbol: 'XTZ', + name: 'Tez', + decimals: 18 + } + }, + [ChainId.ETHERLINK_TESTNET]: { + chainId: ChainId.ETHERLINK_TESTNET, + type: NetworkType.TESTNET, + name: 'etherlink-testnet', + title: 'ETHERLINK Testnet', + logoURI: `https://assets.sequence.info/images/networks/medium/${ChainId.ETHERLINK_TESTNET}.webp`, + testnet: true, + blockExplorer: { + name: 'ETHERLINK Testnet Explorer', + rootUrl: 'https://testnet.explorer.etherlink.com/' + }, + nativeToken: { + symbol: 'XTZ', + name: 'Tez', + decimals: 18 + } + }, + [ChainId.MONAD_TESTNET]: { + chainId: ChainId.MONAD_TESTNET, + type: NetworkType.TESTNET, + name: 'monad-testnet', + title: 'MONAD Testnet', + logoURI: `https://assets.sequence.info/images/networks/medium/${ChainId.MONAD_TESTNET}.webp`, + testnet: true, + blockExplorer: { + name: 'MONAD Testnet Explorer', + rootUrl: 'https://testnet.monadexplorer.com/' + }, + nativeToken: { + symbol: 'MON', + name: 'MON', + decimals: 18 + } + }, + + [ChainId.SOMNIA_TESTNET]: { + chainId: ChainId.SOMNIA_TESTNET, + type: NetworkType.TESTNET, + name: 'somnia-testnet', + title: 'SOMNIA Testnet', + logoURI: `https://assets.sequence.info/images/networks/medium/${ChainId.SOMNIA_TESTNET}.webp`, + testnet: true, + blockExplorer: { + name: 'SOMNIA Testnet Explorer', + rootUrl: 'https://somnia-testnet.socialscan.io/' + }, + nativeToken: { + symbol: 'STT', + name: 'STT', + decimals: 18 + } + } +} + +export function getChainIdFromNetwork(networkName: string): ChainId { + for (const [chainId, network] of Object.entries(networks)) { + if (network.name === networkName) { + return Number(chainId) as ChainId + } } + throw new Error(`Unknown network name: ${networkName}`) } diff --git a/packages/network/src/json-rpc-provider.ts b/packages/network/src/json-rpc-provider.ts index 4c2404af0..9695f26da 100644 --- a/packages/network/src/json-rpc-provider.ts +++ b/packages/network/src/json-rpc-provider.ts @@ -1,13 +1,15 @@ import { ethers } from 'ethers' import { JsonRpcRouter, - JsonRpcSender, - loggingProviderMiddleware, EagerProvider, SingleflightMiddleware, CachedProvider, JsonRpcMiddleware, - JsonRpcMiddlewareHandler + JsonRpcMiddlewareHandler, + JsonRpcHandler, + EIP1193Provider, + JsonRpcSender, + JsonRpcRequest } from './json-rpc' import { ChainId, networks } from './constants' @@ -23,18 +25,23 @@ export interface JsonRpcProviderOptions { } // JsonRpcProvider with a middleware stack. By default it will use a simple caching middleware. -export class JsonRpcProvider extends ethers.providers.JsonRpcProvider { - private _chainId?: number - private _sender: JsonRpcSender +export class JsonRpcProvider extends ethers.JsonRpcProvider implements EIP1193Provider, JsonRpcSender { + #chainId?: number + #nextId: number = 1 + #sender: EIP1193Provider - constructor(url: ethers.utils.ConnectionInfo | string, options?: JsonRpcProviderOptions) { - super(url, options?.chainId) + constructor( + public url: string | ethers.FetchRequest | undefined, + options?: JsonRpcProviderOptions, + jsonRpcApiProviderOptions?: ethers.JsonRpcApiProviderOptions + ) { + super(url, options?.chainId, jsonRpcApiProviderOptions) const chainId = options?.chainId const middlewares = options?.middlewares const blockCache = options?.blockCache - this._chainId = chainId + this.#chainId = chainId // NOTE: it will either use the middleware stack passed to the constructor // or it will use the default caching middleware provider. It does not concat them, @@ -47,52 +54,87 @@ export class JsonRpcProvider extends ethers.providers.JsonRpcProvider { new SingleflightMiddleware(), new CachedProvider({ defaultChainId: chainId, blockCache: blockCache }) ], - new JsonRpcSender(this.fetch, chainId) + new JsonRpcHandler(this.fetch, chainId) ) - this._sender = new JsonRpcSender(router, chainId) + this.#sender = router } - async getNetwork(): Promise { - const chainId = this._chainId + async request(request: { method: string; params?: any[]; chainId?: number }): Promise { + return this.#sender.request(request) + } + + async send(method: string, params?: any[] | Record, chainId?: number): Promise { + return this.request({ method, params: params as any, chainId }) + } + + async getNetwork(): Promise { + const chainId = this.#chainId if (chainId) { const network = networks[chainId as ChainId] const name = network?.name || '' const ensAddress = network?.ensAddress - return { - name: name, - chainId: chainId, - ensAddress: ensAddress - } + return ethers.Network.from({ + name, + chainId, + ensAddress + }) } else { const chainIdHex = await this.send('eth_chainId', []) - this._chainId = ethers.BigNumber.from(chainIdHex).toNumber() + this.#chainId = Number(chainIdHex) return this.getNetwork() } } - send = (method: string, params: Array): Promise => { - return this._sender.send(method, params) - } + private fetch = async (request: { method: string; params?: any[]; chainId?: number }): Promise => { + if (this.url === undefined) { + throw new Error('missing provider URL') + } - private fetch = (method: string, params: Array): Promise => { - const request = { - method: method, - params: params, - id: this._nextId++, + const { method, params } = request + + const jsonRpcRequest: JsonRpcRequest = { + method, + params, + id: this.#nextId++, jsonrpc: '2.0' } - const result = ethers.utils.fetchJson(this.connection, JSON.stringify(request), getResult).then( - result => { - return result - }, - error => { - throw error + // const result = ethers.fetchJson(this.connection, JSON.stringify(request), getResult).then( + // result => { + // return result + // }, + // error => { + // throw error + // } + // ) + + const fetchRequest = typeof this.url === 'string' ? new ethers.FetchRequest(this.url) : this.url + fetchRequest.body = JSON.stringify(jsonRpcRequest) + + // TODOXXX: what about headers, etc..? + // we probably need these in the options of the construtor, etc.. + + try { + const res = await fetchRequest.send() + + if (res.body) { + try { + const result = JSON.parse(ethers.toUtf8String(res.body)) + + // TODO: Process result + + return getResult(result) + } catch (err) { + throw new Error('invalid JSON response') + } } - ) - return result + return null + } catch (err) { + // TODO - error handling + throw err + } } } diff --git a/packages/network/src/json-rpc/handler.ts b/packages/network/src/json-rpc/handler.ts new file mode 100644 index 000000000..8d3b961f1 --- /dev/null +++ b/packages/network/src/json-rpc/handler.ts @@ -0,0 +1,40 @@ +import { ethers } from 'ethers' +import { EIP1193Provider, EIP1193ProviderFunc, JsonRpcSender } from './types' + +import { isJsonRpcSender, isJsonRpcProvider } from './utils' + +export class JsonRpcHandler implements EIP1193Provider, JsonRpcSender { + private provider: EIP1193ProviderFunc + private defaultChainId?: number + + constructor(provider: EIP1193ProviderFunc | JsonRpcSender | ethers.JsonRpcProvider, defaultChainId?: number) { + if (isJsonRpcSender(provider)) { + this.provider = (request: { method: string; params?: any[]; chainId?: number }): Promise => { + return provider.send(request.method, request.params, request.chainId) + } + } else if (isJsonRpcProvider(provider)) { + this.provider = (request: { method: string; params?: any[]; chainId?: number }): Promise => { + return provider.send(request.method, request.params || []) + } + } else { + this.provider = provider + } + this.defaultChainId = defaultChainId + } + + request = (request: { method: string; params?: any[]; chainId?: number }): Promise => { + if (!request.chainId) { + request.chainId = this.defaultChainId + } + return this.provider(request) + } + + send(method: string, params?: any[], chainId?: number): Promise { + const request = { + method, + params, + chainId + } + return this.request(request) + } +} diff --git a/packages/network/src/json-rpc/index.ts b/packages/network/src/json-rpc/index.ts index 6eceac084..3f25c5690 100644 --- a/packages/network/src/json-rpc/index.ts +++ b/packages/network/src/json-rpc/index.ts @@ -1,5 +1,5 @@ export * from './types' export * from './router' -export * from './sender' +export * from './handler' export * from './middleware' export * from './utils' diff --git a/packages/network/src/json-rpc/middleware/allow-provider.ts b/packages/network/src/json-rpc/middleware/allow-provider.ts index 5d5c624a6..6be8b2791 100644 --- a/packages/network/src/json-rpc/middleware/allow-provider.ts +++ b/packages/network/src/json-rpc/middleware/allow-provider.ts @@ -1,13 +1,7 @@ -import { - JsonRpcHandlerFunc, - JsonRpcRequest, - JsonRpcResponseCallback, - JsonRpcMiddleware, - JsonRpcMiddlewareHandler -} from '../types' +import { JsonRpcRequest, EIP1193ProviderFunc, JsonRpcMiddleware, JsonRpcMiddlewareHandler } from '../types' export class AllowProvider implements JsonRpcMiddlewareHandler { - sendAsyncMiddleware: JsonRpcMiddleware + requestHandler: JsonRpcMiddleware private isAllowedFunc: (request: JsonRpcRequest) => boolean @@ -18,25 +12,25 @@ export class AllowProvider implements JsonRpcMiddlewareHandler { this.isAllowedFunc = (request: JsonRpcRequest): boolean => true } - this.sendAsyncMiddleware = allowProviderMiddleware(this.isAllowedFunc) + this.requestHandler = allowProviderMiddleware(this.isAllowedFunc) } setIsAllowedFunc(fn: (request: JsonRpcRequest) => boolean) { this.isAllowedFunc = fn - this.sendAsyncMiddleware = allowProviderMiddleware(this.isAllowedFunc) + this.requestHandler = allowProviderMiddleware(this.isAllowedFunc) } } export const allowProviderMiddleware = (isAllowed: (request: JsonRpcRequest) => boolean): JsonRpcMiddleware => - (next: JsonRpcHandlerFunc) => { - return (request: JsonRpcRequest, callback: JsonRpcResponseCallback, chainId?: number) => { + (next: EIP1193ProviderFunc) => { + return (request: JsonRpcRequest): Promise => { // ensure precondition is met or do not allow the request to continue if (!isAllowed(request)) { throw new Error('allowProvider middleware precondition is unmet.') } // request is allowed. keep going.. - next(request, callback, chainId) + return next(request) } } diff --git a/packages/network/src/json-rpc/middleware/cached-provider.ts b/packages/network/src/json-rpc/middleware/cached-provider.ts index 7ede68530..2aa01f211 100644 --- a/packages/network/src/json-rpc/middleware/cached-provider.ts +++ b/packages/network/src/json-rpc/middleware/cached-provider.ts @@ -1,4 +1,4 @@ -import { JsonRpcHandlerFunc, JsonRpcRequest, JsonRpcResponse, JsonRpcResponseCallback, JsonRpcMiddlewareHandler } from '../types' +import { EIP1193ProviderFunc, JsonRpcRequest, JsonRpcMiddlewareHandler } from '../types' export interface CachedProviderOptions { // defaultChainId passes a chainId to provider handler if one isn't passed. @@ -52,48 +52,38 @@ export class CachedProvider implements JsonRpcMiddlewareHandler { } } - sendAsyncMiddleware = (next: JsonRpcHandlerFunc) => { - return (request: JsonRpcRequest, callback: JsonRpcResponseCallback, chainId?: number) => { + requestHandler = (next: EIP1193ProviderFunc) => { + return async (request: JsonRpcRequest): Promise => { // Respond early with cached result if (this.cachableJsonRpcMethods.includes(request.method) || this.cachableJsonRpcMethodsByBlock.includes(request.method)) { - const key = this.cacheKey(request.method, request.params!, chainId || this.defaultChainId) + const key = this.cacheKey(request.method, request.params! as any[], request.chainId || this.defaultChainId) const result = this.getCacheValue(key) if (result && result !== '') { - callback(undefined, { - jsonrpc: '2.0', + return { id: request.id!, - result: result - }) - return + result + } } } // Continue down the handler chain - next( - request, - (error: any, response?: JsonRpcResponse, chainId?: number) => { - // Store result in cache and continue - if ( - this.cachableJsonRpcMethods.includes(request.method) || - this.cachableJsonRpcMethodsByBlock.includes(request.method) - ) { - if (response && response.result && this.shouldCacheResponse(request, response)) { - // cache the value - const key = this.cacheKey(request.method, request.params!, chainId || this.defaultChainId) - - if (this.cachableJsonRpcMethods.includes(request.method)) { - this.setCacheValue(key, response.result) - } else { - this.setCacheByBlockValue(key, response.result) - } - } + const result = await next(request) + + // Store result in cache and continue + if (this.cachableJsonRpcMethods.includes(request.method) || this.cachableJsonRpcMethodsByBlock.includes(request.method)) { + if (result && this.shouldCacheResponse(request, result)) { + // cache the value + const key = this.cacheKey(request.method, request.params! as any[], request.chainId || this.defaultChainId) + + if (this.cachableJsonRpcMethods.includes(request.method)) { + this.setCacheValue(key, result) + } else { + this.setCacheByBlockValue(key, result) } + } + } - // Exec next handler - callback(error, response) - }, - chainId || this.defaultChainId - ) + return result } } @@ -149,14 +139,14 @@ export class CachedProvider implements JsonRpcMiddlewareHandler { } } - shouldCacheResponse = (request: JsonRpcRequest, response?: JsonRpcResponse): boolean => { + shouldCacheResponse = (request: JsonRpcRequest, result?: any): boolean => { // skip if we do not have response result - if (!response || !response.result) { + if (!result) { return false } // skip caching eth_getCode where resposne value is '0x' or empty - if (request.method === 'eth_getCode' && response.result.length <= 2) { + if (request.method === 'eth_getCode' && result.length <= 2) { return false } diff --git a/packages/network/src/json-rpc/middleware/eager-provider.ts b/packages/network/src/json-rpc/middleware/eager-provider.ts index df85adc44..22793e9ec 100644 --- a/packages/network/src/json-rpc/middleware/eager-provider.ts +++ b/packages/network/src/json-rpc/middleware/eager-provider.ts @@ -1,6 +1,6 @@ import { commons } from '@0xsequence/core' import { ethers } from 'ethers' -import { JsonRpcHandlerFunc, JsonRpcRequest, JsonRpcResponseCallback, JsonRpcResponse, JsonRpcMiddlewareHandler } from '../types' +import { EIP1193ProviderFunc, JsonRpcMiddlewareHandler, JsonRpcRequest } from '../types' // EagerProvider will eagerly respond to a provider request from pre-initialized data values. // @@ -20,43 +20,37 @@ export class EagerProvider implements JsonRpcMiddlewareHandler { this.options = options } - sendAsyncMiddleware = (next: JsonRpcHandlerFunc) => { - return (request: JsonRpcRequest, callback: JsonRpcResponseCallback, chainId?: number) => { - const { id, method } = request - - switch (method) { + requestHandler = (next: EIP1193ProviderFunc) => { + return async (request: JsonRpcRequest): Promise => { + switch (request.method) { case 'net_version': if (this.options.chainId) { - callback(undefined, { jsonrpc: '2.0', id: id!, result: `${this.options.chainId}` }) - return + return `${this.options.chainId}` } break case 'eth_chainId': if (this.options.chainId) { - callback(undefined, { jsonrpc: '2.0', id: id!, result: ethers.utils.hexlify(this.options.chainId) }) - return + return ethers.toQuantity(this.options.chainId) } break case 'eth_accounts': if (this.options.accountAddress) { - callback(undefined, { jsonrpc: '2.0', id: id!, result: [ethers.utils.getAddress(this.options.accountAddress)] }) - return + return [ethers.getAddress(this.options.accountAddress)] } break case 'sequence_getWalletContext': if (this.options.walletContext) { - callback(undefined, { jsonrpc: '2.0', id: id!, result: this.options.walletContext }) - return + return this.options.walletContext } break default: } - next(request, callback, chainId) + return next(request) } } } diff --git a/packages/network/src/json-rpc/middleware/exception-provider.ts b/packages/network/src/json-rpc/middleware/exception-provider.ts index 570051a07..e33674392 100644 --- a/packages/network/src/json-rpc/middleware/exception-provider.ts +++ b/packages/network/src/json-rpc/middleware/exception-provider.ts @@ -1,21 +1,15 @@ -import { JsonRpcHandlerFunc, JsonRpcRequest, JsonRpcResponse, JsonRpcResponseCallback, JsonRpcMiddleware } from '../types' +import { EIP1193ProviderFunc, JsonRpcMiddleware } from '../types' -export const exceptionProviderMiddleware: JsonRpcMiddleware = (next: JsonRpcHandlerFunc) => { - return (request: JsonRpcRequest, callback: JsonRpcResponseCallback, chainId?: number) => { - next( - request, - (error: any, response?: JsonRpcResponse) => { - if (!error && response && response.error) { - if (typeof response.error === 'string') { - throw new Error(response.error) - } else { - throw new Error(response.error.message) - } - } - - callback(error, response) - }, - chainId - ) +export const exceptionProviderMiddleware: JsonRpcMiddleware = (next: EIP1193ProviderFunc) => { + return async (request: { method: string; params?: any[]; chainId?: number }): Promise => { + try { + return await next(request) + } catch (error) { + if (typeof error === 'string') { + throw new Error(error) + } else { + throw new Error(error.message) + } + } } } diff --git a/packages/network/src/json-rpc/middleware/logging-provider.ts b/packages/network/src/json-rpc/middleware/logging-provider.ts index a64e78763..d933681bf 100644 --- a/packages/network/src/json-rpc/middleware/logging-provider.ts +++ b/packages/network/src/json-rpc/middleware/logging-provider.ts @@ -1,33 +1,30 @@ -import { JsonRpcHandlerFunc, JsonRpcRequest, JsonRpcResponse, JsonRpcResponseCallback, JsonRpcMiddleware } from '../types' +import { EIP1193ProviderFunc, JsonRpcMiddleware, JsonRpcRequest } from '../types' import { logger } from '@0xsequence/utils' // TODO: rename to loggerMiddleware -export const loggingProviderMiddleware: JsonRpcMiddleware = (next: JsonRpcHandlerFunc) => { - return (request: JsonRpcRequest, callback: JsonRpcResponseCallback, chainId?: number) => { - const chainIdLabel = chainId ? ` chainId:${chainId}` : '' +export const loggingProviderMiddleware: JsonRpcMiddleware = (next: EIP1193ProviderFunc) => { + return async (request: JsonRpcRequest): Promise => { + const chainIdLabel = request.chainId ? ` chainId:${request.chainId}` : '' logger.info(`[provider request]${chainIdLabel} id:${request.id} method:${request.method} params:`, request.params) - next( - request, - (error: any, response?: JsonRpcResponse) => { - if (error) { - logger.warn( - `[provider response]${chainIdLabel} id:${request.id} method:${request.method} params:`, - request.params, - `error:`, - error - ) - } else { - logger.info( - `[provider response]${chainIdLabel} id:${request.id} method:${request.method} params:`, - request.params, - `response:`, - response - ) - } - callback(error, response) - }, - chainId - ) + try { + const result = await next(request) + + logger.info( + `[provider response]${chainIdLabel} id:${request.id} method:${request.method} params:`, + request.params, + `result:`, + result + ) + + return result + } catch (error) { + logger.warn( + `[provider response]${chainIdLabel} id:${request.id} method:${request.method} params:`, + request.params, + `error:`, + error + ) + } } } diff --git a/packages/network/src/json-rpc/middleware/network-provider.ts b/packages/network/src/json-rpc/middleware/network-provider.ts index 75bba1007..b4404c11c 100644 --- a/packages/network/src/json-rpc/middleware/network-provider.ts +++ b/packages/network/src/json-rpc/middleware/network-provider.ts @@ -1,33 +1,23 @@ import { ethers } from 'ethers' -import { - JsonRpcHandlerFunc, - JsonRpcRequest, - JsonRpcResponseCallback, - JsonRpcMiddleware, - JsonRpcMiddlewareHandler -} from '../types' +import { EIP1193ProviderFunc, JsonRpcRequest, JsonRpcMiddleware } from '../types' export const networkProviderMiddleware = (getChainId: (request: JsonRpcRequest) => number): JsonRpcMiddleware => - (next: JsonRpcHandlerFunc) => { - return (request: JsonRpcRequest, callback: JsonRpcResponseCallback, chainId?: number) => { + (next: EIP1193ProviderFunc) => { + return async (request: JsonRpcRequest): Promise => { const networkChainId = getChainId(request) - const { id, method } = request + switch (request.method) { + case 'net_version': { + return `${networkChainId}` + } - switch (method) { - case 'net_version': - callback(undefined, { jsonrpc: '2.0', id: id!, result: `${networkChainId}` }) - return - - case 'eth_chainId': - callback(undefined, { jsonrpc: '2.0', id: id!, result: ethers.utils.hexlify(networkChainId) }) - return - - default: + case 'eth_chainId': { + return ethers.toQuantity(networkChainId) + } } // request is allowed. keep going.. - next(request, callback, chainId) + return next(request) } } diff --git a/packages/network/src/json-rpc/middleware/public-provider.ts b/packages/network/src/json-rpc/middleware/public-provider.ts index 7b0b1042e..e8a9bd77e 100644 --- a/packages/network/src/json-rpc/middleware/public-provider.ts +++ b/packages/network/src/json-rpc/middleware/public-provider.ts @@ -1,12 +1,12 @@ -import { providers } from 'ethers' -import { JsonRpcHandlerFunc, JsonRpcRequest, JsonRpcResponseCallback, JsonRpcMiddlewareHandler } from '../types' +import { ethers } from 'ethers' +import { EIP1193ProviderFunc, JsonRpcMiddlewareHandler, JsonRpcRequest } from '../types' import { SignerJsonRpcMethods } from './signing-provider' import { logger } from '@0xsequence/utils' export class PublicProvider implements JsonRpcMiddlewareHandler { private privateJsonRpcMethods = ['net_version', 'eth_chainId', 'eth_accounts', ...SignerJsonRpcMethods] - private provider?: providers.JsonRpcProvider + private provider?: ethers.JsonRpcProvider private rpcUrl?: string constructor(rpcUrl?: string) { @@ -15,26 +15,16 @@ export class PublicProvider implements JsonRpcMiddlewareHandler { } } - sendAsyncMiddleware = (next: JsonRpcHandlerFunc) => { - return (request: JsonRpcRequest, callback: JsonRpcResponseCallback) => { + requestHandler = (next: EIP1193ProviderFunc) => { + return (request: JsonRpcRequest): Promise => { // When provider is configured, send non-private methods to our local public provider if (this.provider && !this.privateJsonRpcMethods.includes(request.method)) { - this.provider - .send(request.method, request.params!) - .then(r => { - callback(undefined, { - jsonrpc: '2.0', - id: request.id!, - result: r - }) - }) - .catch(e => callback(e)) - return + return this.provider.send(request.method, request.params || []) } // Continue to next handler logger.debug('[public-provider] sending request to signer window', request.method) - next(request, callback) + return next(request) } } @@ -50,7 +40,7 @@ export class PublicProvider implements JsonRpcMiddlewareHandler { this.rpcUrl = rpcUrl // TODO: maybe use @0xsequence/network JsonRpcProvider here instead, // which supports better caching. - this.provider = new providers.JsonRpcProvider(rpcUrl) + this.provider = new ethers.JsonRpcProvider(rpcUrl) } } } diff --git a/packages/network/src/json-rpc/middleware/signing-provider.ts b/packages/network/src/json-rpc/middleware/signing-provider.ts index fab1bcccf..47947725b 100644 --- a/packages/network/src/json-rpc/middleware/signing-provider.ts +++ b/packages/network/src/json-rpc/middleware/signing-provider.ts @@ -1,4 +1,4 @@ -import { JsonRpcHandlerFunc, JsonRpcRequest, JsonRpcResponseCallback, JsonRpcMiddlewareHandler, JsonRpcHandler } from '../types' +import { EIP1193Provider, EIP1193ProviderFunc, JsonRpcMiddlewareHandler, JsonRpcRequest } from '../types' export const SignerJsonRpcMethods = [ 'personal_sign', @@ -30,22 +30,21 @@ export const SignerJsonRpcMethods = [ ] export class SigningProvider implements JsonRpcMiddlewareHandler { - private provider: JsonRpcHandler + private provider: EIP1193Provider - constructor(provider: JsonRpcHandler) { + constructor(provider: EIP1193Provider) { this.provider = provider } - sendAsyncMiddleware = (next: JsonRpcHandlerFunc) => { - return (request: JsonRpcRequest, callback: JsonRpcResponseCallback, chainId?: number) => { + requestHandler = (next: EIP1193ProviderFunc) => { + return (request: JsonRpcRequest): Promise => { // Forward signing requests to the signing provider if (SignerJsonRpcMethods.includes(request.method)) { - this.provider.sendAsync(request, callback, chainId) - return + return this.provider.request(request) } // Continue to next handler - next(request, callback, chainId) + return next(request) } } } diff --git a/packages/network/src/json-rpc/middleware/singleflight.ts b/packages/network/src/json-rpc/middleware/singleflight.ts index 324a478fa..10fb44c93 100644 --- a/packages/network/src/json-rpc/middleware/singleflight.ts +++ b/packages/network/src/json-rpc/middleware/singleflight.ts @@ -1,4 +1,4 @@ -import { JsonRpcHandlerFunc, JsonRpcRequest, JsonRpcResponse, JsonRpcResponseCallback, JsonRpcMiddlewareHandler } from '../types' +import { EIP1193ProviderFunc, JsonRpcResponseCallback, JsonRpcMiddlewareHandler, JsonRpcRequest } from '../types' export class SingleflightMiddleware implements JsonRpcMiddlewareHandler { private singleflightJsonRpcMethods = [ @@ -31,52 +31,47 @@ export class SingleflightMiddleware implements JsonRpcMiddlewareHandler { this.inflight = {} } - sendAsyncMiddleware = (next: JsonRpcHandlerFunc) => { - return (request: JsonRpcRequest, callback: JsonRpcResponseCallback, chainId?: number) => { + requestHandler = (next: EIP1193ProviderFunc) => { + return async (request: JsonRpcRequest): Promise => { // continue to next handler if method isn't part of methods list if (!this.singleflightJsonRpcMethods.includes(request.method)) { - next(request, callback, chainId) - return + return next(request) } - const key = this.requestKey(request.method, request.params || [], chainId) + const key = this.requestKey(request.method, request.params || [], request.chainId) if (!this.inflight[key]) { // first request -- init the empty list this.inflight[key] = [] } else { // already in-flight, add the callback to the list and return - this.inflight[key].push({ id: request.id!, callback }) - return + return new Promise((resolve, reject) => { + this.inflight[key].push({ + id: request.id!, + callback: (error: any, response: any) => { + if (error) { + reject(error) + } else { + resolve(response) + } + } + }) + }) } // Continue down the handler chain - next( - request, - (error: any, response?: JsonRpcResponse, chainId?: number) => { - // callback the original request - callback(error, response) - - // callback all other requests of the same kind in queue, with the - // same response result as from the first response. - for (let i = 0; i < this.inflight[key].length; i++) { - const sub = this.inflight[key][i] - if (error) { - sub.callback(error, response) - } else if (response) { - sub.callback(undefined, { - jsonrpc: '2.0', - id: sub.id, - result: response!.result - }) - } - } - - // clear request key - delete this.inflight[key] - }, - chainId - ) + try { + // Exec the handler, and on success resolve all other promises + const response = await next(request) + this.inflight[key].forEach(({ callback }) => callback(undefined, response)) + return response + } catch (error) { + // If the request fails, reject all queued promises. + this.inflight[key].forEach(({ callback }) => callback(error, undefined)) + throw error + } finally { + delete this.inflight[key] + } } } diff --git a/packages/network/src/json-rpc/router.ts b/packages/network/src/json-rpc/router.ts index 26e8a1fa8..bcd26d08c 100644 --- a/packages/network/src/json-rpc/router.ts +++ b/packages/network/src/json-rpc/router.ts @@ -1,17 +1,10 @@ -import { - JsonRpcHandlerFunc, - JsonRpcRequest, - JsonRpcResponseCallback, - JsonRpcHandler, - JsonRpcMiddleware, - JsonRpcMiddlewareHandler -} from './types' +import { EIP1193Provider, EIP1193ProviderFunc, JsonRpcMiddleware, JsonRpcMiddlewareHandler } from './types' -export class JsonRpcRouter implements JsonRpcHandler { - private sender: JsonRpcHandler - private handler: JsonRpcHandlerFunc +export class JsonRpcRouter implements EIP1193Provider { + private sender: EIP1193Provider + private handler: EIP1193Provider - constructor(middlewares: Array, sender: JsonRpcHandler) { + constructor(middlewares: Array, sender: EIP1193Provider) { this.sender = sender if (middlewares) { this.setMiddleware(middlewares) @@ -19,36 +12,32 @@ export class JsonRpcRouter implements JsonRpcHandler { } setMiddleware(middlewares: Array) { - this.handler = createJsonRpcMiddlewareStack(middlewares, this.sender.sendAsync) + this.handler = createJsonRpcMiddlewareStack(middlewares, this.sender) } - sendAsync(request: JsonRpcRequest, callback: JsonRpcResponseCallback, chainId?: number) { - try { - this.handler(request, callback, chainId) - } catch (err) { - callback(err, undefined) - } + request(request: { id?: number; method: string; params?: any[]; chainId?: number }): Promise { + return this.handler.request(request) } } export const createJsonRpcMiddlewareStack = ( middlewares: Array, - handler: JsonRpcHandlerFunc -): JsonRpcHandlerFunc => { + handler: EIP1193Provider +): EIP1193Provider => { if (middlewares.length === 0) return handler const toMiddleware = (v: any): JsonRpcMiddleware => { - if (v.sendAsyncMiddleware) { - return (v as JsonRpcMiddlewareHandler).sendAsyncMiddleware + if (v.requestHandler) { + return (v as JsonRpcMiddlewareHandler).requestHandler } else { return v } } - let chain: JsonRpcHandlerFunc - chain = toMiddleware(middlewares[middlewares.length - 1])(handler) + let chain: EIP1193ProviderFunc + chain = toMiddleware(middlewares[middlewares.length - 1])(handler.request) for (let i = middlewares.length - 2; i >= 0; i--) { chain = toMiddleware(middlewares[i])(chain) } - return chain + return { request: chain } } diff --git a/packages/network/src/json-rpc/sender.ts b/packages/network/src/json-rpc/sender.ts deleted file mode 100644 index 28ad94a05..000000000 --- a/packages/network/src/json-rpc/sender.ts +++ /dev/null @@ -1,99 +0,0 @@ -import { providers } from 'ethers' -import { - JsonRpcRequest, - JsonRpcResponse, - JsonRpcResponseCallback, - JsonRpcHandler, - JsonRpcFetchFunc, - JsonRpcRequestFunc, - JsonRpcVersion -} from './types' -import { isJsonRpcProvider, isJsonRpcHandler } from './utils' - -type ExternalProvider = providers.ExternalProvider - -let _nextId = 0 - -export class JsonRpcSender implements JsonRpcHandler { - readonly send: JsonRpcFetchFunc - readonly request: JsonRpcRequestFunc - readonly defaultChainId?: number - - constructor(provider: providers.JsonRpcProvider | JsonRpcHandler | JsonRpcFetchFunc, defaultChainId?: number) { - this.defaultChainId = defaultChainId - - if (isJsonRpcProvider(provider)) { - // we can ignore defaultChainId for JsonRpcProviders as they are already chain-bound - this.send = provider.send.bind(provider) - } else if (isJsonRpcHandler(provider)) { - this.send = (method: string, params?: Array, chainId?: number): Promise => { - return new Promise((resolve, reject) => { - provider.sendAsync( - { - // TODO: really shouldn't have to set these here? - jsonrpc: JsonRpcVersion, - id: ++_nextId, - method, - params - }, - (error: any, response?: JsonRpcResponse) => { - if (error) { - reject(error) - } else if (response) { - resolve(response.result) - } else { - resolve(undefined) - } - }, - chainId || this.defaultChainId - ) - }) - } - } else { - this.send = provider - } - - this.request = (request: { method: string; params?: any[] }, chainId?: number): Promise => { - return this.send(request.method, request.params, chainId) - } - } - - sendAsync = ( - request: JsonRpcRequest, - callback: JsonRpcResponseCallback | ((error: any, response: any) => void), - chainId?: number - ) => { - this.send(request.method, request.params, chainId || this.defaultChainId) - .then(r => { - callback(undefined, { - jsonrpc: '2.0', - id: request.id, - result: r - }) - }) - .catch(e => { - callback(e, undefined) - }) - } -} - -export class JsonRpcExternalProvider implements ExternalProvider, JsonRpcHandler { - constructor(private provider: providers.JsonRpcProvider) {} - - sendAsync = (request: JsonRpcRequest, callback: JsonRpcResponseCallback | ((error: any, response: any) => void)) => { - this.provider - .send(request.method, request.params!) - .then(r => { - callback(undefined, { - jsonrpc: '2.0', - id: request.id, - result: r - }) - }) - .catch(e => { - callback(e, undefined) - }) - } - - send = this.sendAsync -} diff --git a/packages/network/src/json-rpc/types.ts b/packages/network/src/json-rpc/types.ts index cfe45f8fb..f135202a1 100644 --- a/packages/network/src/json-rpc/types.ts +++ b/packages/network/src/json-rpc/types.ts @@ -1,39 +1,45 @@ -export const JsonRpcVersion = '2.0' - -export interface JsonRpcRequest { - jsonrpc?: string +export type JsonRpcRequest = { + jsonrpc?: '2.0' id?: number method: string params?: any[] + + // ... + chainId?: number } -export interface JsonRpcResponse { - jsonrpc: string +export type JsonRpcResponse = { + jsonrpc?: string id: number result: any - error?: ProviderRpcError + error?: JsonRpcErrorPayload +} + +export type JsonRpcErrorPayload = { + code: number + message?: string + data?: any } -export type JsonRpcResponseCallback = (error?: ProviderRpcError, response?: JsonRpcResponse) => void +// EIP1193Provider with reponse of R (default any), but in most cases R will be of type JsonRpcResponse. +export interface EIP1193Provider { + request(request: { method: string; params?: any[]; chainId?: number }): Promise +} -export type JsonRpcHandlerFunc = (request: JsonRpcRequest, callback: JsonRpcResponseCallback, chainId?: number) => void +export type EIP1193ProviderFunc = (request: { method: string; params?: any[]; chainId?: number }) => Promise -export interface JsonRpcHandler { - sendAsync: JsonRpcHandlerFunc +export interface JsonRpcSender { + send(method: string, params?: any[], chainId?: number): Promise } -export type JsonRpcFetchFunc = (method: string, params?: any[], chainId?: number) => Promise +export type JsonRpcSendFunc = (method: string, params?: any[], chainId?: number) => Promise -// EIP-1193 function signature -export type JsonRpcRequestFunc = (request: { method: string; params?: any[] }, chainId?: number) => Promise +export type JsonRpcResponseCallback = (error: JsonRpcErrorPayload | undefined, response?: JsonRpcResponse) => void -export type JsonRpcMiddleware = (next: JsonRpcHandlerFunc) => JsonRpcHandlerFunc +export type JsonRpcSendAsyncFunc = (request: JsonRpcRequest, callback: JsonRpcResponseCallback, chainId?: number) => void -export interface JsonRpcMiddlewareHandler { - sendAsyncMiddleware: JsonRpcMiddleware -} +export type JsonRpcMiddleware = (next: EIP1193ProviderFunc) => EIP1193ProviderFunc -export interface ProviderRpcError extends Error { - code?: number - data?: { [key: string]: any } +export interface JsonRpcMiddlewareHandler { + requestHandler: JsonRpcMiddleware } diff --git a/packages/network/src/json-rpc/utils.ts b/packages/network/src/json-rpc/utils.ts index 7d03f965f..db7281c77 100644 --- a/packages/network/src/json-rpc/utils.ts +++ b/packages/network/src/json-rpc/utils.ts @@ -1,7 +1,8 @@ -import { providers } from 'ethers' -import { JsonRpcHandler } from './types' +import { ethers } from 'ethers' +import { JsonRpcSender } from './types' -export function isJsonRpcProvider(cand: any): cand is providers.JsonRpcProvider { +// TODOXXX: review.. +export function isJsonRpcProvider(cand: any): cand is ethers.JsonRpcProvider { return ( cand !== undefined && cand.send !== undefined && @@ -12,6 +13,6 @@ export function isJsonRpcProvider(cand: any): cand is providers.JsonRpcProvider ) } -export function isJsonRpcHandler(cand: any): cand is JsonRpcHandler { - return cand !== undefined && cand.sendAsync !== undefined +export function isJsonRpcSender(cand: any): cand is JsonRpcSender { + return cand !== undefined && cand.send !== undefined } diff --git a/packages/network/src/utils.ts b/packages/network/src/utils.ts index 648eb9a69..7cf445737 100644 --- a/packages/network/src/utils.ts +++ b/packages/network/src/utils.ts @@ -1,4 +1,4 @@ -import { ethers, BigNumberish } from 'ethers' +import { ethers } from 'ethers' import { ChainIdLike } from '.' import { NetworkConfig } from './config' @@ -13,7 +13,7 @@ export const getChainId = (chainId: ChainIdLike): number => { if ((chainId).chainId) { return (chainId).chainId } - return ethers.BigNumber.from(chainId as BigNumberish).toNumber() + return Number(chainId as ethers.BigNumberish) } export const maybeChainId = (chainId?: ChainIdLike): number | undefined => { @@ -138,7 +138,7 @@ export const validateAndSortNetworks = (networks: NetworkConfig[]) => { export const findNetworkConfig = (networks: NetworkConfig[], chainId: ChainIdLike): NetworkConfig | undefined => { if (typeof chainId === 'string') { if (chainId.startsWith('0x')) { - const id = ethers.BigNumber.from(chainId).toNumber() + const id = Number(chainId) return networks.find(n => n.chainId === id) } else { return networks.find(n => n.name === chainId || `${n.chainId}` === chainId) @@ -147,8 +147,8 @@ export const findNetworkConfig = (networks: NetworkConfig[], chainId: ChainIdLik return networks.find(n => n.chainId === chainId) } else if ((chainId).chainId) { return networks.find(n => n.chainId === (chainId).chainId) - } else if (ethers.BigNumber.isBigNumber(chainId)) { - const id = chainId.toNumber() + } else if (typeof chainId === 'bigint') { + const id = Number(chainId) return networks.find(n => n.chainId === id) } else { return undefined diff --git a/packages/provider/CHANGELOG.md b/packages/provider/CHANGELOG.md index 96bf50684..a90a72394 100644 --- a/packages/provider/CHANGELOG.md +++ b/packages/provider/CHANGELOG.md @@ -1,5 +1,868 @@ # @0xsequence/provider +## 2.2.14 + +### Patch Changes + +- Somnia Testnet and Monad Testnet +- Updated dependencies + - @0xsequence/abi@2.2.14 + - @0xsequence/account@2.2.14 + - @0xsequence/auth@2.2.14 + - @0xsequence/core@2.2.14 + - @0xsequence/migration@2.2.14 + - @0xsequence/network@2.2.14 + - @0xsequence/relayer@2.2.14 + - @0xsequence/utils@2.2.14 + - @0xsequence/wallet@2.2.14 + +## 2.2.13 + +### Patch Changes + +- Add XR1 to all networks +- Updated dependencies + - @0xsequence/abi@2.2.13 + - @0xsequence/account@2.2.13 + - @0xsequence/auth@2.2.13 + - @0xsequence/core@2.2.13 + - @0xsequence/migration@2.2.13 + - @0xsequence/network@2.2.13 + - @0xsequence/relayer@2.2.13 + - @0xsequence/utils@2.2.13 + - @0xsequence/wallet@2.2.13 + +## 2.2.12 + +### Patch Changes + +- Add XR1 +- Updated dependencies + - @0xsequence/abi@2.2.12 + - @0xsequence/account@2.2.12 + - @0xsequence/auth@2.2.12 + - @0xsequence/core@2.2.12 + - @0xsequence/migration@2.2.12 + - @0xsequence/network@2.2.12 + - @0xsequence/relayer@2.2.12 + - @0xsequence/utils@2.2.12 + - @0xsequence/wallet@2.2.12 + +## 2.2.11 + +### Patch Changes + +- Relayer updates +- Updated dependencies + - @0xsequence/abi@2.2.11 + - @0xsequence/account@2.2.11 + - @0xsequence/auth@2.2.11 + - @0xsequence/core@2.2.11 + - @0xsequence/migration@2.2.11 + - @0xsequence/network@2.2.11 + - @0xsequence/relayer@2.2.11 + - @0xsequence/utils@2.2.11 + - @0xsequence/wallet@2.2.11 + +## 2.2.10 + +### Patch Changes + +- Etherlink support +- Updated dependencies + - @0xsequence/abi@2.2.10 + - @0xsequence/account@2.2.10 + - @0xsequence/auth@2.2.10 + - @0xsequence/core@2.2.10 + - @0xsequence/migration@2.2.10 + - @0xsequence/network@2.2.10 + - @0xsequence/relayer@2.2.10 + - @0xsequence/utils@2.2.10 + - @0xsequence/wallet@2.2.10 + +## 2.2.9 + +### Patch Changes + +- Indexer gateway native token balances +- Updated dependencies + - @0xsequence/abi@2.2.9 + - @0xsequence/account@2.2.9 + - @0xsequence/auth@2.2.9 + - @0xsequence/core@2.2.9 + - @0xsequence/migration@2.2.9 + - @0xsequence/network@2.2.9 + - @0xsequence/relayer@2.2.9 + - @0xsequence/utils@2.2.9 + - @0xsequence/wallet@2.2.9 + +## 2.2.8 + +### Patch Changes + +- Add Moonbeam and Moonbase Alpha +- Updated dependencies + - @0xsequence/abi@2.2.8 + - @0xsequence/account@2.2.8 + - @0xsequence/auth@2.2.8 + - @0xsequence/core@2.2.8 + - @0xsequence/migration@2.2.8 + - @0xsequence/network@2.2.8 + - @0xsequence/relayer@2.2.8 + - @0xsequence/utils@2.2.8 + - @0xsequence/wallet@2.2.8 + +## 2.2.7 + +### Patch Changes + +- Update Builder package +- Updated dependencies + - @0xsequence/abi@2.2.7 + - @0xsequence/account@2.2.7 + - @0xsequence/auth@2.2.7 + - @0xsequence/core@2.2.7 + - @0xsequence/migration@2.2.7 + - @0xsequence/network@2.2.7 + - @0xsequence/relayer@2.2.7 + - @0xsequence/utils@2.2.7 + - @0xsequence/wallet@2.2.7 + +## 2.2.6 + +### Patch Changes + +- Update relayer package +- Updated dependencies + - @0xsequence/abi@2.2.6 + - @0xsequence/account@2.2.6 + - @0xsequence/auth@2.2.6 + - @0xsequence/core@2.2.6 + - @0xsequence/migration@2.2.6 + - @0xsequence/network@2.2.6 + - @0xsequence/relayer@2.2.6 + - @0xsequence/utils@2.2.6 + - @0xsequence/wallet@2.2.6 + +## 2.2.5 + +### Patch Changes + +- auth: fix sequence indexer gateway url +- account: immutable wallet proxy hook +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.2.5 + - @0xsequence/account@2.2.5 + - @0xsequence/auth@2.2.5 + - @0xsequence/core@2.2.5 + - @0xsequence/migration@2.2.5 + - @0xsequence/network@2.2.5 + - @0xsequence/relayer@2.2.5 + - @0xsequence/utils@2.2.5 + - @0xsequence/wallet@2.2.5 + +## 2.2.4 + +### Patch Changes + +- network: update soneium mainnet block explorer url +- waas: signTypedData intent support +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.2.4 + - @0xsequence/account@2.2.4 + - @0xsequence/auth@2.2.4 + - @0xsequence/core@2.2.4 + - @0xsequence/migration@2.2.4 + - @0xsequence/network@2.2.4 + - @0xsequence/relayer@2.2.4 + - @0xsequence/utils@2.2.4 + - @0xsequence/wallet@2.2.4 + +## 2.2.3 + +### Patch Changes + +- provider: updating initWallet to use connected network configs if they exist +- Updated dependencies + - @0xsequence/abi@2.2.3 + - @0xsequence/account@2.2.3 + - @0xsequence/auth@2.2.3 + - @0xsequence/core@2.2.3 + - @0xsequence/migration@2.2.3 + - @0xsequence/network@2.2.3 + - @0xsequence/relayer@2.2.3 + - @0xsequence/utils@2.2.3 + - @0xsequence/wallet@2.2.3 + +## 2.2.2 + +### Patch Changes + +- pass projectAccessKey to relayer at all times +- Updated dependencies + - @0xsequence/abi@2.2.2 + - @0xsequence/account@2.2.2 + - @0xsequence/auth@2.2.2 + - @0xsequence/core@2.2.2 + - @0xsequence/migration@2.2.2 + - @0xsequence/network@2.2.2 + - @0xsequence/relayer@2.2.2 + - @0xsequence/utils@2.2.2 + - @0xsequence/wallet@2.2.2 + +## 2.2.1 + +### Patch Changes + +- waas-ethers: sign typed data +- Updated dependencies + - @0xsequence/abi@2.2.1 + - @0xsequence/account@2.2.1 + - @0xsequence/auth@2.2.1 + - @0xsequence/core@2.2.1 + - @0xsequence/migration@2.2.1 + - @0xsequence/network@2.2.1 + - @0xsequence/relayer@2.2.1 + - @0xsequence/utils@2.2.1 + - @0xsequence/wallet@2.2.1 + +## 2.2.0 + +### Minor Changes + +- indexer: gateway client +- @0xsequence/builder +- upgrade puppeteer to v23.10.3 + +### Patch Changes + +- Updated dependencies +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.2.0 + - @0xsequence/account@2.2.0 + - @0xsequence/auth@2.2.0 + - @0xsequence/core@2.2.0 + - @0xsequence/migration@2.2.0 + - @0xsequence/network@2.2.0 + - @0xsequence/relayer@2.2.0 + - @0xsequence/utils@2.2.0 + - @0xsequence/wallet@2.2.0 + +## 2.1.8 + +### Patch Changes + +- Add Soneium Mainnet +- Updated dependencies + - @0xsequence/abi@2.1.8 + - @0xsequence/account@2.1.8 + - @0xsequence/auth@2.1.8 + - @0xsequence/core@2.1.8 + - @0xsequence/migration@2.1.8 + - @0xsequence/network@2.1.8 + - @0xsequence/relayer@2.1.8 + - @0xsequence/utils@2.1.8 + - @0xsequence/wallet@2.1.8 + +## 2.1.7 + +### Patch Changes + +- guard: pass project access key to guard requests +- Updated dependencies + - @0xsequence/abi@2.1.7 + - @0xsequence/account@2.1.7 + - @0xsequence/auth@2.1.7 + - @0xsequence/core@2.1.7 + - @0xsequence/migration@2.1.7 + - @0xsequence/network@2.1.7 + - @0xsequence/relayer@2.1.7 + - @0xsequence/utils@2.1.7 + - @0xsequence/wallet@2.1.7 + +## 2.1.6 + +### Patch Changes + +- Add LAOS and Telos Testnet chains +- Updated dependencies + - @0xsequence/abi@2.1.6 + - @0xsequence/account@2.1.6 + - @0xsequence/auth@2.1.6 + - @0xsequence/core@2.1.6 + - @0xsequence/migration@2.1.6 + - @0xsequence/network@2.1.6 + - @0xsequence/relayer@2.1.6 + - @0xsequence/utils@2.1.6 + - @0xsequence/wallet@2.1.6 + +## 2.1.5 + +### Patch Changes + +- account: save presigned configuration with reference chain id 1 +- Updated dependencies + - @0xsequence/abi@2.1.5 + - @0xsequence/account@2.1.5 + - @0xsequence/auth@2.1.5 + - @0xsequence/core@2.1.5 + - @0xsequence/migration@2.1.5 + - @0xsequence/network@2.1.5 + - @0xsequence/relayer@2.1.5 + - @0xsequence/utils@2.1.5 + - @0xsequence/wallet@2.1.5 + +## 2.1.4 + +### Patch Changes + +- provider: pass projectAccessKey into MuxMessageProvider +- Updated dependencies + - @0xsequence/abi@2.1.4 + - @0xsequence/account@2.1.4 + - @0xsequence/auth@2.1.4 + - @0xsequence/core@2.1.4 + - @0xsequence/migration@2.1.4 + - @0xsequence/network@2.1.4 + - @0xsequence/relayer@2.1.4 + - @0xsequence/utils@2.1.4 + - @0xsequence/wallet@2.1.4 + +## 2.1.3 + +### Patch Changes + +- waas: time drift date fix due to strange browser quirk +- Updated dependencies + - @0xsequence/abi@2.1.3 + - @0xsequence/account@2.1.3 + - @0xsequence/auth@2.1.3 + - @0xsequence/core@2.1.3 + - @0xsequence/migration@2.1.3 + - @0xsequence/network@2.1.3 + - @0xsequence/relayer@2.1.3 + - @0xsequence/utils@2.1.3 + - @0xsequence/wallet@2.1.3 + +## 2.1.2 + +### Patch Changes + +- provider: export analytics correctly +- Updated dependencies + - @0xsequence/abi@2.1.2 + - @0xsequence/account@2.1.2 + - @0xsequence/auth@2.1.2 + - @0xsequence/core@2.1.2 + - @0xsequence/migration@2.1.2 + - @0xsequence/network@2.1.2 + - @0xsequence/relayer@2.1.2 + - @0xsequence/utils@2.1.2 + - @0xsequence/wallet@2.1.2 + +## 2.1.1 + +### Patch Changes + +- Add LAOS chain support +- Updated dependencies + - @0xsequence/abi@2.1.1 + - @0xsequence/account@2.1.1 + - @0xsequence/auth@2.1.1 + - @0xsequence/core@2.1.1 + - @0xsequence/migration@2.1.1 + - @0xsequence/network@2.1.1 + - @0xsequence/relayer@2.1.1 + - @0xsequence/utils@2.1.1 + - @0xsequence/wallet@2.1.1 + +## 2.1.0 + +### Minor Changes + +- account: forward project access key when estimating fees and sending transactions + +### Patch Changes + +- sessions: save signatures with reference chain id +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.1.0 + - @0xsequence/account@2.1.0 + - @0xsequence/auth@2.1.0 + - @0xsequence/core@2.1.0 + - @0xsequence/migration@2.1.0 + - @0xsequence/network@2.1.0 + - @0xsequence/relayer@2.1.0 + - @0xsequence/utils@2.1.0 + - @0xsequence/wallet@2.1.0 + +## 2.0.26 + +### Patch Changes + +- account: fix chain id comparison +- Updated dependencies + - @0xsequence/abi@2.0.26 + - @0xsequence/account@2.0.26 + - @0xsequence/auth@2.0.26 + - @0xsequence/core@2.0.26 + - @0xsequence/migration@2.0.26 + - @0xsequence/network@2.0.26 + - @0xsequence/relayer@2.0.26 + - @0xsequence/utils@2.0.26 + - @0xsequence/wallet@2.0.26 + +## 2.0.25 + +### Patch Changes + +- skale-nebula: deploy gas limit = 10m +- Updated dependencies + - @0xsequence/abi@2.0.25 + - @0xsequence/account@2.0.25 + - @0xsequence/auth@2.0.25 + - @0xsequence/core@2.0.25 + - @0xsequence/migration@2.0.25 + - @0xsequence/network@2.0.25 + - @0xsequence/relayer@2.0.25 + - @0xsequence/utils@2.0.25 + - @0xsequence/wallet@2.0.25 + +## 2.0.24 + +### Patch Changes + +- sessions: arweave: configurable gateway url +- waas: use /status to get time drift before sending any intents +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.24 + - @0xsequence/account@2.0.24 + - @0xsequence/auth@2.0.24 + - @0xsequence/core@2.0.24 + - @0xsequence/migration@2.0.24 + - @0xsequence/network@2.0.24 + - @0xsequence/relayer@2.0.24 + - @0xsequence/utils@2.0.24 + - @0xsequence/wallet@2.0.24 + +## 2.0.23 + +### Patch Changes + +- Add The Root Network support +- Updated dependencies + - @0xsequence/abi@2.0.23 + - @0xsequence/account@2.0.23 + - @0xsequence/auth@2.0.23 + - @0xsequence/core@2.0.23 + - @0xsequence/migration@2.0.23 + - @0xsequence/network@2.0.23 + - @0xsequence/relayer@2.0.23 + - @0xsequence/utils@2.0.23 + - @0xsequence/wallet@2.0.23 + +## 2.0.22 + +### Patch Changes + +- Add SKALE Nebula Mainnet support +- Updated dependencies + - @0xsequence/abi@2.0.22 + - @0xsequence/account@2.0.22 + - @0xsequence/auth@2.0.22 + - @0xsequence/core@2.0.22 + - @0xsequence/migration@2.0.22 + - @0xsequence/network@2.0.22 + - @0xsequence/relayer@2.0.22 + - @0xsequence/utils@2.0.22 + - @0xsequence/wallet@2.0.22 + +## 2.0.21 + +### Patch Changes + +- account: add publishWitnessFor +- Updated dependencies + - @0xsequence/abi@2.0.21 + - @0xsequence/account@2.0.21 + - @0xsequence/auth@2.0.21 + - @0xsequence/core@2.0.21 + - @0xsequence/migration@2.0.21 + - @0xsequence/network@2.0.21 + - @0xsequence/relayer@2.0.21 + - @0xsequence/utils@2.0.21 + - @0xsequence/wallet@2.0.21 + +## 2.0.20 + +### Patch Changes + +- upgrade deps, and improve waas session status handling +- Updated dependencies + - @0xsequence/abi@2.0.20 + - @0xsequence/account@2.0.20 + - @0xsequence/auth@2.0.20 + - @0xsequence/core@2.0.20 + - @0xsequence/migration@2.0.20 + - @0xsequence/network@2.0.20 + - @0xsequence/relayer@2.0.20 + - @0xsequence/utils@2.0.20 + - @0xsequence/wallet@2.0.20 + +## 2.0.19 + +### Patch Changes + +- Add Immutable zkEVM support +- Updated dependencies + - @0xsequence/abi@2.0.19 + - @0xsequence/account@2.0.19 + - @0xsequence/auth@2.0.19 + - @0xsequence/core@2.0.19 + - @0xsequence/migration@2.0.19 + - @0xsequence/network@2.0.19 + - @0xsequence/relayer@2.0.19 + - @0xsequence/utils@2.0.19 + - @0xsequence/wallet@2.0.19 + +## 2.0.18 + +### Patch Changes + +- waas: new contractCall transaction type +- sessions: add arweave owner +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.18 + - @0xsequence/account@2.0.18 + - @0xsequence/auth@2.0.18 + - @0xsequence/core@2.0.18 + - @0xsequence/migration@2.0.18 + - @0xsequence/network@2.0.18 + - @0xsequence/relayer@2.0.18 + - @0xsequence/utils@2.0.18 + - @0xsequence/wallet@2.0.18 + +## 2.0.17 + +### Patch Changes + +- update waas auth to clear session before signIn +- Updated dependencies + - @0xsequence/abi@2.0.17 + - @0xsequence/account@2.0.17 + - @0xsequence/auth@2.0.17 + - @0xsequence/core@2.0.17 + - @0xsequence/migration@2.0.17 + - @0xsequence/network@2.0.17 + - @0xsequence/relayer@2.0.17 + - @0xsequence/utils@2.0.17 + - @0xsequence/wallet@2.0.17 + +## 2.0.16 + +### Patch Changes + +- Removed Astar chains +- Updated dependencies + - @0xsequence/abi@2.0.16 + - @0xsequence/account@2.0.16 + - @0xsequence/auth@2.0.16 + - @0xsequence/core@2.0.16 + - @0xsequence/migration@2.0.16 + - @0xsequence/network@2.0.16 + - @0xsequence/relayer@2.0.16 + - @0xsequence/utils@2.0.16 + - @0xsequence/wallet@2.0.16 + +## 2.0.15 + +### Patch Changes + +- indexer: update bindings with token balance additions +- Updated dependencies + - @0xsequence/abi@2.0.15 + - @0xsequence/account@2.0.15 + - @0xsequence/auth@2.0.15 + - @0xsequence/core@2.0.15 + - @0xsequence/migration@2.0.15 + - @0xsequence/network@2.0.15 + - @0xsequence/relayer@2.0.15 + - @0xsequence/utils@2.0.15 + - @0xsequence/wallet@2.0.15 + +## 2.0.14 + +### Patch Changes + +- sessions: arweave config reader +- network: add b3 and apechain mainnet configs +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.14 + - @0xsequence/account@2.0.14 + - @0xsequence/auth@2.0.14 + - @0xsequence/core@2.0.14 + - @0xsequence/migration@2.0.14 + - @0xsequence/network@2.0.14 + - @0xsequence/relayer@2.0.14 + - @0xsequence/utils@2.0.14 + - @0xsequence/wallet@2.0.14 + +## 2.0.13 + +### Patch Changes + +- network: toy-testnet +- Updated dependencies + - @0xsequence/abi@2.0.13 + - @0xsequence/account@2.0.13 + - @0xsequence/auth@2.0.13 + - @0xsequence/core@2.0.13 + - @0xsequence/migration@2.0.13 + - @0xsequence/network@2.0.13 + - @0xsequence/relayer@2.0.13 + - @0xsequence/utils@2.0.13 + - @0xsequence/wallet@2.0.13 + +## 2.0.12 + +### Patch Changes + +- api: update bindings +- Updated dependencies + - @0xsequence/abi@2.0.12 + - @0xsequence/account@2.0.12 + - @0xsequence/auth@2.0.12 + - @0xsequence/core@2.0.12 + - @0xsequence/migration@2.0.12 + - @0xsequence/network@2.0.12 + - @0xsequence/relayer@2.0.12 + - @0xsequence/utils@2.0.12 + - @0xsequence/wallet@2.0.12 + +## 2.0.11 + +### Patch Changes + +- waas: intents test fix +- api: update bindings +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.11 + - @0xsequence/account@2.0.11 + - @0xsequence/auth@2.0.11 + - @0xsequence/core@2.0.11 + - @0xsequence/migration@2.0.11 + - @0xsequence/network@2.0.11 + - @0xsequence/relayer@2.0.11 + - @0xsequence/utils@2.0.11 + - @0xsequence/wallet@2.0.11 + +## 2.0.10 + +### Patch Changes + +- network: soneium minato testnet +- Updated dependencies + - @0xsequence/abi@2.0.10 + - @0xsequence/account@2.0.10 + - @0xsequence/auth@2.0.10 + - @0xsequence/core@2.0.10 + - @0xsequence/migration@2.0.10 + - @0xsequence/network@2.0.10 + - @0xsequence/relayer@2.0.10 + - @0xsequence/utils@2.0.10 + - @0xsequence/wallet@2.0.10 + +## 2.0.9 + +### Patch Changes + +- network: fix SKALE network name +- Updated dependencies + - @0xsequence/abi@2.0.9 + - @0xsequence/account@2.0.9 + - @0xsequence/auth@2.0.9 + - @0xsequence/core@2.0.9 + - @0xsequence/migration@2.0.9 + - @0xsequence/network@2.0.9 + - @0xsequence/relayer@2.0.9 + - @0xsequence/utils@2.0.9 + - @0xsequence/wallet@2.0.9 + +## 2.0.8 + +### Patch Changes + +- metadata: update bindings +- Updated dependencies + - @0xsequence/abi@2.0.8 + - @0xsequence/account@2.0.8 + - @0xsequence/auth@2.0.8 + - @0xsequence/core@2.0.8 + - @0xsequence/migration@2.0.8 + - @0xsequence/network@2.0.8 + - @0xsequence/relayer@2.0.8 + - @0xsequence/utils@2.0.8 + - @0xsequence/wallet@2.0.8 + +## 2.0.7 + +### Patch Changes + +- wallet request handler fix +- Updated dependencies + - @0xsequence/abi@2.0.7 + - @0xsequence/account@2.0.7 + - @0xsequence/auth@2.0.7 + - @0xsequence/core@2.0.7 + - @0xsequence/migration@2.0.7 + - @0xsequence/network@2.0.7 + - @0xsequence/relayer@2.0.7 + - @0xsequence/utils@2.0.7 + - @0xsequence/wallet@2.0.7 + +## 2.0.6 + +### Patch Changes + +- network: matic -> pol +- Updated dependencies + - @0xsequence/abi@2.0.6 + - @0xsequence/account@2.0.6 + - @0xsequence/auth@2.0.6 + - @0xsequence/core@2.0.6 + - @0xsequence/migration@2.0.6 + - @0xsequence/network@2.0.6 + - @0xsequence/relayer@2.0.6 + - @0xsequence/utils@2.0.6 + - @0xsequence/wallet@2.0.6 + +## 2.0.5 + +### Patch Changes + +- provider: update databeat to 0.9.2 +- Updated dependencies + - @0xsequence/abi@2.0.5 + - @0xsequence/account@2.0.5 + - @0xsequence/auth@2.0.5 + - @0xsequence/core@2.0.5 + - @0xsequence/migration@2.0.5 + - @0xsequence/network@2.0.5 + - @0xsequence/relayer@2.0.5 + - @0xsequence/utils@2.0.5 + - @0xsequence/wallet@2.0.5 + +## 2.0.4 + +### Patch Changes + +- network: add skale-nebula-testnet +- Updated dependencies + - @0xsequence/abi@2.0.4 + - @0xsequence/account@2.0.4 + - @0xsequence/auth@2.0.4 + - @0xsequence/core@2.0.4 + - @0xsequence/migration@2.0.4 + - @0xsequence/network@2.0.4 + - @0xsequence/relayer@2.0.4 + - @0xsequence/utils@2.0.4 + - @0xsequence/wallet@2.0.4 + +## 2.0.3 + +### Patch Changes + +- waas: check session status in SequenceWaaS.isSignedIn() +- Updated dependencies + - @0xsequence/abi@2.0.3 + - @0xsequence/account@2.0.3 + - @0xsequence/auth@2.0.3 + - @0xsequence/core@2.0.3 + - @0xsequence/migration@2.0.3 + - @0xsequence/network@2.0.3 + - @0xsequence/relayer@2.0.3 + - @0xsequence/utils@2.0.3 + - @0xsequence/wallet@2.0.3 + +## 2.0.2 + +### Patch Changes + +- sessions: property convert serialized bignumber hex value to bigint +- Updated dependencies + - @0xsequence/abi@2.0.2 + - @0xsequence/account@2.0.2 + - @0xsequence/auth@2.0.2 + - @0xsequence/core@2.0.2 + - @0xsequence/migration@2.0.2 + - @0xsequence/network@2.0.2 + - @0xsequence/relayer@2.0.2 + - @0xsequence/utils@2.0.2 + - @0xsequence/wallet@2.0.2 + +## 2.0.1 + +### Patch Changes + +- waas: http signature check for authenticator requests +- provider: unwrap legacy json rpc responses +- use json replacer and reviver for bigints +- Updated dependencies +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.1 + - @0xsequence/account@2.0.1 + - @0xsequence/auth@2.0.1 + - @0xsequence/core@2.0.1 + - @0xsequence/migration@2.0.1 + - @0xsequence/network@2.0.1 + - @0xsequence/relayer@2.0.1 + - @0xsequence/utils@2.0.1 + - @0xsequence/wallet@2.0.1 + +## 2.0.0 + +### Major Changes + +- ethers v6 + +### Patch Changes + +- Updated dependencies + - @0xsequence/abi@2.0.0 + - @0xsequence/account@2.0.0 + - @0xsequence/auth@2.0.0 + - @0xsequence/core@2.0.0 + - @0xsequence/migration@2.0.0 + - @0xsequence/network@2.0.0 + - @0xsequence/relayer@2.0.0 + - @0xsequence/utils@2.0.0 + - @0xsequence/wallet@2.0.0 + +## 1.10.15 + +### Patch Changes + +- utils: extractProjectIdFromAccessKey +- Updated dependencies + - @0xsequence/abi@1.10.15 + - @0xsequence/account@1.10.15 + - @0xsequence/auth@1.10.15 + - @0xsequence/core@1.10.15 + - @0xsequence/migration@1.10.15 + - @0xsequence/network@1.10.15 + - @0xsequence/relayer@1.10.15 + - @0xsequence/utils@1.10.15 + - @0xsequence/wallet@1.10.15 + ## 1.10.14 ### Patch Changes diff --git a/packages/provider/hardhat1.config.cts b/packages/provider/hardhat1.config.cts new file mode 100644 index 000000000..bfaf75531 --- /dev/null +++ b/packages/provider/hardhat1.config.cts @@ -0,0 +1,18 @@ +import { HardhatUserConfig } from 'hardhat/config' +import '@nomicfoundation/hardhat-toolbox' + +const config: HardhatUserConfig = { + solidity: '0.7.6', + + networks: { + hardhat: { + initialBaseFeePerGas: 1, + chainId: 31337, + accounts: { + mnemonic: 'ripple axis someone ridge uniform wrist prosper there frog rate olympic knee' + } + } + } +} + +export default config diff --git a/packages/provider/hardhat2.config.cts b/packages/provider/hardhat2.config.cts new file mode 100644 index 000000000..5064eac76 --- /dev/null +++ b/packages/provider/hardhat2.config.cts @@ -0,0 +1,18 @@ +import { HardhatUserConfig } from 'hardhat/config' +import '@nomicfoundation/hardhat-toolbox' + +const config: HardhatUserConfig = { + solidity: '0.7.6', + + networks: { + hardhat: { + initialBaseFeePerGas: 1, + chainId: 31338, + accounts: { + mnemonic: 'ripple axis someone ridge uniform wrist prosper there frog rate olympic knee' + } + } + } +} + +export default config diff --git a/packages/provider/package.json b/packages/provider/package.json index fe35f4aea..600e56f8f 100644 --- a/packages/provider/package.json +++ b/packages/provider/package.json @@ -1,6 +1,6 @@ { "name": "@0xsequence/provider", - "version": "1.10.14", + "version": "2.2.14", "description": "provider sub-package for Sequence", "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/provider", "source": "src/index.ts", @@ -19,6 +19,9 @@ "start:hardhat1:verbose": "hardhat node --config hardhat1.config.js --hostname 0.0.0.0 --port 9595", "start:hardhat2:verbose": "hardhat node --config hardhat2.config.js --hostname 0.0.0.0 --port 8595" }, + "peerDependencies": { + "ethers": ">=6" + }, "dependencies": { "@0xsequence/abi": "workspace:*", "@0xsequence/account": "workspace:*", @@ -29,17 +32,14 @@ "@0xsequence/relayer": "workspace:*", "@0xsequence/utils": "workspace:*", "@0xsequence/wallet": "workspace:*", - "@databeat/tracker": "^0.9.1", + "@databeat/tracker": "^0.9.3", "eventemitter2": "^6.4.5", "webextension-polyfill": "^0.10.0" }, - "peerDependencies": { - "ethers": ">=5.5 < 6" - }, "devDependencies": { "@types/webextension-polyfill": "^0.10.0", - "ethers": "^5.7.2", - "hardhat": "^2.20.1" + "ethers": "6.13.4", + "hardhat": "^2.22.14" }, "files": [ "src", diff --git a/packages/provider/src/analytics.ts b/packages/provider/src/analytics.ts index 54cb2832e..8578c2d22 100644 --- a/packages/provider/src/analytics.ts +++ b/packages/provider/src/analytics.ts @@ -1,6 +1,6 @@ import { Databeat, Event as DatabeatEvent, Auth, isBrowser } from '@databeat/tracker' -export enum EventType { +export enum AnalyticsEventType { // Core types part of Databeat INIT, VIEW, @@ -11,11 +11,11 @@ export enum EventType { SEND_TRANSACTION_REQUEST } -export type EventTypes = keyof typeof EventType -export type Event = DatabeatEvent +export type AnalyticsEventTypes = keyof typeof AnalyticsEventType +export type AnalyticsEvent = DatabeatEvent // Analytics sub-class to add some custom helper methods -export class Analytics extends Databeat {} +export class Analytics extends Databeat {} // Setup analytics tracker export const setupAnalytics = (projectAccessKey: string, server?: string) => { diff --git a/packages/provider/src/client.ts b/packages/provider/src/client.ts index ea280f641..d2883ec1c 100644 --- a/packages/provider/src/client.ts +++ b/packages/provider/src/client.ts @@ -1,4 +1,4 @@ -import { JsonRpcRequest, JsonRpcResponse, NetworkConfig } from '@0xsequence/network' +import { NetworkConfig } from '@0xsequence/network' import { ConnectDetails, ConnectOptions, @@ -15,14 +15,12 @@ import { isProviderTransport, messageToBytes } from '.' -import { commons } from '@0xsequence/core' +import { commons, VERSION } from '@0xsequence/core' import { TypedData } from '@0xsequence/utils' import { toExtended } from './extended' import { Analytics, setupAnalytics } from './analytics' import { ethers } from 'ethers' -import packageJson from '../package.json' - /** * This session class is meant to persist the state of the wallet connection * whitin the dapp. This enables the client to retain the wallet address (and some more) @@ -56,10 +54,14 @@ export class SequenceClientSession { } getSession(): WalletSession | undefined { - const session = this.store.getItem(SequenceClientSession.SESSION_LOCALSTORE_KEY) + try { + const session = this.store.getItem(SequenceClientSession.SESSION_LOCALSTORE_KEY) - if (session) { - return JSON.parse(session) + if (session) { + return JSON.parse(session) + } + } catch (err) { + console.error('Error parsing session', err) } return undefined @@ -144,7 +146,7 @@ export class SequenceClient { constructor(transport: ProviderTransport | MuxTransportTemplate, store: ItemStore, options?: SequenceClientOptions) { if (isMuxTransportTemplate(transport)) { - this.transport = MuxMessageProvider.new(transport) + this.transport = MuxMessageProvider.new(transport, options?.projectAccessKey) } else if (isProviderTransport(transport)) { this.transport = transport } else { @@ -166,7 +168,7 @@ export class SequenceClient { }) this.transport.on('connect', (response: ConnectDetails) => { - const chainIdHex = ethers.utils.hexValue(this.getChainId()) + const chainIdHex = ethers.toQuantity(this.getChainId()) this.callbacks.connect?.forEach(cb => cb({ ...response, @@ -204,7 +206,7 @@ export class SequenceClient { // We don't listen for the transport chainChanged event // instead we handle it locally, so we listen for changes in the store this.defaultChainId.onDefaultChainIdChanged((chainId: number) => { - const chainIdHex = ethers.utils.hexValue(chainId) + const chainIdHex = ethers.toQuantity(chainId) this.callbacks.chainChanged?.forEach(cb => cb(chainIdHex)) }) @@ -337,7 +339,7 @@ export class SequenceClient { await this.openWallet(undefined, { type: 'connect', - options: { ...options, networkId: this.getChainId(), clientVersion: packageJson.version } + options: { ...options, networkId: this.getChainId(), clientVersion: VERSION } }) const connectDetails = await this.transport.waitUntilConnected().catch((error): ConnectDetails => { @@ -351,7 +353,7 @@ export class SequenceClient { // Normalize chainId into a decimal string // TODO: Remove this once wallet-webapp returns chainId as a string if (connectDetails.chainId) { - connectDetails.chainId = ethers.BigNumber.from(connectDetails.chainId).toString() + connectDetails.chainId = BigInt(connectDetails.chainId).toString() } if (connectDetails.connected) { @@ -381,40 +383,23 @@ export class SequenceClient { // Higher level API - // Working with sendAsync is less idiomatic - // but transport uses it instead of send, so we wrap it - send(request: JsonRpcRequest, chainId?: number): Promise { + async request(request: { method: string; params?: any[]; chainId?: number }): Promise { // Internally when sending requests we use `legacy_sign` // to avoid the default EIP6492 behavior overriding an explicit // "legacy sign" request, so we map the method here. request.method = this.mapSignMethod(request.method) - return new Promise((resolve, reject) => { - this.transport.sendAsync( - request, - (error, response) => { - if (error) { - reject(error) - } else if (response === undefined) { - reject(new Error(`Got undefined response for request: ${request}`)) - } else if (typeof response === 'object' && response.error) { - reject(response.error) - } else if (typeof response === 'object' && response.result) { - resolve(response.result) - } else { - reject(new Error(`Got invalid response for request: ${request}`)) - } - }, - chainId || this.getChainId() - ) - }) + const result = await this.transport.request(request) + + // We may need to unwrap the response if it's a JSON-RPC response. ie. older universal wallet versions + return unwrapJsonRpcResponse(result) } async getNetworks(pull?: boolean): Promise { const connectedSession = this.session.connectedSession() if (pull) { - connectedSession.networks = await this.send({ method: 'sequence_getNetworks' }) + connectedSession.networks = await this.request({ method: 'sequence_getNetworks' }) this.session.setSession(connectedSession) } @@ -474,11 +459,14 @@ export class SequenceClient { this.analytics?.track({ event: 'SIGN_MESSAGE_REQUEST', props: { chainId: `${options?.chainId || this.getChainId()}` } }) - // Serialize a BytesLike or string message into a hex string before sending - message = ethers.utils.hexlify(messageToBytes(message)) + message = ethers.hexlify(messageToBytes(message)) // Address is ignored by the wallet webapp - return this.send({ method, params: [message, this.getAddress()] }, options?.chainId) + return this.request({ + method, + params: [message, this.getAddress()], + chainId: options?.chainId + }) } async signTypedData(typedData: TypedData, options?: OptionalEIP6492 & OptionalChainId): Promise { @@ -486,7 +474,7 @@ export class SequenceClient { // TODO: Stop using ethers for this, this is the only place where we use it // and it makes the client depend on ethers. - const encoded = ethers.utils._TypedDataEncoder.getPayload(typedData.domain, typedData.types, typedData.message) + const encoded = ethers.TypedDataEncoder.getPayload(typedData.domain, typedData.types, typedData.message) // The sign typed data will use one of the following chainIds, in order: // - The one provided in the options @@ -495,36 +483,33 @@ export class SequenceClient { this.analytics?.track({ event: 'SIGN_TYPED_DATA_REQUEST', props: { chainId: `${options?.chainId || this.getChainId()}` } }) - return this.send( - { method, params: [this.getAddress(), encoded] }, - options?.chainId || - (typedData.domain.chainId && ethers.BigNumber.from(typedData.domain.chainId).toNumber()) || - this.getChainId() - ) + return this.request({ + method, + params: [this.getAddress(), encoded], + chainId: options?.chainId || (typedData.domain.chainId && Number(typedData.domain.chainId)) || this.getChainId() + }) } - async sendTransaction( - tx: ethers.providers.TransactionRequest[] | ethers.providers.TransactionRequest, - options?: OptionalChainId - ): Promise { + async sendTransaction(tx: ethers.TransactionRequest[] | ethers.TransactionRequest, options?: OptionalChainId): Promise { const sequenceTxs = Array.isArray(tx) ? tx : [tx] const extendedTxs = toExtended(sequenceTxs) this.analytics?.track({ event: 'SEND_TRANSACTION_REQUEST', props: { chainId: `${options?.chainId || this.getChainId()}` } }) - return this.send({ method: 'eth_sendTransaction', params: [extendedTxs] }, options?.chainId) + return this.request({ method: 'eth_sendTransaction', params: [extendedTxs], chainId: options?.chainId }) } async getWalletContext(): Promise { - return this.send({ method: 'sequence_getWalletContext' }) + return this.request({ method: 'sequence_getWalletContext' }) } async getOnchainWalletConfig(options?: OptionalChainId): Promise { // NOTICE: sequence_getWalletConfig sends the chainId as a param - const res = await this.send( - { method: 'sequence_getWalletConfig', params: [options?.chainId || this.getChainId()] }, - options?.chainId - ) + const res = await this.request({ + method: 'sequence_getWalletConfig', + params: [options?.chainId || this.getChainId()], + chainId: options?.chainId + }) return Array.isArray(res) ? res[0] : res } @@ -533,3 +518,12 @@ export class SequenceClient { // wallet-webapp does implement them, but this client is meant to be // exclusively used for Sequence specific methods } + +// Unwrap a JsonRpcResponse result +const unwrapJsonRpcResponse = (response: any): any => { + if (response && typeof response === 'object' && 'jsonrpc' in response && 'result' in response) { + return response.result + } + + return response +} diff --git a/packages/provider/src/eip191exceptions.ts b/packages/provider/src/eip191exceptions.ts index af24a5315..81219852f 100644 --- a/packages/provider/src/eip191exceptions.ts +++ b/packages/provider/src/eip191exceptions.ts @@ -23,7 +23,7 @@ const DCL_REGEX = /^Decentraland Login\nEphemeral address: 0x[a-fA-F0-9]{40}\nExpiration: (\d{4})-(\d{2})-(\d{2})T(\d{2}):(\d{2}):(\d{2}(?:\.\d*)?)((-(\d{2}):(\d{2})|Z)?)$/ export function isDecentralandLoginMessage(bytes: Uint8Array): boolean { try { - const stringified = ethers.utils.toUtf8String(bytes) + const stringified = ethers.toUtf8String(bytes) return DCL_REGEX.test(stringified) } catch { return false @@ -33,7 +33,7 @@ export function isDecentralandLoginMessage(bytes: Uint8Array): boolean { // try to interpret bytes as abi-encoded 0x v3 OrderWithHash - // see https://github.com/0xProject/0x-protocol-specification/blob/master/v3/v3-specification.md export function isZeroExV3Order(bytes: Uint8Array): boolean { - const abi = new ethers.utils.Interface(ZeroXV3EIP1271OrderWithHashAbi) + const abi = new ethers.Interface(ZeroXV3EIP1271OrderWithHashAbi) try { abi.decodeFunctionData('OrderWithHash', bytes) return true diff --git a/packages/provider/src/extended.ts b/packages/provider/src/extended.ts index b8e15a5fc..ddbca17d8 100644 --- a/packages/provider/src/extended.ts +++ b/packages/provider/src/extended.ts @@ -1,10 +1,10 @@ import { ethers } from 'ethers' -export type ExtendedTransactionRequest = ethers.providers.TransactionRequest & { - auxiliary?: ethers.providers.TransactionRequest[] +export type ExtendedTransactionRequest = ethers.TransactionRequest & { + auxiliary?: ethers.TransactionRequest[] } -export function toExtended(transactions: ethers.providers.TransactionRequest[]): ExtendedTransactionRequest { +export function toExtended(transactions: ethers.TransactionRequest[]): ExtendedTransactionRequest { if (transactions.length === 0) { throw new Error('No transaction provided') } @@ -17,10 +17,10 @@ export function toExtended(transactions: ethers.providers.TransactionRequest[]): } } -export function fromExtended(transaction: ExtendedTransactionRequest): ethers.providers.TransactionRequest[] { +export function fromExtended(transaction: ExtendedTransactionRequest): ethers.TransactionRequest[] { return [transaction, ...(transaction.auxiliary || [])] } -export function isExtended(transaction: ethers.providers.TransactionRequest): transaction is ExtendedTransactionRequest { +export function isExtended(transaction: ethers.TransactionRequest): transaction is ExtendedTransactionRequest { return (transaction as any).auxiliary !== undefined } diff --git a/packages/provider/src/index.ts b/packages/provider/src/index.ts index 50e99d811..01cfe369b 100644 --- a/packages/provider/src/index.ts +++ b/packages/provider/src/index.ts @@ -6,3 +6,4 @@ export * from './utils' export * from './client' export * from './signer' export * from './init' +export * from './analytics' diff --git a/packages/provider/src/init.ts b/packages/provider/src/init.ts index 371acae3f..c84ed3e68 100644 --- a/packages/provider/src/init.ts +++ b/packages/provider/src/init.ts @@ -1,13 +1,12 @@ import { CachedProvider, ChainIdLike, - JsonRpcRouter, - JsonRpcSender, NetworkConfig, allNetworks, exceptionProviderMiddleware, findNetworkConfig, - loggingProviderMiddleware + loggingProviderMiddleware, + JsonRpcProvider } from '@0xsequence/network' import { MuxTransportTemplate } from './transports' import { ItemStore, useBestStore } from './utils' @@ -85,57 +84,31 @@ export const initWallet = (projectAccessKey: string, partialConfig?: Partial = {} + let networks: NetworkConfig[] = [] - // Find any new networks that aren't already defined in sequence.js - // and add them to the list of networks, (they must have a rpcUrl and chainId) - const newNetworks = (config.networks?.filter(n => { - n.rpcUrl !== undefined && n.chainId !== undefined && !allNetworks.find(an => an.chainId === n.chainId) - }) ?? []) as NetworkConfig[] + const updateNetworks = (connectedNetworks: NetworkConfig[] = []) => { + networks = mergeNetworks(allNetworks, connectedNetworks, config.networks ?? []) - // Override any information about the networks using the config - const combinedNetworks = allNetworks - .map(n => { - const network = config.networks?.find(cn => cn.chainId === n.chainId) - return network ? { ...n, ...network } : n - }) - .concat(newNetworks) - .map(network => { - // don't double-append in the case the user has already included their access key in the rpc URL + // Append projectAccessKey to network rpcUrls + networks = networks.map(network => { + // Don't double-append in the case the user has already included their access key in the rpc URL if (network.rpcUrl.includes(projectAccessKey)) { return network } - // this will probably break non-sequence RPC provider URLs. + // XXX: This will probably break non-sequence RPC provider URLs. network.rpcUrl = network.rpcUrl + `/${projectAccessKey}` + return network }) - - // This builds a "public rpc" on demand, we build them on demand because we don't want to - // generate a bunch of providers for networks that aren't used. - const providerForChainId = (chainId: number) => { - if (!rpcProviders[chainId]) { - const rpcUrl = combinedNetworks.find(n => n.chainId === chainId)?.rpcUrl - if (!rpcUrl) { - throw new Error(`no rpcUrl found for chainId: ${chainId}`) - } - - const baseProvider = new ethers.providers.JsonRpcProvider(rpcUrl) - const router = new JsonRpcRouter( - [loggingProviderMiddleware, exceptionProviderMiddleware, new CachedProvider()], - new JsonRpcSender(baseProvider) - ) - - rpcProviders[chainId] = new ethers.providers.Web3Provider(router, chainId) - } - - return rpcProviders[chainId] } + updateNetworks() + // This is the starting default network (as defined by the config) // it can be later be changed using `wallet_switchEthereumChain` or some // of the other methods on the provider. - const defaultNetwork = config.defaultNetwork ? findNetworkConfig(combinedNetworks, config.defaultNetwork)?.chainId : undefined + const defaultNetwork = config.defaultNetwork ? findNetworkConfig(networks, config.defaultNetwork)?.chainId : undefined if (!defaultNetwork && config.defaultNetwork) { throw new Error(`defaultNetwork not found for chainId: ${config.defaultNetwork}`) } @@ -151,6 +124,39 @@ export const initWallet = (projectAccessKey: string, partialConfig?: Partial { + updateNetworks(ev.session?.networks) + }) + + const rpcProviders: Record = {} + + // This builds a "public rpc" on demand, we build them on demand because we don't want to + // generate a bunch of providers for networks that aren't used. + const providerForChainId = (chainId: number) => { + const network = findNetworkConfig(networks, chainId) + + if (!network) { + throw new Error(`no network config found for chainId: ${chainId}`) + } + + const { rpcUrl } = network + + // Cache providers by rpc url + if (!rpcProviders[rpcUrl]) { + rpcProviders[rpcUrl] = new JsonRpcProvider( + rpcUrl, + { + middlewares: [loggingProviderMiddleware, exceptionProviderMiddleware, new CachedProvider()] + }, + { cacheTimeout: -1 } + ) + } + + return rpcProviders[rpcUrl] + } + sequenceWalletProvider = new SequenceProvider(client, providerForChainId) return sequenceWalletProvider } @@ -168,3 +174,18 @@ export const getWallet = () => { } return sequenceWalletProvider } + +// allNetworks <- connectedNetworks <- config.networks +const mergeNetworks = (...networks: Partial[][]) => { + const networkMap = new Map() + + for (const network of networks.flat()) { + if (network.chainId && network.rpcUrl) { + const existingNetwork = networkMap.get(network.chainId) + + networkMap.set(network.chainId, { ...existingNetwork, ...network } as NetworkConfig) + } + } + + return Array.from(networkMap.values()) +} diff --git a/packages/provider/src/provider.ts b/packages/provider/src/provider.ts index 0ebeb1bd6..b5070f5ff 100644 --- a/packages/provider/src/provider.ts +++ b/packages/provider/src/provider.ts @@ -1,7 +1,7 @@ import { ethers } from 'ethers' import { SequenceClient } from './client' -import { ChainIdLike, NetworkConfig, allNetworks, findNetworkConfig } from '@0xsequence/network' -import { ConnectDetails, ConnectOptions, EIP1193Provider, OpenWalletIntent, OptionalChainIdLike, WalletSession } from './types' +import { EIP1193Provider, ChainIdLike, NetworkConfig, allNetworks, findNetworkConfig } from '@0xsequence/network' +import { ConnectDetails, ConnectOptions, OpenWalletIntent, OptionalChainIdLike, WalletSession } from './types' import { commons } from '@0xsequence/core' import { WalletUtils } from './utils/index' import { SequenceSigner, SingleNetworkSequenceSigner } from './signer' @@ -46,7 +46,10 @@ export interface ISequenceProvider { utils: WalletUtils } -export class SequenceProvider extends ethers.providers.BaseProvider implements ISequenceProvider, EIP1193Provider { +const EIP1193EventTypes = ['connect', 'disconnect', 'chainChanged', 'accountsChanged'] as const +type EIP1193EventType = (typeof EIP1193EventTypes)[number] + +export class SequenceProvider extends ethers.AbstractProvider implements ISequenceProvider, EIP1193Provider { private readonly singleNetworkProviders: { [chainId: number]: SingleNetworkSequenceProvider } = {} readonly _isSequenceProvider = true @@ -54,30 +57,37 @@ export class SequenceProvider extends ethers.providers.BaseProvider implements I readonly signer: SequenceSigner + readonly eip1193EventListeners = new Map>() + constructor( public readonly client: SequenceClient, - private readonly providerFor: (networkId: number) => ethers.providers.JsonRpcProvider, - public readonly networks: NetworkConfig[] = allNetworks + private readonly providerFor: (networkId: number) => ethers.JsonRpcProvider, + public readonly networks: NetworkConfig[] = allNetworks, + public readonly options?: ethers.AbstractProviderOptions ) { // We support a lot of networks // but we start with the default one - super(client.getChainId()) + super(client.getChainId(), options) // Emit events as defined by EIP-1193 client.onConnect(details => { - this.emit('connect', details) + //this.emit('connect', details) + this.eip1193EventListeners.get('connect')?.forEach(listener => listener(details)) }) client.onDisconnect(error => { - this.emit('disconnect', error) + //this.emit('disconnect', error) + this.eip1193EventListeners.get('disconnect')?.forEach(listener => listener(error)) }) client.onDefaultChainIdChanged(chainId => { - this.emit('chainChanged', chainId) + //this.emit('chainChanged', chainId) + this.eip1193EventListeners.get('chainChanged')?.forEach(listener => listener(chainId)) }) client.onAccountsChanged(accounts => { - this.emit('accountsChanged', accounts) + //this.emit('accountsChanged', accounts) + this.eip1193EventListeners.get('accountsChanged')?.forEach(listener => listener(accounts)) }) // NOTICE: We don't emit 'open' and 'close' events @@ -95,6 +105,36 @@ export class SequenceProvider extends ethers.providers.BaseProvider implements I this.utils = new WalletUtils(this.signer) } + async on(event: ethers.ProviderEvent | EIP1193EventType, listener: ethers.Listener): Promise { + if (EIP1193EventTypes.includes(event as EIP1193EventType)) { + const listeners = this.eip1193EventListeners.get(event as EIP1193EventType) || new Set() + listeners.add(listener) + this.eip1193EventListeners.set(event as EIP1193EventType, listeners) + + return this + } + + return super.on(event, listener) as Promise + } + + async off(event: ethers.ProviderEvent | EIP1193EventType, listener?: ethers.Listener | undefined): Promise { + if (EIP1193EventTypes.includes(event as EIP1193EventType)) { + const listeners = this.eip1193EventListeners.get(event as EIP1193EventType) + + if (listeners) { + if (listener) { + listeners.delete(listener) + } else { + listeners.clear() + } + } + + return this + } + + return super.off(event, listener) as Promise + } + getSigner(): SequenceSigner getSigner(chainId: ChainIdLike): SingleNetworkSequenceSigner getSigner(chainId?: ChainIdLike): SequenceSigner | SingleNetworkSequenceSigner @@ -206,13 +246,18 @@ export class SequenceProvider extends ethers.providers.BaseProvider implements I getProvider(chainId?: ChainIdLike) { // The provider without a chainId is... this one if (!chainId) { - return this + return this as SequenceProvider } const useChainId = this.toChainId(chainId) if (!this.singleNetworkProviders[useChainId]) { - this.singleNetworkProviders[useChainId] = new SingleNetworkSequenceProvider(this.client, this.providerFor, useChainId) + this.singleNetworkProviders[useChainId] = new SingleNetworkSequenceProvider( + this.client, + this.providerFor, + useChainId, + this.options + ) } return this.singleNetworkProviders[useChainId] @@ -222,7 +267,7 @@ export class SequenceProvider extends ethers.providers.BaseProvider implements I * This returns a subprovider, this is a regular non-sequence provider that * can be used to fulfill read only requests on a given network. */ - async _getSubprovider(chainId?: ChainIdLike): Promise { + async _getSubprovider(chainId?: ChainIdLike): Promise { const useChainId = await this.useChainId(chainId) // Whoever implements providerFrom should memoize the generated provider @@ -236,10 +281,23 @@ export class SequenceProvider extends ethers.providers.BaseProvider implements I return provider } + async _perform(req: ethers.PerformActionRequest): Promise { + const { method, ...args } = req + + const provider = await this._getSubprovider() + const prepared = provider.getRpcRequest(req) ?? { method, args: Object.values(args) } + + if (!prepared) { + throw new Error(`Unsupported method ${req.method}`) + } + + return provider.send(prepared.method, prepared.args) + } + async perform(method: string, params: any): Promise { // First we check if the method should be handled by the client if (method === 'eth_chainId') { - return ethers.utils.hexValue(await this.useChainId()) + return ethers.toQuantity(await this.useChainId()) } if (method === 'eth_accounts') { @@ -268,14 +326,10 @@ export class SequenceProvider extends ethers.providers.BaseProvider implements I ) { // We pass the chainId to the client, if we don't pass one // the client will use its own default chainId - return this.client.send({ method, params }, this.getChainId()) + return this.client.request({ method, params, chainId: this.getChainId() }) } - // Forward call to the corresponding provider - // we use the provided chainId, or the default one provided by the client - const provider = await this._getSubprovider() - const prepared = provider.prepareRequest(method, params) ?? [method, params] - return provider.send(prepared[0], prepared[1]) + return this._perform({ method, ...params }) } send(method: string, params: any): Promise { @@ -286,17 +340,23 @@ export class SequenceProvider extends ethers.providers.BaseProvider implements I return this.perform(request.method, request.params) } - async detectNetwork(): Promise { + async _detectNetwork(): Promise { const chainId = this.client.getChainId() - const network = findNetworkConfig(this.networks, chainId) + const found = findNetworkConfig(this.networks, chainId) - if (!network) { + if (!found) { throw new Error(`Unknown network ${chainId}`) } + const network = new ethers.Network(found.name, found.chainId) + return network } + async detectNetwork(): Promise { + return this._detectNetwork() + } + // Override most of the methods, so we add support for an optional chainId // argument, which is used to select the provider to use. // @@ -314,76 +374,61 @@ export class SequenceProvider extends ethers.providers.BaseProvider implements I return provider.getBlockNumber() } - async getGasPrice(optionals?: OptionalChainIdLike) { + async getFeeData(optionals?: OptionalChainIdLike) { const provider = await this._getSubprovider(optionals?.chainId) - return provider.getGasPrice() + return provider.getFeeData() } - async getBalance( - addressOrName: string | Promise, - blockTag?: ethers.providers.BlockTag | Promise, - optionals?: OptionalChainIdLike - ) { + async getBalance(addressOrName: string | Promise, blockTag?: ethers.BlockTag, optionals?: OptionalChainIdLike) { const provider = await this._getSubprovider(optionals?.chainId) return provider.getBalance(addressOrName, blockTag) } async getTransactionCount( addressOrName: string | Promise, - blockTag?: ethers.providers.BlockTag | Promise, + blockTag?: ethers.BlockTag, optionals?: OptionalChainIdLike ) { const provider = await this._getSubprovider(optionals?.chainId) return provider.getTransactionCount(addressOrName, blockTag) } - async getCode( - addressOrName: string | Promise, - blockTag?: ethers.providers.BlockTag | Promise, - optionals?: OptionalChainIdLike - ) { + async getCode(addressOrName: string | Promise, blockTag?: ethers.BlockTag, optionals?: OptionalChainIdLike) { const provider = await this._getSubprovider(optionals?.chainId) return provider.getCode(addressOrName, blockTag) } - async getStorageAt( + async getStorage( addressOrName: string | Promise, - position: ethers.BigNumberish | Promise, - blockTag?: ethers.providers.BlockTag | Promise, + position: ethers.BigNumberish, + blockTag?: ethers.BlockTag, optionals?: OptionalChainIdLike ) { const provider = await this._getSubprovider(optionals?.chainId) - return provider.getStorageAt(addressOrName, position, blockTag) + return provider.getStorage(addressOrName, position, blockTag) } - async call( - transaction: ethers.utils.Deferrable, - blockTag?: ethers.providers.BlockTag | Promise, - optionals?: OptionalChainIdLike - ) { + async call(transaction: ethers.TransactionRequest, optionals?: OptionalChainIdLike) { const provider = await this._getSubprovider(optionals?.chainId) - return provider.call(transaction, blockTag) + return provider.call(transaction) } - async estimateGas(transaction: ethers.utils.Deferrable, optionals?: OptionalChainIdLike) { + async estimateGas(transaction: ethers.TransactionRequest, optionals?: OptionalChainIdLike) { const provider = await this._getSubprovider(optionals?.chainId) return provider.estimateGas(transaction) } - async getBlock( - blockHashOrBlockTag: ethers.providers.BlockTag | string | Promise, - optionals?: OptionalChainIdLike - ) { + async getBlock(blockHashOrBlockTag: ethers.BlockTag | string, prefetchTxs?: boolean, optionals?: OptionalChainIdLike) { const provider = await this._getSubprovider(optionals?.chainId) - return provider.getBlock(blockHashOrBlockTag) + return provider.getBlock(blockHashOrBlockTag, prefetchTxs) } - async getTransaction(transactionHash: string | Promise, optionals?: OptionalChainIdLike) { + async getTransaction(transactionHash: string, optionals?: OptionalChainIdLike) { const provider = await this._getSubprovider(optionals?.chainId) return provider.getTransaction(transactionHash) } - async getLogs(filter: ethers.providers.Filter | Promise, optionals?: OptionalChainIdLike) { + async getLogs(filter: ethers.Filter, optionals?: OptionalChainIdLike) { const provider = await this._getSubprovider(optionals?.chainId) return provider.getLogs(filter) } @@ -405,8 +450,8 @@ export class SequenceProvider extends ethers.providers.BaseProvider implements I return provider.getResolver(name) } - async resolveName(name: string | Promise) { - if (ethers.utils.isAddress(await name)) { + async resolveName(name: string) { + if (ethers.isAddress(name)) { return name } @@ -419,7 +464,7 @@ export class SequenceProvider extends ethers.providers.BaseProvider implements I return provider.resolveName(name) } - async lookupAddress(address: string | Promise) { + async lookupAddress(address: string) { if (!(await this.supportsENS())) { return null } @@ -443,9 +488,9 @@ export class SequenceProvider extends ethers.providers.BaseProvider implements I } } -function normalizeChainId(chainId: string | number | bigint | { chainId: string }): number { +function normalizeChainId(chainId: ethers.BigNumberish | { chainId: string }): number { if (typeof chainId === 'object') return normalizeChainId(chainId.chainId) - return ethers.BigNumber.from(chainId).toNumber() + return Number(chainId) } /** @@ -462,10 +507,11 @@ export class SingleNetworkSequenceProvider extends SequenceProvider { constructor( client: SequenceClient, - providerFor: (networkId: number) => ethers.providers.JsonRpcProvider, - public readonly chainId: ChainIdLike + providerFor: (networkId: number) => ethers.JsonRpcProvider, + public readonly chainId: ChainIdLike, + options?: ethers.AbstractProviderOptions ) { - super(client, providerFor) + super(client, providerFor, undefined, options) } private _useChainId(chainId?: ChainIdLike): number { @@ -486,15 +532,15 @@ export class SingleNetworkSequenceProvider extends SequenceProvider { return super.toChainId(this.chainId) } - async getNetwork(): Promise { + async getNetwork(): Promise { const networks = await this.client.getNetworks() - const res = findNetworkConfig(networks, this.chainId) + const found = findNetworkConfig(networks, this.chainId) - if (!res) { + if (!found) { throw new Error(`Unsupported network ${this.chainId}`) } - return res + return new ethers.Network(found.name, found.chainId) } /** diff --git a/packages/provider/src/signer.ts b/packages/provider/src/signer.ts index 5e15dbb0c..168b1ddee 100644 --- a/packages/provider/src/signer.ts +++ b/packages/provider/src/signer.ts @@ -8,7 +8,7 @@ import { resolveArrayProperties } from './utils' import { WalletUtils } from './utils/index' import { OptionalChainIdLike, OptionalEIP6492 } from './types' -export interface ISequenceSigner extends ethers.Signer { +export interface ISequenceSigner extends Omit { getProvider(): SequenceProvider getProvider(chainId: ChainIdLike): SingleNetworkSequenceProvider getProvider(chainId?: ChainIdLike): SequenceProvider | SingleNetworkSequenceProvider @@ -20,6 +20,8 @@ export interface ISequenceSigner extends ethers.Signer { getWalletConfig(chainId?: ChainIdLike): Promise getNetworks(): Promise + connect: (provider: SequenceProvider) => SequenceSigner + signMessage(message: ethers.BytesLike, options?: OptionalChainIdLike & OptionalEIP6492): Promise signTypedData( @@ -33,9 +35,7 @@ export interface ISequenceSigner extends ethers.Signer { // the signer, and finally sends it to the relayer for submission to an Ethereum network. // It supports any kind of transaction, including regular ethers transactions, and Sequence transactions. sendTransaction( - transaction: - | ethers.utils.Deferrable[] - | ethers.utils.Deferrable, + transaction: ethers.TransactionRequest[] | ethers.TransactionRequest, options?: OptionalChainIdLike ): Promise @@ -45,7 +45,6 @@ export interface ISequenceSigner extends ethers.Signer { export class SequenceSigner implements ISequenceSigner { private readonly singleNetworkSigners: { [chainId: number]: SingleNetworkSequenceSigner } = {} - readonly _isSigner: boolean = true readonly _isSequenceSigner: boolean = true get utils(): WalletUtils { @@ -63,7 +62,7 @@ export class SequenceSigner implements ISequenceSigner { // This method shouldn't be used directly // it exists to maintain compatibility with ethers.Signer - connect(provider: ethers.providers.Provider): SequenceSigner { + connect(provider: ethers.Provider): SequenceSigner { if (!SequenceProvider.is(provider)) { throw new Error('SequenceSigner can only be connected to a SequenceProvider') } @@ -124,25 +123,28 @@ export class SequenceSigner implements ISequenceSigner { return this.provider.getProvider(chainId) } - async sendTransaction( - transaction: - | ethers.utils.Deferrable[] - | ethers.utils.Deferrable, - options?: OptionalChainIdLike - ) { + async sendTransaction(transaction: ethers.TransactionRequest[] | ethers.TransactionRequest, options?: OptionalChainIdLike) { const chainId = this.useChainId(options?.chainId) const resolved = await resolveArrayProperties(transaction) const txHash = await this.client.sendTransaction(resolved, { chainId }) const provider = this.getProvider(chainId) try { - return (await ethers.utils.poll( - async () => { + const result = await new Promise(resolve => { + const check = async () => { const tx = await provider.getTransaction(txHash) - return tx ? provider._wrapTransaction(tx, txHash) : undefined - }, - { onceBlock: provider } - )) as ethers.providers.TransactionResponse + + if (tx !== null) { + return resolve(tx) + } + + await provider.once('block', check) + } + + check() + }) + + return result } catch (err) { err.transactionHash = txHash throw err @@ -158,35 +160,24 @@ export class SequenceSigner implements ISequenceSigner { return this.client.getNetworks() } - async getBalance(blockTag?: ethers.providers.BlockTag | undefined, optionals?: OptionalChainIdLike): Promise { + async getBalance(blockTag?: ethers.BlockTag | undefined, optionals?: OptionalChainIdLike): Promise { const provider = this.getProvider(optionals?.chainId) return provider.getBalance(this.getAddress(), blockTag) } - async estimateGas( - transaction: ethers.utils.Deferrable, - optionals?: OptionalChainIdLike - ): Promise { + async estimateGas(transaction: ethers.TransactionRequest, optionals?: OptionalChainIdLike): Promise { return this.getProvider(optionals?.chainId).estimateGas(transaction) } - async call( - transaction: ethers.utils.Deferrable, - blockTag?: ethers.providers.BlockTag | undefined, - optionals?: OptionalChainIdLike - ): Promise { - return this.getProvider(optionals?.chainId).call(transaction, blockTag) + async call(transaction: ethers.TransactionRequest, optionals?: OptionalChainIdLike): Promise { + return this.getProvider(optionals?.chainId).call(transaction) } getChainId(): Promise { return Promise.resolve(this.client.getChainId()) } - async getGasPrice(optionals?: OptionalChainIdLike): Promise { - return this.getProvider(optionals?.chainId).getGasPrice() - } - - async getFeeData(optionals?: OptionalChainIdLike): Promise { + async getFeeData(optionals?: OptionalChainIdLike): Promise { return this.getProvider(optionals?.chainId).getFeeData() } @@ -194,7 +185,7 @@ export class SequenceSigner implements ISequenceSigner { const res = await this.provider.resolveName(name) // For some reason ethers.Signer expects this to return `string` - // but ethers.providers.Provider expects this to return `string | null`. + // but ethers.Provider expects this to return `string | null`. // The signer doesn't have any other source of information, so we'll // fail if the provider doesn't return a result. if (res === null) { @@ -208,25 +199,29 @@ export class SequenceSigner implements ISequenceSigner { // We always have a provider, so this is a noop } - populateTransaction( - _transaction: ethers.utils.Deferrable - ): Promise { + getNonce(_blockTag?: ethers.BlockTag): Promise { + throw new Error('SequenceSigner does not support getNonce') + } + + populateCall(_transaction: ethers.TransactionRequest): Promise> { + throw new Error('SequenceSigner does not support populateCall') + } + + populateTransaction(_transaction: ethers.TransactionRequest): Promise> { throw new Error('SequenceSigner does not support populateTransaction') } - checkTransaction( - _transaction: ethers.utils.Deferrable - ): ethers.utils.Deferrable { + checkTransaction(_transaction: ethers.TransactionRequest): ethers.TransactionRequest { throw new Error('SequenceSigner does not support checkTransaction') } - getTransactionCount(_blockTag?: ethers.providers.BlockTag | undefined): Promise { + getTransactionCount(_blockTag?: ethers.BlockTag): Promise { // We could try returning the sequence nonce here // but we aren't sure how ethers will use this nonce throw new Error('SequenceSigner does not support getTransactionCount') } - signTransaction(_transaction: ethers.utils.Deferrable): Promise { + signTransaction(_transaction: commons.transaction.Transactionish): Promise { // We could implement signTransaction/sendTransaction here // but first we need a way of serializing these signed transactions // and it could lead to more trouble, because the dapp could try to send this transaction diff --git a/packages/provider/src/transactions.ts b/packages/provider/src/transactions.ts index 3b95b9017..4ebe8cdf5 100644 --- a/packages/provider/src/transactions.ts +++ b/packages/provider/src/transactions.ts @@ -12,7 +12,7 @@ const PROHIBITED_FUNCTIONS = new Map( 'updateImageHash(bytes32)', 'updateImageHashAndIPFS(bytes32,bytes32)', 'updateImplementation(address)' - ].map(signature => [ethers.utils.keccak256(ethers.utils.toUtf8Bytes(signature)).slice(0, 10), signature]) + ].map(signature => [ethers.id(signature).slice(0, 10), signature]) ) export function validateTransactionRequest(wallet: string, transaction: commons.transaction.Transactionish) { @@ -24,7 +24,7 @@ export function validateTransactionRequest(wallet: string, transaction: commons. function validateTransaction(wallet: string, transaction: commons.transaction.Transaction) { if (transaction.to.toLowerCase() === wallet.toLowerCase()) { if (transaction.data) { - const data = ethers.utils.arrayify(transaction.data) + const data = ethers.getBytes(transaction.data) if (data.length >= 4 && !isCreateContractCall(data)) { throw new Error('self calls are forbidden') } @@ -36,7 +36,7 @@ function validateTransaction(wallet: string, transaction: commons.transaction.Tr } if (transaction.data) { - const data = ethers.utils.hexlify(transaction.data) + const data = ethers.hexlify(transaction.data) const selector = data.slice(0, 10) const signature = PROHIBITED_FUNCTIONS.get(selector) if (signature) { @@ -47,7 +47,7 @@ function validateTransaction(wallet: string, transaction: commons.transaction.Tr } function isCreateContractCall(data: ethers.BytesLike): boolean { - const walletInterface = new ethers.utils.Interface(walletContracts.mainModule.abi) + const walletInterface = new ethers.Interface(walletContracts.mainModule.abi) try { walletInterface.decodeFunctionData('createContract', data) return true diff --git a/packages/provider/src/transports/base-provider-transport.ts b/packages/provider/src/transports/base-provider-transport.ts index 033839535..6e0199e0e 100644 --- a/packages/provider/src/transports/base-provider-transport.ts +++ b/packages/provider/src/transports/base-provider-transport.ts @@ -17,10 +17,10 @@ import { TypedEventEmitter } from '../types' -import { NetworkConfig, JsonRpcRequest, JsonRpcResponseCallback } from '@0xsequence/network' +import { NetworkConfig } from '@0xsequence/network' import { logger } from '@0xsequence/utils' import { ethers } from 'ethers' -import { commons } from '@0xsequence/core' +import { VERSION, commons } from '@0xsequence/core' export const PROVIDER_OPEN_TIMEOUT = 30000 // in ms @@ -46,10 +46,14 @@ export abstract class BaseProviderTransport implements ProviderTransport { protected _init: InitState protected _registered: boolean - constructor() { + readonly projectAccessKey?: string + + constructor(projectAccessKey?: string) { this.state = OpenState.CLOSED this._registered = false this._init = InitState.NIL + + this.projectAccessKey = projectAccessKey } get registered(): boolean { @@ -89,9 +93,7 @@ export abstract class BaseProviderTransport implements ProviderTransport { ) } - sendAsync = async (request: JsonRpcRequest, callback: JsonRpcResponseCallback, chainId?: number) => { - // here, we receive the message from the dapp provider call - + async request(request: { method: string; params?: any[]; chainId?: number }): Promise { if (this.state === OpenState.CLOSED) { // flag the wallet to auto-close once user submits input. ie. // prompting to sign a message or transaction @@ -104,24 +106,22 @@ export abstract class BaseProviderTransport implements ProviderTransport { // NOTE: if we're not signed in, then the provider will fail, users must first connect+sign in. // // TODO: how does this behave with a session has expired? - this.openWallet(undefined, { type: 'jsonRpcRequest', method: request.method }, chainId) - - // send message request, await, and then execute callback after receiving the response - try { - if (!this.isOpened()) { - await this.waitUntilOpened() // will throw on timeout - } + this.openWallet(undefined, { type: 'jsonRpcRequest', method: request.method }, request.chainId) - const response = await this.sendMessageRequest({ - idx: nextMessageIdx(), - type: EventType.MESSAGE, - data: request, - chainId: chainId - }) - callback(undefined, response.data) - } catch (err) { - callback(err) + if (!this.isOpened()) { + await this.waitUntilOpened() // will throw on timeout } + + const response = await this.sendMessageRequest({ + idx: nextMessageIdx(), + type: EventType.MESSAGE, + data: request, + chainId: request.chainId, + clientVersion: VERSION, + projectAccessKey: this.projectAccessKey + }) + + return response.data } // handleMessage will handle message received from the remote wallet @@ -142,7 +142,8 @@ export abstract class BaseProviderTransport implements ProviderTransport { data: { sessionId: this._sessionId, nonce: nonce - } + }, + clientVersion: VERSION }) } @@ -228,7 +229,7 @@ export abstract class BaseProviderTransport implements ProviderTransport { this.accountsChangedPayload = { accounts: [] } if (message.data && message.data.length > 0) { this.accountsChangedPayload = { - accounts: [ethers.utils.getAddress(message.data[0])], + accounts: [ethers.getAddress(message.data[0])], origin: message.origin } this.events.emit('accountsChanged', this.accountsChangedPayload.accounts, this.accountsChangedPayload.origin) diff --git a/packages/provider/src/transports/base-wallet-transport.ts b/packages/provider/src/transports/base-wallet-transport.ts index b3a15d46c..36e2fc825 100644 --- a/packages/provider/src/transports/base-wallet-transport.ts +++ b/packages/provider/src/transports/base-wallet-transport.ts @@ -14,13 +14,13 @@ import { import { WalletRequestHandler } from './wallet-request-handler' -import { NetworkConfig, JsonRpcRequest, JsonRpcResponseCallback, findSupportedNetwork } from '@0xsequence/network' +import { NetworkConfig, findSupportedNetwork } from '@0xsequence/network' import { logger, sanitizeAlphanumeric, sanitizeHost, sanitizeNumberString } from '@0xsequence/utils' import { AuthorizationOptions } from '@0xsequence/auth' import { PROVIDER_OPEN_TIMEOUT } from './base-provider-transport' import { isBrowserExtension, useBestStore } from '../utils' -import { commons } from '@0xsequence/core' +import { VERSION, commons } from '@0xsequence/core' const TRANSPORT_SESSION_LS_KEY = '@sequence.transportSession' @@ -65,7 +65,7 @@ export abstract class BaseWalletTransport implements WalletTransport { if (!networks || networks.length === 0) { this.notifyChainChanged('0x0') } else { - this.notifyChainChanged(ethers.utils.hexValue(networks.find(network => network.isDefaultChain)!.chainId)) + this.notifyChainChanged(ethers.toQuantity(networks.find(network => network.isDefaultChain)!.chainId)) } }) @@ -96,7 +96,7 @@ export abstract class BaseWalletTransport implements WalletTransport { throw new Error('abstract method') } - sendAsync = async (request: JsonRpcRequest, callback: JsonRpcResponseCallback, chainId?: number) => { + request(request: { method: string; params?: any[]; chainId?: number }): Promise { throw new Error('abstract method') } @@ -181,7 +181,8 @@ export abstract class BaseWalletTransport implements WalletTransport { sessionId, session, error - } + }, + clientVersion: VERSION }) } @@ -189,7 +190,8 @@ export abstract class BaseWalletTransport implements WalletTransport { this.sendMessage({ idx: -1, type: EventType.CLOSE, - data: error ? { error } : null + data: error ? { error } : null, + clientVersion: VERSION }) } @@ -197,7 +199,8 @@ export abstract class BaseWalletTransport implements WalletTransport { this.sendMessage({ idx: -1, type: EventType.CONNECT, - data: connectDetails + data: connectDetails, + clientVersion: VERSION }) } @@ -206,7 +209,8 @@ export abstract class BaseWalletTransport implements WalletTransport { idx: -1, type: EventType.DISCONNECT, data: error ? { error } : null, - origin + origin, + clientVersion: VERSION }) } @@ -215,7 +219,8 @@ export abstract class BaseWalletTransport implements WalletTransport { idx: -1, type: EventType.ACCOUNTS_CHANGED, data: accounts, - origin + origin, + clientVersion: VERSION }) } @@ -224,7 +229,8 @@ export abstract class BaseWalletTransport implements WalletTransport { idx: -1, type: EventType.CHAIN_CHANGED, data: chainIdHex, - origin + origin, + clientVersion: VERSION }) } @@ -232,7 +238,8 @@ export abstract class BaseWalletTransport implements WalletTransport { this.sendMessage({ idx: -1, type: EventType.NETWORKS, - data: networks + data: networks, + clientVersion: VERSION }) } @@ -240,7 +247,8 @@ export abstract class BaseWalletTransport implements WalletTransport { this.sendMessage({ idx: -1, type: EventType.WALLET_CONTEXT, - data: walletContext + data: walletContext, + clientVersion: VERSION }) } @@ -309,7 +317,8 @@ export abstract class BaseWalletTransport implements WalletTransport { this.sendMessage({ idx: -1, type: EventType.INIT, - data: { nonce: this._initNonce } + data: { nonce: this._initNonce }, + clientVersion: VERSION }) this._init = InitState.SENT_NONCE diff --git a/packages/provider/src/transports/mux-transport/mux-message-provider.ts b/packages/provider/src/transports/mux-transport/mux-message-provider.ts index 109181aba..e9b43e8d7 100644 --- a/packages/provider/src/transports/mux-transport/mux-message-provider.ts +++ b/packages/provider/src/transports/mux-transport/mux-message-provider.ts @@ -9,12 +9,12 @@ import { ConnectDetails } from '../../types' -import { JsonRpcRequest, JsonRpcResponseCallback } from '@0xsequence/network' import { ProxyMessageChannelPort, ProxyMessageProvider } from '../proxy-transport' import { Runtime } from 'webextension-polyfill' import { UnrealMessageProvider } from '../unreal-transport' import { ExtensionMessageProvider } from '../extension-transport' import { WindowMessageProvider } from '../window-transport' +import { JsonRpcResponse } from '@0xsequence/network' export type MuxTransportTemplate = { walletAppURL?: string @@ -62,16 +62,16 @@ export class MuxMessageProvider implements ProviderTransport { private messageProviders: ProviderTransport[] private provider: ProviderTransport | undefined - constructor(...messageProviders: ProviderTransport[]) { + constructor(messageProviders: ProviderTransport[] = []) { this.messageProviders = messageProviders this.provider = undefined } - static new(template: MuxTransportTemplate): MuxMessageProvider { + static new(template: MuxTransportTemplate, projectAccessKey?: string): MuxMessageProvider { const muxMessageProvider = new MuxMessageProvider() if (template.windowTransport?.enabled && typeof window === 'object' && template.walletAppURL) { - const windowMessageProvider = new WindowMessageProvider(template.walletAppURL) + const windowMessageProvider = new WindowMessageProvider(template.walletAppURL, projectAccessKey) muxMessageProvider.add(windowMessageProvider) } @@ -198,12 +198,11 @@ export class MuxMessageProvider implements ProviderTransport { return true } - sendAsync = async (request: JsonRpcRequest, callback: JsonRpcResponseCallback, chainId?: number) => { - if (this.provider) { - this.provider.sendAsync(request, callback, chainId) - return + request(request: { method: string; params?: any[]; chainId?: number }): Promise { + if (!this.provider) { + throw new Error('impossible state, wallet must be opened first') } - throw new Error('impossible state, wallet must be opened first') + return this.provider.request(request) } sendMessage(message: ProviderMessage) { diff --git a/packages/provider/src/transports/proxy-transport/proxy-message-provider.ts b/packages/provider/src/transports/proxy-transport/proxy-message-provider.ts index b5d817c78..c69d7c8e8 100644 --- a/packages/provider/src/transports/proxy-transport/proxy-message-provider.ts +++ b/packages/provider/src/transports/proxy-transport/proxy-message-provider.ts @@ -3,6 +3,7 @@ import { BaseProviderTransport } from '../base-provider-transport' import { ProviderMessage, OpenState, OpenWalletIntent, EventType, InitState } from '../../types' import { ProxyMessageChannelPort, ProxyEventTypes } from './proxy-message-channel' +import { VERSION } from '@0xsequence/core' export class ProxyMessageProvider extends BaseProviderTransport { private port: ProxyMessageChannelPort @@ -62,7 +63,8 @@ export class ProxyMessageProvider extends BaseProviderTransport { intent, networkId, sessionId - } + }, + clientVersion: VERSION }) } } @@ -71,7 +73,8 @@ export class ProxyMessageProvider extends BaseProviderTransport { this.sendMessage({ idx: -1, type: EventType.CLOSE, - data: null + data: null, + clientVersion: VERSION }) this.close() } diff --git a/packages/provider/src/transports/unreal-transport/overridelogs.ts b/packages/provider/src/transports/unreal-transport/overridelogs.ts index 5148d9389..40676823f 100644 --- a/packages/provider/src/transports/unreal-transport/overridelogs.ts +++ b/packages/provider/src/transports/unreal-transport/overridelogs.ts @@ -1,3 +1,5 @@ +import { bigintReplacer } from '@0xsequence/utils' + interface UnrealInjectedWindow { ue?: { sequencewallettransport?: { @@ -30,5 +32,7 @@ export function overrideLogs(side: 'dapp' | 'wallet') { } function stringify(things: unknown[]): string { - return things.map(a => (typeof a === 'object' ? (a instanceof Error ? a.message : JSON.stringify(a)) : String(a))).join(' ') + return things + .map(a => (typeof a === 'object' ? (a instanceof Error ? a.message : JSON.stringify(a, bigintReplacer)) : String(a))) + .join(' ') } diff --git a/packages/provider/src/transports/unreal-transport/unreal-message-handler.ts b/packages/provider/src/transports/unreal-transport/unreal-message-handler.ts index 8358d6c6c..9d74c72ed 100644 --- a/packages/provider/src/transports/unreal-transport/unreal-message-handler.ts +++ b/packages/provider/src/transports/unreal-transport/unreal-message-handler.ts @@ -10,7 +10,7 @@ import { } from '../../types' import { WalletRequestHandler } from '../wallet-request-handler' import { BaseWalletTransport } from '../base-wallet-transport' -import { logger, base64DecodeObject } from '@0xsequence/utils' +import { logger, base64DecodeObject, bigintReplacer } from '@0xsequence/utils' import { overrideLogs } from './overridelogs' // all lowercase is an annoying limitation of Unreal CEF BindUObject @@ -104,7 +104,7 @@ export class UnrealMessageHandler extends BaseWalletTransport { return } // prepare payload - const payload = JSON.stringify(message) + const payload = JSON.stringify(message, bigintReplacer) // post-message to app. window.ue?.sequencewallettransport?.sendmessagetosequencejs(payload) diff --git a/packages/provider/src/transports/unreal-transport/unreal-message-provider.ts b/packages/provider/src/transports/unreal-transport/unreal-message-provider.ts index 8b1908589..3b1170e07 100644 --- a/packages/provider/src/transports/unreal-transport/unreal-message-provider.ts +++ b/packages/provider/src/transports/unreal-transport/unreal-message-provider.ts @@ -1,6 +1,6 @@ import { OpenWalletIntent, ProviderMessage, InitState, WindowSessionParams } from '../../types' import { BaseProviderTransport } from '../base-provider-transport' -import { base64EncodeObject } from '@0xsequence/utils' +import { base64EncodeObject, bigintReplacer } from '@0xsequence/utils' import { overrideLogs } from './overridelogs' let registeredUnrealMessageProvider: UnrealMessageProvider | undefined @@ -114,7 +114,7 @@ export class UnrealMessageProvider extends BaseProviderTransport { // all lowercase is an annoying limitation of Unreal CEF BindUObject sendMessage(message: ProviderMessage) { - const postedMessage = typeof message !== 'string' ? JSON.stringify(message) : message + const postedMessage = typeof message !== 'string' ? JSON.stringify(message, bigintReplacer) : message console.log('Sending message to wallet:', postedMessage) window.ue?.sequencewallettransport?.sendmessagetowallet(postedMessage) } diff --git a/packages/provider/src/transports/wallet-request-handler.ts b/packages/provider/src/transports/wallet-request-handler.ts index 98dbf3cf3..911e9c089 100644 --- a/packages/provider/src/transports/wallet-request-handler.ts +++ b/packages/provider/src/transports/wallet-request-handler.ts @@ -6,14 +6,12 @@ import { ChainIdLike, findNetworkConfig, findSupportedNetwork, - JsonRpcHandler, - JsonRpcRequest, - JsonRpcResponse, - JsonRpcResponseCallback, - NetworkConfig + NetworkConfig, + EIP1193Provider, + JsonRpcResponse } from '@0xsequence/network' -import { logger, TypedData } from '@0xsequence/utils' -import { BigNumber, ethers, providers } from 'ethers' +import { logger, toHexString, TypedData } from '@0xsequence/utils' +import { ethers } from 'ethers' import { EventEmitter2 as EventEmitter } from 'eventemitter2' import { fromExtended } from '../extended' @@ -36,8 +34,6 @@ import { } from '../types' import { prefixEIP191Message } from '../utils' -type ExternalProvider = providers.ExternalProvider - const SIGNER_READY_TIMEOUT = 10000 export interface WalletSignInOptions { @@ -45,7 +41,7 @@ export interface WalletSignInOptions { defaultNetworkId?: number } -export class WalletRequestHandler implements ExternalProvider, JsonRpcHandler, ProviderMessageRequestHandler { +export class WalletRequestHandler implements EIP1193Provider, ProviderMessageRequestHandler { // signer interface of the wallet. A null value means there is no signer (ie. user not signed in). An undefined // value means the signer state is unknown, usually meaning the wallet app is booting up and initializing. Of course // a Signer value is the actually interface to a signed-in account @@ -154,7 +150,7 @@ export class WalletRequestHandler implements ExternalProvider, JsonRpcHandler, P const connectDetails: ConnectDetails = { connected: true, - chainId: ethers.utils.hexValue(chainId) + chainId: ethers.toQuantity(chainId) } if (options && options.authorize) { @@ -215,35 +211,45 @@ export class WalletRequestHandler implements ExternalProvider, JsonRpcHandler, P // sendMessageRequest will unwrap the ProviderMessageRequest and send it to the JsonRpcHandler // (aka, the signer in this instance) and then responds with a wrapped response of // ProviderMessageResponse to be sent over the transport - sendMessageRequest(message: ProviderMessageRequest): Promise { - return new Promise(resolve => { - this.sendAsync( - message.data, - (error: any, response?: JsonRpcResponse) => { - // TODO: if response includes data.error, why do we need a separate error argument here? - - const responseMessage: ProviderMessageResponse = { - ...message, - data: response! - } + async sendMessageRequest(message: ProviderMessageRequest): Promise { + // Older versions of the client require the response to be jsonrpc wrapped + const majorVersion = Number(message.clientVersion?.split('.')[0] || '0') + const isJsonRpcResponse = majorVersion < 2 + const jsonRpcResponse: JsonRpcResponse = { + id: message.data.id!, + jsonrpc: '2.0', + result: null, + error: undefined + } - // NOTE: we always resolve here, are the sendAsync call will wrap any exceptions - // in the error field of the response to ensure we send back to the user - resolve(responseMessage) - }, - message.chainId - ) - }) - } + try { + const result = await this.request({ + method: message.data.method, + params: message.data.params, + chainId: message.chainId, + origin: message.origin, + projectAccessKey: message.projectAccessKey + }) - // sendAsync implements the JsonRpcHandler interface for sending JsonRpcRequests to the wallet - sendAsync = async (request: JsonRpcRequest, callback: JsonRpcResponseCallback, chainId?: number) => { - const response: JsonRpcResponse = { - jsonrpc: '2.0', - id: request.id!, - result: null + return { + ...message, + data: isJsonRpcResponse ? { ...jsonRpcResponse, result } : result + } + } catch (error) { + return { + ...message, + data: isJsonRpcResponse ? { ...jsonRpcResponse, error } : { error } + } } + } + async request(request: { + method: string + params?: any[] + chainId?: number + origin?: string + projectAccessKey?: string + }): Promise { await this.getAccount() try { @@ -255,12 +261,22 @@ export class WalletRequestHandler implements ExternalProvider, JsonRpcHandler, P // wallet account const account = this.account - if (!account) throw new Error('WalletRequestHandler: wallet account is not configured') + if (!account) { + throw new Error('WalletRequestHandler: wallet account is not configured') + } // fetch the provider for the specific chain, or undefined will select defaultChain - const provider = this.account?.providerFor(chainId ?? this.defaultChainId()) - if (!provider) throw new Error(`WalletRequestHandler: wallet provider is not configured for chainId ${chainId}`) - const jsonRpcProvider = provider instanceof ethers.providers.JsonRpcProvider ? provider : undefined + const provider = this.account?.providerFor(request.chainId ?? this.defaultChainId()) + if (!provider) { + throw new Error(`WalletRequestHandler: wallet provider is not configured for chainId ${request.chainId}`) + } + + // NOTE: we cannot use `instanceof ethers.JsonRpcProvider` because despite that we know + // its the proper type, its not resolving properly at runtime during the pupeteer e2e tests. + // Switching to the type guard function below is safer and more reliable. + // + // const jsonRpcProvider = provider instanceof ethers.JsonRpcProvider ? provider : undefined + const jsonRpcProvider = isJsonRpcProvider(provider) ? provider : undefined switch (request.method) { case 'net_version': { @@ -268,9 +284,7 @@ export class WalletRequestHandler implements ExternalProvider, JsonRpcHandler, P throw new Error(`Account provider doesn't support send method`) } - const result = await jsonRpcProvider.send('net_version', []) - response.result = result - break + return await jsonRpcProvider.send('net_version', []) } case 'eth_chainId': { @@ -278,22 +292,17 @@ export class WalletRequestHandler implements ExternalProvider, JsonRpcHandler, P throw new Error(`Account provider doesn't support send method`) } - const result = await jsonRpcProvider.send('eth_chainId', []) - response.result = result - break + return await jsonRpcProvider.send('eth_chainId', []) } case 'eth_accounts': { - const walletAddress = account.address - response.result = [walletAddress] - break + return [account.address] } case 'eth_getBalance': { const [accountAddress, blockTag] = request.params! const walletBalance = await provider.getBalance(accountAddress, blockTag) - response.result = walletBalance.toHexString() - break + return toHexString(walletBalance) } case 'sequence_sign': @@ -328,31 +337,32 @@ export class WalletRequestHandler implements ExternalProvider, JsonRpcHandler, P // TODO: // if (process.env.TEST_MODE === 'true' && this.prompter === null) { const sequenceVerified = request.method === 'sequence_sign' + if (this.prompter === null) { // prompter is null, so we'll sign from here sig = await account.signMessage( prefixedMessage, - chainId ?? this.defaultChainId(), + request.chainId ?? this.defaultChainId(), sequenceVerified ? 'eip6492' : 'ignore' ) } else { sig = await this.prompter.promptSignMessage( { - chainId: chainId, - message: prefixedMessage, + chainId: request.chainId, + message: ethers.getBytes(prefixedMessage), eip6492: sequenceVerified }, - this.connectOptions + request.origin, + request.projectAccessKey ) } if (sig && sig.length > 0) { - response.result = sig + return sig } else { // The user has declined the request when value is null throw new Error('declined by user') } - break } case 'sequence_signTypedData_v4': @@ -386,27 +396,27 @@ export class WalletRequestHandler implements ExternalProvider, JsonRpcHandler, P typedData.domain, typedData.types, typedData.message, - chainId ?? this.defaultChainId(), + request.chainId ?? this.defaultChainId(), sequenceVerified ? 'eip6492' : 'ignore' ) } else { sig = await this.prompter.promptSignMessage( { - chainId: chainId, + chainId: request.chainId, typedData: typedData, eip6492: sequenceVerified }, - this.connectOptions + request.origin, + request.projectAccessKey ) } if (sig && sig.length > 0) { - response.result = sig + return sig } else { // The user has declined the request when value is null throw new Error('declined by user') } - break } case 'eth_sendTransaction': { @@ -427,26 +437,30 @@ export class WalletRequestHandler implements ExternalProvider, JsonRpcHandler, P let txnHash = '' if (this.prompter === null) { // prompter is null, so we'll send from here - const txnResponse = await account.sendTransaction(transactionParams, chainId ?? this.defaultChainId()) + const txnResponse = await account.sendTransaction(transactionParams, request.chainId ?? this.defaultChainId()) txnHash = txnResponse?.hash ?? '' } else { // prompt user to provide the response - txnHash = await this.prompter.promptSendTransaction(transactionParams, chainId, this.connectOptions) + txnHash = await this.prompter.promptSendTransaction( + transactionParams, + request.chainId, + request.origin, + request.projectAccessKey + ) } if (txnHash) { - response.result = txnHash + return txnHash } else { // The user has declined the request when value is null throw new Error('declined by user') } - break } case 'eth_signTransaction': { // https://eth.wiki/json-rpc/API#eth_signTransaction const [transaction] = request.params! - const sender = ethers.utils.getAddress(transaction.from) + const sender = ethers.getAddress(transaction.from) if (sender !== account.address) { throw new Error('sender address does not match wallet') @@ -460,12 +474,15 @@ export class WalletRequestHandler implements ExternalProvider, JsonRpcHandler, P // // TODO: verify serializing / transporting the SignedTransaction object works as expected, most likely however // we will want to resolveProperties the big number values to hex strings - response.result = await account.signTransactions(transaction, chainId ?? this.defaultChainId()) + return await account.signTransactions(transaction, request.chainId ?? this.defaultChainId()) } else { - response.result = await this.prompter.promptSignTransaction(transaction, chainId, this.connectOptions) + return await this.prompter.promptSignTransaction( + transaction, + request.chainId, + request.origin, + request.projectAccessKey + ) } - - break } case 'eth_sendRawTransaction': { @@ -474,71 +491,60 @@ export class WalletRequestHandler implements ExternalProvider, JsonRpcHandler, P // https://eth.wiki/json-rpc/API#eth_sendRawTransaction if (commons.transaction.isSignedTransactionBundle(request.params![0])) { - const txChainId = BigNumber.from(request.params![0].chainId).toNumber() + const txChainId = Number(request.params![0].chainId) const tx = await account.relayer(txChainId)!.relay(request.params![0]) - response.result = tx.hash + return tx.hash } else { - const tx = await provider.sendTransaction(request.params![0]) - response.result = tx.hash + const tx = await provider.broadcastTransaction(request.params![0]) + return tx.hash } - break } case 'eth_getTransactionCount': { - const address = ethers.utils.getAddress(request.params![0] as string) + const address = ethers.getAddress(request.params![0] as string) const tag = request.params![1] // TODO: Maybe we should fetch this data from the relayer or from the reader // but for now we keep it simple and just use the provider const count = await provider.getTransactionCount(address, tag) - response.result = ethers.BigNumber.from(count).toHexString() - - break + return toHexString(BigInt(count)) } case 'eth_blockNumber': { - response.result = await provider.getBlockNumber() - break + return await provider.getBlockNumber() } case 'eth_getBlockByNumber': { - response.result = await provider.getBlock(request.params![0] /* , jsonRpcRequest.params[1] */) - break + return await provider.getBlock(request.params![0] /* , jsonRpcRequest.params[1] */) } case 'eth_getBlockByHash': { - response.result = await provider.getBlock(request.params![0] /* , jsonRpcRequest.params[1] */) - break + return await provider.getBlock(request.params![0] /* , jsonRpcRequest.params[1] */) } case 'eth_getTransactionByHash': { - response.result = await provider.getTransaction(request.params![0]) - break + return await provider.getTransaction(request.params![0]) } case 'eth_call': { const [transactionObject, blockTag] = request.params! - response.result = await provider.call(transactionObject, blockTag) - break + return await provider.call({ ...transactionObject, blockTag }) } case 'eth_getCode': { const [contractAddress, blockTag] = request.params! - response.result = await provider.getCode(contractAddress, blockTag) - break + return await provider.getCode(contractAddress, blockTag) } case 'eth_estimateGas': { const [transactionObject] = request.params! - response.result = await provider.estimateGas(transactionObject) - break + return await provider.estimateGas(transactionObject) } case 'eth_gasPrice': { - const gasPrice = await provider.getGasPrice() - response.result = gasPrice.toHexString() - break + const feeData = await provider.getFeeData() + return feeData.gasPrice === null ? null : toHexString(feeData.gasPrice) } case 'wallet_switchEthereumChain': { @@ -547,34 +553,31 @@ export class WalletRequestHandler implements ExternalProvider, JsonRpcHandler, P throw new Error('invalid chainId') } - const chainId = ethers.BigNumber.from(switchParams.chainId) + const chainId = BigInt(switchParams.chainId) - this.setDefaultChainId(chainId.toNumber()) + this.setDefaultChainId(Number(chainId)) - response.result = null // success - break + return null // success } // smart wallet method case 'sequence_getWalletContext': { - response.result = account.contexts - break + return account.contexts } // smart wallet method case 'sequence_getWalletConfig': { const [chainId] = request.params! if (chainId) { - response.result = [(await account.status(chainId)).onChain.config] + return [(await account.status(chainId)).onChain.config] } else { - response.result = await Promise.all( + return await Promise.all( account.networks.map(async network => { const status = await account.status(network.chainId) return status.onChain.config }) ) } - break } // smart wallet method @@ -582,16 +585,15 @@ export class WalletRequestHandler implements ExternalProvider, JsonRpcHandler, P const [chainId] = request.params! // TODO: Add getWalletState to the Signer interface if (chainId) { - response.result = [getLegacyWalletState(chainId, await account.status(chainId))] + return [getLegacyWalletState(chainId, await account.status(chainId))] } else { - response.result = await Promise.all( + return await Promise.all( account.networks.map(async network => { const status = await account.status(network.chainId) return getLegacyWalletState(network.chainId, status) }) ) } - break } // smart wallet method @@ -599,13 +601,11 @@ export class WalletRequestHandler implements ExternalProvider, JsonRpcHandler, P // NOTE: must ensure that the response result below returns clean serialized data, which is to omit // the provider and relayer objects and only return the urls so can be reinstantiated on dapp side. // This is handled by this.getNetworks() but noted here for future readers. - response.result = await this.getNetworks(true) - break + return await this.getNetworks(true) } case 'sequence_isSequence': { - response.result = true - break + return true } // smart wallet method @@ -616,14 +616,12 @@ export class WalletRequestHandler implements ExternalProvider, JsonRpcHandler, P // for confirmation. // // const [newConfig] = request.params - // response.result = await signer.updateConfig(newConfig) - break + // return await signer.updateConfig(newConfig) } // smart wallet method case 'sequence_publishConfig': { throw new Error('sequence_publishConfig method is not allowed from a dapp') - break } // relayer method @@ -653,8 +651,7 @@ export class WalletRequestHandler implements ExternalProvider, JsonRpcHandler, P } this.setDefaultChainId(defaultChainId) - response.result = await this.getNetworks(true) - break + return await this.getNetworks(true) } default: { @@ -663,22 +660,13 @@ export class WalletRequestHandler implements ExternalProvider, JsonRpcHandler, P } // NOTE: provider here will be chain-bound if chainId is provided - const providerResponse = await jsonRpcProvider.send(request.method, request.params!) - response.result = providerResponse + return await jsonRpcProvider.send(request.method, request.params!) } } } catch (err) { logger.error(err) - - // See https://github.com/ethereum/EIPs/blob/master/EIPS/eip-1193.md#rpc-errors - response.result = null - response.error = { - ...new Error(err), - code: 4001 - } + throw { message: typeof err == 'string' ? err : err?.message || 'unkown error', code: 4001 } as ProviderRpcError } - - callback(undefined, response) } on(event: K, fn: ProviderEventTypes[K]) { @@ -707,7 +695,6 @@ export class WalletRequestHandler implements ExternalProvider, JsonRpcHandler, P setConnectOptions(options: ConnectOptions | undefined) { this._connectOptions = options - this.onConnectOptionsChange?.(options) } @@ -776,7 +763,7 @@ export class WalletRequestHandler implements ExternalProvider, JsonRpcHandler, P } notifyChainChanged(chainId: number, origin?: string) { - this.events.emit('chainChanged', ethers.utils.hexValue(chainId), origin) + this.events.emit('chainChanged', ethers.toQuantity(chainId), origin) } async notifyNetworks(networks?: NetworkConfig[]) { @@ -785,7 +772,7 @@ export class WalletRequestHandler implements ExternalProvider, JsonRpcHandler, P if (n.length > 0) { const defaultNetwork = n.find(network => network.chainId === this.defaultChainId()) if (defaultNetwork) { - this.events.emit('chainChanged', ethers.utils.hexValue(defaultNetwork.chainId)) + this.events.emit('chainChanged', ethers.toQuantity(defaultNetwork.chainId)) } } else { this.events.emit('chainChanged', '0x0') @@ -833,7 +820,8 @@ export class WalletRequestHandler implements ExternalProvider, JsonRpcHandler, P prompter: WalletUserPrompter, account: Account, sequenceVerified: boolean, - chainId?: number + chainId?: number, + origin?: string ): Promise { // check if wallet is deployed and up to date, if not, prompt user to deploy // if no chainId is provided, we'll assume the wallet is auth chain wallet and is up to date @@ -850,7 +838,7 @@ export class WalletRequestHandler implements ExternalProvider, JsonRpcHandler, P return true } - const promptResult = await prompter.promptConfirmWalletDeploy(chainId, this.connectOptions) + const promptResult = await prompter.promptConfirmWalletDeploy(chainId, origin) // if client returned true, check again to make sure wallet is deployed and up to date if (promptResult) { @@ -870,15 +858,22 @@ export class WalletRequestHandler implements ExternalProvider, JsonRpcHandler, P export interface WalletUserPrompter { getDefaultChainId(): number - - promptConnect(options?: ConnectOptions): Promise - promptSignInConnect(options?: ConnectOptions): Promise - - promptSignMessage(message: MessageToSign, options?: ConnectOptions): Promise - promptSignTransaction(txn: commons.transaction.Transactionish, chainId?: number, options?: ConnectOptions): Promise - promptSendTransaction(txn: commons.transaction.Transactionish, chainId?: number, options?: ConnectOptions): Promise - promptConfirmWalletDeploy(chainId: number, options?: ConnectOptions): Promise - + promptConnect(connectOptions?: ConnectOptions): Promise + promptSignInConnect(connectOptions?: ConnectOptions): Promise + promptSignMessage(message: MessageToSign, origin?: string, projectAccessKey?: string): Promise + promptSignTransaction( + txn: commons.transaction.Transactionish, + chainId?: number, + origin?: string, + projectAccessKey?: string + ): Promise + promptSendTransaction( + txn: commons.transaction.Transactionish, + chainId?: number, + origin?: string, + projectAccessKey?: string + ): Promise + promptConfirmWalletDeploy(chainId: number, origin?: string): Promise promptChangeNetwork(chainId: number): Promise } @@ -938,3 +933,9 @@ const permittedJsonRpcMethods = [ 'sequence_getNetworks', 'sequence_setDefaultNetwork' ] + +function isJsonRpcProvider(provider: any): provider is ethers.JsonRpcProvider { + return ( + provider && typeof provider === 'object' && typeof provider.send === 'function' && typeof provider.getNetwork === 'function' + ) +} diff --git a/packages/provider/src/transports/window-transport/window-message-handler.ts b/packages/provider/src/transports/window-transport/window-message-handler.ts index 18a268f3f..dd7bf38f9 100644 --- a/packages/provider/src/transports/window-transport/window-message-handler.ts +++ b/packages/provider/src/transports/window-transport/window-message-handler.ts @@ -10,7 +10,8 @@ import { } from '../../types' import { WalletRequestHandler } from '../wallet-request-handler' import { BaseWalletTransport } from '../base-wallet-transport' -import { logger, sanitizeNumberString, base64DecodeObject } from '@0xsequence/utils' +import { logger, base64DecodeObject, bigintReviver, bigintReplacer } from '@0xsequence/utils' +import { ethers } from 'ethers' export class WindowMessageHandler extends BaseWalletTransport { protected parentWindow: Window @@ -30,7 +31,7 @@ export class WindowMessageHandler extends BaseWalletTransport { } // record open details (sessionId + default network) from the window url - const { pathname, search: rawParams } = new URL(windowHref || window.location.href) + const { search: rawParams } = new URL(windowHref || window.location.href) let session: TransportSession | null = this.getWindowTransportSession(rawParams) @@ -92,12 +93,15 @@ export class WindowMessageHandler extends BaseWalletTransport { // Wallet always expects json-rpc request messages from a dapp let request: ProviderMessageRequest try { - request = JSON.parse(event.data) + request = JSON.parse(event.data, bigintReviver) } catch (err) { // event is not a ProviderMessage JSON object, skip return } + // Set the origin on the request + request.origin ??= event.origin + logger.debug('RECEIVED MESSAGE', request) // Record event origin for valid init ack @@ -117,7 +121,7 @@ export class WindowMessageHandler extends BaseWalletTransport { // postMessage sends message to the dapp window sendMessage(message: ProviderMessage) { // prepare payload - const payload = JSON.stringify(message) + const payload = JSON.stringify(message, bigintReplacer) // post-message to app. // only for init requests, we send to '*' origin diff --git a/packages/provider/src/transports/window-transport/window-message-provider.ts b/packages/provider/src/transports/window-transport/window-message-provider.ts index 5256214d1..17923bfb0 100644 --- a/packages/provider/src/transports/window-transport/window-message-provider.ts +++ b/packages/provider/src/transports/window-transport/window-message-provider.ts @@ -1,6 +1,6 @@ -import { OpenWalletIntent, ProviderMessage, InitState, EventType, WindowSessionParams } from '../../types' +import { OpenWalletIntent, ProviderMessage, InitState, WindowSessionParams } from '../../types' import { BaseProviderTransport } from '../base-provider-transport' -import { logger, base64EncodeObject } from '@0xsequence/utils' +import { logger, base64EncodeObject, bigintReplacer, bigintReviver } from '@0xsequence/utils' import { isBrowserExtension, isUnityPlugin } from '../../utils' // .. @@ -10,8 +10,8 @@ export class WindowMessageProvider extends BaseProviderTransport { private walletURL: URL private walletWindow: Window | null - constructor(walletAppURL: string) { - super() + constructor(walletAppURL: string, projectAccessKey?: string) { + super(projectAccessKey) this.walletURL = new URL(walletAppURL) } @@ -172,7 +172,7 @@ export class WindowMessageProvider extends BaseProviderTransport { let message: ProviderMessage try { - message = JSON.parse(event.data) + message = JSON.parse(event.data, bigintReviver) } catch (err) { // event is not a ProviderMessage JSON object, skip return @@ -191,7 +191,7 @@ export class WindowMessageProvider extends BaseProviderTransport { logger.warn('WindowMessageProvider: sendMessage failed as walletWindow is unavailable') return } - const postedMessage = typeof message !== 'string' ? JSON.stringify(message) : message + const postedMessage = typeof message !== 'string' ? JSON.stringify(message, bigintReplacer) : message this.walletWindow.postMessage(postedMessage, this.walletURL.origin) } } diff --git a/packages/provider/src/types.ts b/packages/provider/src/types.ts index 60bfb26da..eca311c16 100644 --- a/packages/provider/src/types.ts +++ b/packages/provider/src/types.ts @@ -2,15 +2,15 @@ import { ETHAuthProof as AuthETHAuthProof } from '@0xsequence/auth' import { commons } from '@0xsequence/core' import { ChainIdLike, - JsonRpcHandler, + EIP1193Provider, JsonRpcRequest, JsonRpcResponse, NetworkConfig, - ProviderRpcError as NetworkProviderRpcError + JsonRpcErrorPayload } from '@0xsequence/network' import { TypedData } from '@0xsequence/utils' -export interface ProviderTransport extends JsonRpcHandler, ProviderMessageTransport, ProviderMessageRequestHandler { +export interface ProviderTransport extends EIP1193Provider, ProviderMessageTransport, ProviderMessageRequestHandler { register(): void unregister(): void @@ -42,7 +42,7 @@ export function isProviderTransport(transport: any): transport is ProviderTransp ) } -export interface WalletTransport extends JsonRpcHandler, ProviderMessageTransport, ProviderMessageRequestHandler { +export interface WalletTransport extends EIP1193Provider, ProviderMessageTransport, ProviderMessageRequestHandler { register(): void unregister(): void @@ -61,18 +61,21 @@ export interface ProviderMessage { data: T // the ethereum json-rpc payload chainId?: number // chain id which the message is intended origin?: string // origin of the message + clientVersion: string // client version of the message + projectAccessKey?: string // project access key } export type ProviderMessageRequest = ProviderMessage -export type ProviderMessageResponse = ProviderMessage +// Older versions of sequence.js will require a JsonRpcResponse result type, but newer versions use raw EIP1193 results +export type ProviderMessageResponse = ProviderMessage // ProviderMessageCallback is used to respond to ProviderMessage requests. The error // argument is for exceptions during the execution, and response is the response payload // which may contain the result or an error payload from the wallet. export type ProviderMessageResponseCallback = (error?: ProviderRpcError, response?: ProviderMessageResponse) => void -export type ProviderRpcError = NetworkProviderRpcError +export type ProviderRpcError = JsonRpcErrorPayload export interface ProviderMessageRequestHandler { // sendMessageRequest sends a ProviderMessageRequest over the wire to the wallet. @@ -350,6 +353,8 @@ export interface TypedEventEmitter { emit(event: E, ...args: Arguments): boolean eventNames(): (keyof Events | string | symbol)[] + + // eslint-disable-next-line listeners(event: E): Function[] listenerCount(event: E): number } @@ -373,8 +378,3 @@ export type OptionalEIP6492 = eip6492?: boolean } | undefined - -// This is required by viem, it expects a provider to have an EIP-1193 compliant `request` attribute. -export interface EIP1193Provider { - request: (request: { method: string; params?: Array }) => Promise -} diff --git a/packages/provider/src/utils.ts b/packages/provider/src/utils.ts index 615ba0215..d1d67c7b8 100644 --- a/packages/provider/src/utils.ts +++ b/packages/provider/src/utils.ts @@ -1,25 +1,25 @@ -import { ethers, BytesLike } from 'ethers' +import { ethers } from 'ethers' import { messageIsExemptFromEIP191Prefix } from './eip191exceptions' import { AccountStatus } from '@0xsequence/account' import { commons } from '@0xsequence/core' import { encodeMessageDigest, TypedData, encodeTypedDataDigest } from '@0xsequence/utils' -const eip191prefix = ethers.utils.toUtf8Bytes('\x19Ethereum Signed Message:\n') +const eip191prefix = ethers.toUtf8Bytes('\x19Ethereum Signed Message:\n') -export const messageToBytes = (message: BytesLike): Uint8Array => { - if (ethers.utils.isBytesLike(message)) { - return ethers.utils.arrayify(message) +export const messageToBytes = (message: ethers.BytesLike): Uint8Array => { + if (ethers.isBytesLike(message)) { + return ethers.getBytes(message) } - return ethers.utils.toUtf8Bytes(message) + return ethers.toUtf8Bytes(message) } -export const prefixEIP191Message = (message: BytesLike): Uint8Array => { +export const prefixEIP191Message = (message: ethers.BytesLike): Uint8Array => { const messageBytes = messageToBytes(message) if (messageIsExemptFromEIP191Prefix(messageBytes)) { return messageBytes } else { - return ethers.utils.concat([eip191prefix, ethers.utils.toUtf8Bytes(String(messageBytes.length)), messageBytes]) + return ethers.getBytes(ethers.concat([eip191prefix, ethers.toUtf8Bytes(String(messageBytes.length)), messageBytes])) } } @@ -47,9 +47,9 @@ export const trimEIP191Prefix = (prefixedMessage: Uint8Array): Uint8Array => { let prefixAsNumber: number try { - prefixAsNumber = Number(ethers.utils.toUtf8String(ethereumSignedMessagePartSlicedArray.slice(0, maxPrefixCharLength))) + prefixAsNumber = Number(ethers.toUtf8String(ethereumSignedMessagePartSlicedArray.slice(0, maxPrefixCharLength))) } catch { - prefixAsNumber = Number(ethers.utils.hexlify(ethereumSignedMessagePartSlicedArray.slice(0, maxPrefixCharLength))) + prefixAsNumber = Number(ethers.hexlify(ethereumSignedMessagePartSlicedArray.slice(0, maxPrefixCharLength))) } if (prefixAsNumber > ethereumSignedMessagePartSlicedArray.length || !Number.isInteger(prefixAsNumber)) { @@ -67,7 +67,7 @@ export const isValidSignature = async ( address: string, digest: Uint8Array, sig: string, - provider: ethers.providers.Provider + provider: ethers.Provider ): Promise => { const reader = new commons.reader.OnChainReader(provider) return reader.isValidSignature(address, digest, sig) @@ -78,7 +78,7 @@ export const isValidMessageSignature = async ( address: string, message: string | Uint8Array, signature: string, - provider: ethers.providers.Provider + provider: ethers.Provider ): Promise => { const prefixed = prefixEIP191Message(message) const digest = encodeMessageDigest(prefixed) @@ -90,7 +90,7 @@ export const isValidTypedDataSignature = ( address: string, typedData: TypedData, signature: string, - provider: ethers.providers.Provider + provider: ethers.Provider ): Promise => { return isValidSignature(address, encodeTypedDataDigest(typedData), signature, provider) } @@ -200,13 +200,11 @@ export function useBestStore(): ItemStore { return new MemoryItemStore() } -export async function resolveArrayProperties( - object: Readonly> | Readonly>[] -): Promise { +export async function resolveArrayProperties(object: Readonly | Readonly[]): Promise { if (Array.isArray(object)) { // T must include array type - return Promise.all(object.map(o => ethers.utils.resolveProperties(o))) as any + return Promise.all(object.map(o => ethers.resolveProperties(o))) as any } - return ethers.utils.resolveProperties(object) + return ethers.resolveProperties(object) } diff --git a/packages/provider/src/utils/index.ts b/packages/provider/src/utils/index.ts index 73105a5d3..256dbadbb 100644 --- a/packages/provider/src/utils/index.ts +++ b/packages/provider/src/utils/index.ts @@ -1,4 +1,4 @@ -import { BytesLike, TypedDataDomain, TypedDataField } from 'ethers' +import { ethers } from 'ethers' import { ChainIdLike } from '@0xsequence/network' import { encodeMessageDigest, TypedData, encodeTypedDataDigest } from '@0xsequence/utils' import { isValidSignature, prefixEIP191Message } from '../utils' @@ -17,14 +17,14 @@ export class WalletUtils { } // Sign message on a specified chain, or DefaultChain by default - signMessage(message: BytesLike, chainId?: ChainIdLike, eip6492?: boolean): Promise { + signMessage(message: ethers.BytesLike, chainId?: ChainIdLike, eip6492?: boolean): Promise { return this.signer.signMessage(message, { chainId, eip6492 }) } // Sign EIP-712 TypedData on a specified chain, or DefaultChain by default signTypedData( - domain: TypedDataDomain, - types: Record>, + domain: ethers.TypedDataDomain, + types: Record>, message: Record, chainId?: ChainIdLike, eip6492?: boolean diff --git a/packages/provider/tests/client.spec.ts b/packages/provider/tests/client.spec.ts index 7f223f62b..94e43467f 100644 --- a/packages/provider/tests/client.spec.ts +++ b/packages/provider/tests/client.spec.ts @@ -10,11 +10,10 @@ import { } from '../src' import { JsonRpcRequest, JsonRpcResponse, JsonRpcResponseCallback, allNetworks } from '@0xsequence/network' import EventEmitter from 'events' -import { commons, v1, v2 } from '@0xsequence/core' +import { commons, v1, v2, VERSION } from '@0xsequence/core' import { ethers } from 'ethers' -import { TypedData } from '@0xsequence/utils' +import { TypedData, parseEther } from '@0xsequence/utils' import { ExtendedTransactionRequest } from '../src/extended' -import packageJson from '../package.json' const basicMockTransport = { on: () => {}, @@ -60,7 +59,7 @@ describe('SequenceClient', () => { } } - client = new SequenceClient(mockTransport as unknown as ProviderTransport, useBestStore(), 1) + client = new SequenceClient(mockTransport as unknown as ProviderTransport, useBestStore()) }) it('shoud emit open event', async () => { @@ -389,7 +388,7 @@ describe('SequenceClient', () => { app: 'This is a test', authorizeVersion: 2, networkId: 2, - clientVersion: packageJson.version, + clientVersion: VERSION, projectAccessKey: undefined } }) @@ -501,22 +500,27 @@ describe('SequenceClient', () => { it('should handle arbitrary send', async () => { let calledSendAsync = 0 - const commands = [ - { chainId: 2, req: { method: 'eth_chainId', params: [] }, res: { result: '0x1' } }, - { chainId: 2, req: { method: 'eth_accounts', params: [] }, res: { result: '0x12345' } }, - { chainId: 5, req: { method: 'eth_sendTransaction', params: [{ to: '0x1234' }] }, res: { result: '0x000' } }, - { chainId: 9, req: { method: 'non-standard', params: [{ a: 23123, b: true }] }, res: { result: '0x99' } } - ] as { chainId: number; req: JsonRpcRequest; res: JsonRpcResponse }[] + const commands: { req: JsonRpcRequest; res: any }[] = [ + { req: { method: 'eth_chainId', params: [], chainId: 2 }, res: '0x1' }, + { req: { method: 'eth_accounts', params: [], chainId: 2 }, res: '0x12345' }, + { req: { method: 'eth_sendTransaction', params: [{ to: '0x1234' }], chainId: 5 }, res: '0x000' }, + { req: { method: 'non-standard', params: [{ a: 23123, b: true }], chainId: 9 }, res: '0x99' } + ] const client = new SequenceClient( { ...basicMockTransport, - sendAsync: (request: JsonRpcRequest, callback: JsonRpcResponseCallback, chainId?: number) => { + request(request: JsonRpcRequest): Promise { calledSendAsync++ const command = commands.shift() + + if (!request.chainId) { + request.chainId = client.getChainId() + } + expect(request).to.deep.equal(command?.req) - expect(chainId).to.equal(command?.chainId) - callback(undefined, command?.res) + + return Promise.resolve(command?.res) } }, useBestStore(), @@ -527,24 +531,25 @@ describe('SequenceClient', () => { expect(calledSendAsync).to.equal(0) - const result1 = await client.send({ method: 'eth_chainId', params: [] }) - expect(result1).to.deep.equal('0x1') + const result1 = await client.request({ method: 'eth_chainId', params: [] }) + + expect(result1).to.equal('0x1') expect(calledSendAsync).to.equal(1) - const result2 = await client.send({ method: 'eth_accounts', params: [] }, 2) - expect(result2).to.deep.equal('0x12345') + const result2 = await client.request({ method: 'eth_accounts', params: [], chainId: 2 }) + expect(result2).to.equal('0x12345') expect(calledSendAsync).to.equal(2) - const result3 = await client.send({ method: 'eth_sendTransaction', params: [{ to: '0x1234' }] }, 5) - expect(result3).to.deep.equal('0x000') + const result3 = await client.request({ method: 'eth_sendTransaction', params: [{ to: '0x1234' }], chainId: 5 }) + expect(result3).to.equal('0x000') expect(calledSendAsync).to.equal(3) // Changing the default chainId // should change the chainId of the request client.setDefaultChainId(9) - const result4 = await client.send({ method: 'non-standard', params: [{ a: 23123, b: true }] }) - expect(result4).to.deep.equal('0x99') + const result4 = await client.request({ method: 'non-standard', params: [{ a: 23123, b: true }] }) + expect(result4).to.equal('0x99') expect(calledSendAsync).to.equal(4) }) @@ -552,8 +557,8 @@ describe('SequenceClient', () => { const client = new SequenceClient( { ...basicMockTransport, - sendAsync: (request: JsonRpcRequest, callback: JsonRpcResponseCallback, chainId?: number) => { - callback(new Error('Failed to send')) + request(request: JsonRpcRequest): Promise { + return Promise.reject(new Error('Failed to send')) } }, useBestStore(), @@ -562,16 +567,16 @@ describe('SequenceClient', () => { } ) - const result = client.send({ method: 'eth_chainId', params: [] }) + const result = client.request({ method: 'eth_chainId', params: [] }) await expect(result).to.be.rejectedWith('Failed to send') }) - it('should fail is response is empty', async () => { + it('should handle json rpc wrapped results', async () => { const client = new SequenceClient( { ...basicMockTransport, - sendAsync: (request: JsonRpcRequest, callback: JsonRpcResponseCallback, chainId?: number) => { - callback(undefined, undefined) + request(request: JsonRpcRequest): Promise { + return Promise.resolve({ jsonrpc: '2.0', result: '0x1234', id: request.id }) } }, useBestStore(), @@ -580,11 +585,31 @@ describe('SequenceClient', () => { } ) - const request = { method: 'eth_chainId', params: [] } - const result = client.send(request) - await expect(result).to.be.rejectedWith(`Got undefined response for request: ${request}`) + const result = await client.request({ method: 'eth_chainId', params: [] }) + expect(result).to.equal('0x1234') }) + // XXX: Request is not rejected if response is empty + // it('should fail if response is empty', async () => { + // const client = new SequenceClient( + // { + // ...basicMockTransport, + // request(request: JsonRpcRequest): Promise { + // return Promise.resolve(undefined) + // } + // }, + // useBestStore(), + // { + // defaultChainId: 2 + // } + // ) + + // const request = { method: 'eth_chainId', params: [] } + // const result = client.request(request) + + // await expect(result).to.be.rejectedWith(`Got undefined response for request: ${request}`) + // }) + it('shound handle getNetworks', async () => { // Networks are fetched once (during connect) and cached let calledSendAsync = 0 @@ -598,17 +623,15 @@ describe('SequenceClient', () => { const client = new SequenceClient( { ...basicMockTransport, - sendAsync: (request: JsonRpcRequest, callback: JsonRpcResponseCallback) => { + request(request: JsonRpcRequest): Promise { calledSendAsync++ expect(request).to.deep.equal({ method: 'sequence_getNetworks' }) - callback(undefined, { - result: [ - { - chainId: 5, - name: 'test' - } - ] - } as any) + return Promise.resolve([ + { + chainId: 5, + name: 'test' + } + ]) }, openWallet: () => { return Promise.resolve(true) @@ -708,35 +731,37 @@ describe('SequenceClient', () => { let calledSendAsync = 0 - const requests = [ + const requests: { eip6492: boolean; chainId: number; message: ethers.BytesLike; result: string }[] = [ { eip6492: false, chainId: 2, message: '0x1234', result: '0x0000' }, - { eip6492: true, chainId: 2, message: [4, 2, 9, 1], result: '0x1111' }, + { eip6492: true, chainId: 2, message: new Uint8Array([4, 2, 9, 1]), result: '0x1111' }, { eip6492: false, chainId: 5, message: '0x9993212', result: '0x2222' }, - { eip6492: true, chainId: 6, message: [4, 2, 9, 1], result: '0x3333' } - ] as { eip6492: boolean; chainId: number; message: ethers.BytesLike; result: string }[] + { eip6492: true, chainId: 6, message: new Uint8Array([4, 2, 9, 1]), result: '0x3333' } + ] const client = new SequenceClient( { ...basicMockTransport, - sendAsync: (request: JsonRpcRequest, callback: JsonRpcResponseCallback, chainId?: number) => { + request(request: JsonRpcRequest): Promise { calledSendAsync++ const req = requests.shift() if (!req) { - throw new Error('No more requests to handle') + throw new Error('Could not get test request for comparison') } - const message = ethers.utils.hexlify(messageToBytes(req.message)) + if (!request.chainId) { + request.chainId = client.getChainId() + } - expect(request).to.deep.equal( - { - method: req.eip6492 ? 'sequence_sign' : 'personal_sign', - params: [message, session.accountAddress] - }, - 'sendAsync request mismatch' - ) - expect(chainId).to.equal(req.chainId) - callback(undefined, { result: req.result } as any) + const message = ethers.hexlify(messageToBytes(req.message)) + + expect(request).to.deep.equal({ + method: req.eip6492 ? 'sequence_sign' : 'personal_sign', + params: [message, session.accountAddress], + chainId: req.chainId + }) + expect(request.chainId).to.equal(req.chainId) + return Promise.resolve(req?.result) }, openWallet: () => { return Promise.resolve(true) @@ -766,7 +791,7 @@ describe('SequenceClient', () => { const result2 = await client.signMessage('0x1234') expect(result2).to.equal('0x0000') - const result3 = await client.signMessage([4, 2, 9, 1], { eip6492: true, chainId: 2 }) + const result3 = await client.signMessage(new Uint8Array([4, 2, 9, 1]), { eip6492: true, chainId: 2 }) expect(result3).to.equal('0x1111') client.setDefaultChainId(5) @@ -774,7 +799,7 @@ describe('SequenceClient', () => { const result4 = await client.signMessage('0x9993212') expect(result4).to.equal('0x2222') - const result5 = await client.signMessage([4, 2, 9, 1], { eip6492: true, chainId: 6 }) + const result5 = await client.signMessage(new Uint8Array([4, 2, 9, 1]), { eip6492: true, chainId: 6 }) expect(result5).to.equal('0x3333') expect(calledSendAsync).to.equal(4) @@ -912,19 +937,24 @@ describe('SequenceClient', () => { const client = new SequenceClient( { ...basicMockTransport, - sendAsync: (request: JsonRpcRequest, callback: JsonRpcResponseCallback, chainId?: number) => { + request(request: JsonRpcRequest): Promise { const req = requests[calledSendAsync] calledSendAsync++ - const encoded = ethers.utils._TypedDataEncoder.getPayload(req!.data.domain, req!.data.types, req!.data.message) + const encoded = ethers.TypedDataEncoder.getPayload(req!.data.domain, req!.data.types, req!.data.message) + + if (!request.chainId) { + request.chainId = client.getChainId() + } expect(request).to.deep.equal({ method: req?.eip6492 ? 'sequence_signTypedData_v4' : 'eth_signTypedData_v4', - params: [session.accountAddress, encoded] + params: [session.accountAddress, encoded], + chainId: req.chainId }) - expect(chainId).to.equal(req?.chainId) - callback(undefined, { result: req?.result } as any) + expect(request.chainId).to.equal(req?.chainId) + return Promise.resolve(req?.result) }, openWallet: () => { return Promise.resolve(true) @@ -980,7 +1010,7 @@ describe('SequenceClient', () => { chainId: 2, tx: { to: '0x88E1627e95071d140Abaec34574ee4AC991295fC', - value: ethers.utils.parseEther('1.0'), + value: parseEther('1.0'), auxiliary: [] }, result: '0x0000' @@ -1008,7 +1038,7 @@ describe('SequenceClient', () => { chainId: 6, tx: { to: '0x88E1627e95071d140Abaec34574ee4AC991295fC', - value: ethers.utils.parseEther('1.0'), + value: parseEther('1.0'), auxiliary: [ { to: '0xD20bC67fD6feFad616Ed6B29d6d15884E08b6D86', @@ -1027,15 +1057,21 @@ describe('SequenceClient', () => { const client = new SequenceClient( { ...basicMockTransport, - sendAsync: (request: JsonRpcRequest, callback: JsonRpcResponseCallback, chainId?: number) => { + request(request: JsonRpcRequest): Promise { calledSendAsync++ const req = requests.shift() + + if (!request.chainId) { + request.chainId = client.getChainId() + } + expect(request).to.deep.equal({ method: 'eth_sendTransaction', - params: [req?.tx] + params: [req?.tx], + chainId: req?.chainId }) - expect(chainId).to.equal(req?.chainId) - callback(undefined, { result: req?.result } as any) + expect(request.chainId).to.equal(req?.chainId) + return Promise.resolve(req?.result) } }, useBestStore(), @@ -1051,7 +1087,7 @@ describe('SequenceClient', () => { // // const result1 = client.sendTransaction({ // to: '0x88E1627e95071d140Abaec34574ee4AC991295fC', - // value: ethers.utils.parseEther('1.0'), + // value: parseEther('1.0'), // }) // await expect(result1).to.be.rejectedWith('Sequence session not connected') @@ -1059,7 +1095,7 @@ describe('SequenceClient', () => { const result2 = await client.sendTransaction({ to: '0x88E1627e95071d140Abaec34574ee4AC991295fC', - value: ethers.utils.parseEther('1.0') + value: parseEther('1.0') }) expect(result2).to.equal('0x0000') @@ -1088,7 +1124,7 @@ describe('SequenceClient', () => { [ { to: '0x88E1627e95071d140Abaec34574ee4AC991295fC', - value: ethers.utils.parseEther('1.0') + value: parseEther('1.0') }, { to: '0xD20bC67fD6feFad616Ed6B29d6d15884E08b6D86', @@ -1113,12 +1149,12 @@ describe('SequenceClient', () => { const client = new SequenceClient( { ...basicMockTransport, - sendAsync: (request: JsonRpcRequest, callback: JsonRpcResponseCallback, chainId?: number) => { + request(request: JsonRpcRequest): Promise { calledSendAsync++ expect(request).to.deep.equal({ method: 'sequence_getWalletContext' }) - callback(undefined, { result: sampleContext } as any) + return Promise.resolve(sampleContext) } }, useBestStore(), @@ -1180,15 +1216,21 @@ describe('SequenceClient', () => { const client = new SequenceClient( { ...basicMockTransport, - sendAsync: (request: JsonRpcRequest, callback: JsonRpcResponseCallback, chainId?: number) => { + request(request: JsonRpcRequest): Promise { const req = results[calledSendAsync] calledSendAsync++ + + if (!request.chainId) { + request.chainId = client.getChainId() + } + expect(request).to.deep.equal({ method: 'sequence_getWalletConfig', - params: [req?.chainId] + params: [req?.chainId], + chainId: req?.chainId }) - expect(chainId).to.be.equal(req?.chainId) - callback(undefined, { result: req?.result } as any) + expect(request.chainId).to.be.equal(req?.chainId) + return Promise.resolve(req?.result) } }, useBestStore(), @@ -1305,17 +1347,17 @@ describe('SequenceClient', () => { const client = new SequenceClient( { ...basicMockTransport, - sendAsync: (request: JsonRpcRequest, callback: JsonRpcResponseCallback, chainId?: number) => { + request(request: JsonRpcRequest): Promise { if (requests === 0) { expect(request.method).to.equal('personal_sign') requests++ - callback(undefined, { result: '0x445566' } as any) + return Promise.resolve('0x445566') } else if (requests === 1) { expect(request.method).to.equal('eth_signTypedData_v4') requests++ - callback(undefined, { result: '0x112233' } as any) + return Promise.resolve('0x112233') } else { - expect.fail('Should not have called sendAsync') + expect.fail('Should not have called request') } }, openWallet: () => { @@ -1377,17 +1419,17 @@ describe('SequenceClient', () => { const client = new SequenceClient( { ...basicMockTransport, - sendAsync: (request: JsonRpcRequest, callback: JsonRpcResponseCallback, chainId?: number) => { + request(request: JsonRpcRequest): Promise { if (requests === 0) { expect(request.method).to.equal('sequence_sign') requests++ - callback(undefined, { result: '0x445566' } as any) + return Promise.resolve('0x445566') } else if (requests === 1) { expect(request.method).to.equal('sequence_signTypedData_v4') requests++ - callback(undefined, { result: '0x112233' } as any) + return Promise.resolve('0x112233') } else { - expect.fail('Should not have called sendAsync') + expect.fail('Should not have called request') } }, openWallet: () => { @@ -1450,17 +1492,17 @@ describe('SequenceClient', () => { const client = new SequenceClient( { ...basicMockTransport, - sendAsync: (request: JsonRpcRequest, callback: JsonRpcResponseCallback, chainId?: number) => { + request(request: JsonRpcRequest): Promise { if (requests === 0) { expect(request.method).to.equal('personal_sign') requests++ - callback(undefined, { result: '0x445566' } as any) + return Promise.resolve('0x445566') } else if (requests === 1) { expect(request.method).to.equal('eth_signTypedData_v4') requests++ - callback(undefined, { result: '0x112233' } as any) + return Promise.resolve('0x112233') } else { - expect.fail('Should not have called sendAsync') + expect.fail('Should not have called request') } }, openWallet: () => { @@ -1484,10 +1526,10 @@ describe('SequenceClient', () => { expect(client.defaultEIP6492).to.be.false - const result1 = await client.send({ method: 'personal_sign', params: ['0x112233'] }) + const result1 = await client.request({ method: 'personal_sign', params: ['0x112233'] }) expect(result1).to.equal('0x445566') - const result2 = await client.send({ method: 'eth_signTypedData_v4', params: [data] }) + const result2 = await client.request({ method: 'eth_signTypedData_v4', params: [data] }) expect(result2).to.equal('0x112233') }) @@ -1522,17 +1564,17 @@ describe('SequenceClient', () => { const client = new SequenceClient( { ...basicMockTransport, - sendAsync: (request: JsonRpcRequest, callback: JsonRpcResponseCallback, chainId?: number) => { + request(request: JsonRpcRequest): Promise { if (requests === 0) { expect(request.method).to.equal('sequence_sign') requests++ - callback(undefined, { result: '0x445566' } as any) + return Promise.resolve('0x445566') } else if (requests === 1) { expect(request.method).to.equal('sequence_signTypedData_v4') requests++ - callback(undefined, { result: '0x112233' } as any) + return Promise.resolve('0x112233') } else { - expect.fail('Should not have called sendAsync') + expect.fail('Should not have called request') } }, openWallet: () => { @@ -1557,10 +1599,10 @@ describe('SequenceClient', () => { expect(client.defaultEIP6492).to.be.true - const result1 = await client.send({ method: 'personal_sign', params: ['0x112233'] }) + const result1 = await client.request({ method: 'personal_sign', params: ['0x112233'] }) expect(result1).to.equal('0x445566') - const result2 = await client.send({ method: 'eth_signTypedData_v4', params: [data] }) + const result2 = await client.request({ method: 'eth_signTypedData_v4', params: [data] }) expect(result2).to.equal('0x112233') }) @@ -1595,17 +1637,17 @@ describe('SequenceClient', () => { const client = new SequenceClient( { ...basicMockTransport, - sendAsync: (request: JsonRpcRequest, callback: JsonRpcResponseCallback, chainId?: number) => { + request(request: JsonRpcRequest): Promise { if (requests === 0) { expect(request.method).to.equal('sequence_sign') requests++ - callback(undefined, { result: '0x445566' } as any) + return Promise.resolve('0x445566') } else if (requests === 1) { expect(request.method).to.equal('sequence_signTypedData_v4') requests++ - callback(undefined, { result: '0x112233' } as any) + return Promise.resolve('0x112233') } else { - expect.fail('Should not have called sendAsync') + expect.fail('Should not have called request') } }, openWallet: () => { @@ -1627,10 +1669,10 @@ describe('SequenceClient', () => { await client.connect({ app: 'This is a test' }) - const result1 = await client.send({ method: 'sequence_sign', params: ['0x112233'] }) + const result1 = await client.request({ method: 'sequence_sign', params: ['0x112233'] }) expect(result1).to.equal('0x445566') - const result2 = await client.send({ method: 'sequence_signTypedData_v4', params: [data] }) + const result2 = await client.request({ method: 'sequence_signTypedData_v4', params: [data] }) expect(result2).to.equal('0x112233') }) }) diff --git a/packages/provider/tests/messages.ts b/packages/provider/tests/messages.ts index 48f17a576..4b49060bf 100644 --- a/packages/provider/tests/messages.ts +++ b/packages/provider/tests/messages.ts @@ -11,7 +11,7 @@ const dclText = `Decentraland Login Ephemeral address: 0xe1bCF3CAc83534a055f7254C1FD88B21159fCc67 Expiration: 2022-10-27T16:03:29.191Z` -export const dclLogin = ethers.utils.toUtf8Bytes(dclText) +export const dclLogin = ethers.toUtf8Bytes(dclText) // Ethereum personal sign 0x v3 order export const zeroExV3Order = new Uint8Array([ diff --git a/packages/provider/tests/provider.spec.ts b/packages/provider/tests/provider.spec.ts index 2025f6264..5a27ab239 100644 --- a/packages/provider/tests/provider.spec.ts +++ b/packages/provider/tests/provider.spec.ts @@ -5,14 +5,15 @@ import { OptionalChainId, SequenceClient, SequenceProvider, - SingleNetworkSequenceProvider + SingleNetworkSequenceProvider, + WalletEventTypes } from '../src' import { expect } from 'chai' -import { JsonRpcRequest, JsonRpcResponse, allNetworks } from '@0xsequence/network' +import { ChainId, JsonRpcRequest, JsonRpcResponse, allNetworks } from '@0xsequence/network' import { ExtendedTransactionRequest } from '../src/extended' -const hardhat1Provider = new ethers.providers.JsonRpcProvider('http://127.0.0.1:9595') -const hardhat2Provider = new ethers.providers.JsonRpcProvider('http://127.0.0.1:8595') +const hardhat1Provider = new ethers.JsonRpcProvider('http://127.0.0.1:9595', undefined, { cacheTimeout: -1 }) +const hardhat2Provider = new ethers.JsonRpcProvider('http://127.0.0.1:8595', undefined, { cacheTimeout: -1 }) const providerFor = (chainId: number) => { if (chainId === 31337) { @@ -49,7 +50,7 @@ const basicMockClient = { onAccountsChanged: () => {} } as unknown as SequenceClient -async function waitUntilNoFail(provider: ethers.providers.Provider, timeout = 20000): Promise { +async function waitUntilNoFail(provider: ethers.Provider, timeout = 20000): Promise { const start = Date.now() while (Date.now() - start < timeout) { try { @@ -343,21 +344,23 @@ describe('SequenceProvider', () => { describe('provider events', () => { let provider: SequenceProvider - const callbacks: { [event: string]: (data: any) => void } = {} + const callbacks: { [event in keyof WalletEventTypes]: (data: any) => any } = {} as any beforeEach(() => { - const usecb = (name: string, cb: (data: any) => any) => { + const registerCallback = (name: K, cb: WalletEventTypes[K]) => { callbacks[name] = cb return () => {} } + // When SequenceProvider is instantiated it will register callbacks on the client which emit events + // We capture these callbacks and call them manually to simulate the events provider = new SequenceProvider( { ...basicMockClient, - onConnect: (c: any) => usecb('connect', c), - onDisconnect: (c: any) => usecb('disconnect', c), - onDefaultChainIdChanged: (c: any) => usecb('chainChanged', c), - onAccountsChanged: (c: any) => usecb('accountsChanged', c) + onConnect: (cb: WalletEventTypes['connect']) => registerCallback('connect', cb), + onDisconnect: (cb: WalletEventTypes['disconnect']) => registerCallback('disconnect', cb), + onDefaultChainIdChanged: (cb: WalletEventTypes['chainChanged']) => registerCallback('chainChanged', cb), + onAccountsChanged: (cb: WalletEventTypes['accountsChanged']) => registerCallback('accountsChanged', cb) } as unknown as SequenceClient, providerFor ) @@ -505,20 +508,23 @@ describe('SequenceProvider', () => { }) it('should fail if the passed network config doesnt exist on the provider', () => { - const fakeNetwork = { chainId: 99999, name: 'fake', rpcUrl: 'http://127.0.0.1:99999' } + const fakeNetwork = { + chainId: 99999, + name: 'fake', + rpcUrl: 'http://127.0.0.1:99999', + nativeToken: { symbol: 'ETH', name: 'Ether', decimals: 18 } + } expect(() => provider.toChainId(fakeNetwork)).to.throw(`Unsupported network ${fakeNetwork}`) }) - it('should work when passing a BigNumber', () => { - expect(provider.toChainId(ethers.BigNumber.from(1))).to.equal(1) - expect(provider.toChainId(ethers.BigNumber.from(31337))).to.equal(31337) - expect(provider.toChainId(ethers.BigNumber.from(31338))).to.equal(31338) + it('should work when passing a BigInt', () => { + expect(provider.toChainId(1n)).to.equal(1) + expect(provider.toChainId(31337n)).to.equal(31337) + expect(provider.toChainId(31338n)).to.equal(31338) }) - it('should fail if network is not supported - BigNumber', () => { - expect(() => provider.toChainId(ethers.BigNumber.from(99999))).to.throw( - `Unsupported network ${ethers.BigNumber.from(99999)}` - ) + it('should fail if network is not supported - BigInt', () => { + expect(() => provider.toChainId(99999n)).to.throw('Unsupported network 99999') }) it('should return undefined if passed undefined', () => { @@ -681,6 +687,7 @@ describe('SequenceProvider', () => { if (bn1 === bn2) { await hardhat2Provider.send('evm_mine', []) + bn2 = await hardhat2Provider.getBlockNumber() } @@ -715,7 +722,7 @@ describe('SequenceProvider', () => { }) }) - describe('forward getGasPrice', () => { + describe('forward getFeeData', () => { let provider: SequenceProvider beforeEach(() => { @@ -724,54 +731,54 @@ describe('SequenceProvider', () => { if (chainId === 31337) { return { ...hardhat1Provider, - getGasPrice: async () => ethers.BigNumber.from(1) - } as unknown as ethers.providers.JsonRpcProvider + getFeeData: async () => ({ gasPrice: 1n }) + } as unknown as ethers.JsonRpcProvider } if (chainId === 31338) { return { ...hardhat2Provider, - getGasPrice: async () => ethers.BigNumber.from(2) - } as unknown as ethers.providers.JsonRpcProvider + getFeeData: async () => ({ gasPrice: 2n }) + } as unknown as ethers.JsonRpcProvider } throw new Error(`No provider for chainId ${chainId}`) }) }) - it('forward getGasPrice - default', async () => { - expect(await provider.getGasPrice()).to.deep.equal(ethers.BigNumber.from(1)) + it('forward getFeeData - default', async () => { + expect((await provider.getFeeData()).gasPrice).to.equal(1n) provider.setDefaultChainId(31338) - expect(await provider.getGasPrice()).to.deep.equal(ethers.BigNumber.from(2)) + expect((await provider.getFeeData()).gasPrice).to.equal(2n) }) - it('forward getGasPrice - specific chain', async () => { - expect(await provider.getGasPrice({ chainId: 31337 })).to.deep.equal(ethers.BigNumber.from(1)) - expect(await provider.getGasPrice({ chainId: 31338 })).to.deep.equal(ethers.BigNumber.from(2)) + it('forward getFeeData - specific chain', async () => { + expect((await provider.getFeeData({ chainId: 31337 })).gasPrice).to.equal(1n) + expect((await provider.getFeeData({ chainId: 31338 })).gasPrice).to.equal(2n) }) - it('forward getGasPrice - static network provider', async () => { - expect(await provider.getProvider('hardhat').getGasPrice()).to.deep.equal(ethers.BigNumber.from(1)) - expect(await provider.getProvider(31338).getGasPrice()).to.deep.equal(ethers.BigNumber.from(2)) + it('forward getFeeData - static network provider', async () => { + expect((await provider.getProvider('hardhat').getFeeData()).gasPrice).to.equal(1n) + expect((await provider.getProvider(31338).getFeeData()).gasPrice).to.equal(2n) }) - it('fail to forward getGasPrice - static network provider for different chain', async () => { - await expect(provider.getProvider('hardhat').getGasPrice({ chainId: 31338 })).to.be.rejectedWith( + it('fail to forward getFeeData - static network provider for different chain', async () => { + await expect(provider.getProvider('hardhat').getFeeData({ chainId: 31338 })).to.be.rejectedWith( 'This provider only supports the network 31337, but 31338 was requested.' ) }) }) describe('forward getBalance', () => { - let b1: ethers.BigNumber - let b2: ethers.BigNumber + let b1: bigint + let b2: bigint beforeEach(async () => { b1 = await hardhat1Provider.getBalance(testAccounts[0].address) b2 = await hardhat2Provider.getBalance(testAccounts[1].address) - if (b1.eq(b2)) { + if (b1 === b2) { await testAccounts[1].sendTransaction({ to: ethers.Wallet.createRandom().address, value: 1 @@ -780,27 +787,27 @@ describe('SequenceProvider', () => { b2 = await hardhat2Provider.getBalance(testAccounts[1].address) } - expect(b1).to.not.deep.equal(b2) + expect(b1).to.not.equal(b2) }) it('forward getBalance - default', async () => { const provider = new SequenceProvider(basicMockClient, providerFor) - expect(await provider.getBalance(testAccounts[0].address)).to.deep.equal(b1) + expect(await provider.getBalance(testAccounts[0].address)).to.equal(b1) provider.setDefaultChainId(31338) - expect(await provider.getBalance(testAccounts[1].address)).to.deep.equal(b2) + expect(await provider.getBalance(testAccounts[1].address)).to.equal(b2) }) it('forward getBalance - specific chain', async () => { const provider = new SequenceProvider(basicMockClient, providerFor) - expect(await provider.getBalance(testAccounts[0].address, undefined, { chainId: 31337 })).to.deep.equal(b1) - expect(await provider.getBalance(testAccounts[1].address, undefined, { chainId: 31338 })).to.deep.equal(b2) + expect(await provider.getBalance(testAccounts[0].address, undefined, { chainId: 31337 })).to.equal(b1) + expect(await provider.getBalance(testAccounts[1].address, undefined, { chainId: 31338 })).to.equal(b2) }) it('forward getBalance - static network provider', async () => { const provider = new SequenceProvider(basicMockClient, providerFor) - expect(await provider.getProvider('hardhat').getBalance(testAccounts[0].address)).to.deep.equal(b1) - expect(await provider.getProvider('hardhat2').getBalance(testAccounts[1].address)).to.deep.equal(b2) + expect(await provider.getProvider('hardhat').getBalance(testAccounts[0].address)).to.equal(b1) + expect(await provider.getProvider('hardhat2').getBalance(testAccounts[1].address)).to.equal(b2) }) it('fail to forward getBalance - static network provider for different chain', async () => { @@ -869,6 +876,10 @@ describe('SequenceProvider', () => { }) .then(r => r.wait()) + if (!res?.contractAddress) { + throw new Error('Could not get transaction receipt') + } + addr = res.contractAddress expect(await hardhat1Provider.getCode(addr)).to.equal('0x112233') @@ -903,7 +914,7 @@ describe('SequenceProvider', () => { }) }) - describe('forward getStorageAt', () => { + describe('forward getStorage', () => { const expected = '0x0000000000000000000000000000000000000000000000000000000000112233' const empty = '0x0000000000000000000000000000000000000000000000000000000000000000' @@ -917,36 +928,40 @@ describe('SequenceProvider', () => { }) .then(r => r.wait()) + if (!res?.contractAddress) { + throw new Error('Could not get transaction receipt') + } + addr = res.contractAddress - expect(await hardhat1Provider.getStorageAt(addr, '0x445566')).to.equal(expected) - expect(await hardhat2Provider.getStorageAt(addr, '0x445566')).to.equal(empty) + expect(await hardhat1Provider.getStorage(addr, '0x445566')).to.equal(expected) + expect(await hardhat2Provider.getStorage(addr, '0x445566')).to.equal(empty) }) - it('forward getStorageAt - default', async () => { + it('forward getStorage - default', async () => { const provider = new SequenceProvider(basicMockClient, providerFor) - expect(await provider.getStorageAt(addr, '0x445566')).to.equal(expected) + expect(await provider.getStorage(addr, '0x445566')).to.equal(expected) provider.setDefaultChainId(31338) - expect(await provider.getStorageAt(addr, '0x445566')).to.equal(empty) + expect(await provider.getStorage(addr, '0x445566')).to.equal(empty) }) - it('forward getStorageAt - specific chain', async () => { + it('forward getStorage - specific chain', async () => { const provider = new SequenceProvider(basicMockClient, providerFor) - expect(await provider.getStorageAt(addr, '0x445566', undefined, { chainId: 31337 })).to.equal(expected) - expect(await provider.getStorageAt(addr, '0x445566', undefined, { chainId: 31338 })).to.equal(empty) + expect(await provider.getStorage(addr, '0x445566', undefined, { chainId: 31337 })).to.equal(expected) + expect(await provider.getStorage(addr, '0x445566', undefined, { chainId: 31338 })).to.equal(empty) }) - it('forward getStorageAt - static network provider', async () => { + it('forward getStorage - static network provider', async () => { const provider = new SequenceProvider(basicMockClient, providerFor) - expect(await provider.getProvider('hardhat').getStorageAt(addr, '0x445566')).to.equal(expected) - expect(await provider.getProvider('hardhat2').getStorageAt(addr, '0x445566')).to.equal(empty) + expect(await provider.getProvider('hardhat').getStorage(addr, '0x445566')).to.equal(expected) + expect(await provider.getProvider('hardhat2').getStorage(addr, '0x445566')).to.equal(empty) }) - it('fail to forward getStorageAt - static network provider for different chain', async () => { + it('fail to forward getStorage - static network provider for different chain', async () => { const provider = new SequenceProvider(basicMockClient, providerFor) await expect( - provider.getProvider('hardhat2').getStorageAt(addr, '0x445566', undefined, { chainId: 31337 }) + provider.getProvider('hardhat2').getStorage(addr, '0x445566', undefined, { chainId: 31337 }) ).to.be.rejectedWith('This provider only supports the network 31338, but 31337 was requested.') }) }) @@ -962,6 +977,10 @@ describe('SequenceProvider', () => { }) .then(r => r.wait()) + if (!res?.contractAddress) { + throw new Error('Could not get transaction receipt') + } + addr = res.contractAddress expect(await hardhat1Provider.call({ to: addr })).to.equal('0x112233') @@ -978,8 +997,8 @@ describe('SequenceProvider', () => { it('forward call - specific chain', async () => { const provider = new SequenceProvider(basicMockClient, providerFor) - expect(await provider.call({ to: addr }, undefined, { chainId: 31337 })).to.equal('0x112233') - expect(await provider.call({ to: addr }, undefined, { chainId: 31338 })).to.equal('0x') + expect(await provider.call({ to: addr }, { chainId: 31337 })).to.equal('0x112233') + expect(await provider.call({ to: addr }, { chainId: 31338 })).to.equal('0x') }) it('forward call - static network provider', async () => { @@ -990,15 +1009,15 @@ describe('SequenceProvider', () => { it('fail to forward call - static network provider for different chain', async () => { const provider = new SequenceProvider(basicMockClient, providerFor) - await expect(provider.getProvider('hardhat2').call({ to: addr }, undefined, { chainId: 31337 })).to.be.rejectedWith( + await expect(provider.getProvider('hardhat2').call({ to: addr }, { chainId: 31337 })).to.be.rejectedWith( 'This provider only supports the network 31338, but 31337 was requested.' ) }) }) describe('forward estimateGas', () => { - let eg1: ethers.BigNumber - let eg2: ethers.BigNumber + let eg1: bigint + let eg2: bigint let addr: string @@ -1011,32 +1030,36 @@ describe('SequenceProvider', () => { }) .then(r => r.wait()) + if (!res?.contractAddress) { + throw new Error('Could not get transaction receipt') + } + addr = res.contractAddress eg1 = await hardhat1Provider.estimateGas({ to: addr }) eg2 = await hardhat2Provider.estimateGas({ to: addr }) - expect(eg1).to.not.deep.equal(eg2) + expect(eg1).to.not.equal(eg2) }) it('forward estimateGas - default', async () => { const provider = new SequenceProvider(basicMockClient, providerFor) - expect(await provider.estimateGas({ to: addr })).to.deep.equal(eg1) + expect(await provider.estimateGas({ to: addr })).to.equal(eg1) provider.setDefaultChainId(31338) - expect(await provider.estimateGas({ to: addr })).to.deep.equal(eg2) + expect(await provider.estimateGas({ to: addr })).to.equal(eg2) }) it('forward estimateGas - specific chain', async () => { const provider = new SequenceProvider(basicMockClient, providerFor) - expect(await provider.estimateGas({ to: addr }, { chainId: 31337 })).to.deep.equal(eg1) - expect(await provider.estimateGas({ to: addr }, { chainId: 31338 })).to.deep.equal(eg2) + expect(await provider.estimateGas({ to: addr }, { chainId: 31337 })).to.equal(eg1) + expect(await provider.estimateGas({ to: addr }, { chainId: 31338 })).to.equal(eg2) }) it('forward estimateGas - static network provider', async () => { const provider = new SequenceProvider(basicMockClient, providerFor) - expect(await provider.getProvider('hardhat').estimateGas({ to: addr })).to.deep.equal(eg1) - expect(await provider.getProvider('hardhat2').estimateGas({ to: addr })).to.deep.equal(eg2) + expect(await provider.getProvider('hardhat').estimateGas({ to: addr })).to.equal(eg1) + expect(await provider.getProvider('hardhat2').estimateGas({ to: addr })).to.equal(eg2) }) it('fail to forward estimateGas - static network provider for different chain', async () => { @@ -1048,8 +1071,8 @@ describe('SequenceProvider', () => { }) describe('forward getBlock', () => { - let b1: ethers.providers.Block - let b2: ethers.providers.Block + let b1: ethers.Block | null + let b2: ethers.Block | null beforeEach(async () => { b1 = await hardhat1Provider.getBlock(1) @@ -1068,8 +1091,8 @@ describe('SequenceProvider', () => { it('forward getBlock - specific chain', async () => { const provider = new SequenceProvider(basicMockClient, providerFor) - expect(await provider.getBlock(1, { chainId: 31337 })).to.deep.equal(b1) - expect(await provider.getBlock(1, { chainId: 31338 })).to.deep.equal(b2) + expect(await provider.getBlock(1, undefined, { chainId: 31337 })).to.deep.equal(b1) + expect(await provider.getBlock(1, undefined, { chainId: 31338 })).to.deep.equal(b2) }) it('forward getBlock - static network provider', async () => { @@ -1080,7 +1103,7 @@ describe('SequenceProvider', () => { it('fail to forward getBlock - static network provider for different chain', async () => { const provider = new SequenceProvider(basicMockClient, providerFor) - await expect(provider.getProvider('hardhat2').getBlock(0, { chainId: 31337 })).to.be.rejectedWith( + await expect(provider.getProvider('hardhat2').getBlock(0, undefined, { chainId: 31337 })).to.be.rejectedWith( 'This provider only supports the network 31338, but 31337 was requested.' ) }) @@ -1101,7 +1124,7 @@ describe('SequenceProvider', () => { it('forward getTransaction - default', async () => { const provider = new SequenceProvider(basicMockClient, providerFor) - expect(await provider.getTransaction(t1).then(r => r.hash)).to.equal(t1) + expect(await provider.getTransaction(t1).then(r => r?.hash)).to.equal(t1) provider.setDefaultChainId(31338) expect(await provider.getTransaction(t1)).to.be.null @@ -1109,7 +1132,7 @@ describe('SequenceProvider', () => { it('forward getTransaction - specific chain', async () => { const provider = new SequenceProvider(basicMockClient, providerFor) - expect(await provider.getTransaction(t1, { chainId: 31337 }).then(r => r.hash)).to.equal(t1) + expect(await provider.getTransaction(t1, { chainId: 31337 }).then(r => r?.hash)).to.equal(t1) expect(await provider.getTransaction(t1, { chainId: 31338 })).to.be.null }) @@ -1119,7 +1142,7 @@ describe('SequenceProvider', () => { await provider .getProvider('hardhat') .getTransaction(t1) - .then(r => r.hash) + .then(r => r?.hash) ).to.equal(t1) expect(await provider.getProvider('hardhat2').getTransaction(t1)).to.be.null }) @@ -1135,8 +1158,8 @@ describe('SequenceProvider', () => { describe('forward getLogs', () => { let t1: string - let r1: Array - let r2: Array + let r1: Array + let r2: Array beforeEach(async () => { // Deploy a contract that emits a single LOG0 event (during deployment) @@ -1146,6 +1169,10 @@ describe('SequenceProvider', () => { }) .then(r => r.wait()) + if (!res?.contractAddress) { + throw new Error('Could not get transaction receipt') + } + t1 = res.contractAddress r1 = await hardhat1Provider.getLogs({ address: t1 }) @@ -1190,12 +1217,12 @@ describe('SequenceProvider', () => { .sendTransaction({ to: ethers.Wallet.createRandom().address }) - .then(r => r.hash) + .then(r => r!.hash) }) it('forward waitForTransaction - default', async () => { const provider = new SequenceProvider(basicMockClient, providerFor) - expect(await provider.waitForTransaction(t1, undefined, 250).then(r => r.transactionHash)).to.equal(t1) + expect(await provider.waitForTransaction(t1, undefined, 250).then(r => r?.hash)).to.equal(t1) provider.setDefaultChainId(31338) await expect(provider.waitForTransaction(t1, undefined, 250)).to.be.rejected @@ -1203,9 +1230,7 @@ describe('SequenceProvider', () => { it('forward waitForTransaction - specific chain', async () => { const provider = new SequenceProvider(basicMockClient, providerFor) - expect(await provider.waitForTransaction(t1, undefined, 250, { chainId: 31337 }).then(r => r.transactionHash)).to.equal( - t1 - ) + expect(await provider.waitForTransaction(t1, undefined, 250, { chainId: 31337 }).then(r => r?.hash)).to.equal(t1) await expect(provider.waitForTransaction(t1, undefined, 250, { chainId: 31338 })).to.be.rejected }) @@ -1215,7 +1240,7 @@ describe('SequenceProvider', () => { await provider .getProvider('hardhat') .waitForTransaction(t1, undefined, 250) - .then(r => r.transactionHash) + .then(r => r?.hash) ).to.equal(t1) await expect(provider.getProvider('hardhat2').waitForTransaction(t1, undefined, 250)).to.be.rejected }) @@ -1232,12 +1257,12 @@ describe('SequenceProvider', () => { // on using the sequence mainnet provider describe('forward ENS methods', () => { let provider: SequenceProvider - let mainnetProvider: ethers.providers.JsonRpcProvider + let mainnetProvider: ethers.JsonRpcProvider let vitalikAddr: string | null before(async () => { - mainnetProvider = new ethers.providers.JsonRpcProvider('https://nodes.sequence.app/mainnet') + mainnetProvider = new ethers.JsonRpcProvider('https://nodes.sequence.app/mainnet') vitalikAddr = await mainnetProvider.resolveName('vitalik.eth') }) @@ -1282,24 +1307,24 @@ describe('SequenceProvider', () => { describe('perform eth_chainId', async () => { it('should return initial default chainId', async () => { const provider = new SequenceProvider(basicMockClient, providerFor) - expect(await provider.perform('eth_chainId', [])).to.equal(ethers.utils.hexValue(31337)) + expect(await provider.perform('eth_chainId', [])).to.equal(ethers.toQuantity(31337)) }) it('should return new default chainId', async () => { const provider = new SequenceProvider(basicMockClient, providerFor) provider.setDefaultChainId(31338) - expect(await provider.perform('eth_chainId', [])).to.equal(ethers.utils.hexValue(31338)) + expect(await provider.perform('eth_chainId', [])).to.equal(ethers.toQuantity(31338)) }) it('should return static chainId', async () => { const provider = new SequenceProvider(basicMockClient, providerFor) - expect(await provider.getProvider(31337).perform('eth_chainId', [])).to.equal(ethers.utils.hexValue(31337)) - expect(await provider.getProvider(31338).perform('eth_chainId', [])).to.equal(ethers.utils.hexValue(31338)) + expect(await provider.getProvider(31337).perform('eth_chainId', [])).to.equal(ethers.toQuantity(31337)) + expect(await provider.getProvider(31338).perform('eth_chainId', [])).to.equal(ethers.toQuantity(31338)) }) it('should return chainId using request', async () => { const provider = new SequenceProvider(basicMockClient, providerFor) - expect(await provider.request({ method: 'eth_chainId' })).to.equal(ethers.utils.hexValue(31337)) + expect(await provider.request({ method: 'eth_chainId' })).to.equal(ethers.toQuantity(31337)) }) }) @@ -1335,7 +1360,7 @@ describe('SequenceProvider', () => { describe('perform wallet_switchEthereumChain', async () => { it('should switch default chainId using request', async () => { const provider = new SequenceProvider(basicMockClient, providerFor) - expect(await provider.request({ method: 'eth_chainId' })).to.equal(ethers.utils.hexValue(31337)) + expect(await provider.request({ method: 'eth_chainId' })).to.equal(ethers.toQuantity(31337)) await provider.request({ method: 'wallet_switchEthereumChain', params: [{ chainId: '0x7a6a' }] }) expect(defaultChainId).to.equal(31338) @@ -1343,38 +1368,38 @@ describe('SequenceProvider', () => { it('should switch default chainId using object', async () => { const provider = new SequenceProvider(basicMockClient, providerFor) - expect(await provider.perform('eth_chainId', [])).to.equal(ethers.utils.hexValue(31337)) + expect(await provider.perform('eth_chainId', [])).to.equal(ethers.toQuantity(31337)) await provider.perform('wallet_switchEthereumChain', [{ chainId: '0x7a6a' }]) expect(defaultChainId).to.equal(31338) - expect(await provider.perform('eth_chainId', [])).to.equal(ethers.utils.hexValue(31338)) + expect(await provider.perform('eth_chainId', [])).to.equal(ethers.toQuantity(31338)) }) it('should switch default chainId using hex string', async () => { const provider = new SequenceProvider(basicMockClient, providerFor) - expect(await provider.perform('eth_chainId', [])).to.equal(ethers.utils.hexValue(31337)) + expect(await provider.perform('eth_chainId', [])).to.equal(ethers.toQuantity(31337)) await provider.perform('wallet_switchEthereumChain', ['0x7a6a']) expect(defaultChainId).to.equal(31338) - expect(await provider.perform('eth_chainId', [])).to.equal(ethers.utils.hexValue(31338)) + expect(await provider.perform('eth_chainId', [])).to.equal(ethers.toQuantity(31338)) }) it('should switch default chainId using number', async () => { const provider = new SequenceProvider(basicMockClient, providerFor) - expect(await provider.perform('eth_chainId', [])).to.equal(ethers.utils.hexValue(31337)) + expect(await provider.perform('eth_chainId', [])).to.equal(ethers.toQuantity(31337)) await provider.perform('wallet_switchEthereumChain', [31338]) expect(defaultChainId).to.equal(31338) - expect(await provider.perform('eth_chainId', [])).to.equal(ethers.utils.hexValue(31338)) + expect(await provider.perform('eth_chainId', [])).to.equal(ethers.toQuantity(31338)) }) it('should switch default chainId using string', async () => { const provider = new SequenceProvider(basicMockClient, providerFor) - expect(await provider.perform('eth_chainId', [])).to.equal(ethers.utils.hexValue(31337)) + expect(await provider.perform('eth_chainId', [])).to.equal(ethers.toQuantity(31337)) await provider.perform('wallet_switchEthereumChain', ['31338']) expect(defaultChainId).to.equal(31338) - expect(await provider.perform('eth_chainId', [])).to.equal(ethers.utils.hexValue(31338)) + expect(await provider.perform('eth_chainId', [])).to.equal(ethers.toQuantity(31338)) }) it('should fail to switch default chainId on static network provider', async () => { @@ -1387,38 +1412,38 @@ describe('SequenceProvider', () => { describe('using the setDefaultChainId method', async () => { it('should switch default chainId using name', async () => { const provider = new SequenceProvider(basicMockClient, providerFor) - expect(await provider.perform('eth_chainId', [])).to.equal(ethers.utils.hexValue(31337)) + expect(await provider.perform('eth_chainId', [])).to.equal(ethers.toQuantity(31337)) provider.setDefaultChainId('hardhat2') expect(defaultChainId).to.equal(31338) - expect(await provider.perform('eth_chainId', [])).to.equal(ethers.utils.hexValue(31338)) + expect(await provider.perform('eth_chainId', [])).to.equal(ethers.toQuantity(31338)) }) it('should switch default chainId using number', async () => { const provider = new SequenceProvider(basicMockClient, providerFor) - expect(await provider.perform('eth_chainId', [])).to.equal(ethers.utils.hexValue(31337)) + expect(await provider.perform('eth_chainId', [])).to.equal(ethers.toQuantity(31337)) provider.setDefaultChainId(31338) expect(defaultChainId).to.equal(31338) - expect(await provider.perform('eth_chainId', [])).to.equal(ethers.utils.hexValue(31338)) + expect(await provider.perform('eth_chainId', [])).to.equal(ethers.toQuantity(31338)) }) it('should switch default chainId using string', async () => { const provider = new SequenceProvider(basicMockClient, providerFor) - expect(await provider.perform('eth_chainId', [])).to.equal(ethers.utils.hexValue(31337)) + expect(await provider.perform('eth_chainId', [])).to.equal(ethers.toQuantity(31337)) provider.setDefaultChainId('31338') expect(defaultChainId).to.equal(31338) - expect(await provider.perform('eth_chainId', [])).to.equal(ethers.utils.hexValue(31338)) + expect(await provider.perform('eth_chainId', [])).to.equal(ethers.toQuantity(31338)) }) it('should switch default chainId using hex string', async () => { const provider = new SequenceProvider(basicMockClient, providerFor) - expect(await provider.perform('eth_chainId', [])).to.equal(ethers.utils.hexValue(31337)) + expect(await provider.perform('eth_chainId', [])).to.equal(ethers.toQuantity(31337)) provider.setDefaultChainId('0x7a6a') expect(defaultChainId).to.equal(31338) - expect(await provider.perform('eth_chainId', [])).to.equal(ethers.utils.hexValue(31338)) + expect(await provider.perform('eth_chainId', [])).to.equal(ethers.toQuantity(31338)) }) it('should fail to switch default chainId on static network provider', async () => { @@ -1439,25 +1464,25 @@ describe('SequenceProvider', () => { describe('sequence client methods', () => { describe('perform eth_sendTransaction', async () => { - const expectedResult = ethers.utils.hexlify(ethers.utils.randomBytes(32)) + const expectedResult = ethers.hexlify(ethers.randomBytes(32)) let provider: SequenceProvider let calledCount: number let expectedChainId: number - let expectedTx: ethers.providers.TransactionRequest + let expectedTx: ethers.TransactionRequest beforeEach(async () => { calledCount = 0 provider = new SequenceProvider( { ...basicMockClient, - send: async (request: JsonRpcRequest, chainId?: number) => { - expect(chainId).to.equal(expectedChainId) + request(request: JsonRpcRequest): Promise { + expect(request.chainId).to.equal(expectedChainId) expect(request.method).to.equal('eth_sendTransaction') expect(request.params).to.deep.equal([expectedTx]) calledCount++ - return expectedResult + return Promise.resolve(expectedResult) } } as unknown as SequenceClient, providerFor @@ -1466,7 +1491,7 @@ describe('SequenceProvider', () => { expectedTx = { to: ethers.Wallet.createRandom().address, value: '9000', - data: ethers.utils.hexlify(ethers.utils.randomBytes(66)) + data: ethers.hexlify(ethers.randomBytes(66)) } }) @@ -1512,7 +1537,7 @@ describe('SequenceProvider', () => { }) ;['eth_sign', 'personal_sign', 'sequence_sign'].forEach(method => { describe(`perform ${method}`, async () => { - const expectedResult = ethers.utils.hexlify(ethers.utils.randomBytes(120)) + const expectedResult = ethers.hexlify(ethers.randomBytes(120)) let provider: SequenceProvider let calledCount: number @@ -1526,19 +1551,19 @@ describe('SequenceProvider', () => { provider = new SequenceProvider( { ...basicMockClient, - send: async (request: JsonRpcRequest, chainId?: number) => { - expect(chainId).to.equal(expectedChainId) + request(request: JsonRpcRequest): Promise { + expect(request.chainId).to.equal(expectedChainId) expect(request.method).to.equal(method) expect(request.params).to.deep.equal([expectedAddress, expectedMessage]) calledCount++ - return expectedResult + return Promise.resolve(expectedResult) } } as unknown as SequenceClient, providerFor ) expectedAddress = ethers.Wallet.createRandom().address - expectedMessage = ethers.utils.hexlify(ethers.utils.randomBytes(66)) + expectedMessage = ethers.hexlify(ethers.randomBytes(66)) }) it('should call sign on main provider', async () => { @@ -1573,7 +1598,7 @@ describe('SequenceProvider', () => { }) ;['eth_signTypedData', 'eth_signTypedData_v4', 'sequence_signTypedData_v4'].forEach(method => { describe(`perform ${method}`, async () => { - const expectedResult = ethers.utils.hexlify(ethers.utils.randomBytes(121)) + const expectedResult = ethers.hexlify(ethers.randomBytes(121)) let provider: SequenceProvider let calledCount: number @@ -1587,19 +1612,19 @@ describe('SequenceProvider', () => { provider = new SequenceProvider( { ...basicMockClient, - send: async (request: JsonRpcRequest, chainId?: number) => { - expect(chainId).to.equal(expectedChainId) + request(request: JsonRpcRequest): Promise { + expect(request.chainId).to.equal(expectedChainId) expect(request.method).to.equal(method) expect(request.params).to.deep.equal([expectedAddress, expectedMessage]) calledCount++ - return expectedResult + return Promise.resolve(expectedResult) } } as unknown as SequenceClient, providerFor ) expectedAddress = ethers.Wallet.createRandom().address - expectedMessage = [{ thisisjustdata: ethers.utils.hexlify(ethers.utils.randomBytes(66)), sure: 'yes' }] + expectedMessage = [{ thisisjustdata: ethers.hexlify(ethers.randomBytes(66)), sure: 'yes' }] }) it('should call sign on main provider', async () => { @@ -1667,14 +1692,14 @@ describe('SequenceProvider', () => { it('should forward method with parameters', async () => { await provider.perform('evm_mine', []) await provider.perform('evm_mine', []) - const block1 = await hardhat1Provider.getBlock(2).then(t => t.hash) + const block1 = await hardhat1Provider.getBlock(2).then(t => t?.hash) expect(await provider.perform('eth_getBlockByNumber', ['0x2', false]).then(t => t.hash)).to.equal(block1) }) it('should forward method using request', async () => { await provider.request({ method: 'evm_mine', params: [] }) await provider.request({ method: 'evm_mine', params: [] }) - const block1 = await hardhat1Provider.getBlock(2).then(t => t.hash) + const block1 = await hardhat1Provider.getBlock(2).then(t => t?.hash) expect(await provider.request({ method: 'eth_getBlockByNumber', params: ['0x2', false] }).then(t => t.hash)).to.equal( block1 ) @@ -1708,13 +1733,13 @@ describe('SequenceProvider', () => { const provider = new SequenceProvider(basicMockClient, providerFor) const initialNetwork = await provider.detectNetwork() - expect(initialNetwork.chainId).to.equal(31337, 'initial network') + expect(initialNetwork.chainId).to.equal(31337n, 'initial network') provider.setDefaultChainId(31338) await new Promise(resolve => setTimeout(resolve, 100)) const newNetwork = await provider.detectNetwork() - expect(newNetwork.chainId).to.equal(31338, '2nd network') + expect(newNetwork.chainId).to.equal(31338n, '2nd network') }) it('should update polling block number', async () => { @@ -1730,7 +1755,7 @@ describe('SequenceProvider', () => { expect(b1).to.not.equal(b2) await new Promise(resolve => setTimeout(resolve, 250)) - const initialBlockNumber = provider.blockNumber + const initialBlockNumber = await provider.getBlockNumber() provider.setDefaultChainId(31338) diff --git a/packages/provider/tests/remove-eip191prefix.spec.ts b/packages/provider/tests/remove-eip191prefix.spec.ts index 1a4c31f7c..f0a839f93 100644 --- a/packages/provider/tests/remove-eip191prefix.spec.ts +++ b/packages/provider/tests/remove-eip191prefix.spec.ts @@ -19,16 +19,16 @@ const { expect } = chai.use(chaiAsPromised) describe('trimming eip191prefix', () => { it('should trim prefix', () => { - expect(ethers.utils.toUtf8String(trimEIP191Prefix(trimEIP191Prefix_test1_prefixed))).equal(trimEIP191Prefix_test1_raw) + expect(ethers.toUtf8String(trimEIP191Prefix(trimEIP191Prefix_test1_prefixed))).equal(trimEIP191Prefix_test1_raw) }) it('should handle eip191 exempt messages (by returning early)', () => { - expect(ethers.utils.toUtf8String(trimEIP191Prefix(trimEIP191Prefix_test2_prefixed))).equal(trimEIP191Prefix_test2_raw) + expect(ethers.toUtf8String(trimEIP191Prefix(trimEIP191Prefix_test2_prefixed))).equal(trimEIP191Prefix_test2_raw) }) it('should trim prefix for case where max prefix char as number is bigger than the length of the message', () => { - expect(ethers.utils.toUtf8String(trimEIP191Prefix(trimEIP191Prefix_test3_prefixed))).equal(trimEIP191Prefix_test3_raw) - expect(ethers.utils.toUtf8String(trimEIP191Prefix(trimEIP191Prefix_test4_prefixed))).equal(trimEIP191Prefix_test4_raw) - expect(ethers.utils.toUtf8String(trimEIP191Prefix(trimEIP191Prefix_test5_prefixed))).equal(trimEIP191Prefix_test5_raw) + expect(ethers.toUtf8String(trimEIP191Prefix(trimEIP191Prefix_test3_prefixed))).equal(trimEIP191Prefix_test3_raw) + expect(ethers.toUtf8String(trimEIP191Prefix(trimEIP191Prefix_test4_prefixed))).equal(trimEIP191Prefix_test4_raw) + expect(ethers.toUtf8String(trimEIP191Prefix(trimEIP191Prefix_test5_prefixed))).equal(trimEIP191Prefix_test5_raw) }) }) diff --git a/packages/provider/tests/signer.spec.ts b/packages/provider/tests/signer.spec.ts index 36044d9a9..bf0a86825 100644 --- a/packages/provider/tests/signer.spec.ts +++ b/packages/provider/tests/signer.spec.ts @@ -13,11 +13,10 @@ import { } from '../src' import { expect } from 'chai' import { JsonRpcRequest, JsonRpcResponse, allNetworks } from '@0xsequence/network' -import { ExtendedTransactionRequest } from '../src/extended' -import { TypedData } from '@0xsequence/utils' +import { TypedData, parseEther } from '@0xsequence/utils' -const hardhat1Provider = new ethers.providers.JsonRpcProvider('http://127.0.0.1:9595') -const hardhat2Provider = new ethers.providers.JsonRpcProvider('http://127.0.0.1:8595') +const hardhat1Provider = new ethers.JsonRpcProvider('http://127.0.0.1:9595') +const hardhat2Provider = new ethers.JsonRpcProvider('http://127.0.0.1:8595') const testAccounts = [ new ethers.Wallet('0xcd0434442164a4a6ef9bb677da8dc326fddf412cad4df65e1a3f2555aee5e2b3').connect(hardhat1Provider), @@ -59,7 +58,7 @@ const basicMockClient = { onAccountsChanged: () => {} } as unknown as SequenceClient -async function waitUntilNoFail(provider: ethers.providers.Provider, timeout = 20000): Promise { +async function waitUntilNoFail(provider: ethers.Provider, timeout = 20000): Promise { const start = Date.now() while (Date.now() - start < timeout) { try { @@ -248,79 +247,53 @@ describe('SequenceSigner', () => { ).getSigner() // Send 10 wei in hardhat1 and 20 wei in hardhat2 - await testAccounts[0].sendTransaction({ - to: address, - value: 10 - }) + await testAccounts[0] + .sendTransaction({ + to: address, + value: 10 + }) + .then(tx => tx.wait()) - await testAccounts[1].sendTransaction({ - to: address, - value: 20 - }) + await testAccounts[1] + .sendTransaction({ + to: address, + value: 20 + }) + .then(tx => tx.wait()) }) it('should return the balance on default chain', async () => { - expect(await signer.getBalance().then(b => b.toNumber())).to.equal(10) + expect(await signer.getBalance()).to.equal(10n) }) it('should return the balance on default chain after switching networks', async () => { signer.provider.setDefaultChainId(31338) - expect(await signer.getBalance().then(b => b.toNumber())).to.equal(20) + expect(await signer.getBalance()).to.equal(20n) }) it('should return the balance on specific chain', async () => { - expect(await signer.getBalance(undefined, { chainId: 31337 }).then(b => b.toNumber())).to.equal(10) - expect(await signer.getBalance(undefined, { chainId: 31338 }).then(b => b.toNumber())).to.equal(20) + expect(await signer.getBalance(undefined, { chainId: 31337 })).to.equal(10n) + expect(await signer.getBalance(undefined, { chainId: 31338 })).to.equal(20n) }) it('should return the balance on specific chain using string network name', async () => { - expect(await signer.getBalance(undefined, { chainId: 'hardhat' }).then(b => b.toNumber())).to.equal(10) - expect(await signer.getBalance(undefined, { chainId: 'hardhat2' }).then(b => b.toNumber())).to.equal(20) + expect(await signer.getBalance(undefined, { chainId: 'hardhat' })).to.equal(10n) + expect(await signer.getBalance(undefined, { chainId: 'hardhat2' })).to.equal(20n) }) it('should return the balance on static network signer', async () => { - expect( - await signer - .getSigner(31337) - .getBalance() - .then(b => b.toNumber()) - ).to.equal(10) - expect( - await signer - .getSigner(31338) - .getBalance() - .then(b => b.toNumber()) - ).to.equal(20) + expect(await signer.getSigner(31337).getBalance()).to.equal(10n) + expect(await signer.getSigner(31338).getBalance()).to.equal(20n) }) it('should return the balance on static network signer using string network name', async () => { - expect( - await signer - .getSigner('hardhat') - .getBalance() - .then(b => b.toNumber()) - ).to.equal(10) - expect( - await signer - .getSigner('hardhat2') - .getBalance() - .then(b => b.toNumber()) - ).to.equal(20) + expect(await signer.getSigner('hardhat').getBalance()).to.equal(10n) + expect(await signer.getSigner('hardhat2').getBalance()).to.equal(20n) }) it('should return balance on specific chain when passing chainId', async () => { - expect( - await signer - .getSigner('hardhat') - .getBalance(undefined, { chainId: 31337 }) - .then(b => b.toNumber()) - ).to.equal(10) - expect( - await signer - .getSigner('hardhat2') - .getBalance(undefined, { chainId: 31338 }) - .then(b => b.toNumber()) - ).to.equal(20) + expect(await signer.getSigner('hardhat').getBalance(undefined, { chainId: 31337 })).to.equal(10n) + expect(await signer.getSigner('hardhat2').getBalance(undefined, { chainId: 31338 })).to.equal(20n) }) it('should fail to return balance on specific chain when passing different chainId', async () => { @@ -333,8 +306,8 @@ describe('SequenceSigner', () => { describe('estimate gas', () => { let signer: SequenceSigner - let eg1: ethers.BigNumber - let eg2: ethers.BigNumber + let eg1: bigint + let eg2: bigint let addr: string @@ -347,31 +320,35 @@ describe('SequenceSigner', () => { }) .then(r => r.wait()) + if (!res?.contractAddress) { + throw new Error('Could not get transaction receipt') + } + addr = res.contractAddress eg1 = await hardhat1Provider.estimateGas({ to: addr }) eg2 = await hardhat2Provider.estimateGas({ to: addr }) - expect(eg1).to.not.deep.equal(eg2) + expect(eg1).to.not.equal(eg2) signer = new SequenceProvider(basicMockClient, providerFor).getSigner() }) it('forward estimateGas - default', async () => { - expect(await signer.estimateGas({ to: addr })).to.deep.equal(eg1) + expect(await signer.estimateGas({ to: addr })).to.equal(eg1) signer.provider.setDefaultChainId(31338) - expect(await signer.estimateGas({ to: addr })).to.deep.equal(eg2) + expect(await signer.estimateGas({ to: addr })).to.equal(eg2) }) it('forward estimateGas - specific chain', async () => { - expect(await signer.estimateGas({ to: addr }, { chainId: 31337 })).to.deep.equal(eg1) - expect(await signer.estimateGas({ to: addr }, { chainId: 31338 })).to.deep.equal(eg2) + expect(await signer.estimateGas({ to: addr }, { chainId: 31337 })).to.equal(eg1) + expect(await signer.estimateGas({ to: addr }, { chainId: 31338 })).to.equal(eg2) }) it('forward estimateGas - static network provider', async () => { - expect(await signer.getSigner('hardhat').estimateGas({ to: addr })).to.deep.equal(eg1) - expect(await signer.getSigner('hardhat2').estimateGas({ to: addr })).to.deep.equal(eg2) + expect(await signer.getSigner('hardhat').estimateGas({ to: addr })).to.equal(eg1) + expect(await signer.getSigner('hardhat2').estimateGas({ to: addr })).to.equal(eg2) }) it('fail to forward estimateGas - static network provider for different chain', async () => { @@ -393,6 +370,10 @@ describe('SequenceSigner', () => { }) .then(r => r.wait()) + if (!res?.contractAddress) { + throw new Error('Could not get transaction receipt') + } + addr = res.contractAddress expect(await hardhat1Provider.call({ to: addr })).to.equal('0x112233') @@ -408,8 +389,8 @@ describe('SequenceSigner', () => { }) it('forward call - specific chain', async () => { - expect(await signer.call({ to: addr }, undefined, { chainId: 31337 })).to.equal('0x112233') - expect(await signer.call({ to: addr }, undefined, { chainId: 31338 })).to.equal('0x') + expect(await signer.call({ to: addr }, { chainId: 31337 })).to.equal('0x112233') + expect(await signer.call({ to: addr }, { chainId: 31338 })).to.equal('0x') }) it('forward call - static network provider', async () => { @@ -418,13 +399,13 @@ describe('SequenceSigner', () => { }) it('fail to forward call - static network provider for different chain', async () => { - await expect(signer.getSigner('hardhat2').call({ to: addr }, undefined, { chainId: 31337 })).to.be.rejectedWith( + await expect(signer.getSigner('hardhat2').call({ to: addr }, { chainId: 31337 })).to.be.rejectedWith( 'This signer only supports the network 31338, but 31337 was requested.' ) }) }) - describe('getGasPrice', () => { + describe('getFeeData', () => { let signer: SequenceSigner beforeEach(() => { @@ -433,40 +414,40 @@ describe('SequenceSigner', () => { if (chainId === 31337) { return { ...hardhat1Provider, - getGasPrice: async () => ethers.BigNumber.from(1) - } as unknown as ethers.providers.JsonRpcProvider + getFeeData: async () => ({ gasPrice: 1n }) + } as unknown as ethers.JsonRpcProvider } if (chainId === 31338) { return { ...hardhat2Provider, - getGasPrice: async () => ethers.BigNumber.from(2) - } as unknown as ethers.providers.JsonRpcProvider + getFeeData: async () => ({ gasPrice: 2n }) + } as unknown as ethers.JsonRpcProvider } throw new Error(`No provider for chainId ${chainId}`) }).getSigner() }) - it('forward getGasPrice - default', async () => { - expect(await signer.getGasPrice()).to.deep.equal(ethers.BigNumber.from(1)) + it('forward getFeeData - default', async () => { + expect((await signer.getFeeData()).gasPrice).to.equal(1n) signer.provider.setDefaultChainId(31338) - expect(await signer.getGasPrice()).to.deep.equal(ethers.BigNumber.from(2)) + expect((await signer.getFeeData()).gasPrice).to.equal(2n) }) - it('forward getGasPrice - specific chain', async () => { - expect(await signer.getGasPrice({ chainId: 31337 })).to.deep.equal(ethers.BigNumber.from(1)) - expect(await signer.getGasPrice({ chainId: 31338 })).to.deep.equal(ethers.BigNumber.from(2)) + it('forward getFeeData - specific chain', async () => { + expect((await signer.getFeeData({ chainId: 31337 })).gasPrice).to.equal(1n) + expect((await signer.getFeeData({ chainId: 31338 })).gasPrice).to.equal(2n) }) - it('forward getGasPrice - static network provider', async () => { - expect(await signer.getSigner('hardhat').getGasPrice()).to.deep.equal(ethers.BigNumber.from(1)) - expect(await signer.getSigner(31338).getGasPrice()).to.deep.equal(ethers.BigNumber.from(2)) + it('forward getFeeData - static network provider', async () => { + expect((await signer.getSigner('hardhat').getFeeData()).gasPrice).to.equal(1n) + expect((await signer.getSigner(31338).getFeeData()).gasPrice).to.equal(2n) }) - it('fail to forward getGasPrice - static network provider for different chain', async () => { - await expect(signer.getSigner('hardhat').getGasPrice({ chainId: 31338 })).to.be.rejectedWith( + it('fail to forward getFeeData - static network provider for different chain', async () => { + await expect(signer.getSigner('hardhat').getFeeData({ chainId: 31338 })).to.be.rejectedWith( 'This signer only supports the network 31337, but 31338 was requested.' ) }) @@ -474,12 +455,12 @@ describe('SequenceSigner', () => { describe('ENS', () => { let signer: SequenceSigner - let mainnetProvider: ethers.providers.JsonRpcProvider + let mainnetProvider: ethers.JsonRpcProvider let vitalikAddr: string | null before(async () => { - mainnetProvider = new ethers.providers.JsonRpcProvider('https://nodes.sequence.app/mainnet') + mainnetProvider = new ethers.JsonRpcProvider('https://nodes.sequence.app/mainnet') vitalikAddr = await mainnetProvider.resolveName('vitalik.eth') }) @@ -639,15 +620,15 @@ describe('SequenceSigner', () => { let signer: SequenceSigner let callsToSignMessage: number - let expectedSignMessage: ethers.utils.BytesLike + let expectedSignMessage: ethers.BytesLike let expectedOptions: OptionalEIP6492 & OptionalChainId let returnValue: string beforeEach(() => { callsToSignMessage = 0 - expectedSignMessage = ethers.utils.hexlify(ethers.utils.randomBytes(64)) + expectedSignMessage = ethers.hexlify(ethers.randomBytes(64)) expectedOptions = {} - returnValue = ethers.utils.hexlify(ethers.utils.randomBytes(99)) + returnValue = ethers.hexlify(ethers.randomBytes(99)) signer = new SequenceProvider( { @@ -738,7 +719,7 @@ describe('SequenceSigner', () => { }) it('should pass array instead of string', async () => { - expectedSignMessage = ethers.utils.arrayify(ethers.utils.randomBytes(199)) + expectedSignMessage = ethers.randomBytes(199) expectedOptions = { chainId: 31337, eip6492: true } expect(await signer.signMessage(expectedSignMessage)).to.equal(returnValue) }) @@ -760,7 +741,7 @@ describe('SequenceSigner', () => { name: 'Sequence', version: '1', chainId: 31337, - verifyingContract: ethers.utils.hexlify(ethers.utils.randomBytes(12)) + verifyingContract: ethers.hexlify(ethers.randomBytes(12)) } expectedTypes = { EIP712Domain: [ @@ -778,12 +759,12 @@ describe('SequenceSigner', () => { } expectedMessage = { nonce: 1, - from: ethers.utils.hexlify(ethers.utils.randomBytes(12)), - to: ethers.utils.hexlify(ethers.utils.randomBytes(20)), - data: ethers.utils.hexlify(ethers.utils.randomBytes(32)) + from: ethers.hexlify(ethers.randomBytes(12)), + to: ethers.hexlify(ethers.randomBytes(20)), + data: ethers.hexlify(ethers.randomBytes(32)) } expectedOptions = {} - returnValue = ethers.utils.hexlify(ethers.utils.randomBytes(99)) + returnValue = ethers.hexlify(ethers.randomBytes(99)) signer = new SequenceProvider( { @@ -893,9 +874,7 @@ describe('SequenceSigner', () => { describe('sendTransaction', () => { let callsToSendTransaction: number - let expectedTransactionRequest: - | ethers.utils.Deferrable[] - | ethers.utils.Deferrable + let expectedTransactionRequest: ethers.TransactionRequest[] | ethers.TransactionRequest let expectedOptions: OptionalChainIdLike @@ -905,9 +884,9 @@ describe('SequenceSigner', () => { callsToSendTransaction = 0 expectedTransactionRequest = { - to: ethers.utils.hexlify(ethers.utils.randomBytes(12)), - value: ethers.utils.parseEther('1.0'), - data: ethers.utils.hexlify(ethers.utils.randomBytes(55)), + to: ethers.hexlify(ethers.randomBytes(12)), + value: parseEther('1.0'), + data: ethers.hexlify(ethers.randomBytes(55)), gasLimit: 40000 } @@ -917,9 +896,7 @@ describe('SequenceSigner', () => { { ...basicMockClient, sendTransaction: async ( - transactionRequest: - | ethers.utils.Deferrable[] - | ethers.utils.Deferrable, + transactionRequest: ethers.TransactionRequest[] | ethers.TransactionRequest, options: OptionalChainIdLike ) => { expect(transactionRequest).to.deep.equal(expectedTransactionRequest) @@ -943,50 +920,50 @@ describe('SequenceSigner', () => { it('should send transaction on default chain', async () => { expectedOptions = { chainId: 31337 } - const tx = await signer.sendTransaction(expectedTransactionRequest) - expect(tx.wait()).to.be.fulfilled - expect(ethers.utils.arrayify(tx.hash)).to.have.lengthOf(32) + const tx = await signer.sendTransaction(expectedTransactionRequest).then(tx => tx.wait()) + expect(ethers.getBytes(tx!.hash)).to.have.lengthOf(32) expect(callsToSendTransaction).to.equal(1) }) it('should send transaction on default chain after switching networks', async () => { expectedOptions = { chainId: 31338 } signer.provider.setDefaultChainId(31338) - const tx = await signer.sendTransaction(expectedTransactionRequest) - expect(tx.wait()).to.be.fulfilled - expect(ethers.utils.arrayify(tx.hash)).to.have.lengthOf(32) + const tx = await signer.sendTransaction(expectedTransactionRequest).then(tx => tx.wait()) + expect(ethers.getBytes(tx!.hash)).to.have.lengthOf(32) expect(callsToSendTransaction).to.equal(1) }) it('should send transaction on specific chain', async () => { expectedOptions = { chainId: 31338 } - const tx = await signer.sendTransaction(expectedTransactionRequest, { chainId: 31338 }) - expect(tx.wait()).to.be.fulfilled - expect(ethers.utils.arrayify(tx.hash)).to.have.lengthOf(32) + const tx = await signer.sendTransaction(expectedTransactionRequest, { chainId: 31338 }).then(tx => tx.wait()) + expect(ethers.getBytes(tx!.hash)).to.have.lengthOf(32) expect(callsToSendTransaction).to.equal(1) }) it('should send transaction on specific chain using string network name', async () => { expectedOptions = { chainId: 31338 } - const tx = await signer.sendTransaction(expectedTransactionRequest, { chainId: 'hardhat2' }) - expect(tx.wait()).to.be.fulfilled - expect(ethers.utils.arrayify(tx.hash)).to.have.lengthOf(32) + const tx = await signer.sendTransaction(expectedTransactionRequest, { chainId: 'hardhat2' }).then(tx => tx.wait()) + expect(ethers.getBytes(tx!.hash)).to.have.lengthOf(32) expect(callsToSendTransaction).to.equal(1) }) it('should send transaction on static network signer', async () => { expectedOptions = { chainId: 31338 } - const tx = await signer.getSigner(31338).sendTransaction(expectedTransactionRequest) - expect(tx.wait()).to.be.fulfilled - expect(ethers.utils.arrayify(tx.hash)).to.have.lengthOf(32) + const tx = await signer + .getSigner(31338) + .sendTransaction(expectedTransactionRequest) + .then(tx => tx.wait()) + expect(ethers.getBytes(tx!.hash)).to.have.lengthOf(32) expect(callsToSendTransaction).to.equal(1) }) it('should send transaction on static network signer if passing chainId', async () => { expectedOptions = { chainId: 31338 } - const tx = await signer.getSigner(31338).sendTransaction(expectedTransactionRequest, { chainId: 'hardhat2' }) - expect(tx.wait()).to.be.fulfilled - expect(ethers.utils.arrayify(tx.hash)).to.have.lengthOf(32) + const tx = await signer + .getSigner(31338) + .sendTransaction(expectedTransactionRequest, { chainId: 'hardhat2' }) + .then(tx => tx.wait()) + expect(ethers.getBytes(tx!.hash)).to.have.lengthOf(32) expect(callsToSendTransaction).to.equal(1) }) @@ -1000,92 +977,24 @@ describe('SequenceSigner', () => { expectedOptions = { chainId: 31338 } expectedTransactionRequest = [ { - to: ethers.utils.hexlify(ethers.utils.randomBytes(12)), - value: ethers.utils.parseEther('1.0'), - data: ethers.utils.hexlify(ethers.utils.randomBytes(55)) + to: ethers.hexlify(ethers.randomBytes(12)), + value: parseEther('1.0'), + data: ethers.hexlify(ethers.randomBytes(55)) }, { - to: ethers.utils.hexlify(ethers.utils.randomBytes(12)), - data: ethers.utils.hexlify(ethers.utils.randomBytes(1)) + to: ethers.hexlify(ethers.randomBytes(12)), + data: ethers.hexlify(ethers.randomBytes(1)) }, { - to: ethers.utils.hexlify(ethers.utils.randomBytes(12)), + to: ethers.hexlify(ethers.randomBytes(12)), value: 2 } ] const tx = await signer.sendTransaction(expectedTransactionRequest, { chainId: 31338 }) expect(tx.wait()).to.be.fulfilled - expect(ethers.utils.arrayify(tx.hash)).to.have.lengthOf(32) + expect(ethers.getBytes(tx.hash)).to.have.lengthOf(32) expect(callsToSendTransaction).to.equal(1) }) - - it('shoud send deffered transaction', async () => { - expectedOptions = { chainId: 31338 } - const expected = { - to: ethers.utils.hexlify(ethers.utils.randomBytes(12)), - value: ethers.utils.parseEther('1.0').toString() - } - - expectedTransactionRequest = JSON.parse(JSON.stringify(expected)) - - const derrered = { - to: new Promise(async r => { - await new Promise(d => setTimeout(d, 1000)) - return r(expected.to) - }), - value: new Promise(async r => { - await new Promise(d => setTimeout(d, 600)) - return r(expected.value) - }) - } - - const tx = await signer.sendTransaction(derrered, { chainId: 31338 }) - expect(tx.wait()).to.be.fulfilled - expect(ethers.utils.arrayify(tx.hash)).to.have.lengthOf(32) - }) - - it('shoud send array of deffered transactions', async () => { - expectedOptions = { chainId: 31338 } - const expected = [ - { - to: ethers.utils.hexlify(ethers.utils.randomBytes(12)), - value: ethers.utils.parseEther('1.0').toString() - }, - { - to: ethers.utils.hexlify(ethers.utils.randomBytes(12)), - data: ethers.utils.hexlify(ethers.utils.randomBytes(111)) - } - ] - - expectedTransactionRequest = JSON.parse(JSON.stringify(expected)) - - const derrered = [ - { - to: new Promise(async r => { - await new Promise(d => setTimeout(d, 1000)) - return r(expected[0].to) - }), - value: new Promise(async r => { - await new Promise(d => setTimeout(d, 600)) - return r(expected[0].value!) - }) - }, - { - to: new Promise(async r => { - await new Promise(d => setTimeout(d, 412)) - return r(expected[1].to) - }), - data: new Promise(async r => { - await new Promise(d => setTimeout(d, 1001)) - return r(expected[1].data!) - }) - } - ] - - const tx = await signer.sendTransaction(derrered, { chainId: 31338 }) - expect(tx.wait()).to.be.fulfilled - expect(ethers.utils.arrayify(tx.hash)).to.have.lengthOf(32) - }) }) }) diff --git a/packages/react-native/CHANGELOG.md b/packages/react-native/CHANGELOG.md index 65ef2cac8..9a59d43ed 100644 --- a/packages/react-native/CHANGELOG.md +++ b/packages/react-native/CHANGELOG.md @@ -1,5 +1,452 @@ # @0xsequence/react-native +## 2.2.14 + +### Patch Changes + +- Somnia Testnet and Monad Testnet +- Updated dependencies + - @0xsequence/waas@2.2.14 + +## 2.2.13 + +### Patch Changes + +- Add XR1 to all networks +- Updated dependencies + - @0xsequence/waas@2.2.13 + +## 2.2.12 + +### Patch Changes + +- Add XR1 +- Updated dependencies + - @0xsequence/waas@2.2.12 + +## 2.2.11 + +### Patch Changes + +- Relayer updates +- Updated dependencies + - @0xsequence/waas@2.2.11 + +## 2.2.10 + +### Patch Changes + +- Etherlink support +- Updated dependencies + - @0xsequence/waas@2.2.10 + +## 2.2.9 + +### Patch Changes + +- Indexer gateway native token balances +- Updated dependencies + - @0xsequence/waas@2.2.9 + +## 2.2.8 + +### Patch Changes + +- Add Moonbeam and Moonbase Alpha +- Updated dependencies + - @0xsequence/waas@2.2.8 + +## 2.2.7 + +### Patch Changes + +- Update Builder package +- Updated dependencies + - @0xsequence/waas@2.2.7 + +## 2.2.6 + +### Patch Changes + +- Update relayer package +- Updated dependencies + - @0xsequence/waas@2.2.6 + +## 2.2.5 + +### Patch Changes + +- auth: fix sequence indexer gateway url +- account: immutable wallet proxy hook +- Updated dependencies +- Updated dependencies + - @0xsequence/waas@2.2.5 + +## 2.2.4 + +### Patch Changes + +- network: update soneium mainnet block explorer url +- waas: signTypedData intent support +- Updated dependencies +- Updated dependencies + - @0xsequence/waas@2.2.4 + +## 2.2.3 + +### Patch Changes + +- provider: updating initWallet to use connected network configs if they exist +- Updated dependencies + - @0xsequence/waas@2.2.3 + +## 2.2.2 + +### Patch Changes + +- pass projectAccessKey to relayer at all times +- Updated dependencies + - @0xsequence/waas@2.2.2 + +## 2.2.1 + +### Patch Changes + +- waas-ethers: sign typed data +- Updated dependencies + - @0xsequence/waas@2.2.1 + +## 2.2.0 + +### Minor Changes + +- indexer: gateway client +- @0xsequence/builder +- upgrade puppeteer to v23.10.3 + +### Patch Changes + +- Updated dependencies +- Updated dependencies +- Updated dependencies + - @0xsequence/waas@2.2.0 + +## 2.1.8 + +### Patch Changes + +- Add Soneium Mainnet +- Updated dependencies + - @0xsequence/waas@2.1.8 + +## 2.1.7 + +### Patch Changes + +- guard: pass project access key to guard requests +- Updated dependencies + - @0xsequence/waas@2.1.7 + +## 2.1.6 + +### Patch Changes + +- Add LAOS and Telos Testnet chains +- Updated dependencies + - @0xsequence/waas@2.1.6 + +## 2.1.5 + +### Patch Changes + +- account: save presigned configuration with reference chain id 1 +- Updated dependencies + - @0xsequence/waas@2.1.5 + +## 2.1.4 + +### Patch Changes + +- provider: pass projectAccessKey into MuxMessageProvider +- Updated dependencies + - @0xsequence/waas@2.1.4 + +## 2.1.3 + +### Patch Changes + +- waas: time drift date fix due to strange browser quirk +- Updated dependencies + - @0xsequence/waas@2.1.3 + +## 2.1.2 + +### Patch Changes + +- provider: export analytics correctly +- Updated dependencies + - @0xsequence/waas@2.1.2 + +## 2.1.1 + +### Patch Changes + +- Add LAOS chain support +- Updated dependencies + - @0xsequence/waas@2.1.1 + +## 2.1.0 + +### Minor Changes + +- account: forward project access key when estimating fees and sending transactions + +### Patch Changes + +- sessions: save signatures with reference chain id +- Updated dependencies +- Updated dependencies + - @0xsequence/waas@2.1.0 + +## 2.0.26 + +### Patch Changes + +- account: fix chain id comparison +- Updated dependencies + - @0xsequence/waas@2.0.26 + +## 2.0.25 + +### Patch Changes + +- skale-nebula: deploy gas limit = 10m +- Updated dependencies + - @0xsequence/waas@2.0.25 + +## 2.0.24 + +### Patch Changes + +- sessions: arweave: configurable gateway url +- waas: use /status to get time drift before sending any intents +- Updated dependencies +- Updated dependencies + - @0xsequence/waas@2.0.24 + +## 2.0.23 + +### Patch Changes + +- Add The Root Network support +- Updated dependencies + - @0xsequence/waas@2.0.23 + +## 2.0.22 + +### Patch Changes + +- Add SKALE Nebula Mainnet support +- Updated dependencies + - @0xsequence/waas@2.0.22 + +## 2.0.21 + +### Patch Changes + +- account: add publishWitnessFor +- Updated dependencies + - @0xsequence/waas@2.0.21 + +## 2.0.20 + +### Patch Changes + +- upgrade deps, and improve waas session status handling +- Updated dependencies + - @0xsequence/waas@2.0.20 + +## 2.0.19 + +### Patch Changes + +- Add Immutable zkEVM support +- Updated dependencies + - @0xsequence/waas@2.0.19 + +## 2.0.18 + +### Patch Changes + +- waas: new contractCall transaction type +- sessions: add arweave owner +- Updated dependencies +- Updated dependencies + - @0xsequence/waas@2.0.18 + +## 2.0.17 + +### Patch Changes + +- update waas auth to clear session before signIn +- Updated dependencies + - @0xsequence/waas@2.0.17 + +## 2.0.16 + +### Patch Changes + +- Removed Astar chains +- Updated dependencies + - @0xsequence/waas@2.0.16 + +## 2.0.15 + +### Patch Changes + +- indexer: update bindings with token balance additions +- Updated dependencies + - @0xsequence/waas@2.0.15 + +## 2.0.14 + +### Patch Changes + +- sessions: arweave config reader +- network: add b3 and apechain mainnet configs +- Updated dependencies +- Updated dependencies + - @0xsequence/waas@2.0.14 + +## 2.0.13 + +### Patch Changes + +- network: toy-testnet +- Updated dependencies + - @0xsequence/waas@2.0.13 + +## 2.0.12 + +### Patch Changes + +- api: update bindings +- Updated dependencies + - @0xsequence/waas@2.0.12 + +## 2.0.11 + +### Patch Changes + +- waas: intents test fix +- api: update bindings +- Updated dependencies +- Updated dependencies + - @0xsequence/waas@2.0.11 + +## 2.0.10 + +### Patch Changes + +- network: soneium minato testnet +- Updated dependencies + - @0xsequence/waas@2.0.10 + +## 2.0.9 + +### Patch Changes + +- network: fix SKALE network name +- Updated dependencies + - @0xsequence/waas@2.0.9 + +## 2.0.8 + +### Patch Changes + +- metadata: update bindings +- Updated dependencies + - @0xsequence/waas@2.0.8 + +## 2.0.7 + +### Patch Changes + +- wallet request handler fix +- Updated dependencies + - @0xsequence/waas@2.0.7 + +## 2.0.6 + +### Patch Changes + +- network: matic -> pol +- Updated dependencies + - @0xsequence/waas@2.0.6 + +## 2.0.5 + +### Patch Changes + +- provider: update databeat to 0.9.2 +- Updated dependencies + - @0xsequence/waas@2.0.5 + +## 2.0.4 + +### Patch Changes + +- network: add skale-nebula-testnet +- Updated dependencies + - @0xsequence/waas@2.0.4 + +## 2.0.3 + +### Patch Changes + +- waas: check session status in SequenceWaaS.isSignedIn() +- Updated dependencies + - @0xsequence/waas@2.0.3 + +## 2.0.2 + +### Patch Changes + +- sessions: property convert serialized bignumber hex value to bigint +- Updated dependencies + - @0xsequence/waas@2.0.2 + +## 2.0.1 + +### Patch Changes + +- waas: http signature check for authenticator requests +- provider: unwrap legacy json rpc responses +- use json replacer and reviver for bigints +- Updated dependencies +- Updated dependencies +- Updated dependencies + - @0xsequence/waas@2.0.1 + +## 2.0.0 + +### Major Changes + +- ethers v6 + +### Patch Changes + +- Updated dependencies + - @0xsequence/waas@2.0.0 + +## 1.10.15 + +### Patch Changes + +- utils: extractProjectIdFromAccessKey +- Updated dependencies + - @0xsequence/waas@1.10.15 + ## 1.10.14 ### Patch Changes diff --git a/packages/react-native/package.json b/packages/react-native/package.json index 39ac93027..e735eb365 100644 --- a/packages/react-native/package.json +++ b/packages/react-native/package.json @@ -1,6 +1,6 @@ { "name": "@0xsequence/react-native", - "version": "1.10.14", + "version": "2.2.14", "description": "react-native compat-lib sub-package for Sequence", "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/react-native", "source": "src/index.ts", diff --git a/packages/relayer/CHANGELOG.md b/packages/relayer/CHANGELOG.md index a67807e93..b1f56d8cc 100644 --- a/packages/relayer/CHANGELOG.md +++ b/packages/relayer/CHANGELOG.md @@ -1,5 +1,556 @@ # @0xsequence/relayer +## 2.2.14 + +### Patch Changes + +- Somnia Testnet and Monad Testnet +- Updated dependencies + - @0xsequence/abi@2.2.14 + - @0xsequence/core@2.2.14 + - @0xsequence/utils@2.2.14 + +## 2.2.13 + +### Patch Changes + +- Add XR1 to all networks +- Updated dependencies + - @0xsequence/abi@2.2.13 + - @0xsequence/core@2.2.13 + - @0xsequence/utils@2.2.13 + +## 2.2.12 + +### Patch Changes + +- Add XR1 +- Updated dependencies + - @0xsequence/abi@2.2.12 + - @0xsequence/core@2.2.12 + - @0xsequence/utils@2.2.12 + +## 2.2.11 + +### Patch Changes + +- Relayer updates +- Updated dependencies + - @0xsequence/abi@2.2.11 + - @0xsequence/core@2.2.11 + - @0xsequence/utils@2.2.11 + +## 2.2.10 + +### Patch Changes + +- Etherlink support +- Updated dependencies + - @0xsequence/abi@2.2.10 + - @0xsequence/core@2.2.10 + - @0xsequence/utils@2.2.10 + +## 2.2.9 + +### Patch Changes + +- Indexer gateway native token balances +- Updated dependencies + - @0xsequence/abi@2.2.9 + - @0xsequence/core@2.2.9 + - @0xsequence/utils@2.2.9 + +## 2.2.8 + +### Patch Changes + +- Add Moonbeam and Moonbase Alpha +- Updated dependencies + - @0xsequence/abi@2.2.8 + - @0xsequence/core@2.2.8 + - @0xsequence/utils@2.2.8 + +## 2.2.7 + +### Patch Changes + +- Update Builder package +- Updated dependencies + - @0xsequence/abi@2.2.7 + - @0xsequence/core@2.2.7 + - @0xsequence/utils@2.2.7 + +## 2.2.6 + +### Patch Changes + +- Update relayer package +- Updated dependencies + - @0xsequence/abi@2.2.6 + - @0xsequence/core@2.2.6 + - @0xsequence/utils@2.2.6 + +## 2.2.5 + +### Patch Changes + +- auth: fix sequence indexer gateway url +- account: immutable wallet proxy hook +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.2.5 + - @0xsequence/core@2.2.5 + - @0xsequence/utils@2.2.5 + +## 2.2.4 + +### Patch Changes + +- network: update soneium mainnet block explorer url +- waas: signTypedData intent support +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.2.4 + - @0xsequence/core@2.2.4 + - @0xsequence/utils@2.2.4 + +## 2.2.3 + +### Patch Changes + +- provider: updating initWallet to use connected network configs if they exist +- Updated dependencies + - @0xsequence/abi@2.2.3 + - @0xsequence/core@2.2.3 + - @0xsequence/utils@2.2.3 + +## 2.2.2 + +### Patch Changes + +- pass projectAccessKey to relayer at all times +- Updated dependencies + - @0xsequence/abi@2.2.2 + - @0xsequence/core@2.2.2 + - @0xsequence/utils@2.2.2 + +## 2.2.1 + +### Patch Changes + +- waas-ethers: sign typed data +- Updated dependencies + - @0xsequence/abi@2.2.1 + - @0xsequence/core@2.2.1 + - @0xsequence/utils@2.2.1 + +## 2.2.0 + +### Minor Changes + +- indexer: gateway client +- @0xsequence/builder +- upgrade puppeteer to v23.10.3 + +### Patch Changes + +- Updated dependencies +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.2.0 + - @0xsequence/core@2.2.0 + - @0xsequence/utils@2.2.0 + +## 2.1.8 + +### Patch Changes + +- Add Soneium Mainnet +- Updated dependencies + - @0xsequence/abi@2.1.8 + - @0xsequence/core@2.1.8 + - @0xsequence/utils@2.1.8 + +## 2.1.7 + +### Patch Changes + +- guard: pass project access key to guard requests +- Updated dependencies + - @0xsequence/abi@2.1.7 + - @0xsequence/core@2.1.7 + - @0xsequence/utils@2.1.7 + +## 2.1.6 + +### Patch Changes + +- Add LAOS and Telos Testnet chains +- Updated dependencies + - @0xsequence/abi@2.1.6 + - @0xsequence/core@2.1.6 + - @0xsequence/utils@2.1.6 + +## 2.1.5 + +### Patch Changes + +- account: save presigned configuration with reference chain id 1 +- Updated dependencies + - @0xsequence/abi@2.1.5 + - @0xsequence/core@2.1.5 + - @0xsequence/utils@2.1.5 + +## 2.1.4 + +### Patch Changes + +- provider: pass projectAccessKey into MuxMessageProvider +- Updated dependencies + - @0xsequence/abi@2.1.4 + - @0xsequence/core@2.1.4 + - @0xsequence/utils@2.1.4 + +## 2.1.3 + +### Patch Changes + +- waas: time drift date fix due to strange browser quirk +- Updated dependencies + - @0xsequence/abi@2.1.3 + - @0xsequence/core@2.1.3 + - @0xsequence/utils@2.1.3 + +## 2.1.2 + +### Patch Changes + +- provider: export analytics correctly +- Updated dependencies + - @0xsequence/abi@2.1.2 + - @0xsequence/core@2.1.2 + - @0xsequence/utils@2.1.2 + +## 2.1.1 + +### Patch Changes + +- Add LAOS chain support +- Updated dependencies + - @0xsequence/abi@2.1.1 + - @0xsequence/core@2.1.1 + - @0xsequence/utils@2.1.1 + +## 2.1.0 + +### Minor Changes + +- account: forward project access key when estimating fees and sending transactions + +### Patch Changes + +- sessions: save signatures with reference chain id +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.1.0 + - @0xsequence/core@2.1.0 + - @0xsequence/utils@2.1.0 + +## 2.0.26 + +### Patch Changes + +- account: fix chain id comparison +- Updated dependencies + - @0xsequence/abi@2.0.26 + - @0xsequence/core@2.0.26 + - @0xsequence/utils@2.0.26 + +## 2.0.25 + +### Patch Changes + +- skale-nebula: deploy gas limit = 10m +- Updated dependencies + - @0xsequence/abi@2.0.25 + - @0xsequence/core@2.0.25 + - @0xsequence/utils@2.0.25 + +## 2.0.24 + +### Patch Changes + +- sessions: arweave: configurable gateway url +- waas: use /status to get time drift before sending any intents +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.24 + - @0xsequence/core@2.0.24 + - @0xsequence/utils@2.0.24 + +## 2.0.23 + +### Patch Changes + +- Add The Root Network support +- Updated dependencies + - @0xsequence/abi@2.0.23 + - @0xsequence/core@2.0.23 + - @0xsequence/utils@2.0.23 + +## 2.0.22 + +### Patch Changes + +- Add SKALE Nebula Mainnet support +- Updated dependencies + - @0xsequence/abi@2.0.22 + - @0xsequence/core@2.0.22 + - @0xsequence/utils@2.0.22 + +## 2.0.21 + +### Patch Changes + +- account: add publishWitnessFor +- Updated dependencies + - @0xsequence/abi@2.0.21 + - @0xsequence/core@2.0.21 + - @0xsequence/utils@2.0.21 + +## 2.0.20 + +### Patch Changes + +- upgrade deps, and improve waas session status handling +- Updated dependencies + - @0xsequence/abi@2.0.20 + - @0xsequence/core@2.0.20 + - @0xsequence/utils@2.0.20 + +## 2.0.19 + +### Patch Changes + +- Add Immutable zkEVM support +- Updated dependencies + - @0xsequence/abi@2.0.19 + - @0xsequence/core@2.0.19 + - @0xsequence/utils@2.0.19 + +## 2.0.18 + +### Patch Changes + +- waas: new contractCall transaction type +- sessions: add arweave owner +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.18 + - @0xsequence/core@2.0.18 + - @0xsequence/utils@2.0.18 + +## 2.0.17 + +### Patch Changes + +- update waas auth to clear session before signIn +- Updated dependencies + - @0xsequence/abi@2.0.17 + - @0xsequence/core@2.0.17 + - @0xsequence/utils@2.0.17 + +## 2.0.16 + +### Patch Changes + +- Removed Astar chains +- Updated dependencies + - @0xsequence/abi@2.0.16 + - @0xsequence/core@2.0.16 + - @0xsequence/utils@2.0.16 + +## 2.0.15 + +### Patch Changes + +- indexer: update bindings with token balance additions +- Updated dependencies + - @0xsequence/abi@2.0.15 + - @0xsequence/core@2.0.15 + - @0xsequence/utils@2.0.15 + +## 2.0.14 + +### Patch Changes + +- sessions: arweave config reader +- network: add b3 and apechain mainnet configs +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.14 + - @0xsequence/core@2.0.14 + - @0xsequence/utils@2.0.14 + +## 2.0.13 + +### Patch Changes + +- network: toy-testnet +- Updated dependencies + - @0xsequence/abi@2.0.13 + - @0xsequence/core@2.0.13 + - @0xsequence/utils@2.0.13 + +## 2.0.12 + +### Patch Changes + +- api: update bindings +- Updated dependencies + - @0xsequence/abi@2.0.12 + - @0xsequence/core@2.0.12 + - @0xsequence/utils@2.0.12 + +## 2.0.11 + +### Patch Changes + +- waas: intents test fix +- api: update bindings +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.11 + - @0xsequence/core@2.0.11 + - @0xsequence/utils@2.0.11 + +## 2.0.10 + +### Patch Changes + +- network: soneium minato testnet +- Updated dependencies + - @0xsequence/abi@2.0.10 + - @0xsequence/core@2.0.10 + - @0xsequence/utils@2.0.10 + +## 2.0.9 + +### Patch Changes + +- network: fix SKALE network name +- Updated dependencies + - @0xsequence/abi@2.0.9 + - @0xsequence/core@2.0.9 + - @0xsequence/utils@2.0.9 + +## 2.0.8 + +### Patch Changes + +- metadata: update bindings +- Updated dependencies + - @0xsequence/abi@2.0.8 + - @0xsequence/core@2.0.8 + - @0xsequence/utils@2.0.8 + +## 2.0.7 + +### Patch Changes + +- wallet request handler fix +- Updated dependencies + - @0xsequence/abi@2.0.7 + - @0xsequence/core@2.0.7 + - @0xsequence/utils@2.0.7 + +## 2.0.6 + +### Patch Changes + +- network: matic -> pol +- Updated dependencies + - @0xsequence/abi@2.0.6 + - @0xsequence/core@2.0.6 + - @0xsequence/utils@2.0.6 + +## 2.0.5 + +### Patch Changes + +- provider: update databeat to 0.9.2 +- Updated dependencies + - @0xsequence/abi@2.0.5 + - @0xsequence/core@2.0.5 + - @0xsequence/utils@2.0.5 + +## 2.0.4 + +### Patch Changes + +- network: add skale-nebula-testnet +- Updated dependencies + - @0xsequence/abi@2.0.4 + - @0xsequence/core@2.0.4 + - @0xsequence/utils@2.0.4 + +## 2.0.3 + +### Patch Changes + +- waas: check session status in SequenceWaaS.isSignedIn() +- Updated dependencies + - @0xsequence/abi@2.0.3 + - @0xsequence/core@2.0.3 + - @0xsequence/utils@2.0.3 + +## 2.0.2 + +### Patch Changes + +- sessions: property convert serialized bignumber hex value to bigint +- Updated dependencies + - @0xsequence/abi@2.0.2 + - @0xsequence/core@2.0.2 + - @0xsequence/utils@2.0.2 + +## 2.0.1 + +### Patch Changes + +- waas: http signature check for authenticator requests +- provider: unwrap legacy json rpc responses +- use json replacer and reviver for bigints +- Updated dependencies +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.1 + - @0xsequence/core@2.0.1 + - @0xsequence/utils@2.0.1 + +## 2.0.0 + +### Major Changes + +- ethers v6 + +### Patch Changes + +- Updated dependencies + - @0xsequence/abi@2.0.0 + - @0xsequence/core@2.0.0 + - @0xsequence/utils@2.0.0 + +## 1.10.15 + +### Patch Changes + +- utils: extractProjectIdFromAccessKey +- Updated dependencies + - @0xsequence/abi@1.10.15 + - @0xsequence/core@1.10.15 + - @0xsequence/utils@1.10.15 + ## 1.10.14 ### Patch Changes diff --git a/packages/relayer/package.json b/packages/relayer/package.json index 76c80cdf2..13d40cd05 100644 --- a/packages/relayer/package.json +++ b/packages/relayer/package.json @@ -1,6 +1,6 @@ { "name": "@0xsequence/relayer", - "version": "1.10.14", + "version": "2.2.14", "description": "relayer sub-package for Sequence", "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/relayer", "source": "src/index.ts", @@ -11,24 +11,24 @@ "scripts": { "test": "pnpm test:concurrently 'pnpm test:run'", "test:run": "pnpm test:file tests/**/*.spec.ts", - "test:file": "NODE_OPTIONS='--import tsx' mocha --timeout 30000", + "test:file": "NODE_OPTIONS='--import tsx' mocha --timeout 60000", "test:concurrently": "concurrently -k --success first 'pnpm start:hardhat > /dev/null' ", "start:hardhat": "pnpm hardhat node --port 9547", "typecheck": "tsc --noEmit" }, + "peerDependencies": { + "ethers": ">=6" + }, "dependencies": { "@0xsequence/abi": "workspace:*", "@0xsequence/core": "workspace:*", "@0xsequence/utils": "workspace:*" }, - "peerDependencies": { - "ethers": ">=5.5 < 6" - }, "devDependencies": { "@0xsequence/signhub": "workspace:*", "@0xsequence/tests": "workspace:*", - "@0xsequence/wallet-contracts": "^1.10.0", - "ethers": "^5.7.2" + "@0xsequence/wallet-contracts": "^3.0.1", + "ethers": "6.13.4" }, "files": [ "src", diff --git a/packages/relayer/src/index.ts b/packages/relayer/src/index.ts index f771369bb..f43d3e33f 100644 --- a/packages/relayer/src/index.ts +++ b/packages/relayer/src/index.ts @@ -1,4 +1,4 @@ -import { ethers, providers } from 'ethers' +import { ethers } from 'ethers' import { proto } from './rpc-relayer' import { commons } from '@0xsequence/core' @@ -19,7 +19,7 @@ export interface Relayer { // It doesn't make any assumptions about the transaction format. getFeeOptionsRaw( entrypoint: string, - data: ethers.utils.BytesLike, + data: ethers.BytesLike, options?: { simulate?: boolean } @@ -29,10 +29,16 @@ export interface Relayer { // relayer for submitting your transaction to a network. gasRefundOptions(address: string, ...transactions: commons.transaction.Transaction[]): Promise + // Gas tank sponsorship management + listGasSponsors(args: proto.ListGasSponsorsArgs): Promise + addGasSponsor(args: proto.AddGasSponsorArgs): Promise + updateGasSponsor(args: proto.UpdateGasSponsorArgs): Promise + removeGasSponsor(args: proto.RemoveGasSponsorArgs): Promise + // getNonce returns the transaction count/nonce for a wallet, encoded with nonce space. // If space is undefined, the relayer can choose a nonce space to encode the result with. // Otherwise, the relayer must return a nonce encoded for the given nonce space. - getNonce(address: string, space?: ethers.BigNumberish, blockTag?: providers.BlockTag): Promise + getNonce(address: string, space?: ethers.BigNumberish, blockTag?: ethers.BlockTag): Promise // relayer will submit the transaction(s) to the network and return the transaction response. // The quote should be the one returned from getFeeOptions, if any. @@ -40,7 +46,8 @@ export interface Relayer { relay( signedTxs: commons.transaction.IntendedTransactionBundle, quote?: FeeQuote, - waitForReceipt?: boolean + waitForReceipt?: boolean, + projectAccessKey?: string ): Promise // wait for transaction confirmation @@ -53,6 +60,24 @@ export interface Relayer { delay?: number, maxFails?: number ): Promise + + // getMetaTransactions returns a list of meta transactions for a given project and gas tank + getMetaTransactions( + projectId: number, + page?: proto.Page + ): Promise<{ + page: proto.Page + transactions: proto.MetaTxnLog[] + }> + + // getTransactionCost returns the used fee cost for gas tank during a given period + getTransactionCost( + projectId: number, + from: string, + to: string + ): Promise<{ + cost: number + }> } export * from './local-relayer' diff --git a/packages/relayer/src/local-relayer.ts b/packages/relayer/src/local-relayer.ts index 19712ce12..f53fdde52 100644 --- a/packages/relayer/src/local-relayer.ts +++ b/packages/relayer/src/local-relayer.ts @@ -1,24 +1,24 @@ -import { Signer as AbstractSigner, providers, BytesLike } from 'ethers' +import { ethers } from 'ethers' import { logger } from '@0xsequence/utils' -import { FeeOption, FeeQuote, Relayer } from '.' +import { FeeOption, FeeQuote, proto, Relayer } from '.' import { ProviderRelayer, ProviderRelayerOptions } from './provider-relayer' import { commons } from '@0xsequence/core' export type LocalRelayerOptions = Omit & { - signer: AbstractSigner + signer: ethers.Signer } export function isLocalRelayerOptions(obj: any): obj is LocalRelayerOptions { - return obj.signer !== undefined && AbstractSigner.isSigner(obj.signer) + return typeof obj === 'object' && isAbstractSigner(obj.signer) } export class LocalRelayer extends ProviderRelayer implements Relayer { - private signer: AbstractSigner - private txnOptions: providers.TransactionRequest + private signer: ethers.Signer + private txnOptions: ethers.TransactionRequest - constructor(options: LocalRelayerOptions | AbstractSigner) { - super(AbstractSigner.isSigner(options) ? { provider: options.provider! } : { ...options, provider: options.signer.provider! }) - this.signer = AbstractSigner.isSigner(options) ? options : options.signer + constructor(options: LocalRelayerOptions | ethers.AbstractSigner) { + super(isAbstractSigner(options) ? { provider: options.provider! } : { ...options, provider: options.signer.provider! }) + this.signer = isAbstractSigner(options) ? options : options.signer if (!this.signer.provider) throw new Error('Signer must have a provider') } @@ -28,7 +28,7 @@ export class LocalRelayer extends ProviderRelayer implements Relayer { async getFeeOptionsRaw( _entrypoint: string, - _data: BytesLike, + _data: ethers.BytesLike, _options?: { simulate?: boolean } @@ -41,7 +41,7 @@ export class LocalRelayer extends ProviderRelayer implements Relayer { return options } - setTransactionOptions(transactionRequest: providers.TransactionRequest) { + setTransactionOptions(transactionRequest: ethers.TransactionRequest) { this.txnOptions = transactionRequest } @@ -49,7 +49,7 @@ export class LocalRelayer extends ProviderRelayer implements Relayer { signedTxs: commons.transaction.IntendedTransactionBundle, quote?: FeeQuote, waitForReceipt: boolean = true - ): Promise> { + ): Promise> { if (quote !== undefined) { logger.warn(`LocalRelayer doesn't accept fee quotes`) } @@ -58,7 +58,7 @@ export class LocalRelayer extends ProviderRelayer implements Relayer { // TODO: think about computing gas limit individually, summing together and passing across // NOTE: we expect that all txns have set their gasLimit ahead of time through proper estimation - // const gasLimit = signedTxs.transactions.reduce((sum, tx) => sum.add(tx.gasLimit), ethers.BigNumber.from(0)) + // const gasLimit = signedTxs.transactions.reduce((sum, tx) => sum + tx.gasLimit, 0n) // txRequest.gasLimit = gasLimit const responsePromise = this.signer.sendTransaction({ @@ -76,4 +76,50 @@ export class LocalRelayer extends ProviderRelayer implements Relayer { return responsePromise } } + + async getMetaTransactions( + projectId: number, + page?: proto.Page + ): Promise<{ + page: proto.Page + transactions: proto.MetaTxnLog[] + }> { + return { page: { page: 0, pageSize: 100 }, transactions: [] } + } + + async getTransactionCost( + projectId: number, + from: string, + to: string + ): Promise<{ + cost: number + }> { + return { cost: 0 } + } + + async listGasSponsors(args: proto.ListGasSponsorsArgs): Promise { + return { page: { page: 0, pageSize: 100 }, gasSponsors: [] } + } + + async addGasSponsor(args: proto.AddGasSponsorArgs): Promise { + return { status: true, gasSponsor: {} as proto.GasSponsor } + } + + async updateGasSponsor(args: proto.UpdateGasSponsorArgs): Promise { + return { status: true, gasSponsor: {} as proto.GasSponsor } + } + + async removeGasSponsor(args: proto.RemoveGasSponsorArgs): Promise { + return { status: true } + } +} + +function isAbstractSigner(signer: any): signer is ethers.AbstractSigner { + return ( + signer && + typeof signer === 'object' && + typeof signer.provider === 'object' && + typeof signer.getAddress === 'function' && + typeof signer.connect === 'function' + ) } diff --git a/packages/relayer/src/provider-relayer.ts b/packages/relayer/src/provider-relayer.ts index 9135c7acf..3d82139ca 100644 --- a/packages/relayer/src/provider-relayer.ts +++ b/packages/relayer/src/provider-relayer.ts @@ -1,13 +1,13 @@ -import { ethers, providers } from 'ethers' +import { ethers } from 'ethers' import { walletContracts } from '@0xsequence/abi' -import { FeeOption, FeeQuote, Relayer, SimulateResult } from '.' +import { FeeOption, FeeQuote, proto, Relayer, SimulateResult } from '.' import { logger, Optionals } from '@0xsequence/utils' import { commons } from '@0xsequence/core' -const DEFAULT_GAS_LIMIT = ethers.BigNumber.from(800000) +const DEFAULT_GAS_LIMIT = 800000n export interface ProviderRelayerOptions { - provider: providers.Provider + provider: ethers.Provider waitPollRate?: number deltaBlocksLog?: number fromBlockLog?: number @@ -20,11 +20,11 @@ export const ProviderRelayerDefaults: Required } export function isProviderRelayerOptions(obj: any): obj is ProviderRelayerOptions { - return obj.provider !== undefined && providers.Provider.isProvider(obj.provider) + return typeof obj === 'object' && isAbstractProvider(obj.provider) } export abstract class ProviderRelayer implements Relayer { - public provider: providers.Provider + public provider: ethers.Provider public waitPollRate: number public deltaBlocksLog: number public fromBlockLog: number @@ -45,7 +45,7 @@ export abstract class ProviderRelayer implements Relayer { abstract getFeeOptionsRaw( entrypoint: string, - data: ethers.utils.BytesLike, + data: ethers.BytesLike, options?: { simulate?: boolean } @@ -59,12 +59,36 @@ export abstract class ProviderRelayer implements Relayer { waitForReceipt?: boolean ): Promise + abstract getTransactionCost( + projectId: number, + from: string, + to: string + ): Promise<{ + cost: number + }> + + abstract getMetaTransactions( + projectId: number, + page?: proto.Page + ): Promise<{ + page: proto.Page + transactions: proto.MetaTxnLog[] + }> + + abstract listGasSponsors(args: proto.ListGasSponsorsArgs): Promise + + abstract addGasSponsor(args: proto.AddGasSponsorArgs): Promise + + abstract updateGasSponsor(args: proto.UpdateGasSponsorArgs): Promise + + abstract removeGasSponsor(args: proto.RemoveGasSponsorArgs): Promise + async simulate(wallet: string, ...transactions: commons.transaction.Transaction[]): Promise { return ( await Promise.all( transactions.map(async tx => { // Respect gasLimit request of the transaction (as long as its not 0) - if (tx.gasLimit && !ethers.BigNumber.from(tx.gasLimit || 0).eq(ethers.constants.Zero)) { + if (tx.gasLimit && BigInt(tx.gasLimit || 0) !== 0n) { return tx.gasLimit } @@ -74,7 +98,7 @@ export abstract class ProviderRelayer implements Relayer { } // Fee can't be estimated for self-called if wallet hasn't been deployed - if (tx.to === wallet && (await this.provider.getCode(wallet).then(code => ethers.utils.arrayify(code).length === 0))) { + if (tx.to === wallet && (await this.provider.getCode(wallet).then(code => ethers.getBytes(code).length === 0))) { return DEFAULT_GAS_LIMIT } @@ -95,12 +119,12 @@ export abstract class ProviderRelayer implements Relayer { ).map(gasLimit => ({ executed: true, succeeded: true, - gasUsed: ethers.BigNumber.from(gasLimit).toNumber(), - gasLimit: ethers.BigNumber.from(gasLimit).toNumber() + gasUsed: Number(gasLimit), + gasLimit: Number(gasLimit) })) } - async getNonce(address: string, space?: ethers.BigNumberish, blockTag?: providers.BlockTag): Promise { + async getNonce(address: string, space?: ethers.BigNumberish, blockTag?: ethers.BlockTag): Promise { if (!this.provider) { throw new Error('provider is not set') } @@ -123,7 +147,7 @@ export abstract class ProviderRelayer implements Relayer { timeoutDuration?: number, delay: number = this.waitPollRate, maxFails: number = 5 - ): Promise { + ): Promise { if (typeof metaTxnId !== 'string') { metaTxnId = commons.transaction.intendedTransactionID(metaTxnId) } @@ -155,7 +179,7 @@ export abstract class ProviderRelayer implements Relayer { throw new Error(`timed out after ${fails} failed attempts${errorMessage ? `: ${errorMessage}` : ''}`) } - const waitReceipt = async (): Promise => { + const waitReceipt = async (): Promise => { // Transactions can only get executed on nonce change // get all nonce changes and look for metaTxnIds in between logs let lastBlock: number = this.fromBlockLog @@ -199,7 +223,7 @@ export abstract class ProviderRelayer implements Relayer { // Find a transaction with a TxExecuted log const found = txs.find(tx => - tx.logs.find( + tx?.logs.find( l => (l.topics.length === 0 && l.data.replace('0x', '') === normalMetaTxnId) || (l.topics.length === 1 && @@ -212,13 +236,17 @@ export abstract class ProviderRelayer implements Relayer { // If found return that if (found) { - return { - receipt: found, - ...(await retry( - () => this.provider.getTransaction(found.transactionHash), - `unable to get transaction ${found.transactionHash}` - )) + const response = await retry(() => this.provider.getTransaction(found.hash), `unable to get transaction ${found.hash}`) + if (!response) { + throw new Error(`Transaction response not found for ${metaTxnId}`) } + + // NOTE: we have to do this, because ethers-v6 uses private fields + // and we can't just extend the class and override the method, so + // we just modify the response object directly by adding the receipt to it. + const out: any = response + out.receipt = found + return out } // Otherwise wait and try again @@ -233,7 +261,7 @@ export abstract class ProviderRelayer implements Relayer { if (timeoutDuration !== undefined) { return Promise.race([ waitReceipt(), - new Promise((_, reject) => + new Promise((_, reject) => setTimeout(() => { timedOut = true reject(`Timeout waiting for transaction receipt ${metaTxnId}`) @@ -245,3 +273,12 @@ export abstract class ProviderRelayer implements Relayer { } } } + +function isAbstractProvider(provider: any): provider is ethers.AbstractProvider { + return ( + provider && + typeof provider === 'object' && + typeof provider.getNetwork === 'function' && + typeof provider.getBlockNumber === 'function' + ) +} diff --git a/packages/relayer/src/rpc-relayer/index.ts b/packages/relayer/src/rpc-relayer/index.ts index ff7fb32f3..a5172ceaf 100644 --- a/packages/relayer/src/rpc-relayer/index.ts +++ b/packages/relayer/src/rpc-relayer/index.ts @@ -2,7 +2,7 @@ import { ethers } from 'ethers' import { FeeOption, FeeQuote, Relayer, SimulateResult } from '..' import * as proto from './relayer.gen' import { commons } from '@0xsequence/core' -import { getEthersConnectionInfo, logger } from '@0xsequence/utils' +import { bigintReplacer, getFetchRequest, logger, toHexString } from '@0xsequence/utils' export { proto } @@ -16,37 +16,30 @@ const FINAL_STATUSES = [ const FAILED_STATUSES = [proto.ETHTxnStatus.DROPPED, proto.ETHTxnStatus.PARTIALLY_FAILED, proto.ETHTxnStatus.FAILED] export interface RpcRelayerOptions { - provider: ethers.providers.Provider | { url: string } + provider: ethers.AbstractProvider | { url: string } url: string projectAccessKey?: string jwtAuth?: string } export function isRpcRelayerOptions(obj: any): obj is RpcRelayerOptions { - return ( - obj.url !== undefined && - typeof obj.url === 'string' && - obj.provider !== undefined && - ethers.providers.Provider.isProvider(obj.provider) - ) + return obj.url !== undefined && typeof obj.url === 'string' && obj.provider !== undefined && isAbstractProvider(obj.provider) } -const fetch = globalThis.fetch - // TODO: rename to SequenceRelayer export class RpcRelayer implements Relayer { private readonly service: proto.Relayer - public readonly provider: ethers.providers.Provider + public readonly provider: ethers.Provider constructor(public options: RpcRelayerOptions) { this.service = new proto.Relayer(options.url, this._fetch) - if (ethers.providers.Provider.isProvider(options.provider)) { + if (isAbstractProvider(options.provider)) { this.provider = options.provider } else { const { jwtAuth, projectAccessKey } = this.options - const providerConnectionInfo = getEthersConnectionInfo(options.provider.url, projectAccessKey, jwtAuth) - this.provider = new ethers.providers.StaticJsonRpcProvider(providerConnectionInfo) + const fetchRequest = getFetchRequest(options.provider.url, projectAccessKey, jwtAuth) + this.provider = new ethers.JsonRpcProvider(fetchRequest, undefined, { staticNetwork: true }) } } @@ -66,7 +59,7 @@ export class RpcRelayer implements Relayer { } // before the request is made - init!.headers = { ...init!.headers, ...headers } + init!.headers = { ...headers, ...init!.headers } return fetch(input, init) } @@ -114,7 +107,7 @@ export class RpcRelayer implements Relayer { } async simulate(wallet: string, ...transactions: commons.transaction.Transaction[]): Promise { - const coder = ethers.utils.defaultAbiCoder + const coder = ethers.AbiCoder.defaultAbiCoder() const encoded = coder.encode( [commons.transaction.MetaTransactionsType], [commons.transaction.sequenceTxAbiEncode(transactions)] @@ -152,7 +145,7 @@ export class RpcRelayer implements Relayer { }) }) - logger.info(`[rpc-relayer/getFeeOptions] got refund options ${JSON.stringify(options)}`) + logger.info(`[rpc-relayer/getFeeOptions] got refund options ${JSON.stringify(options, bigintReplacer)}`) return { options, quote: { _tag: 'FeeQuote', _quote: quote } } } else { logger.info(`[rpc-relayer/getFeeOptions] relayer fees are not required`) @@ -162,17 +155,21 @@ export class RpcRelayer implements Relayer { async getFeeOptionsRaw( entrypoint: string, - data: ethers.utils.BytesLike, + data: ethers.BytesLike, options?: { simulate?: boolean + projectAccessKey?: string } ): Promise<{ options: FeeOption[]; quote?: FeeQuote }> { - const { options: feeOptions, quote } = await this.service.feeOptions({ - wallet: entrypoint, - to: entrypoint, - data: ethers.utils.hexlify(data), - simulate: options?.simulate - }) + const { options: feeOptions, quote } = await this.service.feeOptions( + { + wallet: entrypoint, + to: entrypoint, + data: ethers.hexlify(data), + simulate: options?.simulate + }, + { ...(options?.projectAccessKey ? { 'X-Access-Key': options.projectAccessKey } : undefined) } + ) return { options: feeOptions, quote: { _tag: 'FeeQuote', _quote: quote } } } @@ -184,9 +181,9 @@ export class RpcRelayer implements Relayer { async getNonce(address: string, space?: ethers.BigNumberish): Promise { logger.info(`[rpc-relayer/getNonce] get nonce for wallet ${address} space: ${space}`) - const encodedNonce = space !== undefined ? ethers.BigNumber.from(space).toHexString() : undefined + const encodedNonce = space !== undefined ? toHexString(BigInt(space)) : undefined const resp = await this.service.getMetaTxnNonce({ walletContractAddress: address, space: encodedNonce }) - const nonce = ethers.BigNumber.from(resp.nonce) + const nonce = BigInt(resp.nonce) const [decodedSpace, decodedNonce] = commons.transaction.decodeNonce(nonce) logger.info(`[rpc-relayer/getNonce] got next nonce for wallet ${address} ${decodedNonce} space: ${decodedSpace}`) return nonce @@ -195,10 +192,11 @@ export class RpcRelayer implements Relayer { async relay( signedTxs: commons.transaction.IntendedTransactionBundle, quote?: FeeQuote, - waitForReceipt: boolean = true + waitForReceipt: boolean = true, + projectAccessKey?: string ): Promise> { logger.info( - `[rpc-relayer/relay] relaying signed meta-transactions ${JSON.stringify(signedTxs)} with quote ${JSON.stringify(quote)}` + `[rpc-relayer/relay] relaying signed meta-transactions ${JSON.stringify(signedTxs, bigintReplacer)} with quote ${JSON.stringify(quote, bigintReplacer)}` ) let typecheckedQuote: string | undefined @@ -216,16 +214,19 @@ export class RpcRelayer implements Relayer { } const data = commons.transaction.encodeBundleExecData(signedTxs) - const metaTxn = await this.service.sendMetaTxn({ - call: { - walletAddress: signedTxs.intent.wallet, - contract: signedTxs.entrypoint, - input: data + const metaTxn = await this.service.sendMetaTxn( + { + call: { + walletAddress: signedTxs.intent.wallet, + contract: signedTxs.entrypoint, + input: data + }, + quote: typecheckedQuote }, - quote: typecheckedQuote - }) + { ...(projectAccessKey ? { 'X-Access-Key': projectAccessKey } : undefined) } + ) - logger.info(`[rpc-relayer/relay] got relay result ${JSON.stringify(metaTxn)}`) + logger.info(`[rpc-relayer/relay] got relay result ${JSON.stringify(metaTxn, bigintReplacer)}`) if (waitForReceipt) { return this.wait(signedTxs.intent.id) @@ -234,10 +235,10 @@ export class RpcRelayer implements Relayer { hash: signedTxs.intent.id, confirmations: 0, from: signedTxs.intent.wallet, - wait: (_confirmations?: number): Promise => Promise.reject(new Error('impossible')) + wait: (_confirmations?: number): Promise => Promise.reject(new Error('impossible')) } - const wait = async (confirmations?: number): Promise => { + const wait = async (confirmations?: number): Promise => { if (!this.provider) { throw new Error('cannot wait for receipt, relayer has no provider set') } @@ -256,6 +257,9 @@ export class RpcRelayer implements Relayer { response.wait = wait + // NOTE: we just ignore these errors which come from the private fields + // of ethers-v6 .. but, we should probably rework this instead.. + // @ts-ignore return response as commons.transaction.TransactionResponse } } @@ -286,9 +290,12 @@ export class RpcRelayer implements Relayer { const txReceipt = JSON.parse(receipt.txnReceipt) as RelayerTxReceipt + // NOTE: we just ignore these errors which come from the private fields + // of ethers-v6 .. but, we should probably rework this instead.. + // @ts-ignore return { blockHash: txReceipt.blockHash, - blockNumber: ethers.BigNumber.from(txReceipt.blockNumber).toNumber(), + blockNumber: Number(txReceipt.blockNumber), confirmations: 1, from: typeof metaTxnId === 'string' ? undefined : metaTxnId.intent.wallet, hash: txReceipt.transactionHash, @@ -297,6 +304,42 @@ export class RpcRelayer implements Relayer { wait: async (confirmations?: number) => this.provider!.waitForTransaction(txReceipt.transactionHash, confirmations) } as commons.transaction.TransactionResponse } + + async getMetaTransactions( + projectId: number, + page?: proto.Page + ): Promise<{ + page: proto.Page + transactions: proto.MetaTxnLog[] + }> { + return this.service.getMetaTransactions({ projectId, page }) + } + + async getTransactionCost( + projectId: number, + from: string, + to: string + ): Promise<{ + cost: number + }> { + return this.service.getTransactionCost({ projectId, from, to }) + } + + async listGasSponsors(args: proto.ListGasSponsorsArgs): Promise { + return this.service.listGasSponsors(args) + } + + async addGasSponsor(args: proto.AddGasSponsorArgs): Promise { + return this.service.addGasSponsor(args) + } + + async updateGasSponsor(args: proto.UpdateGasSponsorArgs): Promise { + return this.service.updateGasSponsor(args) + } + + async removeGasSponsor(args: proto.RemoveGasSponsorArgs): Promise { + return this.service.removeGasSponsor(args) + } } class MetaTransactionResponseException { @@ -326,3 +369,12 @@ export type RelayerTxReceipt = { transactionHash: string transactionIndex: string } + +function isAbstractProvider(provider: any): provider is ethers.AbstractProvider { + return ( + provider && + typeof provider === 'object' && + typeof provider.getNetwork === 'function' && + typeof provider.getBlockNumber === 'function' + ) +} diff --git a/packages/relayer/src/rpc-relayer/relayer.gen.ts b/packages/relayer/src/rpc-relayer/relayer.gen.ts index 91ce2e9b0..f300935a8 100644 --- a/packages/relayer/src/rpc-relayer/relayer.gen.ts +++ b/packages/relayer/src/rpc-relayer/relayer.gen.ts @@ -1,10 +1,14 @@ /* eslint-disable */ -// sequence-relayer v0.4.1 1e27d0fd295aa5897878939595ef0c6adc54b1a3 +// sequence-relayer v0.4.1 da20208d66be29ad86d2662ca38c4425bc5910f8 // -- -// Code generated by webrpc-gen@v0.18.6 with typescript generator. DO NOT EDIT. +// Code generated by webrpc-gen@v0.22.0 with typescript generator. DO NOT EDIT. // // webrpc-gen -schema=relayer.ridl -target=typescript -client -out=./clients/relayer.gen.ts +export const WebrpcHeader = 'Webrpc' + +export const WebrpcHeaderValue = 'webrpc@v0.22.0;gen-typescript@v0.16.1;sequence-relayer@v0.4.1' + // WebRPC description and code-gen version export const WebRPCVersion = 'v1' @@ -12,7 +16,55 @@ export const WebRPCVersion = 'v1' export const WebRPCSchemaVersion = 'v0.4.1' // Schema hash generated from your RIDL schema -export const WebRPCSchemaHash = '1e27d0fd295aa5897878939595ef0c6adc54b1a3' +export const WebRPCSchemaHash = 'da20208d66be29ad86d2662ca38c4425bc5910f8' + +type WebrpcGenVersions = { + webrpcGenVersion: string + codeGenName: string + codeGenVersion: string + schemaName: string + schemaVersion: string +} + +export function VersionFromHeader(headers: Headers): WebrpcGenVersions { + const headerValue = headers.get(WebrpcHeader) + if (!headerValue) { + return { + webrpcGenVersion: '', + codeGenName: '', + codeGenVersion: '', + schemaName: '', + schemaVersion: '' + } + } + + return parseWebrpcGenVersions(headerValue) +} + +function parseWebrpcGenVersions(header: string): WebrpcGenVersions { + const versions = header.split(';') + if (versions.length < 3) { + return { + webrpcGenVersion: '', + codeGenName: '', + codeGenVersion: '', + schemaName: '', + schemaVersion: '' + } + } + + const [_, webrpcGenVersion] = versions[0].split('@') + const [codeGenName, codeGenVersion] = versions[1].split('@') + const [schemaName, schemaVersion] = versions[2].split('@') + + return { + webrpcGenVersion, + codeGenName, + codeGenVersion, + schemaName, + schemaVersion + } +} // // Types @@ -62,10 +114,10 @@ export interface RuntimeStatus { ver: string branch: string commitHash: string + chainID: number useEIP1559: boolean senders: Array checks: RuntimeChecks - numTxnsRelayed: NumTxnsRelayed } export interface SenderStatus { @@ -77,12 +129,6 @@ export interface SenderStatus { export interface RuntimeChecks {} -export interface NumTxnsRelayed { - prev: number - current: number - period: number -} - export interface SequenceContext { factory: string mainModule: string @@ -93,6 +139,7 @@ export interface SequenceContext { export interface GasTank { id: number + chainId: number name: string currentBalance: number unlimited: boolean @@ -114,6 +161,7 @@ export interface GasSponsor { id: number gasTankId: number projectId: number + chainId: number address: string name: string active: boolean @@ -142,6 +190,7 @@ export interface MetaTxn { export interface MetaTxnLog { id: number + chainId: number projectId: number txnHash: string txnNonce: string @@ -165,6 +214,7 @@ export interface MetaTxnLog { gasFeeMarkup?: number usdRate: string creditsUsed: number + cost: string isWhitelisted: boolean gasSponsor?: number gasTank?: number @@ -172,17 +222,6 @@ export interface MetaTxnLog { createdAt: string } -export interface MetaTxnEntry { - id: number - metaTxnID: string - txnStatus: ETHTxnStatus - txnRevertReason: string - index: number - logs?: Array - updatedAt: string - createdAt: string -} - export interface MetaTxnReceipt { id: string status: string @@ -293,22 +332,12 @@ export interface Relayer { signal?: AbortSignal ): Promise getMetaTransactions(args: GetMetaTransactionsArgs, headers?: object, signal?: AbortSignal): Promise + getTransactionCost(args: GetTransactionCostArgs, headers?: object, signal?: AbortSignal): Promise sentTransactions(args: SentTransactionsArgs, headers?: object, signal?: AbortSignal): Promise pendingTransactions(args: PendingTransactionsArgs, headers?: object, signal?: AbortSignal): Promise getGasTank(args: GetGasTankArgs, headers?: object, signal?: AbortSignal): Promise addGasTank(args: AddGasTankArgs, headers?: object, signal?: AbortSignal): Promise updateGasTank(args: UpdateGasTankArgs, headers?: object, signal?: AbortSignal): Promise - getGasSponsor(args: GetGasSponsorArgs, headers?: object, signal?: AbortSignal): Promise - addressGasSponsors(args: AddressGasSponsorsArgs, headers?: object, signal?: AbortSignal): Promise - listGasSponsors(args: ListGasSponsorsArgs, headers?: object, signal?: AbortSignal): Promise - addGasSponsor(args: AddGasSponsorArgs, headers?: object, signal?: AbortSignal): Promise - updateGasSponsor(args: UpdateGasSponsorArgs, headers?: object, signal?: AbortSignal): Promise - removeGasSponsor(args: RemoveGasSponsorArgs, headers?: object, signal?: AbortSignal): Promise - reportGasSponsorUsage( - args: ReportGasSponsorUsageArgs, - headers?: object, - signal?: AbortSignal - ): Promise nextGasTankBalanceAdjustmentNonce( args: NextGasTankBalanceAdjustmentNonceArgs, headers?: object, @@ -329,6 +358,18 @@ export interface Relayer { headers?: object, signal?: AbortSignal ): Promise + listGasSponsors(args: ListGasSponsorsArgs, headers?: object, signal?: AbortSignal): Promise + getGasSponsor(args: GetGasSponsorArgs, headers?: object, signal?: AbortSignal): Promise + addGasSponsor(args: AddGasSponsorArgs, headers?: object, signal?: AbortSignal): Promise + updateGasSponsor(args: UpdateGasSponsorArgs, headers?: object, signal?: AbortSignal): Promise + removeGasSponsor(args: RemoveGasSponsorArgs, headers?: object, signal?: AbortSignal): Promise + addressGasSponsors(args: AddressGasSponsorsArgs, headers?: object, signal?: AbortSignal): Promise + getProjectBalance(args: GetProjectBalanceArgs, headers?: object, signal?: AbortSignal): Promise + adjustProjectBalance( + args: AdjustProjectBalanceArgs, + headers?: object, + signal?: AbortSignal + ): Promise } export interface PingArgs {} @@ -359,6 +400,7 @@ export interface GetChainIDReturn { export interface SendMetaTxnArgs { call: MetaTxn quote?: string + projectID?: number } export interface SendMetaTxnReturn { @@ -425,7 +467,6 @@ export interface GetMetaTxnNetworkFeeOptionsReturn { } export interface GetMetaTransactionsArgs { projectId: number - gasTankId: number page?: Page } @@ -433,6 +474,15 @@ export interface GetMetaTransactionsReturn { page: Page transactions: Array } +export interface GetTransactionCostArgs { + projectId: number + from: string + to: string +} + +export interface GetTransactionCostReturn { + cost: number +} export interface SentTransactionsArgs { filter?: SentTransactionsFilter page?: Page @@ -478,25 +528,42 @@ export interface UpdateGasTankReturn { status: boolean gasTank: GasTank } -export interface GetGasSponsorArgs { +export interface NextGasTankBalanceAdjustmentNonceArgs { id: number } -export interface GetGasSponsorReturn { - gasSponsor: GasSponsor +export interface NextGasTankBalanceAdjustmentNonceReturn { + nonce: number } -export interface AddressGasSponsorsArgs { - address: string +export interface AdjustGasTankBalanceArgs { + id: number + nonce: number + amount: number +} + +export interface AdjustGasTankBalanceReturn { + status: boolean + adjustment: GasTankBalanceAdjustment +} +export interface GetGasTankBalanceAdjustmentArgs { + id: number + nonce: number +} + +export interface GetGasTankBalanceAdjustmentReturn { + adjustment: GasTankBalanceAdjustment +} +export interface ListGasTankBalanceAdjustmentsArgs { + id: number page?: Page } -export interface AddressGasSponsorsReturn { +export interface ListGasTankBalanceAdjustmentsReturn { page: Page - gasSponsors: Array + adjustments: Array } export interface ListGasSponsorsArgs { projectId: number - gasTankId: number page?: Page } @@ -504,9 +571,16 @@ export interface ListGasSponsorsReturn { page: Page gasSponsors: Array } +export interface GetGasSponsorArgs { + projectId: number + id: number +} + +export interface GetGasSponsorReturn { + gasSponsor: GasSponsor +} export interface AddGasSponsorArgs { projectId: number - gasTankId: number address: string name?: string active?: boolean @@ -517,6 +591,7 @@ export interface AddGasSponsorReturn { gasSponsor: GasSponsor } export interface UpdateGasSponsorArgs { + projectId: number id: number name?: string active?: boolean @@ -527,55 +602,37 @@ export interface UpdateGasSponsorReturn { gasSponsor: GasSponsor } export interface RemoveGasSponsorArgs { + projectId: number id: number } export interface RemoveGasSponsorReturn { status: boolean } -export interface ReportGasSponsorUsageArgs { - projectId: number - gasTankId: number - startTime?: string - endTime?: string +export interface AddressGasSponsorsArgs { + address: string + page?: Page } -export interface ReportGasSponsorUsageReturn { - gasSponsorUsage: Array +export interface AddressGasSponsorsReturn { + page: Page + gasSponsors: Array } -export interface NextGasTankBalanceAdjustmentNonceArgs { - id: number +export interface GetProjectBalanceArgs { + projectId: number } -export interface NextGasTankBalanceAdjustmentNonceReturn { - nonce: number +export interface GetProjectBalanceReturn { + balance: number } -export interface AdjustGasTankBalanceArgs { - id: number - nonce: number +export interface AdjustProjectBalanceArgs { + projectId: number amount: number + identifier: string } -export interface AdjustGasTankBalanceReturn { - status: boolean - adjustment: GasTankBalanceAdjustment -} -export interface GetGasTankBalanceAdjustmentArgs { - id: number - nonce: number -} - -export interface GetGasTankBalanceAdjustmentReturn { - adjustment: GasTankBalanceAdjustment -} -export interface ListGasTankBalanceAdjustmentsArgs { - id: number - page?: Page -} - -export interface ListGasTankBalanceAdjustmentsReturn { - page: Page - adjustments: Array +export interface AdjustProjectBalanceReturn { + balance: number } // @@ -587,7 +644,7 @@ export class Relayer implements Relayer { protected path = '/rpc/Relayer/' constructor(hostname: string, fetch: Fetch) { - this.hostname = hostname + this.hostname = hostname.replace(/\/*$/, '') this.fetch = (input: RequestInfo, init?: RequestInit) => fetch(input, init) } @@ -822,6 +879,25 @@ export class Relayer implements Relayer { ) } + getTransactionCost = ( + args: GetTransactionCostArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('GetTransactionCost'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + cost: _data.cost + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + sentTransactions = (args: SentTransactionsArgs, headers?: object, signal?: AbortSignal): Promise => { return this.fetch(this.url('SentTransactions'), createHTTPRequest(args, headers, signal)).then( res => { @@ -905,12 +981,16 @@ export class Relayer implements Relayer { ) } - getGasSponsor = (args: GetGasSponsorArgs, headers?: object, signal?: AbortSignal): Promise => { - return this.fetch(this.url('GetGasSponsor'), createHTTPRequest(args, headers, signal)).then( + nextGasTankBalanceAdjustmentNonce = ( + args: NextGasTankBalanceAdjustmentNonceArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('NextGasTankBalanceAdjustmentNonce'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { return { - gasSponsor: _data.gasSponsor + nonce: _data.nonce } }) }, @@ -920,17 +1000,17 @@ export class Relayer implements Relayer { ) } - addressGasSponsors = ( - args: AddressGasSponsorsArgs, + adjustGasTankBalance = ( + args: AdjustGasTankBalanceArgs, headers?: object, signal?: AbortSignal - ): Promise => { - return this.fetch(this.url('AddressGasSponsors'), createHTTPRequest(args, headers, signal)).then( + ): Promise => { + return this.fetch(this.url('AdjustGasTankBalance'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { return { - page: _data.page, - gasSponsors: >_data.gasSponsors + status: _data.status, + adjustment: _data.adjustment } }) }, @@ -940,13 +1020,36 @@ export class Relayer implements Relayer { ) } - listGasSponsors = (args: ListGasSponsorsArgs, headers?: object, signal?: AbortSignal): Promise => { - return this.fetch(this.url('ListGasSponsors'), createHTTPRequest(args, headers, signal)).then( + getGasTankBalanceAdjustment = ( + args: GetGasTankBalanceAdjustmentArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('GetGasTankBalanceAdjustment'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + adjustment: _data.adjustment + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + listGasTankBalanceAdjustments = ( + args: ListGasTankBalanceAdjustmentsArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('ListGasTankBalanceAdjustments'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { return { page: _data.page, - gasSponsors: >_data.gasSponsors + adjustments: >_data.adjustments } }) }, @@ -956,13 +1059,13 @@ export class Relayer implements Relayer { ) } - addGasSponsor = (args: AddGasSponsorArgs, headers?: object, signal?: AbortSignal): Promise => { - return this.fetch(this.url('AddGasSponsor'), createHTTPRequest(args, headers, signal)).then( + listGasSponsors = (args: ListGasSponsorsArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('ListGasSponsors'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { return { - status: _data.status, - gasSponsor: _data.gasSponsor + page: _data.page, + gasSponsors: >_data.gasSponsors } }) }, @@ -972,12 +1075,11 @@ export class Relayer implements Relayer { ) } - updateGasSponsor = (args: UpdateGasSponsorArgs, headers?: object, signal?: AbortSignal): Promise => { - return this.fetch(this.url('UpdateGasSponsor'), createHTTPRequest(args, headers, signal)).then( + getGasSponsor = (args: GetGasSponsorArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('GetGasSponsor'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { return { - status: _data.status, gasSponsor: _data.gasSponsor } }) @@ -988,12 +1090,13 @@ export class Relayer implements Relayer { ) } - removeGasSponsor = (args: RemoveGasSponsorArgs, headers?: object, signal?: AbortSignal): Promise => { - return this.fetch(this.url('RemoveGasSponsor'), createHTTPRequest(args, headers, signal)).then( + addGasSponsor = (args: AddGasSponsorArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('AddGasSponsor'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { return { - status: _data.status + status: _data.status, + gasSponsor: _data.gasSponsor } }) }, @@ -1003,16 +1106,13 @@ export class Relayer implements Relayer { ) } - reportGasSponsorUsage = ( - args: ReportGasSponsorUsageArgs, - headers?: object, - signal?: AbortSignal - ): Promise => { - return this.fetch(this.url('ReportGasSponsorUsage'), createHTTPRequest(args, headers, signal)).then( + updateGasSponsor = (args: UpdateGasSponsorArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('UpdateGasSponsor'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { return { - gasSponsorUsage: >_data.gasSponsorUsage + status: _data.status, + gasSponsor: _data.gasSponsor } }) }, @@ -1022,16 +1122,12 @@ export class Relayer implements Relayer { ) } - nextGasTankBalanceAdjustmentNonce = ( - args: NextGasTankBalanceAdjustmentNonceArgs, - headers?: object, - signal?: AbortSignal - ): Promise => { - return this.fetch(this.url('NextGasTankBalanceAdjustmentNonce'), createHTTPRequest(args, headers, signal)).then( + removeGasSponsor = (args: RemoveGasSponsorArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('RemoveGasSponsor'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { return { - nonce: _data.nonce + status: _data.status } }) }, @@ -1041,17 +1137,17 @@ export class Relayer implements Relayer { ) } - adjustGasTankBalance = ( - args: AdjustGasTankBalanceArgs, + addressGasSponsors = ( + args: AddressGasSponsorsArgs, headers?: object, signal?: AbortSignal - ): Promise => { - return this.fetch(this.url('AdjustGasTankBalance'), createHTTPRequest(args, headers, signal)).then( + ): Promise => { + return this.fetch(this.url('AddressGasSponsors'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { return { - status: _data.status, - adjustment: _data.adjustment + page: _data.page, + gasSponsors: >_data.gasSponsors } }) }, @@ -1061,16 +1157,12 @@ export class Relayer implements Relayer { ) } - getGasTankBalanceAdjustment = ( - args: GetGasTankBalanceAdjustmentArgs, - headers?: object, - signal?: AbortSignal - ): Promise => { - return this.fetch(this.url('GetGasTankBalanceAdjustment'), createHTTPRequest(args, headers, signal)).then( + getProjectBalance = (args: GetProjectBalanceArgs, headers?: object, signal?: AbortSignal): Promise => { + return this.fetch(this.url('GetProjectBalance'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { return { - adjustment: _data.adjustment + balance: _data.balance } }) }, @@ -1080,17 +1172,16 @@ export class Relayer implements Relayer { ) } - listGasTankBalanceAdjustments = ( - args: ListGasTankBalanceAdjustmentsArgs, + adjustProjectBalance = ( + args: AdjustProjectBalanceArgs, headers?: object, signal?: AbortSignal - ): Promise => { - return this.fetch(this.url('ListGasTankBalanceAdjustments'), createHTTPRequest(args, headers, signal)).then( + ): Promise => { + return this.fetch(this.url('AdjustProjectBalance'), createHTTPRequest(args, headers, signal)).then( res => { return buildResponse(res).then(_data => { return { - page: _data.page, - adjustments: >_data.adjustments + balance: _data.balance } }) }, @@ -1102,9 +1193,12 @@ export class Relayer implements Relayer { } const createHTTPRequest = (body: object = {}, headers: object = {}, signal: AbortSignal | null = null): object => { + const reqHeaders: { [key: string]: string } = { ...headers, 'Content-Type': 'application/json' } + reqHeaders[WebrpcHeader] = WebrpcHeaderValue + return { method: 'POST', - headers: { ...headers, 'Content-Type': 'application/json' }, + headers: reqHeaders, body: JSON.stringify(body || {}), signal } @@ -1336,6 +1430,19 @@ export class PermissionDeniedError extends WebrpcError { } } +export class SessionExpiredError extends WebrpcError { + constructor( + name: string = 'SessionExpired', + code: number = 1002, + message: string = 'Session expired', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, SessionExpiredError.prototype) + } +} + export class MethodNotFoundError extends WebrpcError { constructor( name: string = 'MethodNotFound', @@ -1349,6 +1456,19 @@ export class MethodNotFoundError extends WebrpcError { } } +export class RequestConflictError extends WebrpcError { + constructor( + name: string = 'RequestConflict', + code: number = 1004, + message: string = 'Conflict with target resource', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, RequestConflictError.prototype) + } +} + export class AbortedError extends WebrpcError { constructor( name: string = 'Aborted', @@ -1362,6 +1482,188 @@ export class AbortedError extends WebrpcError { } } +export class GeoblockedError extends WebrpcError { + constructor( + name: string = 'Geoblocked', + code: number = 1006, + message: string = 'Geoblocked region', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, GeoblockedError.prototype) + } +} + +export class RateLimitedError extends WebrpcError { + constructor( + name: string = 'RateLimited', + code: number = 1007, + message: string = 'Rate-limited. Please slow down.', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, RateLimitedError.prototype) + } +} + +export class ProjectNotFoundError extends WebrpcError { + constructor( + name: string = 'ProjectNotFound', + code: number = 1008, + message: string = 'Project not found', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, ProjectNotFoundError.prototype) + } +} + +export class AccessKeyNotFoundError extends WebrpcError { + constructor( + name: string = 'AccessKeyNotFound', + code: number = 1101, + message: string = 'Access key not found', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, AccessKeyNotFoundError.prototype) + } +} + +export class AccessKeyMismatchError extends WebrpcError { + constructor( + name: string = 'AccessKeyMismatch', + code: number = 1102, + message: string = 'Access key mismatch', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, AccessKeyMismatchError.prototype) + } +} + +export class InvalidOriginError extends WebrpcError { + constructor( + name: string = 'InvalidOrigin', + code: number = 1103, + message: string = 'Invalid origin for Access Key', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, InvalidOriginError.prototype) + } +} + +export class InvalidServiceError extends WebrpcError { + constructor( + name: string = 'InvalidService', + code: number = 1104, + message: string = 'Service not enabled for Access key', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, InvalidServiceError.prototype) + } +} + +export class UnauthorizedUserError extends WebrpcError { + constructor( + name: string = 'UnauthorizedUser', + code: number = 1105, + message: string = 'Unauthorized user', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, UnauthorizedUserError.prototype) + } +} + +export class QuotaExceededError extends WebrpcError { + constructor( + name: string = 'QuotaExceeded', + code: number = 1200, + message: string = 'Quota request exceeded', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, QuotaExceededError.prototype) + } +} + +export class QuotaRateLimitError extends WebrpcError { + constructor( + name: string = 'QuotaRateLimit', + code: number = 1201, + message: string = 'Quota rate limit exceeded', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, QuotaRateLimitError.prototype) + } +} + +export class NoDefaultKeyError extends WebrpcError { + constructor( + name: string = 'NoDefaultKey', + code: number = 1300, + message: string = 'No default access key found', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, NoDefaultKeyError.prototype) + } +} + +export class MaxAccessKeysError extends WebrpcError { + constructor( + name: string = 'MaxAccessKeys', + code: number = 1301, + message: string = 'Access keys limit reached', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, MaxAccessKeysError.prototype) + } +} + +export class AtLeastOneKeyError extends WebrpcError { + constructor( + name: string = 'AtLeastOneKey', + code: number = 1302, + message: string = 'You need at least one Access Key', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, AtLeastOneKeyError.prototype) + } +} + +export class TimeoutError extends WebrpcError { + constructor( + name: string = 'Timeout', + code: number = 1900, + message: string = 'Request timed out', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, TimeoutError.prototype) + } +} + export class InvalidArgumentError extends WebrpcError { constructor( name: string = 'InvalidArgument', @@ -1414,6 +1716,19 @@ export class NotFoundError extends WebrpcError { } } +export class InsufficientFeeError extends WebrpcError { + constructor( + name: string = 'InsufficientFee', + code: number = 3004, + message: string = 'Insufficient fee', + status: number = 0, + cause?: string + ) { + super(name, code, message, status, cause) + Object.setPrototypeOf(this, InsufficientFeeError.prototype) + } +} + export enum errors { WebrpcEndpoint = 'WebrpcEndpoint', WebrpcRequestFailed = 'WebrpcRequestFailed', @@ -1428,15 +1743,71 @@ export enum errors { WebrpcStreamFinished = 'WebrpcStreamFinished', Unauthorized = 'Unauthorized', PermissionDenied = 'PermissionDenied', + SessionExpired = 'SessionExpired', MethodNotFound = 'MethodNotFound', + RequestConflict = 'RequestConflict', Aborted = 'Aborted', + Geoblocked = 'Geoblocked', + RateLimited = 'RateLimited', + ProjectNotFound = 'ProjectNotFound', + AccessKeyNotFound = 'AccessKeyNotFound', + AccessKeyMismatch = 'AccessKeyMismatch', + InvalidOrigin = 'InvalidOrigin', + InvalidService = 'InvalidService', + UnauthorizedUser = 'UnauthorizedUser', + QuotaExceeded = 'QuotaExceeded', + QuotaRateLimit = 'QuotaRateLimit', + NoDefaultKey = 'NoDefaultKey', + MaxAccessKeys = 'MaxAccessKeys', + AtLeastOneKey = 'AtLeastOneKey', + Timeout = 'Timeout', InvalidArgument = 'InvalidArgument', Unavailable = 'Unavailable', QueryFailed = 'QueryFailed', - NotFound = 'NotFound' -} - -const webrpcErrorByCode: { [code: number]: any } = { + NotFound = 'NotFound', + InsufficientFee = 'InsufficientFee' +} + +export enum WebrpcErrorCodes { + WebrpcEndpoint = 0, + WebrpcRequestFailed = -1, + WebrpcBadRoute = -2, + WebrpcBadMethod = -3, + WebrpcBadRequest = -4, + WebrpcBadResponse = -5, + WebrpcServerPanic = -6, + WebrpcInternalError = -7, + WebrpcClientDisconnected = -8, + WebrpcStreamLost = -9, + WebrpcStreamFinished = -10, + Unauthorized = 1000, + PermissionDenied = 1001, + SessionExpired = 1002, + MethodNotFound = 1003, + RequestConflict = 1004, + Aborted = 1005, + Geoblocked = 1006, + RateLimited = 1007, + ProjectNotFound = 1008, + AccessKeyNotFound = 1101, + AccessKeyMismatch = 1102, + InvalidOrigin = 1103, + InvalidService = 1104, + UnauthorizedUser = 1105, + QuotaExceeded = 1200, + QuotaRateLimit = 1201, + NoDefaultKey = 1300, + MaxAccessKeys = 1301, + AtLeastOneKey = 1302, + Timeout = 1900, + InvalidArgument = 2001, + Unavailable = 2002, + QueryFailed = 2003, + NotFound = 3000, + InsufficientFee = 3004 +} + +export const webrpcErrorByCode: { [code: number]: any } = { [0]: WebrpcEndpointError, [-1]: WebrpcRequestFailedError, [-2]: WebrpcBadRouteError, @@ -1450,12 +1821,29 @@ const webrpcErrorByCode: { [code: number]: any } = { [-10]: WebrpcStreamFinishedError, [1000]: UnauthorizedError, [1001]: PermissionDeniedError, + [1002]: SessionExpiredError, [1003]: MethodNotFoundError, + [1004]: RequestConflictError, [1005]: AbortedError, + [1006]: GeoblockedError, + [1007]: RateLimitedError, + [1008]: ProjectNotFoundError, + [1101]: AccessKeyNotFoundError, + [1102]: AccessKeyMismatchError, + [1103]: InvalidOriginError, + [1104]: InvalidServiceError, + [1105]: UnauthorizedUserError, + [1200]: QuotaExceededError, + [1201]: QuotaRateLimitError, + [1300]: NoDefaultKeyError, + [1301]: MaxAccessKeysError, + [1302]: AtLeastOneKeyError, + [1900]: TimeoutError, [2001]: InvalidArgumentError, [2002]: UnavailableError, [2003]: QueryFailedError, - [3000]: NotFoundError + [3000]: NotFoundError, + [3004]: InsufficientFeeError } export type Fetch = (input: RequestInfo, init?: RequestInit) => Promise diff --git a/packages/relayer/tests/provider-relayer.spec.ts b/packages/relayer/tests/provider-relayer.spec.ts index 681cb59e5..041bb58c1 100644 --- a/packages/relayer/tests/provider-relayer.spec.ts +++ b/packages/relayer/tests/provider-relayer.spec.ts @@ -20,28 +20,24 @@ describe('Wallet integration', function () { let hookCaller: HookCallerMock let contexts: Awaited> - let provider: ethers.providers.Web3Provider + let provider: ethers.BrowserProvider let signers: ethers.Signer[] before(async () => { - provider = new ethers.providers.Web3Provider(hardhat.network.provider as any) - signers = new Array(8).fill(0).map((_, i) => provider.getSigner(i)) + provider = new ethers.BrowserProvider(hardhat.network.provider, undefined, { cacheTimeout: -1 }) + signers = await Promise.all(new Array(8).fill(0).map((_, i) => provider.getSigner(i))) contexts = await context.deploySequenceContexts(signers[0]) relayer = new LocalRelayer(signers[1]) // Deploy call receiver mock - callReceiver = (await new ethers.ContractFactory( - CallReceiverMockArtifact.abi, - CallReceiverMockArtifact.bytecode, - signers[0] - ).deploy()) as CallReceiverMock + callReceiver = (await new ethers.ContractFactory(CallReceiverMockArtifact.abi, CallReceiverMockArtifact.bytecode, signers[0]) + .deploy() + .then(tx => tx.waitForDeployment())) as CallReceiverMock // Deploy hook caller mock - hookCaller = (await new ethers.ContractFactory( - HookCallerMockArtifact.abi, - HookCallerMockArtifact.bytecode, - signers[0] - ).deploy()) as HookCallerMock + hookCaller = (await new ethers.ContractFactory(HookCallerMockArtifact.abi, HookCallerMockArtifact.bytecode, signers[0]) + .deploy() + .then(tx => tx.waitForDeployment())) as HookCallerMock }) describe('Waiting for receipts', () => { @@ -61,6 +57,8 @@ describe('Wallet integration', function () { const signer = ethers.Wallet.createRandom() const orchestrator = new Orchestrator([signer]) + const network = await provider.getNetwork() + const config = v2.config.ConfigCoder.fromSimple({ threshold: 1, checkpoint: 0, @@ -77,7 +75,7 @@ describe('Wallet integration', function () { context: contexts[2], config, orchestrator, - chainId: provider.network.chainId, + chainId: network.chainId, provider, relayer }) @@ -89,16 +87,18 @@ describe('Wallet integration', function () { describe(`For ${c.name} wallet`, () => { it('Should get receipt of success transaction', async () => { - const txn = { + const txn: commons.transaction.Transaction = { to: ethers.Wallet.createRandom().address, - data: ethers.utils.randomBytes(43), + data: ethers.hexlify(ethers.randomBytes(43)), delegateCall: false, revertOnError: false, gasLimit: 140000, value: 0 } - const id = commons.transaction.subdigestOfTransactions(wallet.address, provider.network.chainId, 0, [txn]) + const network = await provider.getNetwork() + + const id = commons.transaction.subdigestOfTransactions(wallet.address, network.chainId, 0, [txn]) const receiptPromise = relayer.wait(id, 10000) await new Promise(r => setTimeout(r, 1000)) @@ -111,29 +111,31 @@ describe('Wallet integration', function () { }) it('Should get receipt of success batch transaction', async () => { - const txns = [ + const txns: commons.transaction.Transaction[] = [ { to: ethers.Wallet.createRandom().address, - data: ethers.utils.randomBytes(43), + data: ethers.hexlify(ethers.randomBytes(43)), delegateCall: false, revertOnError: false, gasLimit: 140000, - value: 0, - nonce: 0 + value: 0 + // nonce: 0 }, { to: ethers.Wallet.createRandom().address, - data: ethers.utils.randomBytes(43), + data: ethers.hexlify(ethers.randomBytes(43)), delegateCall: false, revertOnError: false, gasLimit: 140000, - value: 0, - nonce: 0 + value: 0 + // nonce: 0 } ] + const network = await provider.getNetwork() + const nonce = 0 //wallet.randomNonce() - const id = commons.transaction.subdigestOfTransactions(wallet.address, provider.network.chainId, nonce, txns) + const id = commons.transaction.subdigestOfTransactions(wallet.address, network.chainId, nonce, txns) const receiptPromise = relayer.wait(id, 10000) await new Promise(r => setTimeout(r, 1000)) @@ -146,15 +148,15 @@ describe('Wallet integration', function () { }) it('Should get receipt of batch transaction with failed meta-txs', async () => { - const txns = [ + const txns: commons.transaction.Transaction[] = [ { to: ethers.Wallet.createRandom().address, - data: ethers.utils.randomBytes(43), + data: ethers.hexlify(ethers.randomBytes(43)), delegateCall: false, revertOnError: false, gasLimit: 140000, - value: 0, - nonce: 0 + value: 0 + // nonce: 0 }, { to: contexts[2].factory, @@ -163,13 +165,14 @@ describe('Wallet integration', function () { delegateCall: false, revertOnError: false, gasLimit: 140000, - value: 0, - nonce: 0 + value: 0 + // nonce: 0 } ] + const network = await provider.getNetwork() const nonce = wallet.randomNonce() - const id = commons.transaction.subdigestOfTransactions(wallet.address, provider.network.chainId, nonce, txns) + const id = commons.transaction.subdigestOfTransactions(wallet.address, network.chainId, nonce, txns) const receiptPromise = relayer.wait(id, 10000) await new Promise(r => setTimeout(r, 1000)) @@ -182,18 +185,19 @@ describe('Wallet integration', function () { }) it('Should get receipt of failed transaction', async () => { - const txn = { + const txn: commons.transaction.Transaction = { to: contexts[1].factory, // 0xff not a valid factory method data: '0xffffffffffff', delegateCall: false, revertOnError: false, gasLimit: 140000, - value: 0, - nonce: 0 + value: 0 + // nonce: 0 } - const id = commons.transaction.subdigestOfTransactions(wallet.address, provider.network.chainId, 0, [txn]) + const network = await provider.getNetwork() + const id = commons.transaction.subdigestOfTransactions(wallet.address, network.chainId, 0, [txn]) const receiptPromise = relayer.wait(id, 10000) await new Promise(r => setTimeout(r, 1000)) @@ -208,6 +212,7 @@ describe('Wallet integration', function () { it('Find correct receipt between multiple other transactions', async () => { const altSigner = ethers.Wallet.createRandom() const orchestrator = new Orchestrator([altSigner]) + const network = await provider.getNetwork() const config = v2.config.ConfigCoder.fromSimple({ threshold: 1, @@ -227,7 +232,7 @@ describe('Wallet integration', function () { provider, relayer, orchestrator, - chainId: provider.network.chainId + chainId: network.chainId }) await altWallet.deploy() @@ -239,7 +244,7 @@ describe('Wallet integration', function () { await altWallet.sendTransaction( { to: ethers.Wallet.createRandom().address, - data: ethers.utils.randomBytes(43), + data: ethers.hexlify(ethers.randomBytes(43)), delegateCall: false, revertOnError: false, gasLimit: 140000, @@ -250,17 +255,17 @@ describe('Wallet integration', function () { }) ) - const txn = { + const txn: commons.transaction.Transaction = { to: ethers.Wallet.createRandom().address, - data: ethers.utils.randomBytes(43), + data: ethers.hexlify(ethers.randomBytes(43)), delegateCall: false, revertOnError: false, gasLimit: 140000, - value: 0, - nonce: 0 + value: 0 + // nonce: 0 } - const id = commons.transaction.subdigestOfTransactions(wallet.address, provider.network.chainId, 0, [txn]) + const id = commons.transaction.subdigestOfTransactions(wallet.address, network.chainId, 0, [txn]) const receiptPromise = relayer.wait(id, 10000) await new Promise(r => setTimeout(r, 1000)) @@ -273,7 +278,7 @@ describe('Wallet integration', function () { await altWallet.sendTransaction( { to: ethers.Wallet.createRandom().address, - data: ethers.utils.randomBytes(43), + data: ethers.hexlify(ethers.randomBytes(43)), delegateCall: false, revertOnError: false, gasLimit: 140000, @@ -294,6 +299,7 @@ describe('Wallet integration', function () { // Pre-txs const altSigner = ethers.Wallet.createRandom() const orchestrator = new Orchestrator([altSigner]) + const network = await provider.getNetwork() const config = v2.config.ConfigCoder.fromSimple({ threshold: 1, @@ -313,7 +319,7 @@ describe('Wallet integration', function () { provider, relayer, orchestrator, - chainId: provider.network.chainId + chainId: network.chainId }) await Promise.all( @@ -321,7 +327,7 @@ describe('Wallet integration', function () { await altWallet.sendTransaction( { to: ethers.Wallet.createRandom().address, - data: ethers.utils.randomBytes(43), + data: ethers.hexlify(ethers.randomBytes(43)), delegateCall: false, revertOnError: false, gasLimit: 140000, @@ -349,17 +355,17 @@ describe('Wallet integration', function () { }) ) - const txn = { + const txn: commons.transaction.Transaction = { to: ethers.Wallet.createRandom().address, - data: ethers.utils.randomBytes(43), + data: ethers.hexlify(ethers.randomBytes(43)), delegateCall: false, revertOnError: false, gasLimit: 140000, - value: 0, - nonce: 0 + value: 0 + // nonce: 0 } - const id = commons.transaction.subdigestOfTransactions(wallet.address, provider.network.chainId, 0, [txn]) + const id = commons.transaction.subdigestOfTransactions(wallet.address, network.chainId, 0, [txn]) const receiptPromise = relayer.wait(id, 10000) await new Promise(r => setTimeout(r, 1000)) @@ -376,6 +382,7 @@ describe('Wallet integration', function () { // Pre-txs const altSigner = ethers.Wallet.createRandom() const orchestrator = new Orchestrator([altSigner]) + const network = await provider.getNetwork() const config = v2.config.ConfigCoder.fromSimple({ threshold: 1, @@ -395,7 +402,7 @@ describe('Wallet integration', function () { provider, relayer, orchestrator, - chainId: provider.network.chainId + chainId: network.chainId }) await Promise.all( @@ -403,7 +410,7 @@ describe('Wallet integration', function () { await altWallet.sendTransaction( { to: ethers.Wallet.createRandom().address, - data: ethers.utils.randomBytes(43), + data: ethers.hexlify(ethers.randomBytes(43)), delegateCall: false, revertOnError: false, gasLimit: 140000 @@ -429,18 +436,18 @@ describe('Wallet integration', function () { }) ) - const txn = { + const txn: commons.transaction.Transaction = { to: contexts[2].factory, // 0xff not a valid factory method data: '0xffffffffffff', delegateCall: false, revertOnError: false, gasLimit: 140000, - value: 0, - nonce: 0 + value: 0 + // nonce: 0 } - const id = commons.transaction.subdigestOfTransactions(wallet.address, provider.network.chainId, 0, [txn]) + const id = commons.transaction.subdigestOfTransactions(wallet.address, network.chainId, 0, [txn]) const receiptPromise = relayer.wait(id, 10000) await new Promise(r => setTimeout(r, 1000)) @@ -453,17 +460,19 @@ describe('Wallet integration', function () { }) it('Should timeout receipt if transaction is never sent', async () => { - const txn = { + const txn: commons.transaction.Transaction = { to: ethers.Wallet.createRandom().address, - data: ethers.utils.randomBytes(43), + data: ethers.hexlify(ethers.randomBytes(43)), delegateCall: false, revertOnError: false, gasLimit: 140000, - value: 0, - nonce: 0 + value: 0 + // nonce: 0 } - const id = commons.transaction.subdigestOfTransactions(wallet.address, provider.network.chainId, 0, [txn]) + const network = await provider.getNetwork() + + const id = commons.transaction.subdigestOfTransactions(wallet.address, network.chainId, 0, [txn]) const receiptPromise = relayer.wait(id, 2000) await expect(receiptPromise).to.be.rejectedWith(`Timeout waiting for transaction receipt ${id}`) @@ -477,7 +486,7 @@ describe('Wallet integration', function () { await wallet.sendTransaction( { to: ethers.Wallet.createRandom().address, - data: ethers.utils.randomBytes(43), + data: ethers.hexlify(ethers.randomBytes(43)), delegateCall: false, revertOnError: false, gasLimit: 140000, @@ -505,15 +514,17 @@ describe('Wallet integration', function () { }) ) - const txn = { + const txn: commons.transaction.Transaction = { to: ethers.Wallet.createRandom().address, - data: ethers.utils.randomBytes(43), + data: ethers.hexlify(ethers.randomBytes(43)), delegateCall: false, revertOnError: false, gasLimit: 140000 } - const id = commons.transaction.subdigestOfTransactions(wallet.address, provider.network.chainId, 0, [txn]) + const network = await provider.getNetwork() + + const id = commons.transaction.subdigestOfTransactions(wallet.address, network.chainId, 0, [txn]) const receiptPromise = relayer.wait(id, 10000) await new Promise(r => setTimeout(r, 1000)) diff --git a/packages/replacer/CHANGELOG.md b/packages/replacer/CHANGELOG.md index e8d9ec560..9beb6ac6f 100644 --- a/packages/replacer/CHANGELOG.md +++ b/packages/replacer/CHANGELOG.md @@ -1,5 +1,504 @@ # @0xsequence/replacer +## 2.2.14 + +### Patch Changes + +- Somnia Testnet and Monad Testnet +- Updated dependencies + - @0xsequence/abi@2.2.14 + - @0xsequence/core@2.2.14 + +## 2.2.13 + +### Patch Changes + +- Add XR1 to all networks +- Updated dependencies + - @0xsequence/abi@2.2.13 + - @0xsequence/core@2.2.13 + +## 2.2.12 + +### Patch Changes + +- Add XR1 +- Updated dependencies + - @0xsequence/abi@2.2.12 + - @0xsequence/core@2.2.12 + +## 2.2.11 + +### Patch Changes + +- Relayer updates +- Updated dependencies + - @0xsequence/abi@2.2.11 + - @0xsequence/core@2.2.11 + +## 2.2.10 + +### Patch Changes + +- Etherlink support +- Updated dependencies + - @0xsequence/abi@2.2.10 + - @0xsequence/core@2.2.10 + +## 2.2.9 + +### Patch Changes + +- Indexer gateway native token balances +- Updated dependencies + - @0xsequence/abi@2.2.9 + - @0xsequence/core@2.2.9 + +## 2.2.8 + +### Patch Changes + +- Add Moonbeam and Moonbase Alpha +- Updated dependencies + - @0xsequence/abi@2.2.8 + - @0xsequence/core@2.2.8 + +## 2.2.7 + +### Patch Changes + +- Update Builder package +- Updated dependencies + - @0xsequence/abi@2.2.7 + - @0xsequence/core@2.2.7 + +## 2.2.6 + +### Patch Changes + +- Update relayer package +- Updated dependencies + - @0xsequence/abi@2.2.6 + - @0xsequence/core@2.2.6 + +## 2.2.5 + +### Patch Changes + +- auth: fix sequence indexer gateway url +- account: immutable wallet proxy hook +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.2.5 + - @0xsequence/core@2.2.5 + +## 2.2.4 + +### Patch Changes + +- network: update soneium mainnet block explorer url +- waas: signTypedData intent support +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.2.4 + - @0xsequence/core@2.2.4 + +## 2.2.3 + +### Patch Changes + +- provider: updating initWallet to use connected network configs if they exist +- Updated dependencies + - @0xsequence/abi@2.2.3 + - @0xsequence/core@2.2.3 + +## 2.2.2 + +### Patch Changes + +- pass projectAccessKey to relayer at all times +- Updated dependencies + - @0xsequence/abi@2.2.2 + - @0xsequence/core@2.2.2 + +## 2.2.1 + +### Patch Changes + +- waas-ethers: sign typed data +- Updated dependencies + - @0xsequence/abi@2.2.1 + - @0xsequence/core@2.2.1 + +## 2.2.0 + +### Minor Changes + +- indexer: gateway client +- @0xsequence/builder +- upgrade puppeteer to v23.10.3 + +### Patch Changes + +- Updated dependencies +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.2.0 + - @0xsequence/core@2.2.0 + +## 2.1.8 + +### Patch Changes + +- Add Soneium Mainnet +- Updated dependencies + - @0xsequence/abi@2.1.8 + - @0xsequence/core@2.1.8 + +## 2.1.7 + +### Patch Changes + +- guard: pass project access key to guard requests +- Updated dependencies + - @0xsequence/abi@2.1.7 + - @0xsequence/core@2.1.7 + +## 2.1.6 + +### Patch Changes + +- Add LAOS and Telos Testnet chains +- Updated dependencies + - @0xsequence/abi@2.1.6 + - @0xsequence/core@2.1.6 + +## 2.1.5 + +### Patch Changes + +- account: save presigned configuration with reference chain id 1 +- Updated dependencies + - @0xsequence/abi@2.1.5 + - @0xsequence/core@2.1.5 + +## 2.1.4 + +### Patch Changes + +- provider: pass projectAccessKey into MuxMessageProvider +- Updated dependencies + - @0xsequence/abi@2.1.4 + - @0xsequence/core@2.1.4 + +## 2.1.3 + +### Patch Changes + +- waas: time drift date fix due to strange browser quirk +- Updated dependencies + - @0xsequence/abi@2.1.3 + - @0xsequence/core@2.1.3 + +## 2.1.2 + +### Patch Changes + +- provider: export analytics correctly +- Updated dependencies + - @0xsequence/abi@2.1.2 + - @0xsequence/core@2.1.2 + +## 2.1.1 + +### Patch Changes + +- Add LAOS chain support +- Updated dependencies + - @0xsequence/abi@2.1.1 + - @0xsequence/core@2.1.1 + +## 2.1.0 + +### Minor Changes + +- account: forward project access key when estimating fees and sending transactions + +### Patch Changes + +- sessions: save signatures with reference chain id +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.1.0 + - @0xsequence/core@2.1.0 + +## 2.0.26 + +### Patch Changes + +- account: fix chain id comparison +- Updated dependencies + - @0xsequence/abi@2.0.26 + - @0xsequence/core@2.0.26 + +## 2.0.25 + +### Patch Changes + +- skale-nebula: deploy gas limit = 10m +- Updated dependencies + - @0xsequence/abi@2.0.25 + - @0xsequence/core@2.0.25 + +## 2.0.24 + +### Patch Changes + +- sessions: arweave: configurable gateway url +- waas: use /status to get time drift before sending any intents +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.24 + - @0xsequence/core@2.0.24 + +## 2.0.23 + +### Patch Changes + +- Add The Root Network support +- Updated dependencies + - @0xsequence/abi@2.0.23 + - @0xsequence/core@2.0.23 + +## 2.0.22 + +### Patch Changes + +- Add SKALE Nebula Mainnet support +- Updated dependencies + - @0xsequence/abi@2.0.22 + - @0xsequence/core@2.0.22 + +## 2.0.21 + +### Patch Changes + +- account: add publishWitnessFor +- Updated dependencies + - @0xsequence/abi@2.0.21 + - @0xsequence/core@2.0.21 + +## 2.0.20 + +### Patch Changes + +- upgrade deps, and improve waas session status handling +- Updated dependencies + - @0xsequence/abi@2.0.20 + - @0xsequence/core@2.0.20 + +## 2.0.19 + +### Patch Changes + +- Add Immutable zkEVM support +- Updated dependencies + - @0xsequence/abi@2.0.19 + - @0xsequence/core@2.0.19 + +## 2.0.18 + +### Patch Changes + +- waas: new contractCall transaction type +- sessions: add arweave owner +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.18 + - @0xsequence/core@2.0.18 + +## 2.0.17 + +### Patch Changes + +- update waas auth to clear session before signIn +- Updated dependencies + - @0xsequence/abi@2.0.17 + - @0xsequence/core@2.0.17 + +## 2.0.16 + +### Patch Changes + +- Removed Astar chains +- Updated dependencies + - @0xsequence/abi@2.0.16 + - @0xsequence/core@2.0.16 + +## 2.0.15 + +### Patch Changes + +- indexer: update bindings with token balance additions +- Updated dependencies + - @0xsequence/abi@2.0.15 + - @0xsequence/core@2.0.15 + +## 2.0.14 + +### Patch Changes + +- sessions: arweave config reader +- network: add b3 and apechain mainnet configs +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.14 + - @0xsequence/core@2.0.14 + +## 2.0.13 + +### Patch Changes + +- network: toy-testnet +- Updated dependencies + - @0xsequence/abi@2.0.13 + - @0xsequence/core@2.0.13 + +## 2.0.12 + +### Patch Changes + +- api: update bindings +- Updated dependencies + - @0xsequence/abi@2.0.12 + - @0xsequence/core@2.0.12 + +## 2.0.11 + +### Patch Changes + +- waas: intents test fix +- api: update bindings +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.11 + - @0xsequence/core@2.0.11 + +## 2.0.10 + +### Patch Changes + +- network: soneium minato testnet +- Updated dependencies + - @0xsequence/abi@2.0.10 + - @0xsequence/core@2.0.10 + +## 2.0.9 + +### Patch Changes + +- network: fix SKALE network name +- Updated dependencies + - @0xsequence/abi@2.0.9 + - @0xsequence/core@2.0.9 + +## 2.0.8 + +### Patch Changes + +- metadata: update bindings +- Updated dependencies + - @0xsequence/abi@2.0.8 + - @0xsequence/core@2.0.8 + +## 2.0.7 + +### Patch Changes + +- wallet request handler fix +- Updated dependencies + - @0xsequence/abi@2.0.7 + - @0xsequence/core@2.0.7 + +## 2.0.6 + +### Patch Changes + +- network: matic -> pol +- Updated dependencies + - @0xsequence/abi@2.0.6 + - @0xsequence/core@2.0.6 + +## 2.0.5 + +### Patch Changes + +- provider: update databeat to 0.9.2 +- Updated dependencies + - @0xsequence/abi@2.0.5 + - @0xsequence/core@2.0.5 + +## 2.0.4 + +### Patch Changes + +- network: add skale-nebula-testnet +- Updated dependencies + - @0xsequence/abi@2.0.4 + - @0xsequence/core@2.0.4 + +## 2.0.3 + +### Patch Changes + +- waas: check session status in SequenceWaaS.isSignedIn() +- Updated dependencies + - @0xsequence/abi@2.0.3 + - @0xsequence/core@2.0.3 + +## 2.0.2 + +### Patch Changes + +- sessions: property convert serialized bignumber hex value to bigint +- Updated dependencies + - @0xsequence/abi@2.0.2 + - @0xsequence/core@2.0.2 + +## 2.0.1 + +### Patch Changes + +- waas: http signature check for authenticator requests +- provider: unwrap legacy json rpc responses +- use json replacer and reviver for bigints +- Updated dependencies +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.1 + - @0xsequence/core@2.0.1 + +## 2.0.0 + +### Major Changes + +- ethers v6 + +### Patch Changes + +- Updated dependencies + - @0xsequence/abi@2.0.0 + - @0xsequence/core@2.0.0 + +## 1.10.15 + +### Patch Changes + +- utils: extractProjectIdFromAccessKey +- Updated dependencies + - @0xsequence/abi@1.10.15 + - @0xsequence/core@1.10.15 + ## 1.10.14 ### Patch Changes diff --git a/packages/replacer/package.json b/packages/replacer/package.json index a4bed98de..2d2cabf8d 100644 --- a/packages/replacer/package.json +++ b/packages/replacer/package.json @@ -1,6 +1,6 @@ { "name": "@0xsequence/replacer", - "version": "1.10.14", + "version": "2.2.14", "description": "EIP-5719 client implementation", "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/replacer", "source": "src/index.ts", @@ -11,13 +11,13 @@ "scripts": { "test": "echo 'TODO: replacer tests'" }, + "peerDependencies": { + "ethers": ">=6" + }, "dependencies": { "@0xsequence/abi": "workspace:*", "@0xsequence/core": "workspace:*" }, - "peerDependencies": { - "ethers": ">=5.5" - }, "devDependencies": {}, "files": [ "src", diff --git a/packages/replacer/src/cached.ts b/packages/replacer/src/cached.ts index 28ae1e5c7..96e8043fe 100644 --- a/packages/replacer/src/cached.ts +++ b/packages/replacer/src/cached.ts @@ -3,7 +3,7 @@ import { runByEIP5719, URISolver } from '.' export class CachedEIP5719 { constructor( - public provider: ethers.providers.Provider, + public provider: ethers.Provider, public solver?: URISolver, public window: number = 1000 ) {} diff --git a/packages/replacer/src/index.ts b/packages/replacer/src/index.ts index 02c76da8f..9811b0001 100644 --- a/packages/replacer/src/index.ts +++ b/packages/replacer/src/index.ts @@ -5,7 +5,7 @@ import { commons } from '@0xsequence/core' export * from './cached' -export function eip5719Contract(address: string, provider: ethers.providers.Provider): ethers.Contract { +export function eip5719Contract(address: string, provider: ethers.Provider): ethers.Contract { // TODO: for some reason walletContracts is not being loaded from local // remove this code once fixed const abi = [ @@ -31,19 +31,19 @@ export function eip5719Contract(address: string, provider: ethers.providers.Prov return new ethers.Contract(address, abi, provider) } -export function eip1271Contract(address: string, provider: ethers.providers.Provider): ethers.Contract { +export function eip1271Contract(address: string, provider: ethers.Provider): ethers.Contract { return new ethers.Contract(address, walletContracts.erc1271.abi, provider) } export async function isValidSignature( address: string, - provider: ethers.providers.Provider, + provider: ethers.Provider, digest: ethers.BytesLike, signature: ethers.BytesLike ): Promise { // First we try to validate the signature using Ethers try { - const addr = ethers.utils.recoverAddress(digest, signature) + const addr = ethers.recoverAddress(digest, ethers.hexlify(signature)) if (addr.toLowerCase() === address.toLowerCase()) return true } catch {} @@ -72,7 +72,7 @@ async function tryAwait(promise: Promise): Promise { export async function runByEIP5719( address: string, - provider: ethers.providers.Provider, + provider: ethers.Provider, digest: ethers.BytesLike, signature: ethers.BytesLike, solver?: URISolver, @@ -94,10 +94,11 @@ export async function runByEIP5719( const altUri = await tryAwait(eip5719Contract(address, provider).getAlternativeSignature(digest) as Promise) if (!altUri || altUri === '') throw new Error('EIP5719 - Invalid signature and no alternative signature') - const altSignature = ethers.utils.hexlify(await (solver || new URISolverIPFS()).resolve(altUri)) + const altSignature = ethers.hexlify(await (solver || new URISolverIPFS()).resolve(altUri)) if (!altSignature || altSignature === '') throw new Error('EIP5719 - Empty alternative signature') - if (altSignature === ethers.utils.hexlify(signature)) throw new Error('EIP5719 - Alternative signature is invalid or the same') - + if (altSignature === ethers.hexlify(signature)) { + throw new Error('EIP5719 - Alternative signature is invalid or the same') + } return runByEIP5719(address, provider, digest, altSignature, solver, tries + 1) } diff --git a/packages/sessions/CHANGELOG.md b/packages/sessions/CHANGELOG.md index a736522ad..4fc78a820 100644 --- a/packages/sessions/CHANGELOG.md +++ b/packages/sessions/CHANGELOG.md @@ -1,5 +1,606 @@ # @0xsequence/sessions +## 2.2.14 + +### Patch Changes + +- Somnia Testnet and Monad Testnet +- Updated dependencies + - @0xsequence/core@2.2.14 + - @0xsequence/migration@2.2.14 + - @0xsequence/replacer@2.2.14 + - @0xsequence/utils@2.2.14 + +## 2.2.13 + +### Patch Changes + +- Add XR1 to all networks +- Updated dependencies + - @0xsequence/core@2.2.13 + - @0xsequence/migration@2.2.13 + - @0xsequence/replacer@2.2.13 + - @0xsequence/utils@2.2.13 + +## 2.2.12 + +### Patch Changes + +- Add XR1 +- Updated dependencies + - @0xsequence/core@2.2.12 + - @0xsequence/migration@2.2.12 + - @0xsequence/replacer@2.2.12 + - @0xsequence/utils@2.2.12 + +## 2.2.11 + +### Patch Changes + +- Relayer updates +- Updated dependencies + - @0xsequence/core@2.2.11 + - @0xsequence/migration@2.2.11 + - @0xsequence/replacer@2.2.11 + - @0xsequence/utils@2.2.11 + +## 2.2.10 + +### Patch Changes + +- Etherlink support +- Updated dependencies + - @0xsequence/core@2.2.10 + - @0xsequence/migration@2.2.10 + - @0xsequence/replacer@2.2.10 + - @0xsequence/utils@2.2.10 + +## 2.2.9 + +### Patch Changes + +- Indexer gateway native token balances +- Updated dependencies + - @0xsequence/core@2.2.9 + - @0xsequence/migration@2.2.9 + - @0xsequence/replacer@2.2.9 + - @0xsequence/utils@2.2.9 + +## 2.2.8 + +### Patch Changes + +- Add Moonbeam and Moonbase Alpha +- Updated dependencies + - @0xsequence/core@2.2.8 + - @0xsequence/migration@2.2.8 + - @0xsequence/replacer@2.2.8 + - @0xsequence/utils@2.2.8 + +## 2.2.7 + +### Patch Changes + +- Update Builder package +- Updated dependencies + - @0xsequence/core@2.2.7 + - @0xsequence/migration@2.2.7 + - @0xsequence/replacer@2.2.7 + - @0xsequence/utils@2.2.7 + +## 2.2.6 + +### Patch Changes + +- Update relayer package +- Updated dependencies + - @0xsequence/core@2.2.6 + - @0xsequence/migration@2.2.6 + - @0xsequence/replacer@2.2.6 + - @0xsequence/utils@2.2.6 + +## 2.2.5 + +### Patch Changes + +- auth: fix sequence indexer gateway url +- account: immutable wallet proxy hook +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.2.5 + - @0xsequence/migration@2.2.5 + - @0xsequence/replacer@2.2.5 + - @0xsequence/utils@2.2.5 + +## 2.2.4 + +### Patch Changes + +- network: update soneium mainnet block explorer url +- waas: signTypedData intent support +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.2.4 + - @0xsequence/migration@2.2.4 + - @0xsequence/replacer@2.2.4 + - @0xsequence/utils@2.2.4 + +## 2.2.3 + +### Patch Changes + +- provider: updating initWallet to use connected network configs if they exist +- Updated dependencies + - @0xsequence/core@2.2.3 + - @0xsequence/migration@2.2.3 + - @0xsequence/replacer@2.2.3 + - @0xsequence/utils@2.2.3 + +## 2.2.2 + +### Patch Changes + +- pass projectAccessKey to relayer at all times +- Updated dependencies + - @0xsequence/core@2.2.2 + - @0xsequence/migration@2.2.2 + - @0xsequence/replacer@2.2.2 + - @0xsequence/utils@2.2.2 + +## 2.2.1 + +### Patch Changes + +- waas-ethers: sign typed data +- Updated dependencies + - @0xsequence/core@2.2.1 + - @0xsequence/migration@2.2.1 + - @0xsequence/replacer@2.2.1 + - @0xsequence/utils@2.2.1 + +## 2.2.0 + +### Minor Changes + +- indexer: gateway client +- @0xsequence/builder +- upgrade puppeteer to v23.10.3 + +### Patch Changes + +- Updated dependencies +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.2.0 + - @0xsequence/migration@2.2.0 + - @0xsequence/replacer@2.2.0 + - @0xsequence/utils@2.2.0 + +## 2.1.8 + +### Patch Changes + +- Add Soneium Mainnet +- Updated dependencies + - @0xsequence/core@2.1.8 + - @0xsequence/migration@2.1.8 + - @0xsequence/replacer@2.1.8 + - @0xsequence/utils@2.1.8 + +## 2.1.7 + +### Patch Changes + +- guard: pass project access key to guard requests +- Updated dependencies + - @0xsequence/core@2.1.7 + - @0xsequence/migration@2.1.7 + - @0xsequence/replacer@2.1.7 + - @0xsequence/utils@2.1.7 + +## 2.1.6 + +### Patch Changes + +- Add LAOS and Telos Testnet chains +- Updated dependencies + - @0xsequence/core@2.1.6 + - @0xsequence/migration@2.1.6 + - @0xsequence/replacer@2.1.6 + - @0xsequence/utils@2.1.6 + +## 2.1.5 + +### Patch Changes + +- account: save presigned configuration with reference chain id 1 +- Updated dependencies + - @0xsequence/core@2.1.5 + - @0xsequence/migration@2.1.5 + - @0xsequence/replacer@2.1.5 + - @0xsequence/utils@2.1.5 + +## 2.1.4 + +### Patch Changes + +- provider: pass projectAccessKey into MuxMessageProvider +- Updated dependencies + - @0xsequence/core@2.1.4 + - @0xsequence/migration@2.1.4 + - @0xsequence/replacer@2.1.4 + - @0xsequence/utils@2.1.4 + +## 2.1.3 + +### Patch Changes + +- waas: time drift date fix due to strange browser quirk +- Updated dependencies + - @0xsequence/core@2.1.3 + - @0xsequence/migration@2.1.3 + - @0xsequence/replacer@2.1.3 + - @0xsequence/utils@2.1.3 + +## 2.1.2 + +### Patch Changes + +- provider: export analytics correctly +- Updated dependencies + - @0xsequence/core@2.1.2 + - @0xsequence/migration@2.1.2 + - @0xsequence/replacer@2.1.2 + - @0xsequence/utils@2.1.2 + +## 2.1.1 + +### Patch Changes + +- Add LAOS chain support +- Updated dependencies + - @0xsequence/core@2.1.1 + - @0xsequence/migration@2.1.1 + - @0xsequence/replacer@2.1.1 + - @0xsequence/utils@2.1.1 + +## 2.1.0 + +### Minor Changes + +- account: forward project access key when estimating fees and sending transactions + +### Patch Changes + +- sessions: save signatures with reference chain id +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.1.0 + - @0xsequence/migration@2.1.0 + - @0xsequence/replacer@2.1.0 + - @0xsequence/utils@2.1.0 + +## 2.0.26 + +### Patch Changes + +- account: fix chain id comparison +- Updated dependencies + - @0xsequence/core@2.0.26 + - @0xsequence/migration@2.0.26 + - @0xsequence/replacer@2.0.26 + - @0xsequence/utils@2.0.26 + +## 2.0.25 + +### Patch Changes + +- skale-nebula: deploy gas limit = 10m +- Updated dependencies + - @0xsequence/core@2.0.25 + - @0xsequence/migration@2.0.25 + - @0xsequence/replacer@2.0.25 + - @0xsequence/utils@2.0.25 + +## 2.0.24 + +### Patch Changes + +- sessions: arweave: configurable gateway url +- waas: use /status to get time drift before sending any intents +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.0.24 + - @0xsequence/migration@2.0.24 + - @0xsequence/replacer@2.0.24 + - @0xsequence/utils@2.0.24 + +## 2.0.23 + +### Patch Changes + +- Add The Root Network support +- Updated dependencies + - @0xsequence/core@2.0.23 + - @0xsequence/migration@2.0.23 + - @0xsequence/replacer@2.0.23 + - @0xsequence/utils@2.0.23 + +## 2.0.22 + +### Patch Changes + +- Add SKALE Nebula Mainnet support +- Updated dependencies + - @0xsequence/core@2.0.22 + - @0xsequence/migration@2.0.22 + - @0xsequence/replacer@2.0.22 + - @0xsequence/utils@2.0.22 + +## 2.0.21 + +### Patch Changes + +- account: add publishWitnessFor +- Updated dependencies + - @0xsequence/core@2.0.21 + - @0xsequence/migration@2.0.21 + - @0xsequence/replacer@2.0.21 + - @0xsequence/utils@2.0.21 + +## 2.0.20 + +### Patch Changes + +- upgrade deps, and improve waas session status handling +- Updated dependencies + - @0xsequence/core@2.0.20 + - @0xsequence/migration@2.0.20 + - @0xsequence/replacer@2.0.20 + - @0xsequence/utils@2.0.20 + +## 2.0.19 + +### Patch Changes + +- Add Immutable zkEVM support +- Updated dependencies + - @0xsequence/core@2.0.19 + - @0xsequence/migration@2.0.19 + - @0xsequence/replacer@2.0.19 + - @0xsequence/utils@2.0.19 + +## 2.0.18 + +### Patch Changes + +- waas: new contractCall transaction type +- sessions: add arweave owner +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.0.18 + - @0xsequence/migration@2.0.18 + - @0xsequence/replacer@2.0.18 + - @0xsequence/utils@2.0.18 + +## 2.0.17 + +### Patch Changes + +- update waas auth to clear session before signIn +- Updated dependencies + - @0xsequence/core@2.0.17 + - @0xsequence/migration@2.0.17 + - @0xsequence/replacer@2.0.17 + - @0xsequence/utils@2.0.17 + +## 2.0.16 + +### Patch Changes + +- Removed Astar chains +- Updated dependencies + - @0xsequence/core@2.0.16 + - @0xsequence/migration@2.0.16 + - @0xsequence/replacer@2.0.16 + - @0xsequence/utils@2.0.16 + +## 2.0.15 + +### Patch Changes + +- indexer: update bindings with token balance additions +- Updated dependencies + - @0xsequence/core@2.0.15 + - @0xsequence/migration@2.0.15 + - @0xsequence/replacer@2.0.15 + - @0xsequence/utils@2.0.15 + +## 2.0.14 + +### Patch Changes + +- sessions: arweave config reader +- network: add b3 and apechain mainnet configs +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.0.14 + - @0xsequence/migration@2.0.14 + - @0xsequence/replacer@2.0.14 + - @0xsequence/utils@2.0.14 + +## 2.0.13 + +### Patch Changes + +- network: toy-testnet +- Updated dependencies + - @0xsequence/core@2.0.13 + - @0xsequence/migration@2.0.13 + - @0xsequence/replacer@2.0.13 + - @0xsequence/utils@2.0.13 + +## 2.0.12 + +### Patch Changes + +- api: update bindings +- Updated dependencies + - @0xsequence/core@2.0.12 + - @0xsequence/migration@2.0.12 + - @0xsequence/replacer@2.0.12 + - @0xsequence/utils@2.0.12 + +## 2.0.11 + +### Patch Changes + +- waas: intents test fix +- api: update bindings +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.0.11 + - @0xsequence/migration@2.0.11 + - @0xsequence/replacer@2.0.11 + - @0xsequence/utils@2.0.11 + +## 2.0.10 + +### Patch Changes + +- network: soneium minato testnet +- Updated dependencies + - @0xsequence/core@2.0.10 + - @0xsequence/migration@2.0.10 + - @0xsequence/replacer@2.0.10 + - @0xsequence/utils@2.0.10 + +## 2.0.9 + +### Patch Changes + +- network: fix SKALE network name +- Updated dependencies + - @0xsequence/core@2.0.9 + - @0xsequence/migration@2.0.9 + - @0xsequence/replacer@2.0.9 + - @0xsequence/utils@2.0.9 + +## 2.0.8 + +### Patch Changes + +- metadata: update bindings +- Updated dependencies + - @0xsequence/core@2.0.8 + - @0xsequence/migration@2.0.8 + - @0xsequence/replacer@2.0.8 + - @0xsequence/utils@2.0.8 + +## 2.0.7 + +### Patch Changes + +- wallet request handler fix +- Updated dependencies + - @0xsequence/core@2.0.7 + - @0xsequence/migration@2.0.7 + - @0xsequence/replacer@2.0.7 + - @0xsequence/utils@2.0.7 + +## 2.0.6 + +### Patch Changes + +- network: matic -> pol +- Updated dependencies + - @0xsequence/core@2.0.6 + - @0xsequence/migration@2.0.6 + - @0xsequence/replacer@2.0.6 + - @0xsequence/utils@2.0.6 + +## 2.0.5 + +### Patch Changes + +- provider: update databeat to 0.9.2 +- Updated dependencies + - @0xsequence/core@2.0.5 + - @0xsequence/migration@2.0.5 + - @0xsequence/replacer@2.0.5 + - @0xsequence/utils@2.0.5 + +## 2.0.4 + +### Patch Changes + +- network: add skale-nebula-testnet +- Updated dependencies + - @0xsequence/core@2.0.4 + - @0xsequence/migration@2.0.4 + - @0xsequence/replacer@2.0.4 + - @0xsequence/utils@2.0.4 + +## 2.0.3 + +### Patch Changes + +- waas: check session status in SequenceWaaS.isSignedIn() +- Updated dependencies + - @0xsequence/core@2.0.3 + - @0xsequence/migration@2.0.3 + - @0xsequence/replacer@2.0.3 + - @0xsequence/utils@2.0.3 + +## 2.0.2 + +### Patch Changes + +- sessions: property convert serialized bignumber hex value to bigint +- Updated dependencies + - @0xsequence/core@2.0.2 + - @0xsequence/migration@2.0.2 + - @0xsequence/replacer@2.0.2 + - @0xsequence/utils@2.0.2 + +## 2.0.1 + +### Patch Changes + +- waas: http signature check for authenticator requests +- provider: unwrap legacy json rpc responses +- use json replacer and reviver for bigints +- Updated dependencies +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.0.1 + - @0xsequence/migration@2.0.1 + - @0xsequence/replacer@2.0.1 + - @0xsequence/utils@2.0.1 + +## 2.0.0 + +### Major Changes + +- ethers v6 + +### Patch Changes + +- Updated dependencies + - @0xsequence/core@2.0.0 + - @0xsequence/migration@2.0.0 + - @0xsequence/replacer@2.0.0 + +## 1.10.15 + +### Patch Changes + +- utils: extractProjectIdFromAccessKey +- Updated dependencies + - @0xsequence/core@1.10.15 + - @0xsequence/migration@1.10.15 + - @0xsequence/replacer@1.10.15 + ## 1.10.14 ### Patch Changes diff --git a/packages/sessions/package.json b/packages/sessions/package.json index 8a14796f9..ca7c6f364 100644 --- a/packages/sessions/package.json +++ b/packages/sessions/package.json @@ -1,6 +1,6 @@ { "name": "@0xsequence/sessions", - "version": "1.10.14", + "version": "2.2.14", "description": "tools for migrating sequence wallets to new versions", "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/sessions", "source": "src/index.ts", @@ -10,20 +10,24 @@ "license": "Apache-2.0", "scripts": { "test": "pnpm test:file tests/**/*.spec.ts", - "test:file": "TS_NODE_PROJECT=../../tsconfig.test.json mocha -r ts-node/register --timeout 30000", + "test:file": "TS_NODE_PROJECT=../../tsconfig.test.json mocha -r ts-node/register --timeout 60000", "test:coverage": "nyc pnpm test" }, + "peerDependencies": { + "ethers": ">=6" + }, "dependencies": { "@0xsequence/core": "workspace:*", "@0xsequence/migration": "workspace:*", "@0xsequence/replacer": "workspace:*", - "ethers": "^5.5.2", + "@0xsequence/utils": "workspace:*", "idb": "^7.1.1" }, "devDependencies": { "@0xsequence/signhub": "workspace:*", "@0xsequence/tests": "workspace:*", "@istanbuljs/nyc-config-typescript": "^1.0.2", + "ethers": "6.13.4", "fake-indexeddb": "^4.0.1", "nyc": "^15.1.0" }, diff --git a/packages/sessions/src/tracker.ts b/packages/sessions/src/tracker.ts index 2ba337339..3542045ab 100644 --- a/packages/sessions/src/tracker.ts +++ b/packages/sessions/src/tracker.ts @@ -5,6 +5,7 @@ export type PresignedConfig = { wallet: string nextConfig: commons.config.Config signature: string + referenceChainId?: ethers.BigNumberish } export type PresignedConfigLink = Omit & { nextImageHash: string } @@ -18,7 +19,7 @@ export type ConfigDataDump = { presignedTransactions: PresignedConfigLink[] } -export abstract class ConfigTracker { +export interface ConfigTracker { loadPresignedConfiguration: (args: { wallet: string fromImageHash: string @@ -48,7 +49,7 @@ export abstract class ConfigTracker { wallet: string proof: { digest: string - chainId: ethers.BigNumber + chainId: bigint signature: string } }[] diff --git a/packages/sessions/src/trackers/arweave.ts b/packages/sessions/src/trackers/arweave.ts new file mode 100644 index 000000000..d0919964c --- /dev/null +++ b/packages/sessions/src/trackers/arweave.ts @@ -0,0 +1,642 @@ +import { commons, universal, v2 } from '@0xsequence/core' +import { migrator } from '@0xsequence/migration' +import { CachedEIP5719 } from '@0xsequence/replacer' +import { ethers } from 'ethers' +import { ConfigTracker, PresignedConfig, PresignedConfigLink } from '../tracker' + +// depending on @0xsequence/abi breaks 0xsequence's proxy-transport-channel integration test +const MAIN_MODULE_ABI = [ + 'function execute((bool delegateCall, bool revertOnError, uint256 gasLimit, address target, uint256 value, bytes data)[] calldata transactions, uint256 nonce, bytes calldata signature)' +] + +export interface Options { + readonly namespace?: string + readonly owners?: string[] + readonly arweaveUrl?: string + readonly graphqlUrl?: string + readonly eip5719Provider?: ethers.Provider + readonly rateLimitRetryDelayMs?: number +} + +export const defaults = { + namespace: 'Sequence-Sessions', + owners: ['AZ6R2mG8zxW9q7--iZXGrBknjegHoPzmG5IG-nxvMaM'], + arweaveUrl: 'https://arweave.net', + graphqlUrl: 'https://arweave.net/graphql', + eip5719Provider: undefined, + rateLimitRetryDelayMs: 5 * 60 * 1000 +} + +export class ArweaveReader implements ConfigTracker, migrator.PresignedMigrationTracker { + private readonly configs: Map> = new Map() + private readonly eip5719?: CachedEIP5719 + + constructor(readonly options: Options = defaults) { + if (options.eip5719Provider) { + this.eip5719 = new CachedEIP5719(options.eip5719Provider) + } + } + + async loadPresignedConfiguration(args: { + wallet: string + fromImageHash: string + longestPath?: boolean + }): Promise { + const wallet = ethers.getAddress(args.wallet) + + const fromConfig = await this.configOfImageHash({ imageHash: args.fromImageHash }) + if (!fromConfig) { + throw new Error(`unable to find from config ${args.fromImageHash}`) + } + if (!v2.config.isWalletConfig(fromConfig)) { + throw new Error(`from config ${args.fromImageHash} is not v2`) + } + const fromCheckpoint = BigInt(fromConfig.checkpoint) + + const items = Object.entries(await findItems({ Type: 'config update', Wallet: wallet }, this.options)).flatMap( + ([id, tags]) => { + try { + const { Signer: signer, Subdigest: subdigest, Digest: digest, 'To-Config': toImageHash } = tags + + let signatureType: 'eip-712' | 'eth_sign' | 'erc-1271' + switch (tags['Signature-Type']) { + case 'eip-712': + case 'eth_sign': + case 'erc-1271': + signatureType = tags['Signature-Type'] + break + default: + throw new Error(`unknown signature type ${tags['Signature-Type']}`) + } + + let toCheckpoint: bigint + try { + toCheckpoint = BigInt(tags['To-Checkpoint']) + } catch { + throw new Error(`to checkpoint is not a number: ${tags['To-Checkpoint']}`) + } + if (toCheckpoint <= fromCheckpoint) { + return [] + } + + if (!ethers.isAddress(signer)) { + throw new Error(`signer is not an address: ${signer}`) + } + + if (!ethers.isHexString(subdigest, 32)) { + throw new Error(`subdigest is not a hash: ${subdigest}`) + } + + if (!ethers.isHexString(digest, 32)) { + throw new Error(`digest is not a hash: ${digest}`) + } + + let chainId: bigint + try { + chainId = BigInt(tags['Chain-ID']) + } catch { + throw new Error(`chain id is not a number: ${tags['Chain-ID']}`) + } + + if (!ethers.isHexString(toImageHash, 32)) { + throw new Error(`to config is not a hash: ${toImageHash}`) + } + + return [{ id, signatureType, signer, subdigest, digest, chainId, toImageHash, toCheckpoint }] + } catch (error) { + console.warn(`invalid wallet ${wallet} config update ${id}:`, error) + return [] + } + } + ) + + const signatures: Map> = new Map() + let candidates: typeof items = [] + + for (const item of items) { + let imageHashSignatures = signatures.get(item.toImageHash) + if (!imageHashSignatures) { + imageHashSignatures = new Map() + signatures.set(item.toImageHash, imageHashSignatures) + candidates.push(item) + } + imageHashSignatures.set(item.signer, item) + } + + if (args.longestPath) { + candidates.sort(({ toCheckpoint: a }, { toCheckpoint: b }) => (a === b ? 0 : a < b ? -1 : 1)) + } else { + candidates.sort(({ toCheckpoint: a }, { toCheckpoint: b }) => (a === b ? 0 : a < b ? 1 : -1)) + } + + const updates: PresignedConfigLink[] = [] + + for (let currentConfig = fromConfig; candidates.length; ) { + const currentImageHash = v2.config.imageHash(currentConfig) + + let nextCandidate: (typeof candidates)[number] | undefined + let nextCandidateItems: Map + let nextCandidateSigners: string[] = [] + + for (const candidate of candidates) { + nextCandidateItems = signatures.get(candidate.toImageHash)! + nextCandidateSigners = Array.from(nextCandidateItems.keys()) + + const { weight } = v2.signature.encodeSigners( + currentConfig, + new Map(nextCandidateSigners.map(signer => [signer, { signature: '0x', isDynamic: false }])), + [], + 0 + ) + + if (weight >= BigInt(currentConfig.threshold)) { + nextCandidate = candidate + break + } + } + + if (!nextCandidate) { + console.warn(`unreachable configs with checkpoint > ${currentConfig.checkpoint} from config ${currentImageHash}`) + break + } + + const nextImageHash = nextCandidate.toImageHash + + try { + const nextConfig = await this.configOfImageHash({ imageHash: nextImageHash }) + if (!nextConfig) { + throw new Error(`unable to find config ${nextImageHash}`) + } + if (!v2.config.isWalletConfig(nextConfig)) { + throw new Error(`config ${nextImageHash} is not v2`) + } + + const nextCandidateSignatures = new Map( + ( + await Promise.all( + nextCandidateSigners.map(async signer => { + const { id, subdigest, signatureType } = nextCandidateItems.get(signer)! + try { + let signature = await (await fetchItem(id, this.options.rateLimitRetryDelayMs, this.options.arweaveUrl)).text() + switch (signatureType) { + case 'eip-712': + signature += '01' + break + case 'eth_sign': + signature += '02' + break + case 'erc-1271': + signature += '03' + break + } + if (this.eip5719) { + try { + signature = ethers.hexlify(await this.eip5719.runByEIP5719(signer, subdigest, signature)) + } catch (error) { + console.warn(`unable to run eip-5719 on config update ${id}`) + } + } + const recovered = commons.signer.tryRecoverSigner(subdigest, signature) + return [[signer, { signature, isDynamic: recovered !== signer }] as const] + } catch (error) { + console.warn(`unable to fetch signer ${signer} config update ${id}:`, error) + return [] + } + }) + ) + ).flat() + ) + + const { encoded: signature, weight } = v2.signature.encodeSigners(currentConfig, nextCandidateSignatures, [], 0) + if (weight < BigInt(currentConfig.threshold)) { + throw new Error(`insufficient signing power ${weight.toString()} < ${currentConfig.threshold}`) + } + updates.push({ wallet, signature, nextImageHash }) + + currentConfig = nextConfig + candidates = candidates.filter(({ toCheckpoint }) => toCheckpoint > BigInt(currentConfig.checkpoint)) + } catch (error) { + console.warn( + `unable to reconstruct wallet ${wallet} update from config ${currentImageHash} to config ${nextImageHash}:`, + error + ) + candidates = candidates.filter(({ toImageHash }) => toImageHash !== nextImageHash) + } + } + + return updates + } + + savePresignedConfiguration(_args: PresignedConfig): Promise { + throw new Error('arweave backend does not support saving config updates') + } + + saveWitnesses(_args: { wallet: string; digest: string; chainId: ethers.BigNumberish; signatures: string[] }): Promise { + throw new Error('arweave backend does not support saving signatures') + } + + async configOfImageHash(args: { imageHash: string; noCache?: boolean }): Promise { + if (!args.noCache) { + const config = this.configs.get(args.imageHash) + if (config) { + try { + return await config + } catch { + const config = this.configs.get(args.imageHash) + if (config) { + return config + } + } + } + } + + const config = (async (imageHash: string): Promise => { + const items = Object.entries(await findItems({ Type: 'config', Config: imageHash }, this.options)).flatMap(([id, tags]) => { + try { + const version = Number(tags.Version) + if (!version) { + throw new Error(`invalid version: ${tags.Version}`) + } + + return [{ id, version }] + } catch (error) { + console.warn(`config ${imageHash} at ${id} invalid:`, error) + return [] + } + }) + + switch (items.length) { + case 0: + this.configs.set(imageHash, Promise.resolve(undefined)) + return + case 1: + break + default: + console.warn(`multiple configs ${imageHash} at ${items.map(({ id }) => id).join(', ')}`) + break + } + + for (const { id, version } of items) { + try { + const config = { + ...(await (await fetchItem(id, this.options.rateLimitRetryDelayMs, this.options.arweaveUrl)).json()), + version + } + if (config.tree) { + config.tree = toTopology(config.tree) + } + + const actual = universal.coderFor(version).config.imageHashOf(config) + if (actual !== imageHash) { + throw new Error(`image hash is ${actual}, expected ${imageHash}`) + } + + this.configs.set(imageHash, Promise.resolve(config)) + return config + } catch (error) { + console.warn(`config at ${id} invalid:`, error) + } + } + + this.configs.set(imageHash, Promise.resolve(undefined)) + return + })(args.imageHash) + + if (!args.noCache) { + this.configs.set(args.imageHash, config) + } + + return config + } + + saveWalletConfig(_args: { config: commons.config.Config }): Promise { + throw new Error('arweave backend does not support saving configs') + } + + async imageHashOfCounterfactualWallet(args: { + wallet: string + noCache?: boolean + }): Promise<{ imageHash: string; context: commons.context.WalletContext } | undefined> { + const wallet = ethers.getAddress(args.wallet) + + const items = Object.entries(await findItems({ Type: 'wallet', Wallet: wallet }, this.options)).flatMap(([id, tags]) => { + try { + const { 'Deploy-Config': imageHash } = tags + + const version = Number(tags['Deploy-Version']) + if (!version) { + throw new Error(`invalid version: ${tags['Deploy-Version']}`) + } + + if (!imageHash) { + throw new Error('no deploy config') + } + + const context = commons.context.defaultContexts[version] + if (!context) { + throw new Error(`unknown version: ${version}`) + } + + if (commons.context.addressOf(context, imageHash) !== wallet) { + throw new Error(`incorrect v${version} deploy config: ${imageHash}`) + } + + return [{ id, imageHash, context }] + } catch (error) { + console.warn(`wallet ${wallet} at ${id} invalid:`, error) + return [] + } + }) + + switch (items.length) { + case 0: + return + case 1: + break + default: + console.warn(`multiple deploy configs for wallet ${wallet} at ${items.map(({ id }) => id).join(', ')}, using first`) + break + } + + return items[0] + } + + saveCounterfactualWallet(_args: { config: commons.config.Config; context: commons.context.WalletContext[] }): Promise { + throw new Error('arweave backend does not support saving wallets') + } + + async walletsOfSigner(args: { + signer: string + noCache?: boolean + allSignatures?: boolean + }): Promise> { + const signer = ethers.getAddress(args.signer) + + const proofs: Map }> = new Map() + + for (const [id, tags] of Object.entries( + await findItems( + { Type: ['signature', 'config update'], Signer: signer, Witness: args.allSignatures ? undefined : 'true' }, + this.options + ) + )) { + const { Wallet: wallet, Subdigest: subdigest, Digest: digest, 'Chain-ID': chainId } = tags + + try { + if (proofs.has(wallet)) { + continue + } + + let signatureType: '01' | '02' | '03' + switch (tags['Signature-Type']) { + case 'eip-712': + signatureType = '01' + break + case 'eth_sign': + signatureType = '02' + break + case 'erc-1271': + signatureType = '03' + break + default: + throw new Error(`unknown signature type ${tags['Signature-Type']}`) + } + + if (subdigest !== commons.signature.subdigestOf({ digest, chainId, address: wallet })) { + throw new Error('incorrect subdigest') + } + + const signature = fetchItem(id, this.options.rateLimitRetryDelayMs, this.options.arweaveUrl).then(async response => { + const signature = (await response.text()) + signatureType + if (this.eip5719) { + try { + return ethers.hexlify(await this.eip5719.runByEIP5719(signer, subdigest, signature)) + } catch (error) { + console.warn(`unable to run eip-5719 on signature ${id}`) + } + } + return signature + }) + + proofs.set(wallet, { digest, chainId: BigInt(chainId), signature }) + } catch (error) { + console.warn(`signer ${signer} signature ${id} of wallet ${wallet} invalid:`, error) + } + } + + return Promise.all( + [...proofs.entries()].map(async ([wallet, { digest, chainId, signature }]) => ({ + wallet, + proof: { digest, chainId, signature: await signature } + })) + ) + } + + async getMigration( + address: string, + fromImageHash: string, + fromVersion: number, + chainId: ethers.BigNumberish + ): Promise { + const wallet = ethers.getAddress(address) + + const items = Object.entries( + await findItems( + { + Type: 'migration', + Migration: wallet, + 'Chain-ID': BigInt(chainId).toString(), + 'From-Version': `${fromVersion}`, + 'From-Config': fromImageHash + }, + this.options + ) + ).flatMap(([id, tags]) => { + try { + const { 'To-Config': toImageHash, Executor: executor } = tags + + const toVersion = Number(tags['To-Version']) + if (!toVersion) { + throw new Error(`invalid version: ${tags['To-Version']}`) + } + + if (!ethers.isHexString(toImageHash, 32)) { + throw new Error(`to config is not a hash: ${toImageHash}`) + } + + if (!ethers.isAddress(executor)) { + throw new Error(`executor is not an address: ${executor}`) + } + + return { id, toVersion, toImageHash, executor } + } catch (error) { + console.warn( + `chain ${chainId} migration ${id} for v${fromVersion} wallet ${wallet} from config ${fromImageHash} invalid:`, + error + ) + return [] + } + }) + + switch (items.length) { + case 0: + return + case 1: + break + default: + console.warn( + `multiple chain ${chainId} migrations for v${fromVersion} wallet ${wallet} from config ${fromImageHash} at ${items.map(({ id }) => id).join(', ')}, using first` + ) + break + } + + const { id, toVersion, toImageHash, executor } = items[0] + + const [data, toConfig] = await Promise.all([ + fetchItem(id, this.options.rateLimitRetryDelayMs, this.options.arweaveUrl).then(response => response.text()), + this.configOfImageHash({ imageHash: toImageHash }) + ]) + + if (!toConfig) { + throw new Error(`unable to find to config ${toImageHash} for migration`) + } + + const mainModule = new ethers.Interface(MAIN_MODULE_ABI) + const [encoded, nonce, signature] = mainModule.decodeFunctionData('execute', data) + const transactions = commons.transaction.fromTxAbiEncode(encoded) + const subdigest = commons.transaction.subdigestOfTransactions(wallet, chainId, nonce, transactions) + + return { + tx: { entrypoint: executor, transactions, nonce, chainId, intent: { id: subdigest, wallet }, signature }, + fromVersion, + toVersion: Number(toVersion), + toConfig + } + } + + saveMigration(_address: string, _signed: migrator.SignedMigration, _contexts: commons.context.VersionedContext): Promise { + throw new Error('arweave backend does not support saving migrations') + } +} + +async function findItems( + filter: { [name: string]: undefined | string | string[] }, + options?: Options & { pageSize?: number; maxResults?: number } +): Promise<{ [id: string]: { [tag: string]: string } }> { + const namespace = options?.namespace ?? defaults.namespace + const owners = options?.owners + const graphqlUrl = options?.graphqlUrl ?? defaults.graphqlUrl + const rateLimitRetryDelayMs = options?.rateLimitRetryDelayMs ?? defaults.rateLimitRetryDelayMs + const pageSize = options?.pageSize ?? 100 + const maxResults = options?.maxResults + + const tags = Object.entries(filter).flatMap(([name, values]) => + values === undefined + ? [] + : [ + `{ name: "${namespace ? `${namespace}-${name}` : name}", values: [${typeof values === 'string' ? `"${values}"` : values.map(value => `"${value}"`).join(', ')}] }` + ] + ) + + const edges: Array<{ cursor: string; node: { id: string; tags: Array<{ name: string; value: string }> } }> = [] + + for (let hasNextPage = true; hasNextPage && (maxResults === undefined || edges.length < maxResults); ) { + const query = ` + query { + transactions(sort: HEIGHT_DESC, ${edges.length ? `first: ${pageSize}, after: "${edges[edges.length - 1].cursor}"` : `first: ${pageSize}`}, tags: [${tags.join(', ')}]${owners === undefined ? '' : `, owners: [${owners.map(owner => `"${owner}"`).join(', ')}]`}) { + pageInfo { + hasNextPage + } + edges { + cursor + node { + id + tags { + name + value + } + } + } + } + } + ` + + let response: Response + while (true) { + response = await fetch(graphqlUrl, { + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + body: JSON.stringify({ query }), + redirect: 'follow' + }) + if (response.status !== 429) { + break + } + console.warn( + `rate limited by ${graphqlUrl}, trying again in ${rateLimitRetryDelayMs / 1000} seconds at ${new Date(Date.now() + rateLimitRetryDelayMs).toLocaleTimeString()}` + ) + await new Promise(resolve => setTimeout(resolve, rateLimitRetryDelayMs)) + } + + const { + data: { transactions } + } = await response.json() + + edges.push(...transactions.edges) + + hasNextPage = transactions.pageInfo.hasNextPage + } + + return Object.fromEntries( + edges.map(({ node: { id, tags } }) => [ + id, + Object.fromEntries( + tags.map(({ name, value }) => [ + namespace && name.startsWith(`${namespace}-`) ? name.slice(namespace.length + 1) : name, + value + ]) + ) + ]) + ) +} + +async function fetchItem( + id: string, + rateLimitRetryDelayMs = defaults.rateLimitRetryDelayMs, + arweaveUrl = defaults.arweaveUrl +): Promise { + while (true) { + const response = await fetch(`${arweaveUrl}/${id}`, { redirect: 'follow' }) + if (response.status !== 429) { + return response + } + console.warn( + `rate limited by ${arweaveUrl}, trying again in ${rateLimitRetryDelayMs / 1000} seconds at ${new Date(Date.now() + rateLimitRetryDelayMs).toLocaleTimeString()}` + ) + await new Promise(resolve => setTimeout(resolve, rateLimitRetryDelayMs)) + } +} + +function toTopology(topology: any): v2.config.Topology { + if (typeof topology === 'string') { + return { nodeHash: topology } + } + + if (typeof topology === 'object' && topology?.node !== undefined) { + return { nodeHash: topology.node } + } + + if (topology instanceof Array && topology.length === 2) { + return { left: toTopology(topology[0]), right: toTopology(topology[1]) } + } + + if (v2.config.isNode(topology)) { + return { left: toTopology(topology.left), right: toTopology(topology.right) } + } + + if (v2.config.isNestedLeaf(topology)) { + return { ...topology, tree: toTopology(topology.tree) } + } + + return topology +} diff --git a/packages/sessions/src/trackers/cached.ts b/packages/sessions/src/trackers/cached.ts index e1bc44768..54f36a8ea 100644 --- a/packages/sessions/src/trackers/cached.ts +++ b/packages/sessions/src/trackers/cached.ts @@ -1,7 +1,7 @@ import { commons, universal } from '@0xsequence/core' import { migrator } from '@0xsequence/migration' -import { ethers } from 'ethers' import { ConfigTracker, PresignedConfig, PresignedConfigLink } from '../tracker' +import { ethers } from 'ethers' export class CachedTracker implements migrator.PresignedMigrationTracker, ConfigTracker { constructor( @@ -58,7 +58,7 @@ export class CachedTracker implements migrator.PresignedMigrationTracker, Config checkpoints.reduce((acc, val) => { if (!val) return acc if (!acc) return val - if (val.checkpoint.gt(acc.checkpoint)) return val + if (val.checkpoint > acc.checkpoint) return val return acc })?.result ?? [] } @@ -125,7 +125,7 @@ export class CachedTracker implements migrator.PresignedMigrationTracker, Config async walletsOfSigner(args: { signer: string noCache?: boolean - }): Promise<{ wallet: string; proof: { digest: string; chainId: ethers.BigNumber; signature: string } }[]> { + }): Promise<{ wallet: string; proof: { digest: string; chainId: bigint; signature: string } }[]> { if (args.noCache) { return this.tracker.walletsOfSigner(args) } @@ -133,7 +133,7 @@ export class CachedTracker implements migrator.PresignedMigrationTracker, Config // In this case we need to both aggregate the results from the cache and the tracker // and then dedupe the results const results = await Promise.all([this.tracker.walletsOfSigner(args), this.cache.walletsOfSigner(args)]) - const wallets = new Map() + const wallets = new Map() for (const result of results) { for (const wallet of result) { diff --git a/packages/sessions/src/trackers/debug.ts b/packages/sessions/src/trackers/debug.ts index 3a7d8bfa9..99937fd05 100644 --- a/packages/sessions/src/trackers/debug.ts +++ b/packages/sessions/src/trackers/debug.ts @@ -1,7 +1,8 @@ import { commons } from '@0xsequence/core' import { migrator } from '@0xsequence/migration' -import { ethers } from 'ethers' import { ConfigTracker, PresignedConfig, PresignedConfigLink } from '../tracker' +import { ethers } from 'ethers' +import { bigintReplacer } from '@0xsequence/utils' export class DebugConfigTracker implements ConfigTracker, migrator.PresignedMigrationTracker { constructor(private readonly tracker: ConfigTracker & migrator.PresignedMigrationTracker) {} @@ -56,7 +57,7 @@ export class DebugConfigTracker implements ConfigTracker, migrator.PresignedMigr async walletsOfSigner(args: { signer: string - }): Promise<{ wallet: string; proof: { digest: string; chainId: ethers.BigNumber; signature: string } }[]> { + }): Promise<{ wallet: string; proof: { digest: string; chainId: bigint; signature: string } }[]> { console.debug('? walletsOfSigner') debug(args, '? ') return debug(await this.tracker.walletsOfSigner(args), '! ') @@ -86,7 +87,7 @@ function debug(value: T, prefix: string = ''): T { console.debug(prefix + 'undefined') break default: - JSON.stringify(value, undefined, 2) + JSON.stringify(value, bigintReplacer, 2) .split('\n') .map(line => prefix + line) .forEach(line => console.debug(line)) diff --git a/packages/sessions/src/trackers/deduped.ts b/packages/sessions/src/trackers/deduped.ts index c8246df85..4a06680d3 100644 --- a/packages/sessions/src/trackers/deduped.ts +++ b/packages/sessions/src/trackers/deduped.ts @@ -1,6 +1,7 @@ import { commons } from '@0xsequence/core' import { migrator } from '@0xsequence/migration' -import { BigNumber, BigNumberish, ethers } from 'ethers' + +import { ethers } from 'ethers' import { ConfigTracker, PresignedConfig, PresignedConfigLink } from '../tracker' import { PromiseCache } from './promise-cache' import { LocalConfigTracker } from './local' @@ -33,7 +34,7 @@ export class DedupedTracker implements migrator.PresignedMigrationTracker, Confi address: string, fromImageHash: string, fromVersion: number, - chainId: BigNumberish + chainId: ethers.BigNumberish ): Promise { return this.cache.do( 'getMigration', @@ -62,7 +63,7 @@ export class DedupedTracker implements migrator.PresignedMigrationTracker, Confi return this.cache.do('savePresignedConfiguration', undefined, args => this.tracker.savePresignedConfiguration(args), args) } - saveWitnesses(args: { wallet: string; digest: string; chainId: BigNumberish; signatures: string[] }): Promise { + saveWitnesses(args: { wallet: string; digest: string; chainId: ethers.BigNumberish; signatures: string[] }): Promise { return this.cache.do('saveWitnesses', undefined, args => this.tracker.saveWitnesses(args), args) } @@ -87,11 +88,11 @@ export class DedupedTracker implements migrator.PresignedMigrationTracker, Confi walletsOfSigner(args: { signer: string - }): Promise<{ wallet: string; proof: { digest: string; chainId: BigNumber; signature: string } }[]> { + }): Promise<{ wallet: string; proof: { digest: string; chainId: bigint; signature: string } }[]> { return this.cache.do('walletsOfSigner', this.window, args => this.tracker.walletsOfSigner(args), args) } - updateProvider(provider: ethers.providers.Provider) { + updateProvider(provider: ethers.Provider) { if (this.tracker instanceof LocalConfigTracker) { this.tracker.updateProvider(provider) } diff --git a/packages/sessions/src/trackers/index.ts b/packages/sessions/src/trackers/index.ts index 05dddeb00..a26c0c789 100644 --- a/packages/sessions/src/trackers/index.ts +++ b/packages/sessions/src/trackers/index.ts @@ -1,3 +1,4 @@ +export * as arweave from './arweave' export * as debug from './debug' export * as local from './local' export * as remote from './remote' diff --git a/packages/sessions/src/trackers/local.ts b/packages/sessions/src/trackers/local.ts index 9d78cf47a..a04d02af5 100644 --- a/packages/sessions/src/trackers/local.ts +++ b/packages/sessions/src/trackers/local.ts @@ -12,7 +12,7 @@ export class LocalConfigTracker implements ConfigTracker, migrator.PresignedMigr // TODO: The provider is only used to determine that EIP1271 signatures have *some* validity // but when reconstructing a presigned transaction we should do the replacement once per chain. // For now, it's recommended to use Mainnet as the provider. - public provider: ethers.providers.Provider, + public provider: ethers.Provider, private store: TrackerStore = new MemoryTrackerStore(), public useEIP5719: boolean = false ) { @@ -30,8 +30,8 @@ export class LocalConfigTracker implements ConfigTracker, migrator.PresignedMigr if (isPlainNested(node)) { return { - weight: ethers.BigNumber.from(node.weight), - threshold: ethers.BigNumber.from(node.threshold), + weight: BigInt(node.weight), + threshold: BigInt(node.threshold), tree: await this.loadTopology(node.tree) } } @@ -62,8 +62,8 @@ export class LocalConfigTracker implements ConfigTracker, migrator.PresignedMigr if (v2.config.isNestedLeaf(node)) { const saveTree = this.saveTopology(node.tree) const saveThis = this.store.saveV2Node(hash, { - weight: ethers.BigNumber.from(node.weight).toString(), - threshold: ethers.BigNumber.from(node.threshold).toString(), + weight: BigInt(node.weight).toString(), + threshold: BigInt(node.threshold).toString(), tree: v2.config.hashNode(node.tree) } as PlainNested) @@ -115,8 +115,8 @@ export class LocalConfigTracker implements ConfigTracker, migrator.PresignedMigr // const storeTree = this.saveTopology(config.tree) // const storeConfig = this.store.saveConfig(imageHash, { // version: 2, - // threshold: ethers.BigNumber.from(config.threshold).toString(), - // checkpoint: ethers.BigNumber.from(config.checkpoint).toString(), + // threshold: BigInt(config.threshold).toString(), + // checkpoint: BigInt(config.checkpoint).toString(), // tree: v2.config.hashNode(config.tree) // }) @@ -148,8 +148,8 @@ export class LocalConfigTracker implements ConfigTracker, migrator.PresignedMigr if (isPlainV2Config(config)) { const fullConfig = { version: 2, - threshold: ethers.BigNumber.from(config.threshold), - checkpoint: ethers.BigNumber.from(config.checkpoint), + threshold: BigInt(config.threshold), + checkpoint: BigInt(config.checkpoint), tree: await this.loadTopology(config.tree) } as v2.config.WalletConfig this.configOfImageHashCache[args.imageHash] = fullConfig @@ -224,7 +224,7 @@ export class LocalConfigTracker implements ConfigTracker, migrator.PresignedMigr const decoded = v2.signature.SignatureCoder.decode(args.signature) const nextImageHash = universal.genericCoderFor(args.nextConfig.version).config.imageHashOf(args.nextConfig) const message = v2.chained.messageSetImageHash(nextImageHash) - const digest = ethers.utils.keccak256(message) + const digest = ethers.keccak256(message) const payload = { message, address: args.wallet, @@ -283,7 +283,7 @@ export class LocalConfigTracker implements ConfigTracker, migrator.PresignedMigr let bestCandidate: | { nextImageHash: string - checkpoint: ethers.BigNumber + checkpoint: bigint signature: string } | undefined @@ -292,14 +292,14 @@ export class LocalConfigTracker implements ConfigTracker, migrator.PresignedMigr nextImageHashes.map(async ({ nextImageHash, payload }) => { const nextConfig = await this.configOfImageHash({ imageHash: nextImageHash }) if (!nextConfig || !v2.config.isWalletConfig(nextConfig)) return undefined - const nextCheckpoint = ethers.BigNumber.from(nextConfig.checkpoint) + const nextCheckpoint = BigInt(nextConfig.checkpoint) return { nextConfig, nextCheckpoint, nextImageHash, payload } }) ) const sortedNextConfigsAndCheckpoints = nextConfigsAndCheckpoints .filter(c => c !== undefined) - .filter(c => c!.nextCheckpoint.gt(fromConfig.checkpoint)) + .filter(c => c!.nextCheckpoint > BigInt(fromConfig.checkpoint)) .sort((a, b) => // If we are looking for the longest path, sort by ascending checkpoint // because we want to find the smalles jump, and we should start with the @@ -309,7 +309,7 @@ export class LocalConfigTracker implements ConfigTracker, migrator.PresignedMigr // We don't have a guarantee that all "next configs" will be valid // so worst case scenario we will need to try all of them. // But we can try to optimize for the most common case. - a!.nextCheckpoint.gt(b!.nextCheckpoint) ? (longestPath ? 1 : -1) : longestPath ? -1 : 1 + a!.nextCheckpoint > b!.nextCheckpoint ? (longestPath ? 1 : -1) : longestPath ? -1 : 1 ) for (const entry of sortedNextConfigsAndCheckpoints) { @@ -319,10 +319,10 @@ export class LocalConfigTracker implements ConfigTracker, migrator.PresignedMigr const bestCheckpoint = bestCandidate.checkpoint if (longestPath) { // Only consider candidates earlier than our current best - if (nextCheckpoint.gte(bestCheckpoint)) continue + if (nextCheckpoint >= bestCheckpoint) continue } else { // Only consider candidates later than our current best - if (nextCheckpoint.lte(bestCheckpoint)) continue + if (nextCheckpoint <= bestCheckpoint) continue } } @@ -336,7 +336,7 @@ export class LocalConfigTracker implements ConfigTracker, migrator.PresignedMigr return [signer, undefined] } - const replacedSignature = ethers.utils.hexlify( + const replacedSignature = ethers.hexlify( this.useEIP5719 ? await this.cachedEIP5719.runByEIP5719(signer, payload.subdigest, signature) : signature ) @@ -353,12 +353,12 @@ export class LocalConfigTracker implements ConfigTracker, migrator.PresignedMigr // Encode the full signature (to see if it has enough weight) const encoded = v2.signature.SignatureCoder.encodeSigners(fromConfig, signatures, [], 0) - if (encoded.weight.lt(fromConfig.threshold)) continue + if (encoded.weight < BigInt(fromConfig.threshold)) continue // Save the new best candidate bestCandidate = { nextImageHash, - checkpoint: ethers.BigNumber.from(nextConfig.checkpoint), + checkpoint: BigInt(nextConfig.checkpoint), signature: encoded.encoded } } @@ -420,7 +420,7 @@ export class LocalConfigTracker implements ConfigTracker, migrator.PresignedMigr wallet: string proof: { digest: string - chainId: ethers.BigNumber + chainId: bigint signature: string } }[] @@ -435,7 +435,7 @@ export class LocalConfigTracker implements ConfigTracker, migrator.PresignedMigr wallet: string proof: { digest: string - chainId: ethers.BigNumber + chainId: bigint signature: string } }[] = [] @@ -452,8 +452,8 @@ export class LocalConfigTracker implements ConfigTracker, migrator.PresignedMigr wallet, proof: { digest: payload.digest, - chainId: ethers.BigNumber.from(payload.chainId), - signature: ethers.utils.hexlify(signature) + chainId: BigInt(payload.chainId), + signature: ethers.hexlify(signature) } }) } @@ -478,7 +478,7 @@ export class LocalConfigTracker implements ConfigTracker, migrator.PresignedMigr // Split signature and save each part const message = commons.transaction.packMetaTransactionsData(signed.tx.nonce, signed.tx.transactions) - const digest = ethers.utils.keccak256(message) + const digest = ethers.keccak256(message) const payload = { chainId: signed.tx.chainId, message, address, digest } const subdigest = commons.signature.subdigestOf(payload) @@ -532,7 +532,7 @@ export class LocalConfigTracker implements ConfigTracker, migrator.PresignedMigr const { subdigest, toImageHash } = tx const payload = await this.payloadOfSubdigest({ subdigest }) if (!payload || !payload.message) return undefined - if (!ethers.BigNumber.from(chainId).eq(payload.chainId)) return undefined + if (BigInt(chainId) !== BigInt(payload.chainId)) return undefined const signers = coder.config.signersOf(currentConfig as any).map(s => s.address) @@ -546,7 +546,7 @@ export class LocalConfigTracker implements ConfigTracker, migrator.PresignedMigr return [signer, undefined] } - const replacedSignature = ethers.utils.hexlify( + const replacedSignature = ethers.hexlify( this.useEIP5719 ? await this.cachedEIP5719.runByEIP5719(signer, subdigest, signature) : signature ) @@ -560,7 +560,7 @@ export class LocalConfigTracker implements ConfigTracker, migrator.PresignedMigr // Encode signature parts into a single signature const encoded = coder.signature.encodeSigners(currentConfig as any, signatures, [], chainId) - if (!encoded || encoded.weight < currentConfig.threshold) return undefined + if (!encoded || encoded.weight < BigInt(currentConfig.threshold)) return undefined // Unpack payload (it should have transactions) const [nonce, transactions] = commons.transaction.unpackMetaTransactionsData(payload.message) @@ -588,7 +588,7 @@ export class LocalConfigTracker implements ConfigTracker, migrator.PresignedMigr return candidates[0] } - updateProvider(provider: ethers.providers.Provider) { + updateProvider(provider: ethers.Provider) { this.provider = provider } } diff --git a/packages/sessions/src/trackers/multiple.ts b/packages/sessions/src/trackers/multiple.ts index d800a257c..f6bdced6f 100644 --- a/packages/sessions/src/trackers/multiple.ts +++ b/packages/sessions/src/trackers/multiple.ts @@ -1,8 +1,9 @@ import { ConfigTracker, PresignedConfig, PresignedConfigLink } from '../tracker' import { migrator } from '@0xsequence/migration' -import { BigNumber, BigNumberish, ethers } from 'ethers' + import { commons, universal } from '@0xsequence/core' import { LocalConfigTracker } from './local' +import { ethers } from 'ethers' export function raceUntil(promises: Promise[], fallback: T, evalRes: (val: T) => boolean): Promise { return new Promise(resolve => { @@ -113,7 +114,7 @@ export class MultipleTracker implements migrator.PresignedMigrationTracker, Conf async walletsOfSigner(args: { signer: string - }): Promise<{ wallet: string; proof: { digest: string; chainId: BigNumber; signature: string } }[]> { + }): Promise<{ wallet: string; proof: { digest: string; chainId: bigint; signature: string } }[]> { // We can't race here, because there is no "correct" response // we just return the union of all results, skipping duplicates const results = await allSafe( @@ -121,7 +122,7 @@ export class MultipleTracker implements migrator.PresignedMigrationTracker, Conf [] ).then(r => r.flat()) - const wallets: { [wallet: string]: { digest: string; chainId: BigNumber; signature: string } } = {} + const wallets: { [wallet: string]: { digest: string; chainId: bigint; signature: string } } = {} for (const r of results) { wallets[r.wallet] = r.proof } @@ -131,7 +132,7 @@ export class MultipleTracker implements migrator.PresignedMigrationTracker, Conf const result = Object.keys(wallets).map(w => ({ wallet: w, proof: wallets[w] })) - const witnesses = new Map() + const witnesses = new Map() result.forEach(({ wallet, proof: { digest, chainId, signature } }) => { const key = `${wallet}-${digest}-${chainId}` let signatures = witnesses.get(key) @@ -146,7 +147,12 @@ export class MultipleTracker implements migrator.PresignedMigrationTracker, Conf return result } - async saveWitnesses(args: { wallet: string; digest: string; chainId: BigNumberish; signatures: string[] }): Promise { + async saveWitnesses(args: { + wallet: string + digest: string + chainId: ethers.BigNumberish + signatures: string[] + }): Promise { await Promise.all(this.trackers.map(t => t.saveWitnesses(args))) } @@ -178,7 +184,7 @@ export class MultipleTracker implements migrator.PresignedMigrationTracker, Conf const best = checkpoints.reduce((acc, val) => { if (!val) return acc if (!acc) return val - if (val.checkpoint.gt(acc.checkpoint)) return val + if (val.checkpoint > acc.checkpoint) return val return acc }) @@ -213,7 +219,7 @@ export class MultipleTracker implements migrator.PresignedMigrationTracker, Conf address: string, fromImageHash: string, fromVersion: number, - chainId: BigNumberish + chainId: ethers.BigNumberish ): Promise { // TODO: Backfeed migration results to other trackers const results = await Promise.all(this.trackers.map(t => t.getMigration(address, fromImageHash, fromVersion, chainId))) diff --git a/packages/sessions/src/trackers/promise-cache.ts b/packages/sessions/src/trackers/promise-cache.ts index 0504adda8..53c1f735d 100644 --- a/packages/sessions/src/trackers/promise-cache.ts +++ b/packages/sessions/src/trackers/promise-cache.ts @@ -13,7 +13,7 @@ export class PromiseCache { task: (...args: S) => Promise, ...args: S ): Promise { - key = `${key}:${ethers.utils.keccak256(ethers.utils.toUtf8Bytes(JSON.stringify(args, deterministically)))}` + key = `${key}:${ethers.id(JSON.stringify(args, deterministically))}` let entry = this.cache.get(key) @@ -52,6 +52,8 @@ type Entry = { function deterministically(_key: string, value: any): any { if (typeof value === 'object' && value !== null && !Array.isArray(value)) { return Object.fromEntries(Object.entries(value).sort()) + } else if (typeof value === 'bigint') { + return value.toString() } return value diff --git a/packages/sessions/src/trackers/remote/index.ts b/packages/sessions/src/trackers/remote/index.ts index 1daaf05c8..ba9c51b3d 100644 --- a/packages/sessions/src/trackers/remote/index.ts +++ b/packages/sessions/src/trackers/remote/index.ts @@ -40,14 +40,15 @@ export class RemoteConfigTracker implements ConfigTracker, migrator.PresignedMig const config = args.nextConfig const imageHash = universal.genericCoderFor(config.version).config.imageHashOf(config) const message = v2.signature.setImageHashStruct(imageHash) - const digest = ethers.utils.keccak256(message) + const digest = ethers.keccak256(message) await this.sessions.saveSignature({ wallet: args.wallet, digest, chainID: '0', signature: args.signature, - toConfig: encodeConfig(config) + toConfig: encodeConfig(config), + referenceChainID: args.referenceChainId !== undefined ? BigInt(args.referenceChainId).toString() : undefined }) } @@ -115,18 +116,18 @@ export class RemoteConfigTracker implements ConfigTracker, migrator.PresignedMig async walletsOfSigner(args: { signer: string - }): Promise<{ wallet: string; proof: { digest: string; chainId: ethers.BigNumber; signature: string } }[]> { + }): Promise<{ wallet: string; proof: { digest: string; chainId: bigint; signature: string } }[]> { const { wallets } = await this.sessions.wallets(args) return Object.entries(wallets).map(([wallet, { digest, chainID, type, signature }]) => { switch (type) { case SignatureType.EIP712: - signature += ethers.utils.hexlify(commons.signer.SigType.EIP712).slice(2) + signature += ethers.toBeHex(commons.signer.SigType.EIP712).slice(2) break case SignatureType.EthSign: - signature += ethers.utils.hexlify(commons.signer.SigType.ETH_SIGN).slice(2) + signature += ethers.toBeHex(commons.signer.SigType.ETH_SIGN).slice(2) break case SignatureType.EIP1271: - signature += ethers.utils.hexlify(commons.signer.SigType.WALLET_BYTES32).slice(2) + signature += ethers.toBeHex(commons.signer.SigType.WALLET_BYTES32).slice(2) break } @@ -135,7 +136,7 @@ export class RemoteConfigTracker implements ConfigTracker, migrator.PresignedMig proof: { digest, signature, - chainId: ethers.BigNumber.from(chainID) + chainId: BigInt(chainID) } } }) @@ -339,7 +340,7 @@ function encodeTransaction(transaction: commons.transaction.Transaction): Transa return { to: transaction.to, value: transaction.value !== undefined ? numberString(transaction.value) : undefined, - data: transaction.data !== undefined ? ethers.utils.hexlify(transaction.data) : undefined, + data: transaction.data !== undefined ? ethers.hexlify(transaction.data) : undefined, gasLimit: transaction.gasLimit !== undefined ? numberString(transaction.gasLimit) : undefined, delegateCall: transaction.delegateCall, revertOnError: transaction.revertOnError @@ -347,11 +348,11 @@ function encodeTransaction(transaction: commons.transaction.Transaction): Transa } function numberNumber(n: ethers.BigNumberish): number { - return ethers.BigNumber.from(n).toNumber() + return Number(n) } function numberString(n: ethers.BigNumberish): string { - return ethers.BigNumber.from(n).toString() + return BigInt(n).toString() } function is404NotFound(error: any): boolean { diff --git a/packages/sessions/src/trackers/remote/sessions.gen.ts b/packages/sessions/src/trackers/remote/sessions.gen.ts index 49eb8207d..3322c1e90 100644 --- a/packages/sessions/src/trackers/remote/sessions.gen.ts +++ b/packages/sessions/src/trackers/remote/sessions.gen.ts @@ -1,9 +1,13 @@ /* eslint-disable */ -// sessions v0.0.1 d81ea64cbe41c1ab8b0107bce2f118817b34ebc0 +// sessions v0.0.1 48681273e3b0249c5feb593b9af1b59dc6a14869 // -- -// Code generated by webrpc-gen@v0.18.6 with typescript generator. DO NOT EDIT. +// Code generated by webrpc-gen@v0.22.1 with typescript generator. DO NOT EDIT. // -// webrpc-gen -schema=sessions.ridl -target=typescript -client -out=./sessions.gen.ts +// webrpc-gen -schema=sessions.ridl -target=typescript -client -out=./clients/sessions.gen.ts + +export const WebrpcHeader = 'Webrpc' + +export const WebrpcHeaderValue = 'webrpc@v0.22.1;gen-typescript@v0.16.2;sessions@v0.0.1' // WebRPC description and code-gen version export const WebRPCVersion = 'v1' @@ -12,7 +16,55 @@ export const WebRPCVersion = 'v1' export const WebRPCSchemaVersion = 'v0.0.1' // Schema hash generated from your RIDL schema -export const WebRPCSchemaHash = 'd81ea64cbe41c1ab8b0107bce2f118817b34ebc0' +export const WebRPCSchemaHash = '48681273e3b0249c5feb593b9af1b59dc6a14869' + +type WebrpcGenVersions = { + webrpcGenVersion: string + codeGenName: string + codeGenVersion: string + schemaName: string + schemaVersion: string +} + +export function VersionFromHeader(headers: Headers): WebrpcGenVersions { + const headerValue = headers.get(WebrpcHeader) + if (!headerValue) { + return { + webrpcGenVersion: '', + codeGenName: '', + codeGenVersion: '', + schemaName: '', + schemaVersion: '' + } + } + + return parseWebrpcGenVersions(headerValue) +} + +function parseWebrpcGenVersions(header: string): WebrpcGenVersions { + const versions = header.split(';') + if (versions.length < 3) { + return { + webrpcGenVersion: '', + codeGenName: '', + codeGenVersion: '', + schemaName: '', + schemaVersion: '' + } + } + + const [_, webrpcGenVersion] = versions[0].split('@') + const [codeGenName, codeGenVersion] = versions[1].split('@') + const [schemaName, schemaVersion] = versions[2].split('@') + + return { + webrpcGenVersion, + codeGenName, + codeGenVersion, + schemaName, + schemaVersion + } +} // // Types @@ -31,23 +83,81 @@ export interface RuntimeStatus { version: string branch: string commit: string + arweave: ArweaveStatus +} + +export interface ArweaveStatus { + nodeURL: string + namespace: string + sender: string + signer: string + flushInterval: string + bundleDelay: string + bundleLimit: number + confirmations: number + lockTTL: string + healthy: boolean + lastFlush?: string + lastFlushSeconds?: number +} + +export interface Info { wallets: { [key: string]: number } configs: { [key: string]: number } configTrees: number migrations: { [key: string]: number } signatures: number digests: number - recorder: RecorderStatus + recorder: RecorderInfo + arweave: ArweaveInfo } -export interface RecorderStatus { +export interface RecorderInfo { requests: number buffer: number lastFlush?: string - secondsSinceLastFlush?: number + lastFlushSeconds?: number endpoints: { [key: string]: number } } +export interface ArweaveInfo { + nodeURL: string + namespace: string + sender: ArweaveSenderInfo + signer: string + flushInterval: string + bundleDelay: string + bundleLimit: number + confirmations: number + lockTTL: string + healthy: boolean + lastFlush?: string + lastFlushSeconds?: number + bundles: number + pending: ArweavePendingInfo +} + +export interface ArweaveSenderInfo { + address: string + balance: string +} + +export interface ArweavePendingInfo { + wallets: number + configs: number + migrations: number + signatures: number + bundles: Array +} + +export interface ArweaveBundleInfo { + transaction: string + block: number + items: number + sentAt: string + confirmations: number +} + export interface Context { version: number factory: string @@ -63,6 +173,15 @@ export interface Signature { chainID: string type: SignatureType signature: string + validOnChain?: string + validOnBlock?: string + validOnBlockHash?: string +} + +export interface SignerSignature { + signer?: string + signature: string + referenceChainID?: string } export interface ConfigUpdate { @@ -101,6 +220,11 @@ export interface Sessions { headers?: object, signal?: AbortSignal ): Promise + saveSignerSignatures2( + args: SaveSignerSignatures2Args, + headers?: object, + signal?: AbortSignal + ): Promise saveMigration(args: SaveMigrationArgs, headers?: object, signal?: AbortSignal): Promise } @@ -117,10 +241,13 @@ export interface ConfigReturn { } export interface WalletsArgs { signer: string + cursor?: number + limit?: number } export interface WalletsReturn { wallets: { [key: string]: Signature } + cursor: number } export interface DeployHashArgs { wallet: string @@ -167,6 +294,7 @@ export interface SaveSignatureArgs { chainID: string signature: string toConfig?: any + referenceChainID?: string } export interface SaveSignatureReturn {} @@ -179,6 +307,15 @@ export interface SaveSignerSignaturesArgs { } export interface SaveSignerSignaturesReturn {} +export interface SaveSignerSignatures2Args { + wallet: string + digest: string + chainID: string + signatures: Array + toConfig?: any +} + +export interface SaveSignerSignatures2Return {} export interface SaveMigrationArgs { wallet: string fromVersion: number @@ -202,7 +339,7 @@ export class Sessions implements Sessions { protected path = '/rpc/Sessions/' constructor(hostname: string, fetch: Fetch) { - this.hostname = hostname + this.hostname = hostname.replace(/\/*$/, '') this.fetch = (input: RequestInfo, init?: RequestInit) => fetch(input, init) } @@ -244,7 +381,8 @@ export class Sessions implements Sessions { res => { return buildResponse(res).then(_data => { return { - wallets: <{ [key: string]: Signature }>_data.wallets + wallets: <{ [key: string]: Signature }>_data.wallets, + cursor: _data.cursor } }) }, @@ -356,6 +494,23 @@ export class Sessions implements Sessions { ) } + saveSignerSignatures2 = ( + args: SaveSignerSignatures2Args, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('SaveSignerSignatures2'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return {} + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + saveMigration = (args: SaveMigrationArgs, headers?: object, signal?: AbortSignal): Promise => { return this.fetch(this.url('SaveMigration'), createHTTPRequest(args, headers, signal)).then( res => { @@ -371,9 +526,12 @@ export class Sessions implements Sessions { } const createHTTPRequest = (body: object = {}, headers: object = {}, signal: AbortSignal | null = null): object => { + const reqHeaders: { [key: string]: string } = { ...headers, 'Content-Type': 'application/json' } + reqHeaders[WebrpcHeader] = WebrpcHeaderValue + return { method: 'POST', - headers: { ...headers, 'Content-Type': 'application/json' }, + headers: reqHeaders, body: JSON.stringify(body || {}), signal } @@ -438,7 +596,7 @@ export class WebrpcEndpointError extends WebrpcError { constructor( name: string = 'WebrpcEndpoint', code: number = 0, - message: string = 'endpoint error', + message: string = `endpoint error`, status: number = 0, cause?: string ) { @@ -451,7 +609,7 @@ export class WebrpcRequestFailedError extends WebrpcError { constructor( name: string = 'WebrpcRequestFailed', code: number = -1, - message: string = 'request failed', + message: string = `request failed`, status: number = 0, cause?: string ) { @@ -464,7 +622,7 @@ export class WebrpcBadRouteError extends WebrpcError { constructor( name: string = 'WebrpcBadRoute', code: number = -2, - message: string = 'bad route', + message: string = `bad route`, status: number = 0, cause?: string ) { @@ -477,7 +635,7 @@ export class WebrpcBadMethodError extends WebrpcError { constructor( name: string = 'WebrpcBadMethod', code: number = -3, - message: string = 'bad method', + message: string = `bad method`, status: number = 0, cause?: string ) { @@ -490,7 +648,7 @@ export class WebrpcBadRequestError extends WebrpcError { constructor( name: string = 'WebrpcBadRequest', code: number = -4, - message: string = 'bad request', + message: string = `bad request`, status: number = 0, cause?: string ) { @@ -503,7 +661,7 @@ export class WebrpcBadResponseError extends WebrpcError { constructor( name: string = 'WebrpcBadResponse', code: number = -5, - message: string = 'bad response', + message: string = `bad response`, status: number = 0, cause?: string ) { @@ -516,7 +674,7 @@ export class WebrpcServerPanicError extends WebrpcError { constructor( name: string = 'WebrpcServerPanic', code: number = -6, - message: string = 'server panic', + message: string = `server panic`, status: number = 0, cause?: string ) { @@ -529,7 +687,7 @@ export class WebrpcInternalErrorError extends WebrpcError { constructor( name: string = 'WebrpcInternalError', code: number = -7, - message: string = 'internal error', + message: string = `internal error`, status: number = 0, cause?: string ) { @@ -542,7 +700,7 @@ export class WebrpcClientDisconnectedError extends WebrpcError { constructor( name: string = 'WebrpcClientDisconnected', code: number = -8, - message: string = 'client disconnected', + message: string = `client disconnected`, status: number = 0, cause?: string ) { @@ -555,7 +713,7 @@ export class WebrpcStreamLostError extends WebrpcError { constructor( name: string = 'WebrpcStreamLost', code: number = -9, - message: string = 'stream lost', + message: string = `stream lost`, status: number = 0, cause?: string ) { @@ -568,7 +726,7 @@ export class WebrpcStreamFinishedError extends WebrpcError { constructor( name: string = 'WebrpcStreamFinished', code: number = -10, - message: string = 'stream finished', + message: string = `stream finished`, status: number = 0, cause?: string ) { @@ -583,7 +741,7 @@ export class InvalidArgumentError extends WebrpcError { constructor( name: string = 'InvalidArgument', code: number = 1, - message: string = 'invalid argument', + message: string = `invalid argument`, status: number = 0, cause?: string ) { @@ -593,7 +751,7 @@ export class InvalidArgumentError extends WebrpcError { } export class NotFoundError extends WebrpcError { - constructor(name: string = 'NotFound', code: number = 2, message: string = 'not found', status: number = 0, cause?: string) { + constructor(name: string = 'NotFound', code: number = 2, message: string = `not found`, status: number = 0, cause?: string) { super(name, code, message, status, cause) Object.setPrototypeOf(this, NotFoundError.prototype) } @@ -615,7 +773,23 @@ export enum errors { NotFound = 'NotFound' } -const webrpcErrorByCode: { [code: number]: any } = { +export enum WebrpcErrorCodes { + WebrpcEndpoint = 0, + WebrpcRequestFailed = -1, + WebrpcBadRoute = -2, + WebrpcBadMethod = -3, + WebrpcBadRequest = -4, + WebrpcBadResponse = -5, + WebrpcServerPanic = -6, + WebrpcInternalError = -7, + WebrpcClientDisconnected = -8, + WebrpcStreamLost = -9, + WebrpcStreamFinished = -10, + InvalidArgument = 1, + NotFound = 2 +} + +export const webrpcErrorByCode: { [code: number]: any } = { [0]: WebrpcEndpointError, [-1]: WebrpcRequestFailedError, [-2]: WebrpcBadRouteError, diff --git a/packages/sessions/src/trackers/stores/indexedDBStore.ts b/packages/sessions/src/trackers/stores/indexedDBStore.ts index 6f0f1e275..12c834e40 100644 --- a/packages/sessions/src/trackers/stores/indexedDBStore.ts +++ b/packages/sessions/src/trackers/stores/indexedDBStore.ts @@ -59,7 +59,7 @@ export function recreateBigNumbers(object: T): T | if (val._isBigNumber === true && val._hex !== undefined && typeof val._hex === 'string' && val._hex.length !== '') { // Entry is a big number - result[key] = ethers.BigNumber.from(val) + result[key] = BigInt(val._hex) } else if (Array.isArray(val)) { // Entry is an array, recurse result[key] = val.map(v => recreateBigNumbers(v)) diff --git a/packages/sessions/tests/arweave.spec.ts b/packages/sessions/tests/arweave.spec.ts new file mode 100644 index 000000000..44bc4692b --- /dev/null +++ b/packages/sessions/tests/arweave.spec.ts @@ -0,0 +1,433 @@ +import { commons, universal, v2 } from '@0xsequence/core' +import { expect } from 'chai' +import { ethers } from 'ethers' + +import { trackers } from '../src' + +class MockProvider extends ethers.AbstractProvider { + _detectNetwork(): Promise { + return Promise.resolve(new ethers.Network('', 0)) + } + + _perform(_req: ethers.PerformActionRequest): Promise { + return Promise.resolve('0x1626ba7e00000000000000000000000000000000000000000000000000000000' as any) + } +} + +describe('Arweave config reader', () => { + const options = { namespace: 'xOovxYFkIwBpEwSi', owners: ['lJYCA4xBPJeZSgr9AF_4pHp4HVGvTOa4NYKJRoMBP5c'] } + const arweave = new trackers.arweave.ArweaveReader(options) + const sessions = new trackers.remote.RemoteConfigTracker('http://localhost:5555') + const provider = new MockProvider() + + it('Should find the config for an image hash', async () => { + const imageHash = '0x8073858470016c4fdee9d3ad7c929e81cb19668a73fde061f00645228676e8dd' + + const config = await arweave.configOfImageHash({ imageHash }) + if (!config) { + throw new Error('config not found') + } + + const coder = universal.genericCoderFor(config.version) + expect(coder.config.imageHashOf(config)).to.equal(imageHash) + }) + + it('Should find the deploy hash for a wallet', async () => { + const address = '0x801DC9A5F00f781cA0f1ca56dbA68DA69fB07cdC' + + const wallet = await arweave.imageHashOfCounterfactualWallet({ wallet: address }) + if (!wallet) { + throw new Error('wallet not found') + } + + expect(commons.context.addressOf(wallet.context, wallet.imageHash)).to.equal(address) + }) + + it('Should find the wallets for a signer', async () => { + const signer = '0x8151D1B52dEb93eF2300884fC4CcddDDFf8C6BdA' + + const wallets = await arweave.walletsOfSigner({ signer }) + + expect(wallets.some(({ wallet }) => wallet === '0x213400e26b4aA36885Bcb29A8B7D67caeB0348EC')).to.be.true + + expect( + wallets.every( + ({ wallet, proof: { digest, chainId, signature } }) => + commons.signer.recoverSigner(commons.signature.subdigestOf({ digest, chainId, address: wallet }), signature) === signer + ) + ).to.be.true + }) + + it('Should find the shortest sequence of config updates from a config', async () => { + const wallet = '0x36f8D1327F738608e275226A6De2D1720AF5C896' + const fromImageHash = '0xacbf7d62011d908d4cdfc96651be39b77d56f8e8048e993a57470724eb6049be' + + const updates = await arweave.loadPresignedConfiguration({ wallet, fromImageHash }) + + expect(updates.every(update => update.wallet === wallet)).to.be.true + + expect(updates.map(({ nextImageHash }) => nextImageHash)).to.deep.equal([ + '0x08b597e0fc694da132d38db2b9e6c598ea85d786aba1c9830def5df0fec6da67', + '0xea570311d302ef75c4efe9da8041011a43b398682b5461bc3edfd5632fe36199' + ]) + + let imageHash = fromImageHash + + for (const { nextImageHash, signature } of updates) { + const digest = v2.chained.hashSetImageHash(nextImageHash) + const decoded = v2.signature.decodeSignature(signature) + const recovered = await v2.signature.recoverSignature(decoded, { digest, chainId: 0, address: wallet }, provider) + expect(v2.config.imageHash(recovered.config)).to.equal(imageHash) + imageHash = nextImageHash + } + }) + + it('Should find the longest sequence of config updates from a config', async () => { + const wallet = '0x36f8D1327F738608e275226A6De2D1720AF5C896' + const fromImageHash = '0xacbf7d62011d908d4cdfc96651be39b77d56f8e8048e993a57470724eb6049be' + + const updates = await arweave.loadPresignedConfiguration({ wallet, fromImageHash, longestPath: true }) + + expect(updates.every(update => update.wallet === wallet)).to.be.true + + expect(updates.map(({ nextImageHash }) => nextImageHash)).to.deep.equal([ + '0x8230d5841133b06eeeba92494fcf28d4c7ca50ae59f092d630dbee0d07c5e4f5', + '0x08b597e0fc694da132d38db2b9e6c598ea85d786aba1c9830def5df0fec6da67', + '0xea570311d302ef75c4efe9da8041011a43b398682b5461bc3edfd5632fe36199' + ]) + + let imageHash = fromImageHash + + for (const { nextImageHash, signature } of updates) { + const digest = v2.chained.hashSetImageHash(nextImageHash) + const decoded = v2.signature.decodeSignature(signature) + const recovered = await v2.signature.recoverSignature(decoded, { digest, chainId: 0, address: wallet }, provider) + expect(v2.config.imageHash(recovered.config)).to.equal(imageHash) + imageHash = nextImageHash + } + }) + + it('Should find a migration', async () => { + const address = '0x9efB45F2e6Bd007Bb47D94CcB461d0b88a1fc6d6' + const fromVersion = 1 + const fromImageHash = '0xb0c9bf9b74e670cd5245ac196261e16c092b701ea769269aeb0b1507bb96f961' + const toVersion = 2 + const toImageHash = '0xc289ea81fb71c62b4eb247c2e83b6897e1274e2ecd09d0cb780619cf4a4f204a' + const chainId = 1 + + const migration = await arweave.getMigration(address, fromImageHash, fromVersion, chainId) + if (!migration) { + throw new Error('migration not found') + } + + expect(migration.tx.intent.wallet).to.equal(address) + expect(BigInt(migration.tx.chainId)).to.equal(BigInt(chainId)) + expect(migration.fromVersion).to.equal(fromVersion) + expect(migration.toVersion).to.equal(toVersion) + expect(migration.toConfig.version).to.equal(toVersion) + + const toCoder = universal.genericCoderFor(migration.toVersion) + expect(toCoder.config.imageHashOf(migration.toConfig)).to.equal(toImageHash) + + const fromCoder = universal.genericCoderFor(migration.fromVersion) + const decoded = fromCoder.signature.decode(migration.tx.signature) + const digest = commons.transaction.digestOfTransactions(migration.tx.nonce, migration.tx.transactions) + const recovered = await fromCoder.signature.recover(decoded, { digest, chainId, address }, provider) + expect(fromCoder.config.imageHashOf(recovered.config)).to.equal(fromImageHash) + }) + + it.skip('Should find the same configs as Sequence Sessions', async () => { + const imageHashes = [ + '0x002f295ccfaf604ff09f200ad3282710f8b156811a03065dba66cf0902fff629', + '0x015cadeea08b6f9ed3181b1560a1f801e58c02f4bb0d33d01b0c1ab7b07b7bb1', + '0x042e86a1fe7f541e287b9053c483e21d059380b56d4baaa4161b0302cc55f22e', + '0x08b597e0fc694da132d38db2b9e6c598ea85d786aba1c9830def5df0fec6da67', + '0x08f915b8325e25003cc47e16fe144103655cda5e1cf43030345640c293feca98', + '0x105823726957bbef0932076d4209de8e0198fd5da59042221583c6ba26ef2637', + '0x1a13a8a34d18946b00b9368cf02f1cba3219eff2a18e76e4951d678824b34bdb', + '0x1d018d98154312f501d1794ed77abd2e544a0a7c035638e965be846c0c347f37', + '0x24f30c67a1f6228c2aa380e77999269a6203eab9ef60f3785ccd7a15ce199827', + '0x2513cf57aca274bc40c2bd6492a1499e8b781d128e39b8dd85659b75687beb47', + '0xeb718fb634b9f5e3a722825a25d4b48d3bbfe106d04efcbba6504fbf4539beed', + '0xecc51be6a1c52bb41183df18c5df0185e20014ffafa04096d9da1148525e476e', + '0xedfd70427e797f3865228c24d53903b0b529c544bf788000653070205e9548f2', + '0xef028a928c04ec9759be984c2f0f72e0aa578efc2f402dbb6ca4893e981bbf41', + '0xf148aa32b0cbd54c95610c8fb423b0506dd642ff659418a9ef64cfa50ef97489', + '0xf2e32da98766f93d86284e029565d814954163c15d681013e53b11b66e13bb0f', + '0xf4e8f9efa633938f6fbc02088074a9ee466178d59ff7ed8eb579ed7f14583dc5', + '0xf54e5829545147e687b7fe39e078de34dbd60dd24096a2deea1bb8dd86d93936', + '0xf5c2d2e6666cd2f04962df167eeeee5d217f731787a7d698b57142bb0da131d3', + '0xff9a2779f55740f1f4011a6a00fee48e717cd51b75e32dd6a7db97e33a7b3d07' + ] + + for (const imageHash of imageHashes) { + const [arweaveConfig, sessionsConfig] = await Promise.all([ + arweave.configOfImageHash({ imageHash }), + sessions.configOfImageHash({ imageHash }) + ]) + + expect(arweaveConfig).to.deep.equal(sessionsConfig) + } + }) + + it.skip('Should find the same deploy hashes as Sequence Sessions', async () => { + const wallets = [ + '0x1982D04a8473d391d4D4cA0312420F13Bb8dE26e', + '0x1dc2DA033d412d5E0D92f97a3157177dF41381D6', + '0x213400e26b4aA36885Bcb29A8B7D67caeB0348EC', + '0x329bD174c721bFa3A664Bde815dB33A7AA8b14a8', + '0x36f8D1327F738608e275226A6De2D1720AF5C896', + '0x41a0D39EFbB9a642c589abf2D501757D2f403470', + '0x55Cfd699C5E105180473c5A0403a3b491c82fb22', + '0x59756e67CFab5e1dFa1c7bCf7f5B04AbCAeb0B0F', + '0x6B7CE863DfcCeAbc6bDbC3f73f6def0de81dfe27', + '0x6Ce4229189988358073de1cd8AE7edFDf979635a', + '0xCa9A0F02c0589D550f06F78AfF604A5405b90448', + '0xD38A7FB85e76681cB409705622e877D11C7Cfe54', + '0xd5b1C31f7626A8Bd206D744128dFE6401dd7D7F6', + '0xDf29fF6EE710c4042dfE71bEeC1971Fca1F6A6F5', + '0xEf87203423cA064A44CE2661Daf93051e2F423a2', + '0xf3Da03EbBda88D28981c63Bd5ddA38d3eCff400a', + '0xf563fbB21208C7c915ea7d28014D36B1F9acACa9', + '0xFAE677fc10bDb6bF3C69Bb9DEEc6752cC7e06224', + '0xfBF80a987857e6dcAF790B297fC9a4f97DbbfBB0', + '0xfc9Adc5cd71F77e46a956F94df0fd5b0dF6Eef12' + ] + + for (const wallet of wallets) { + const [arweaveWallet, sessionsWallet] = await Promise.all([ + arweave.imageHashOfCounterfactualWallet({ wallet }), + sessions.imageHashOfCounterfactualWallet({ wallet }) + ]) + + expect(arweaveWallet?.imageHash).to.equal(sessionsWallet?.imageHash) + expect(arweaveWallet?.context).to.deep.equal(sessionsWallet?.context) + } + }) + + it.skip('Should find the same wallets as Sequence Sessions', async () => { + const signers = [ + '0x079cc5A64Fa4Bdd928bbF0EaBaf7BE91D633abf5', + '0x18510092ee248b1A2BBaB66C5d223EBa784693BA', + '0x1BA6a414d3C45a8E21FBEf451882170d0f6807F7', + '0x1Cd69D558cbD121F6C4DdF11db2CaCC142705a20', + '0x24270586957918c5C075E970A208387C888C4dD8', + '0x289cF67aeF2000DEcafb525103d8aDE044996D45', + '0x37Fd684c78b74b633CA43Ca5418f6f80827fB0fD', + '0x5373B3264EbbF0471FE4CC8B63f30446Cc03F6ad', + '0x553390e8B3dd2694Ea50bE9972C0D66b320bBa27', + '0x58AF1d8567BE0629A9961d8B3e06234B0f731187', + '0xb478671F3705cC2a3A1F47326F2Ef93853b79cf2', + '0xbb8FAEc13852b263644e75fd568B422055A8e8DC', + '0xbcB1EFB67f277cBbBeB886D6248ab222f3ef2195', + '0xc37c114B99242D1F83fFD964236f45042eD8c162', + '0xCa968ebc798feaeE466e73C872f085C3A2c9b7D9', + '0xcD2C0E8b8372FfF16caa0a29F9336F4dFB4D2EA1', + '0xd4c04c7392617D85b6FF33E203714C6Fd46336b4', + '0xe7D97e2d43900297a7537B0eD3B6C27306f6aDC0', + '0xea5dE55520f4cca364AB9Ed5613a11aa1e5C977E', + '0xFf6bEB351a06f35BFD6074d6Cfe34fcb8734F675' + ] + + for (const signer of signers) { + const [arweaveWallets, sessionsWallets] = await Promise.all([ + arweave.walletsOfSigner({ signer }), + sessions.walletsOfSigner({ signer }) + ]) + + expect(Object.fromEntries(arweaveWallets.map(({ wallet, proof }) => [wallet, proof]))).to.deep.equal( + Object.fromEntries(sessionsWallets.map(({ wallet, proof }) => [wallet, proof])) + ) + } + }) + + it.skip('Should find the same config updates as Sequence Sessions', async () => { + const updates = [ + { + wallet: '0x1982D04a8473d391d4D4cA0312420F13Bb8dE26e', + fromImageHash: '0x8073858470016c4fdee9d3ad7c929e81cb19668a73fde061f00645228676e8dd' + }, + { + wallet: '0x213400e26b4aA36885Bcb29A8B7D67caeB0348EC', + fromImageHash: '0x653ad79e81e77bbf9aeca4740a12dbe260e17abde4114c4a4056d7c8ab605270' + }, + { + wallet: '0x329bD174c721bFa3A664Bde815dB33A7AA8b14a8', + fromImageHash: '0x47eb2d6796c08e627d886ce5dd88f4aefbda5ab6209a5e35ded2f5ea95a5f05a' + }, + { + wallet: '0x36f8D1327F738608e275226A6De2D1720AF5C896', + fromImageHash: '0xacbf7d62011d908d4cdfc96651be39b77d56f8e8048e993a57470724eb6049be' + }, + { + wallet: '0x41a0D39EFbB9a642c589abf2D501757D2f403470', + fromImageHash: '0x9cd23aa8bf0945ec412aa2c815ffbb77341a869a0c3d031af0bb0b82faa1fc75' + }, + { + wallet: '0x55Cfd699C5E105180473c5A0403a3b491c82fb22', + fromImageHash: '0xf54e5829545147e687b7fe39e078de34dbd60dd24096a2deea1bb8dd86d93936' + }, + { + wallet: '0x59756e67CFab5e1dFa1c7bCf7f5B04AbCAeb0B0F', + fromImageHash: '0x2a0b27a28d39ec7b4ad61edc83b55d9b8375252ad48c838252d937a7f4afcf89' + }, + { + wallet: '0x6B7CE863DfcCeAbc6bDbC3f73f6def0de81dfe27', + fromImageHash: '0x08f915b8325e25003cc47e16fe144103655cda5e1cf43030345640c293feca98' + }, + { + wallet: '0x6Ce4229189988358073de1cd8AE7edFDf979635a', + fromImageHash: '0xf4e8f9efa633938f6fbc02088074a9ee466178d59ff7ed8eb579ed7f14583dc5' + }, + { + wallet: '0x801DC9A5F00f781cA0f1ca56dbA68DA69fB07cdC', + fromImageHash: '0xab5e99dc4fc094955f547bce2b8e0991845aa17f4fab47e3d212131474982fd6' + }, + { + wallet: '0x82B772b0fDb7Efb31B7DDD8d06C7C10fa1Dca383', + fromImageHash: '0x99da13df61af5b72011ab2e81aea9c4960c58344f7e536a5db27ce887acf0799' + }, + { + wallet: '0x84ac87bc06De4e1456B9df2C2496bF9a12b86C10', + fromImageHash: '0xc36416d54ec63920066c441686788888ee5505cd9137a006e14419940d53222d' + }, + { + wallet: '0x8af66F10b45AE8eba55C819a702344c407fD97fE', + fromImageHash: '0x890364a08ba76febfc67d63507a362c00c71cf4cf67b88e68f6952a9b8b95c66' + }, + { + wallet: '0x8e17D9C9dF4271C9a3cb0D7635004257f9805A6F', + fromImageHash: '0x4aade79c43aa094d77d98f5e2f70efb28cc4670614ff5894713c3bb11d32d9cf' + }, + { + wallet: '0x93fe4617B114F4018eaCfBB7eAb00A06f8C54E2D', + fromImageHash: '0xe9ab45294e8e22a456ff493201bd6f3329a6875193a2b1afc2e357c813ce0842' + }, + { + wallet: '0x9876DD582d28a527586fee03311B4a57461fE4c7', + fromImageHash: '0x7bf4d1c4443f505e86495c4b1666e9484b9636ec53ef166695a6caf3ed03b3d6' + }, + { + wallet: '0x9A203aBD53719C04ad7E1A5e587ea636368A6ed1', + fromImageHash: '0xef028a928c04ec9759be984c2f0f72e0aa578efc2f402dbb6ca4893e981bbf41' + }, + { + wallet: '0x9BdD9F17370d5690230Ba6CdfCE6D40c0dE7Fb49', + fromImageHash: '0xd0fdc647d1fc584cb53bb2798abfd887e61aab0b038caa201b96bebd39e7565f' + }, + { + wallet: '0x9efB45F2e6Bd007Bb47D94CcB461d0b88a1fc6d6', + fromImageHash: '0x2693f1f40c73d0c1f361f472cd1ec4fac9daa2d5232ff5f5b87ec56c1d3e7e20' + }, + { + wallet: '0xa53f6C371539F53Bb4DbcA0f1351eA7AA7F488c5', + fromImageHash: '0x1d018d98154312f501d1794ed77abd2e544a0a7c035638e965be846c0c347f37' + } + ] + + for (const longestPath of [false, true]) { + for (const update of updates) { + const [arweaveUpdates, sessionsUpdates] = await Promise.all([ + arweave.loadPresignedConfiguration({ ...update, longestPath }), + sessions.loadPresignedConfiguration({ ...update, longestPath }) + ]) + + let imageHash = update.fromImageHash + + for (const i in arweaveUpdates) { + const arweaveUpdate = arweaveUpdates[i] + const sessionsUpdate = sessionsUpdates[i] + + expect(arweaveUpdate.wallet).to.equal(update.wallet) + expect(sessionsUpdate.wallet).to.equal(update.wallet) + expect(arweaveUpdate.nextImageHash).to.equal(sessionsUpdate.nextImageHash) + + const nextImageHash = arweaveUpdate.nextImageHash + + const arweaveSignature = v2.signature.decodeSignature(arweaveUpdate.signature) + const sessionsSignature = v2.signature.decodeSignature(sessionsUpdate.signature) + + const digest = v2.chained.hashSetImageHash(nextImageHash) + + const { config: arweaveConfig } = await v2.signature.recoverSignature( + arweaveSignature, + { digest, chainId: 0, address: update.wallet }, + provider + ) + + const { config: sessionsConfig } = await v2.signature.recoverSignature( + sessionsSignature, + { digest, chainId: 0, address: update.wallet }, + provider + ) + + expect(v2.config.imageHash(arweaveConfig)).to.equal(v2.config.imageHash(sessionsConfig)) + + imageHash = nextImageHash + } + } + } + }) + + it.skip('Should find the same migrations as Sequence Sessions', async () => { + const migrations = [ + { + address: '0x1dc2DA033d412d5E0D92f97a3157177dF41381D6', + fromVersion: 1, + fromImageHash: '0xd0cca2788f80d85e93a0b3dd2af2e5962979d162931ec9c4537318be0c8ca312', + chainId: 1 + }, + { + address: '0x213400e26b4aA36885Bcb29A8B7D67caeB0348EC', + fromVersion: 1, + fromImageHash: '0xd94d8b1eaeaa3e2053b3421898e7925ebeef760881d9866c0096a3f97ed78f59', + chainId: 1 + }, + { + address: '0x9efB45F2e6Bd007Bb47D94CcB461d0b88a1fc6d6', + fromVersion: 1, + fromImageHash: '0xb0c9bf9b74e670cd5245ac196261e16c092b701ea769269aeb0b1507bb96f961', + chainId: 1 + }, + { + address: '0xb0E931FB27cc7149Ce0B8585739414Bf0866E0d2', + fromVersion: 1, + fromImageHash: '0x784e8115d0da9724aabe8ce4b6c27a2750ca3bc0ce51f4404c0aee8a2856859d', + chainId: 1 + }, + { + address: '0xc3527Da8b07E49CA6cCCC773C8D032bd4a77D464', + fromVersion: 1, + fromImageHash: '0xa88c665c0507894572288103cb88eea73e791f686b9eb2a4c80b1ca552cd1650', + chainId: 1 + }, + { + address: '0xCa9A0F02c0589D550f06F78AfF604A5405b90448', + fromVersion: 1, + fromImageHash: '0xbaf93699b3cb6214742cd6cccae0a6d1a0240ca4e03bf491b15707cdf46eca24', + chainId: 1 + }, + { + address: '0xd5b1C31f7626A8Bd206D744128dFE6401dd7D7F6', + fromVersion: 1, + fromImageHash: '0xcf813d102720b67781e784e852e624f86a5bb92a9a37234e2a89390b0b814480', + chainId: 1 + }, + { + address: '0xEf87203423cA064A44CE2661Daf93051e2F423a2', + fromVersion: 1, + fromImageHash: '0x338a2e6e1533e902f698e4623afc9b78f7c1b955f1e9c99ff4a4ee914dbbb401', + chainId: 1 + } + ] + + for (const { address, fromVersion, fromImageHash, chainId } of migrations) { + const [arweaveMigration, sessionsMigration] = await Promise.all([ + arweave.getMigration(address, fromImageHash, fromVersion, chainId), + sessions.getMigration(address, fromImageHash, fromVersion, chainId) + ]) + + expect(arweaveMigration).to.deep.equal(sessionsMigration) + } + }) +}) diff --git a/packages/sessions/tests/local.spec.ts b/packages/sessions/tests/local.spec.ts index 7dc9a349b..b8fce5b12 100644 --- a/packages/sessions/tests/local.spec.ts +++ b/packages/sessions/tests/local.spec.ts @@ -106,21 +106,21 @@ const ConfigCases = [ return { version: 2, - threshold: ethers.BigNumber.from(2), - checkpoint: ethers.BigNumber.from(392919), + threshold: 2n, + checkpoint: 392919n, tree: { left: { - subdigest: ethers.utils.hexlify(ethers.utils.randomBytes(32)) + subdigest: ethers.hexlify(ethers.randomBytes(32)) }, right: { left: { - weight: ethers.BigNumber.from(1), - threshold: ethers.BigNumber.from(99), + weight: 1n, + threshold: 99n, tree: nested1.tree }, right: { - weight: ethers.BigNumber.from(99), - threshold: ethers.BigNumber.from(1), + weight: 99n, + threshold: 1n, tree: nested2.tree } } @@ -138,17 +138,17 @@ const randomContext = () => { mainModuleUpgradable: ethers.Wallet.createRandom().address, guestModule: ethers.Wallet.createRandom().address, - walletCreationCode: ethers.utils.hexlify(ethers.utils.randomBytes(32)) + walletCreationCode: ethers.hexlify(ethers.randomBytes(32)) } } const wait = (ms: number) => new Promise(resolve => setTimeout(resolve, ms)) describe('Local config tracker', () => { - let provider: ethers.providers.Web3Provider + let provider: ethers.BrowserProvider before(async () => { - provider = new ethers.providers.Web3Provider(hardhat.network.provider as any) + provider = new ethers.BrowserProvider(hardhat.network.provider, undefined, { cacheTimeout: -1 }) }) ;[ { @@ -255,8 +255,8 @@ describe('Local config tracker', () => { const emptyConfig = { version: 2, - threshold: ethers.BigNumber.from(2), - checkpoint: ethers.BigNumber.from(0), + threshold: 2n, + checkpoint: 0n, tree: { left: { nodeHash: v2.config.hashNode(config1.tree) }, right: { nodeHash: v2.config.hashNode(config2.tree) } @@ -282,8 +282,8 @@ describe('Local config tracker', () => { expect(normalize(await tracker.configOfImageHash({ imageHash }))).to.deep.equal( normalize({ version: 2, - threshold: ethers.BigNumber.from(2), - checkpoint: ethers.BigNumber.from(0), + threshold: 2n, + checkpoint: 0n, tree: { left: config1.tree, right: { nodeHash: v2.config.hashNode(config2.tree) } @@ -303,8 +303,8 @@ describe('Local config tracker', () => { expect(normalize(await tracker.configOfImageHash({ imageHash }))).to.deep.equal( normalize({ version: 2, - threshold: ethers.BigNumber.from(2), - checkpoint: ethers.BigNumber.from(0), + threshold: 2n, + checkpoint: 0n, tree: { left: config1.tree, right: config2.tree @@ -314,7 +314,7 @@ describe('Local config tracker', () => { }) it('Should return undefined for unknown imageHash', async () => { - const imageHash = ethers.utils.hexlify(ethers.utils.randomBytes(32)) + const imageHash = ethers.hexlify(ethers.randomBytes(32)) expect(await tracker.configOfImageHash({ imageHash })).to.be.undefined }) @@ -382,11 +382,11 @@ describe('Local config tracker', () => { let context: commons.context.WalletContext before(async () => { - context = await utils.context.deploySequenceContexts(provider.getSigner(0)).then(c => c[2]) + context = await utils.context.deploySequenceContexts(await provider.getSigner(0)).then(c => c[2]) }) it('Should return return empty chained configuration if config is not known', async () => { - const imageHash = ethers.utils.hexlify(ethers.utils.randomBytes(32)) + const imageHash = ethers.hexlify(ethers.randomBytes(32)) const res = await tracker.loadPresignedConfiguration({ wallet: ethers.Wallet.createRandom().address, fromImageHash: imageHash @@ -675,7 +675,7 @@ describe('Local config tracker', () => { let context: commons.context.WalletContext before(async () => { - context = await utils.context.deploySequenceContexts(provider.getSigner(0)).then(c => c[2]) + context = await utils.context.deploySequenceContexts(await provider.getSigner(0)).then(c => c[2]) }) it('Should retrieve no witness for never used signer', async () => { @@ -698,7 +698,7 @@ describe('Local config tracker', () => { orchestrator: new Orchestrator([signer]) }) - const digest = ethers.utils.hexlify(ethers.utils.randomBytes(32)) + const digest = ethers.hexlify(ethers.randomBytes(32)) const signature = await wallet.signDigest(digest) const decoded = v2.signature.SignatureCoder.decode(signature) @@ -712,12 +712,12 @@ describe('Local config tracker', () => { const witness = await tracker.walletsOfSigner({ signer: signer.address }) expect(witness.length).to.equal(1) expect(witness[0].wallet).to.equal(address) - expect(witness[0].proof.chainId.toNumber()).to.equal(1) + expect(witness[0].proof.chainId).to.equal(1n) expect(witness[0].proof.digest).to.equal(digest) expect(witness[0].proof.signature).to.equal((decoded.decoded.tree as v2.signature.SignatureLeaf).signature) // Adding a second witness should not change anything - const digest2 = ethers.utils.hexlify(ethers.utils.randomBytes(32)) + const digest2 = ethers.hexlify(ethers.randomBytes(32)) const signature2 = await wallet.signDigest(digest2) const decoded2 = v2.signature.SignatureCoder.decode(signature2) await tracker.saveWitnesses({ @@ -731,7 +731,7 @@ describe('Local config tracker', () => { expect(witness2.length).to.equal(1) // Adding a witness for a different chain should not change anything - const digest3 = ethers.utils.hexlify(ethers.utils.randomBytes(32)) + const digest3 = ethers.hexlify(ethers.randomBytes(32)) const wallet2 = new Wallet({ config, chainId: 2, @@ -767,7 +767,7 @@ describe('Local config tracker', () => { orchestrator: new Orchestrator([signer]) }) - const digest = ethers.utils.hexlify(ethers.utils.randomBytes(32)) + const digest = ethers.hexlify(ethers.randomBytes(32)) const signature = await wallet.signDigest(digest) const decoded = v2.signature.SignatureCoder.decode(signature) @@ -790,7 +790,7 @@ describe('Local config tracker', () => { orchestrator: new Orchestrator([signer]) }) - const digest2 = ethers.utils.hexlify(ethers.utils.randomBytes(32)) + const digest2 = ethers.hexlify(ethers.randomBytes(32)) const signature2 = await wallet2.signDigest(digest2) const decoded2 = v2.signature.SignatureCoder.decode(signature2) @@ -809,11 +809,11 @@ describe('Local config tracker', () => { expect(wallet1Result).to.not.be.undefined expect(wallet2Result).to.not.be.undefined - expect(wallet1Result?.proof.chainId.toNumber()).to.equal(1) + expect(wallet1Result?.proof.chainId).to.equal(1n) expect(wallet1Result?.proof.digest).to.equal(digest) expect(wallet1Result?.proof.signature).to.equal((decoded.decoded.tree as v2.signature.SignatureLeaf).signature) - expect(wallet2Result?.proof.chainId.toNumber()).to.equal(1) + expect(wallet2Result?.proof.chainId).to.equal(1n) expect(wallet2Result?.proof.digest).to.equal(digest2) expect(wallet2Result?.proof.signature).to.equal((decoded2.decoded.tree as v2.signature.SignatureLeaf).signature) }) @@ -838,11 +838,11 @@ describe('Local config tracker', () => { it('Storing a config should store it in both', async () => { const config = { version: 2, - threshold: ethers.BigNumber.from(1), - checkpoint: ethers.BigNumber.from(0), + threshold: 1n, + checkpoint: 0n, tree: { address: ethers.Wallet.createRandom().address, - weight: ethers.BigNumber.from(1) + weight: 1n } } @@ -860,11 +860,11 @@ describe('Local config tracker', () => { it('Retrieving a config from tracker1, should mirror to tracker2', async () => { const config = { version: 2, - threshold: ethers.BigNumber.from(1), - checkpoint: ethers.BigNumber.from(0), + threshold: 1n, + checkpoint: 0n, tree: { address: ethers.Wallet.createRandom().address, - weight: ethers.BigNumber.from(1) + weight: 1n } } @@ -885,18 +885,18 @@ describe('Local config tracker', () => { it.skip('Should combine 2 different sources', async () => { const node1 = { address: ethers.Wallet.createRandom().address, - weight: ethers.BigNumber.from(1) + weight: 1n } const node2 = { address: ethers.Wallet.createRandom().address, - weight: ethers.BigNumber.from(1) + weight: 1n } const config1 = { version: 2, - threshold: ethers.BigNumber.from(1), - checkpoint: ethers.BigNumber.from(1234), + threshold: 1n, + checkpoint: 1234n, tree: { left: { nodeHash: v2.config.hashNode(node1) @@ -907,8 +907,8 @@ describe('Local config tracker', () => { const config2 = { version: 2, - threshold: ethers.BigNumber.from(1), - checkpoint: ethers.BigNumber.from(1234), + threshold: 1n, + checkpoint: 1234n, tree: { left: node1, right: { @@ -919,8 +919,8 @@ describe('Local config tracker', () => { const configAll = { version: 2, - threshold: ethers.BigNumber.from(1), - checkpoint: ethers.BigNumber.from(1234), + threshold: 1n, + checkpoint: 1234n, tree: { left: node1, right: node2 @@ -984,7 +984,7 @@ describe('Local config tracker', () => { let context: commons.context.WalletContext before(async () => { - context = await utils.context.deploySequenceContexts(provider.getSigner(0)).then(c => c[2]) + context = await utils.context.deploySequenceContexts(await provider.getSigner(0)).then(c => c[2]) }) it('Should store chained config in both', async () => { @@ -1183,12 +1183,9 @@ describe('Local config tracker', () => { function normalize(value: any): any { switch (typeof value) { case 'object': - if (ethers.BigNumber.isBigNumber(value)) { - return value.toString() - } return Object.fromEntries(Object.entries(value).map(([key, value]) => [key, normalize(value)])) case 'number': - return `${value}` + return BigInt(value) default: return value } diff --git a/packages/signhub/CHANGELOG.md b/packages/signhub/CHANGELOG.md index f569b5d85..d7625f4bd 100644 --- a/packages/signhub/CHANGELOG.md +++ b/packages/signhub/CHANGELOG.md @@ -1,5 +1,452 @@ # @0xsequence/signhub +## 2.2.14 + +### Patch Changes + +- Somnia Testnet and Monad Testnet +- Updated dependencies + - @0xsequence/core@2.2.14 + +## 2.2.13 + +### Patch Changes + +- Add XR1 to all networks +- Updated dependencies + - @0xsequence/core@2.2.13 + +## 2.2.12 + +### Patch Changes + +- Add XR1 +- Updated dependencies + - @0xsequence/core@2.2.12 + +## 2.2.11 + +### Patch Changes + +- Relayer updates +- Updated dependencies + - @0xsequence/core@2.2.11 + +## 2.2.10 + +### Patch Changes + +- Etherlink support +- Updated dependencies + - @0xsequence/core@2.2.10 + +## 2.2.9 + +### Patch Changes + +- Indexer gateway native token balances +- Updated dependencies + - @0xsequence/core@2.2.9 + +## 2.2.8 + +### Patch Changes + +- Add Moonbeam and Moonbase Alpha +- Updated dependencies + - @0xsequence/core@2.2.8 + +## 2.2.7 + +### Patch Changes + +- Update Builder package +- Updated dependencies + - @0xsequence/core@2.2.7 + +## 2.2.6 + +### Patch Changes + +- Update relayer package +- Updated dependencies + - @0xsequence/core@2.2.6 + +## 2.2.5 + +### Patch Changes + +- auth: fix sequence indexer gateway url +- account: immutable wallet proxy hook +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.2.5 + +## 2.2.4 + +### Patch Changes + +- network: update soneium mainnet block explorer url +- waas: signTypedData intent support +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.2.4 + +## 2.2.3 + +### Patch Changes + +- provider: updating initWallet to use connected network configs if they exist +- Updated dependencies + - @0xsequence/core@2.2.3 + +## 2.2.2 + +### Patch Changes + +- pass projectAccessKey to relayer at all times +- Updated dependencies + - @0xsequence/core@2.2.2 + +## 2.2.1 + +### Patch Changes + +- waas-ethers: sign typed data +- Updated dependencies + - @0xsequence/core@2.2.1 + +## 2.2.0 + +### Minor Changes + +- indexer: gateway client +- @0xsequence/builder +- upgrade puppeteer to v23.10.3 + +### Patch Changes + +- Updated dependencies +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.2.0 + +## 2.1.8 + +### Patch Changes + +- Add Soneium Mainnet +- Updated dependencies + - @0xsequence/core@2.1.8 + +## 2.1.7 + +### Patch Changes + +- guard: pass project access key to guard requests +- Updated dependencies + - @0xsequence/core@2.1.7 + +## 2.1.6 + +### Patch Changes + +- Add LAOS and Telos Testnet chains +- Updated dependencies + - @0xsequence/core@2.1.6 + +## 2.1.5 + +### Patch Changes + +- account: save presigned configuration with reference chain id 1 +- Updated dependencies + - @0xsequence/core@2.1.5 + +## 2.1.4 + +### Patch Changes + +- provider: pass projectAccessKey into MuxMessageProvider +- Updated dependencies + - @0xsequence/core@2.1.4 + +## 2.1.3 + +### Patch Changes + +- waas: time drift date fix due to strange browser quirk +- Updated dependencies + - @0xsequence/core@2.1.3 + +## 2.1.2 + +### Patch Changes + +- provider: export analytics correctly +- Updated dependencies + - @0xsequence/core@2.1.2 + +## 2.1.1 + +### Patch Changes + +- Add LAOS chain support +- Updated dependencies + - @0xsequence/core@2.1.1 + +## 2.1.0 + +### Minor Changes + +- account: forward project access key when estimating fees and sending transactions + +### Patch Changes + +- sessions: save signatures with reference chain id +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.1.0 + +## 2.0.26 + +### Patch Changes + +- account: fix chain id comparison +- Updated dependencies + - @0xsequence/core@2.0.26 + +## 2.0.25 + +### Patch Changes + +- skale-nebula: deploy gas limit = 10m +- Updated dependencies + - @0xsequence/core@2.0.25 + +## 2.0.24 + +### Patch Changes + +- sessions: arweave: configurable gateway url +- waas: use /status to get time drift before sending any intents +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.0.24 + +## 2.0.23 + +### Patch Changes + +- Add The Root Network support +- Updated dependencies + - @0xsequence/core@2.0.23 + +## 2.0.22 + +### Patch Changes + +- Add SKALE Nebula Mainnet support +- Updated dependencies + - @0xsequence/core@2.0.22 + +## 2.0.21 + +### Patch Changes + +- account: add publishWitnessFor +- Updated dependencies + - @0xsequence/core@2.0.21 + +## 2.0.20 + +### Patch Changes + +- upgrade deps, and improve waas session status handling +- Updated dependencies + - @0xsequence/core@2.0.20 + +## 2.0.19 + +### Patch Changes + +- Add Immutable zkEVM support +- Updated dependencies + - @0xsequence/core@2.0.19 + +## 2.0.18 + +### Patch Changes + +- waas: new contractCall transaction type +- sessions: add arweave owner +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.0.18 + +## 2.0.17 + +### Patch Changes + +- update waas auth to clear session before signIn +- Updated dependencies + - @0xsequence/core@2.0.17 + +## 2.0.16 + +### Patch Changes + +- Removed Astar chains +- Updated dependencies + - @0xsequence/core@2.0.16 + +## 2.0.15 + +### Patch Changes + +- indexer: update bindings with token balance additions +- Updated dependencies + - @0xsequence/core@2.0.15 + +## 2.0.14 + +### Patch Changes + +- sessions: arweave config reader +- network: add b3 and apechain mainnet configs +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.0.14 + +## 2.0.13 + +### Patch Changes + +- network: toy-testnet +- Updated dependencies + - @0xsequence/core@2.0.13 + +## 2.0.12 + +### Patch Changes + +- api: update bindings +- Updated dependencies + - @0xsequence/core@2.0.12 + +## 2.0.11 + +### Patch Changes + +- waas: intents test fix +- api: update bindings +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.0.11 + +## 2.0.10 + +### Patch Changes + +- network: soneium minato testnet +- Updated dependencies + - @0xsequence/core@2.0.10 + +## 2.0.9 + +### Patch Changes + +- network: fix SKALE network name +- Updated dependencies + - @0xsequence/core@2.0.9 + +## 2.0.8 + +### Patch Changes + +- metadata: update bindings +- Updated dependencies + - @0xsequence/core@2.0.8 + +## 2.0.7 + +### Patch Changes + +- wallet request handler fix +- Updated dependencies + - @0xsequence/core@2.0.7 + +## 2.0.6 + +### Patch Changes + +- network: matic -> pol +- Updated dependencies + - @0xsequence/core@2.0.6 + +## 2.0.5 + +### Patch Changes + +- provider: update databeat to 0.9.2 +- Updated dependencies + - @0xsequence/core@2.0.5 + +## 2.0.4 + +### Patch Changes + +- network: add skale-nebula-testnet +- Updated dependencies + - @0xsequence/core@2.0.4 + +## 2.0.3 + +### Patch Changes + +- waas: check session status in SequenceWaaS.isSignedIn() +- Updated dependencies + - @0xsequence/core@2.0.3 + +## 2.0.2 + +### Patch Changes + +- sessions: property convert serialized bignumber hex value to bigint +- Updated dependencies + - @0xsequence/core@2.0.2 + +## 2.0.1 + +### Patch Changes + +- waas: http signature check for authenticator requests +- provider: unwrap legacy json rpc responses +- use json replacer and reviver for bigints +- Updated dependencies +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.0.1 + +## 2.0.0 + +### Major Changes + +- ethers v6 + +### Patch Changes + +- Updated dependencies + - @0xsequence/core@2.0.0 + +## 1.10.15 + +### Patch Changes + +- utils: extractProjectIdFromAccessKey +- Updated dependencies + - @0xsequence/core@1.10.15 + ## 1.10.14 ### Patch Changes diff --git a/packages/signhub/package.json b/packages/signhub/package.json index 1a8341e3e..ef7e1f91e 100644 --- a/packages/signhub/package.json +++ b/packages/signhub/package.json @@ -1,6 +1,6 @@ { "name": "@0xsequence/signhub", - "version": "1.10.14", + "version": "2.2.14", "description": "orchestrates a series of signers, provides visibility into the signing process, and to the signers themselves", "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/signhub", "source": "src/index.ts", @@ -9,17 +9,19 @@ "author": "Horizon Blockchain Games", "license": "Apache-2.0", "scripts": { - "test": "yarn test:file tests/**/*.spec.ts", + "test": "pnpm test:file tests/**/*.spec.ts", "test:file": "TS_NODE_PROJECT=../../tsconfig.test.json mocha -r ts-node/register --timeout 30000", - "test:coverage": "nyc yarn test" + "test:coverage": "nyc pnpm test" + }, + "peerDependencies": { + "ethers": ">=6" }, "dependencies": { - "@0xsequence/core": "workspace:*", - "ethers": "^5.5.2" + "@0xsequence/core": "workspace:*" }, - "peerDependencies": {}, "devDependencies": { "@istanbuljs/nyc-config-typescript": "^1.0.2", + "ethers": "6.13.4", "nyc": "^15.1.0" }, "files": [ diff --git a/packages/signhub/src/orchestrator.ts b/packages/signhub/src/orchestrator.ts index 49bf5747b..45b672f45 100644 --- a/packages/signhub/src/orchestrator.ts +++ b/packages/signhub/src/orchestrator.ts @@ -70,7 +70,7 @@ export class Orchestrator { } private static randomTag(): string { - return `default-${ethers.utils.hexlify(ethers.utils.randomBytes(8)).slice(2)}` + return `default-${ethers.hexlify(ethers.randomBytes(8)).slice(2)}` } private pullId(): string { diff --git a/packages/signhub/src/signers/wrapper.ts b/packages/signhub/src/signers/wrapper.ts index bbd2b4e80..77fbd9bda 100644 --- a/packages/signhub/src/signers/wrapper.ts +++ b/packages/signhub/src/signers/wrapper.ts @@ -29,13 +29,13 @@ export class SignerWrapper implements SapientSigner { return bundle } - sign(message: ethers.utils.BytesLike, metadata: object): Promise { + sign(message: ethers.BytesLike): Promise { return this.signer.signMessage(message) } notifyStatusChange(_i: string, _s: Status, _m: object): void {} suffix(): ethers.BytesLike { - return [2] + return new Uint8Array([2]) } } diff --git a/packages/signhub/tests/orchestrator.spec.ts b/packages/signhub/tests/orchestrator.spec.ts index 1b4fad943..8e4041795 100644 --- a/packages/signhub/tests/orchestrator.spec.ts +++ b/packages/signhub/tests/orchestrator.spec.ts @@ -119,7 +119,7 @@ describe('Orchestrator', () => { }, notifyStatusChange: function (id: string, status: Status): void {}, suffix: function () { - return [2] + return new Uint8Array([2]) } } @@ -202,7 +202,7 @@ describe('Orchestrator', () => { }, notifyStatusChange: function (id: string, status: Status): void {}, suffix: function () { - return [2] + return new Uint8Array([2]) } } @@ -235,7 +235,7 @@ describe('Orchestrator', () => { }) it('Should pass the correct message to the signer', async () => { - const ogMessage = ethers.utils.randomBytes(99) + const ogMessage = ethers.randomBytes(99) const signer: SapientSigner = { getAddress: async function (): Promise { return '0x1234' @@ -258,7 +258,7 @@ describe('Orchestrator', () => { }, notifyStatusChange: function (id: string, status: Status): void {}, suffix: function () { - return [2] + return new Uint8Array([2]) } } @@ -269,7 +269,7 @@ describe('Orchestrator', () => { }) it('Should pass metadata to signer', async () => { - const ogMessage = ethers.utils.randomBytes(99) + const ogMessage = ethers.randomBytes(99) const signer: SapientSigner = { getAddress: async function (): Promise { return '0x1234' @@ -292,7 +292,7 @@ describe('Orchestrator', () => { }, notifyStatusChange: function (id: string, status: Status): void {}, suffix: function () { - return [2] + return new Uint8Array([2]) } } @@ -303,7 +303,7 @@ describe('Orchestrator', () => { }) it('Should pass updated metadata to signer', async () => { - const ogMessage = ethers.utils.randomBytes(99) + const ogMessage = ethers.randomBytes(99) let firstCall = true let errorOnNotify: any = undefined @@ -340,7 +340,7 @@ describe('Orchestrator', () => { } }, suffix: function () { - return [2] + return new Uint8Array([2]) } } @@ -376,7 +376,7 @@ describe('Orchestrator', () => { } }, suffix: function () { - return [2] + return new Uint8Array([2]) } } @@ -408,7 +408,7 @@ describe('Orchestrator', () => { }) it('Should only sign with candidates', async () => { - const message = ethers.utils.randomBytes(99) + const message = ethers.randomBytes(99) const signer1 = ethers.Wallet.createRandom() const signer2 = ethers.Wallet.createRandom() @@ -455,7 +455,7 @@ describe('Orchestrator', () => { }, notifyStatusChange: function (id: string, status: Status): void {}, suffix: function () { - return [0] + return new Uint8Array([0]) } } @@ -507,7 +507,7 @@ describe('Orchestrator', () => { }, notifyStatusChange: function (id: string, status: Status): void {}, suffix: function () { - return [0] + return new Uint8Array([0]) } } const signer2: SapientSigner = { @@ -538,7 +538,7 @@ describe('Orchestrator', () => { }, notifyStatusChange: function (id: string, status: Status): void {}, suffix: function () { - return [0] + return new Uint8Array([0]) } } diff --git a/packages/simulator/CHANGELOG.md b/packages/simulator/CHANGELOG.md deleted file mode 100644 index f47d5498d..000000000 --- a/packages/simulator/CHANGELOG.md +++ /dev/null @@ -1,1392 +0,0 @@ -# @0xsequence/simulator - -## 1.10.14 - -### Patch Changes - -- network: add borne-testnet to allNetworks -- Updated dependencies - - @0xsequence/core@1.10.14 - -## 1.10.13 - -### Patch Changes - -- network: add borne testnet -- Updated dependencies - - @0xsequence/core@1.10.13 - -## 1.10.12 - -### Patch Changes - -- api: update bindings -- global/window -> globalThis -- Updated dependencies -- Updated dependencies - - @0xsequence/core@1.10.12 - -## 1.10.11 - -### Patch Changes - -- waas: updated intent.gen without webrpc types, errors exported from authenticator.gen -- Updated dependencies - - @0xsequence/core@1.10.11 - -## 1.10.10 - -### Patch Changes - -- metadata: update bindings with new contract collections api -- Updated dependencies - - @0xsequence/core@1.10.10 - -## 1.10.9 - -### Patch Changes - -- waas minor update -- Updated dependencies - - @0xsequence/core@1.10.9 - -## 1.10.8 - -### Patch Changes - -- update metadata bindings -- Updated dependencies - - @0xsequence/core@1.10.8 - -## 1.10.7 - -### Patch Changes - -- minor fixes to waas client -- Updated dependencies - - @0xsequence/core@1.10.7 - -## 1.10.6 - -### Patch Changes - -- metadata: update bindings -- Updated dependencies - - @0xsequence/core@1.10.6 - -## 1.10.5 - -### Patch Changes - -- network: ape-chain-testnet -> apechain-testnet -- Updated dependencies - - @0xsequence/core@1.10.5 - -## 1.10.4 - -### Patch Changes - -- network: add b3-sepolia, ape-chain-testnet, blast, blast-sepolia -- Updated dependencies - - @0xsequence/core@1.10.4 - -## 1.10.3 - -### Patch Changes - -- typing fix -- Updated dependencies - - @0xsequence/core@1.10.3 - -## 1.10.2 - -### Patch Changes - -- - waas: add getIdToken method - - indexer: update api client -- Updated dependencies - - @0xsequence/core@1.10.2 - -## 1.10.1 - -### Patch Changes - -- metadata: update bindings -- Updated dependencies - - @0xsequence/core@1.10.1 - -## 1.10.0 - -### Minor Changes - -- waas release v1.3.0 - -### Patch Changes - -- Updated dependencies - - @0xsequence/core@1.10.0 - -## 1.9.37 - -### Patch Changes - -- network: adds nativeToken data to NetworkMetadata constants -- Updated dependencies - - @0xsequence/core@1.9.37 - -## 1.9.36 - -### Patch Changes - -- guard: export client -- Updated dependencies - - @0xsequence/core@1.9.36 - -## 1.9.35 - -### Patch Changes - -- guard: update bindings -- Updated dependencies - - @0xsequence/core@1.9.35 - -## 1.9.34 - -### Patch Changes - -- waas: always use lowercase email -- Updated dependencies - - @0xsequence/core@1.9.34 - -## 1.9.33 - -### Patch Changes - -- waas: umd build -- Updated dependencies - - @0xsequence/core@1.9.33 - -## 1.9.32 - -### Patch Changes - -- indexer: update bindings -- Updated dependencies - - @0xsequence/core@1.9.32 - -## 1.9.31 - -### Patch Changes - -- metadata: token directory changes -- Updated dependencies - - @0xsequence/core@1.9.31 - -## 1.9.30 - -### Patch Changes - -- update -- Updated dependencies - - @0xsequence/core@1.9.30 - -## 1.9.29 - -### Patch Changes - -- disable gnosis chain -- Updated dependencies - - @0xsequence/core@1.9.29 - -## 1.9.28 - -### Patch Changes - -- add utils/merkletree -- Updated dependencies - - @0xsequence/core@1.9.28 - -## 1.9.27 - -### Patch Changes - -- network: optimistic -> optimism -- waas: remove defaults -- api, sessions: update bindings -- Updated dependencies -- Updated dependencies -- Updated dependencies - - @0xsequence/core@1.9.27 - -## 1.9.26 - -### Patch Changes - -- - add backend interfaces for pluggable interfaces - - introduce @0xsequence/react-native - - update pnpm to lockfile v9 -- Updated dependencies - - @0xsequence/core@1.9.26 - -## 1.9.25 - -### Patch Changes - -- update webrpc clients with new error types -- Updated dependencies - - @0xsequence/core@1.9.25 - -## 1.9.24 - -### Patch Changes - -- waas: add memoryStore backend to localStore -- Updated dependencies - - @0xsequence/core@1.9.24 - -## 1.9.23 - -### Patch Changes - -- update api client bindings -- Updated dependencies - - @0xsequence/core@1.9.23 - -## 1.9.22 - -### Patch Changes - -- update metadata client bindings -- Updated dependencies - - @0xsequence/core@1.9.22 - -## 1.9.21 - -### Patch Changes - -- api client bindings -- Updated dependencies - - @0xsequence/core@1.9.21 - -## 1.9.20 - -### Patch Changes - -- api client bindings update -- Updated dependencies - - @0xsequence/core@1.9.20 - -## 1.9.19 - -### Patch Changes - -- waas update -- Updated dependencies - - @0xsequence/core@1.9.19 - -## 1.9.18 - -### Patch Changes - -- provider: prohibit dangerous functions -- Updated dependencies - - @0xsequence/core@1.9.18 - -## 1.9.17 - -### Patch Changes - -- network: add xr-sepolia -- Updated dependencies - - @0xsequence/core@1.9.17 - -## 1.9.16 - -### Patch Changes - -- waas: sequence.feeOptions -- Updated dependencies - - @0xsequence/core@1.9.16 - -## 1.9.15 - -### Patch Changes - -- metadata: collection external_link field name fix -- Updated dependencies - - @0xsequence/core@1.9.15 - -## 1.9.14 - -### Patch Changes - -- network: astar-zkatana -> astar-zkyoto -- network: deprecate polygon mumbai network -- network: add xai and polygon amoy -- Updated dependencies -- Updated dependencies -- Updated dependencies - - @0xsequence/core@1.9.14 - -## 1.9.13 - -### Patch Changes - -- waas: fix @0xsequence/network dependency -- Updated dependencies - - @0xsequence/core@1.9.13 - -## 1.9.12 - -### Patch Changes - -- indexer: update rpc bindings -- provider: signMessage: Serialize the BytesLike or string message into hexstring before sending -- waas: SessionAuthProof -- Updated dependencies -- Updated dependencies -- Updated dependencies - - @0xsequence/core@1.9.12 - -## 1.9.11 - -### Patch Changes - -- metdata, update rpc bindings -- Updated dependencies - - @0xsequence/core@1.9.11 - -## 1.9.10 - -### Patch Changes - -- update metadata rpc bindings -- Updated dependencies - - @0xsequence/core@1.9.10 - -## 1.9.9 - -### Patch Changes - -- metadata, add SequenceCollections rpc client -- Updated dependencies - - @0xsequence/core@1.9.9 - -## 1.9.8 - -### Patch Changes - -- waas client update -- Updated dependencies - - @0xsequence/core@1.9.8 - -## 1.9.7 - -### Patch Changes - -- update rpc client bindings for api, metadata and relayer -- Updated dependencies - - @0xsequence/core@1.9.7 - -## 1.9.6 - -### Patch Changes - -- waas package update -- Updated dependencies - - @0xsequence/core@1.9.6 - -## 1.9.5 - -### Patch Changes - -- RpcRelayer prioritize project access key -- Updated dependencies - - @0xsequence/core@1.9.5 - -## 1.9.4 - -### Patch Changes - -- waas: fix network dependency -- Updated dependencies - - @0xsequence/core@1.9.4 - -## 1.9.3 - -### Patch Changes - -- provider: don't append access key to RPC url if user has already provided it -- Updated dependencies - - @0xsequence/core@1.9.3 - -## 1.9.2 - -### Patch Changes - -- network: add xai-sepolia -- Updated dependencies - - @0xsequence/core@1.9.2 - -## 1.9.1 - -### Patch Changes - -- analytics fix -- Updated dependencies - - @0xsequence/core@1.9.1 - -## 1.9.0 - -### Minor Changes - -- waas release - -### Patch Changes - -- Updated dependencies - - @0xsequence/core@1.9.0 - -## 1.8.8 - -### Patch Changes - -- update metadata bindings -- Updated dependencies - - @0xsequence/core@1.8.8 - -## 1.8.7 - -### Patch Changes - -- provider: update databeat to 0.9.1 -- Updated dependencies - - @0xsequence/core@1.8.7 - -## 1.8.6 - -### Patch Changes - -- guard: SignedOwnershipProof -- Updated dependencies - - @0xsequence/core@1.8.6 - -## 1.8.5 - -### Patch Changes - -- guard: signOwnershipProof and isSignedOwnershipProof -- Updated dependencies - - @0xsequence/core@1.8.5 - -## 1.8.4 - -### Patch Changes - -- network: add homeverse to networks list -- Updated dependencies - - @0xsequence/core@1.8.4 - -## 1.8.3 - -### Patch Changes - -- api: introduce basic linked wallet support -- Updated dependencies - - @0xsequence/core@1.8.3 - -## 1.8.2 - -### Patch Changes - -- provider: don't initialize analytics unless explicitly requested -- Updated dependencies - - @0xsequence/core@1.8.2 - -## 1.8.1 - -### Patch Changes - -- update to analytics provider -- Updated dependencies - - @0xsequence/core@1.8.1 - -## 1.8.0 - -### Minor Changes - -- provider: project analytics - -### Patch Changes - -- Updated dependencies - - @0xsequence/core@1.8.0 - -## 1.7.2 - -### Patch Changes - -- 0xsequence: ChainId should not be exported as a type -- account, wallet: fix nonce selection -- Updated dependencies -- Updated dependencies - - @0xsequence/core@1.7.2 - -## 1.7.1 - -### Patch Changes - -- network: add missing avalanche logoURI -- Updated dependencies - - @0xsequence/core@1.7.1 - -## 1.7.0 - -### Minor Changes - -- provider: projectAccessKey is now required - -### Patch Changes - -- network: add NetworkMetadata.logoURI property for all networks -- Updated dependencies -- Updated dependencies - - @0xsequence/core@1.7.0 - -## 1.6.3 - -### Patch Changes - -- network list update -- Updated dependencies - - @0xsequence/core@1.6.3 - -## 1.6.2 - -### Patch Changes - -- auth: projectAccessKey option -- wallet: use 12 bytes for random space -- Updated dependencies -- Updated dependencies - - @0xsequence/core@1.6.2 - -## 1.6.1 - -### Patch Changes - -- core: add simple config from subdigest support -- core: fix encode tree with subdigest -- account: implement buildOnChainSignature on Account -- Updated dependencies -- Updated dependencies -- Updated dependencies - - @0xsequence/core@1.6.1 - -## 1.6.0 - -### Minor Changes - -- account, wallet: parallel transactions by default - -### Patch Changes - -- provider: emit disconnect on sign out -- Updated dependencies -- Updated dependencies - - @0xsequence/core@1.6.0 - -## 1.5.0 - -### Minor Changes - -- signhub: add 'signing' signer status - -### Patch Changes - -- auth: Session.open: onAccountAddress callback -- account: allow empty transaction bundles -- Updated dependencies -- Updated dependencies -- Updated dependencies - - @0xsequence/core@1.5.0 - -## 1.4.9 - -### Patch Changes - -- rename SequenceMetadataClient to SequenceMetadata -- Updated dependencies - - @0xsequence/core@1.4.9 - -## 1.4.8 - -### Patch Changes - -- account: Account.getSigners -- Updated dependencies - - @0xsequence/core@1.4.8 - -## 1.4.7 - -### Patch Changes - -- update indexer client bindings -- Updated dependencies - - @0xsequence/core@1.4.7 - -## 1.4.6 - -### Patch Changes - -- - add sepolia networks, mark goerli as deprecated - - update indexer client bindings -- Updated dependencies - - @0xsequence/core@1.4.6 - -## 1.4.5 - -### Patch Changes - -- indexer/metadata: update client bindings -- auth: selectWallet with new address -- Updated dependencies -- Updated dependencies - - @0xsequence/core@1.4.5 - -## 1.4.4 - -### Patch Changes - -- indexer: update bindings -- auth: handle jwt expiry -- Updated dependencies -- Updated dependencies - - @0xsequence/core@1.4.4 - -## 1.4.3 - -### Patch Changes - -- guard: return active status from GuardSigner.getAuthMethods -- Updated dependencies - - @0xsequence/core@1.4.3 - -## 1.4.2 - -### Patch Changes - -- guard: update bindings -- Updated dependencies - - @0xsequence/core@1.4.2 - -## 1.4.1 - -### Patch Changes - -- network: remove unused networks -- signhub: orchestrator interface -- guard: auth methods interface -- guard: update bindings for pin and totp -- guard: no more retry logic -- Updated dependencies -- Updated dependencies -- Updated dependencies -- Updated dependencies -- Updated dependencies - - @0xsequence/core@1.4.1 - -## 1.4.0 - -### Minor Changes - -- project access key support - -### Patch Changes - -- Updated dependencies - - @0xsequence/core@1.4.0 - -## 1.3.0 - -### Minor Changes - -- signhub: account children - -### Patch Changes - -- guard: do not throw when building deploy transaction -- network: snowtrace.io -> subnets.avax.network/c-chain -- Updated dependencies -- Updated dependencies -- Updated dependencies - - @0xsequence/core@1.3.0 - -## 1.2.9 - -### Patch Changes - -- account: AccountSigner.sendTransaction simulateForFeeOptions -- relayer: update bindings -- Updated dependencies -- Updated dependencies - - @0xsequence/core@1.2.9 - -## 1.2.8 - -### Patch Changes - -- rename X-Sequence-Token-Key header to X-Access-Key -- Updated dependencies - - @0xsequence/core@1.2.8 - -## 1.2.7 - -### Patch Changes - -- add x-sequence-token-key to clients -- Updated dependencies - - @0xsequence/core@1.2.7 - -## 1.2.6 - -### Patch Changes - -- Fix bind multicall provider -- Updated dependencies - - @0xsequence/core@1.2.6 - -## 1.2.5 - -### Patch Changes - -- Multicall default configuration fixes -- Updated dependencies - - @0xsequence/core@1.2.5 - -## 1.2.4 - -### Patch Changes - -- provider: Adding missing payment provider types to PaymentProviderOption -- provider: WalletRequestHandler.notifyChainChanged -- Updated dependencies -- Updated dependencies - - @0xsequence/core@1.2.4 - -## 1.2.3 - -### Patch Changes - -- auth, provider: connect to accept optional authorizeNonce -- Updated dependencies - - @0xsequence/core@1.2.3 - -## 1.2.2 - -### Patch Changes - -- provider: allow createContract calls -- core: check for explicit zero address in contract deployments -- Updated dependencies -- Updated dependencies - - @0xsequence/core@1.2.2 - -## 1.2.1 - -### Patch Changes - -- auth: use sequence api chain id as reference chain id if available -- Updated dependencies - - @0xsequence/core@1.2.1 - -## 1.2.0 - -### Minor Changes - -- split services from session, better local support - -### Patch Changes - -- Updated dependencies - - @0xsequence/core@1.2.0 - -## 1.1.15 - -### Patch Changes - -- guard: remove error filtering -- Updated dependencies - - @0xsequence/core@1.1.15 - -## 1.1.14 - -### Patch Changes - -- guard: add GuardSigner.onError -- Updated dependencies - - @0xsequence/core@1.1.14 - -## 1.1.13 - -### Patch Changes - -- provider: pass client version with connect options -- provider: removing large from BannerSize -- Updated dependencies -- Updated dependencies - - @0xsequence/core@1.1.13 - -## 1.1.12 - -### Patch Changes - -- provider: adding bannerSize to ConnectOptions -- Updated dependencies - - @0xsequence/core@1.1.12 - -## 1.1.11 - -### Patch Changes - -- add homeverse configs -- Updated dependencies - - @0xsequence/core@1.1.11 - -## 1.1.10 - -### Patch Changes - -- handle default EIP6492 on send -- Updated dependencies - - @0xsequence/core@1.1.10 - -## 1.1.9 - -### Patch Changes - -- Custom default EIP6492 on client -- Updated dependencies - - @0xsequence/core@1.1.9 - -## 1.1.8 - -### Patch Changes - -- metadata: searchMetadata: add types filter -- Updated dependencies - - @0xsequence/core@1.1.8 - -## 1.1.7 - -### Patch Changes - -- adding signInWith connect settings option to allow dapps to automatically login their users with a certain provider optimizing the normal authentication flow -- Updated dependencies - - @0xsequence/core@1.1.7 - -## 1.1.6 - -### Patch Changes - -- metadata: searchMetadata: add chainID and excludeTokenMetadata filters -- Updated dependencies - - @0xsequence/core@1.1.6 - -## 1.1.5 - -### Patch Changes - -- account: re-compute meta-transaction id for wallet deployment transactions -- Updated dependencies - - @0xsequence/core@1.1.5 - -## 1.1.4 - -### Patch Changes - -- network: rename base-mainnet to base -- provider: override isDefaultChain with ConnectOptions.networkId if provided -- Updated dependencies -- Updated dependencies - - @0xsequence/core@1.1.4 - -## 1.1.3 - -### Patch Changes - -- provider: use network id from transport session -- provider: sign authorization using ConnectOptions.networkId if provided -- Updated dependencies -- Updated dependencies - - @0xsequence/core@1.1.3 - -## 1.1.2 - -### Patch Changes - -- provider: jsonrpc chain id fixes -- Updated dependencies - - @0xsequence/core@1.1.2 - -## 1.1.1 - -### Patch Changes - -- network: add base mainnet and sepolia -- provider: reject toxic transaction requests -- Updated dependencies -- Updated dependencies - - @0xsequence/core@1.1.1 - -## 1.1.0 - -### Minor Changes - -- Refactor dapp facing provider - -### Patch Changes - -- Updated dependencies - - @0xsequence/core@1.1.0 - -## 1.0.5 - -### Patch Changes - -- network: export network constants -- guard: use the correct global for fetch -- network: nova-explorer.arbitrum.io -> nova.arbiscan.io -- Updated dependencies -- Updated dependencies -- Updated dependencies - - @0xsequence/core@1.0.5 - -## 1.0.4 - -### Patch Changes - -- provider: accept name or number for networkId -- Updated dependencies - - @0xsequence/core@1.0.4 - -## 1.0.3 - -### Patch Changes - -- Simpler isValidSignature helpers -- Updated dependencies - - @0xsequence/core@1.0.3 - -## 1.0.2 - -### Patch Changes - -- add extra signature validation utils methods -- Updated dependencies - - @0xsequence/core@1.0.2 - -## 1.0.1 - -### Patch Changes - -- add homeverse testnet -- Updated dependencies - - @0xsequence/core@1.0.1 - -## 1.0.0 - -### Major Changes - -- https://sequence.xyz/blog/sequence-wallet-light-state-sync-full-merkle-wallets - -### Patch Changes - -- Updated dependencies - - @0xsequence/core@1.0.0 - -## 0.43.34 - -### Patch Changes - -- auth: no jwt for indexer -- Updated dependencies - - @0xsequence/transactions@0.43.34 - -## 0.43.33 - -### Patch Changes - -- Adding onConnectOptionsChange handler to WalletRequestHandler -- Updated dependencies - - @0xsequence/transactions@0.43.33 - -## 0.43.32 - -### Patch Changes - -- add Base Goerli network -- Updated dependencies - - @0xsequence/transactions@0.43.32 - -## 0.43.31 - -### Patch Changes - -- remove AuxDataProvider, add promptSignInConnect -- Updated dependencies - - @0xsequence/transactions@0.43.31 - -## 0.43.30 - -### Patch Changes - -- add arbitrum goerli testnet -- Updated dependencies - - @0xsequence/transactions@0.43.30 - -## 0.43.29 - -### Patch Changes - -- provider: check availability of window object -- Updated dependencies - - @0xsequence/transactions@0.43.29 - -## 0.43.28 - -### Patch Changes - -- update api bindings -- Updated dependencies - - @0xsequence/transactions@0.43.28 - -## 0.43.27 - -### Patch Changes - -- Add rpc is sequence method -- Updated dependencies - - @0xsequence/transactions@0.43.27 - -## 0.43.26 - -### Patch Changes - -- add zkevm url to enum -- Updated dependencies - - @0xsequence/transactions@0.43.26 - -## 0.43.25 - -### Patch Changes - -- added polygon zkevm to mainnet networks -- Updated dependencies - - @0xsequence/transactions@0.43.25 - -## 0.43.24 - -### Patch Changes - -- name change from zkevm to polygon-zkevm -- Updated dependencies - - @0xsequence/transactions@0.43.24 - -## 0.43.23 - -### Patch Changes - -- update zkEVM name to Polygon zkEVM -- Updated dependencies - - @0xsequence/transactions@0.43.23 - -## 0.43.22 - -### Patch Changes - -- add zkevm chain -- Updated dependencies - - @0xsequence/transactions@0.43.22 - -## 0.43.21 - -### Patch Changes - -- api: update client bindings -- Updated dependencies - - @0xsequence/transactions@0.43.21 - -## 0.43.20 - -### Patch Changes - -- indexer: update bindings -- Updated dependencies - - @0xsequence/transactions@0.43.20 - -## 0.43.19 - -### Patch Changes - -- session proof update -- Updated dependencies - - @0xsequence/transactions@0.43.19 - -## 0.43.18 - -### Patch Changes - -- rpc client global check, hardening -- Updated dependencies - - @0xsequence/transactions@0.43.18 - -## 0.43.17 - -### Patch Changes - -- rpc clients, check of 'global' is defined -- Updated dependencies - - @0xsequence/transactions@0.43.17 - -## 0.43.16 - -### Patch Changes - -- ethers peerDep to v5, update rpc client global use -- Updated dependencies - - @0xsequence/transactions@0.43.16 - -## 0.43.15 - -### Patch Changes - -- - provider: expand receiver type on some util methods -- Updated dependencies - - @0xsequence/transactions@0.43.15 - -## 0.43.14 - -### Patch Changes - -- bump -- Updated dependencies - - @0xsequence/transactions@0.43.14 - -## 0.43.13 - -### Patch Changes - -- update rpc bindings -- Updated dependencies - - @0xsequence/transactions@0.43.13 - -## 0.43.12 - -### Patch Changes - -- provider: single wallet init, and add new unregisterWallet() method -- Updated dependencies - - @0xsequence/transactions@0.43.12 - -## 0.43.11 - -### Patch Changes - -- fix lockfiles -- re-add mocha type deleter -- Updated dependencies -- Updated dependencies - - @0xsequence/transactions@0.43.11 - -## 0.43.10 - -### Patch Changes - -- various improvements -- Updated dependencies - - @0xsequence/transactions@0.43.10 - -## 0.43.9 - -### Patch Changes - -- update deps -- Updated dependencies - - @0xsequence/transactions@0.43.9 - -## 0.43.8 - -### Patch Changes - -- network: JsonRpcProvider with caching -- Updated dependencies - - @0xsequence/transactions@0.43.8 - -## 0.43.7 - -### Patch Changes - -- provider: fix wallet network init -- Updated dependencies - - @0xsequence/transactions@0.43.7 - -## 0.43.6 - -### Patch Changes - -- metadatata: update rpc bindings -- Updated dependencies - - @0xsequence/transactions@0.43.6 - -## 0.43.5 - -### Patch Changes - -- provider: do not set default network for connect messages -- provider: forward missing error message -- Updated dependencies -- Updated dependencies - - @0xsequence/transactions@0.43.5 - -## 0.43.4 - -### Patch Changes - -- no-change version bump to fix incorrectly tagged snapshot build -- Updated dependencies - - @0xsequence/transactions@0.43.4 - -## 0.43.3 - -### Patch Changes - -- metadata: update bindings -- Updated dependencies - - @0xsequence/transactions@0.43.3 - -## 0.43.2 - -### Patch Changes - -- provider: implement connectUnchecked -- Updated dependencies - - @0xsequence/transactions@0.43.2 - -## 0.43.1 - -### Patch Changes - -- update to latest ethauth dep -- Updated dependencies - - @0xsequence/transactions@0.43.1 - -## 0.43.0 - -### Minor Changes - -- move ethers to a peer dependency - -### Patch Changes - -- Updated dependencies - - @0xsequence/transactions@0.43.0 - -## 0.42.10 - -### Patch Changes - -- add auxDataProvider -- Updated dependencies - - @0xsequence/transactions@0.42.10 - -## 0.42.9 - -### Patch Changes - -- provider: add eip-191 exceptions -- Updated dependencies - - @0xsequence/transactions@0.42.9 - -## 0.42.8 - -### Patch Changes - -- provider: skip setting intent origin if we're unity plugin -- Updated dependencies - - @0xsequence/transactions@0.42.8 - -## 0.42.7 - -### Patch Changes - -- Add sign in options to connection settings -- Updated dependencies - - @0xsequence/transactions@0.42.7 - -## 0.42.6 - -### Patch Changes - -- api bindings update -- Updated dependencies - - @0xsequence/transactions@0.42.6 - -## 0.42.5 - -### Patch Changes - -- relayer: don't treat missing receipt as hard failure -- Updated dependencies - - @0xsequence/transactions@0.42.5 - -## 0.42.4 - -### Patch Changes - -- provider: add custom app protocol to connect options -- Updated dependencies - - @0xsequence/transactions@0.42.4 - -## 0.42.3 - -### Patch Changes - -- update api bindings -- Updated dependencies - - @0xsequence/transactions@0.42.3 - -## 0.42.2 - -### Patch Changes - -- disable rinkeby network -- Updated dependencies - - @0xsequence/transactions@0.42.2 - -## 0.42.1 - -### Patch Changes - -- wallet: optional waitForReceipt parameter -- Updated dependencies - - @0xsequence/transactions@0.42.1 - -## 0.42.0 - -### Minor Changes - -- relayer: estimateGasLimits -> simulate -- add simulator package - -### Patch Changes - -- transactions: fix flattenAuxTransactions -- provider: only filter nullish values -- provider: re-map transaction 'gas' back to 'gasLimit' -- Updated dependencies -- Updated dependencies -- Updated dependencies -- Updated dependencies -- Updated dependencies - - @0xsequence/transactions@0.42.0 diff --git a/packages/simulator/package.json b/packages/simulator/package.json deleted file mode 100644 index 3bd4360c6..000000000 --- a/packages/simulator/package.json +++ /dev/null @@ -1,35 +0,0 @@ -{ - "name": "@0xsequence/simulator", - "version": "1.10.14", - "description": "simulator sub-package for Sequence", - "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/simulator", - "source": "src/index.ts", - "main": "dist/0xsequence-simulator.cjs.js", - "module": "dist/0xsequence-simulator.esm.js", - "author": "Horizon Blockchain Games", - "license": "Apache-2.0", - "scripts": { - "test": "pnpm test:concurrently 'pnpm test:run'", - "test:run": "wait-on -t 120000 http-get://127.0.0.1:10045/ && pnpm test:file tests/**/*.spec.ts", - "test:file": "NODE_OPTIONS='--import tsx' mocha --timeout 30000", - "test:concurrently": "concurrently -k --success first 'pnpm start:geth > /dev/null'", - "start:geth": "docker run --rm -t -p 10045:10045 ethereum/client-go:v1.10.16 --http --http.addr 0.0.0.0 --http.port 10045 --datadir test_chain --dev --rpc.allow-unprotected-txs", - "typecheck": "tsc --noEmit" - }, - "dependencies": { - "@0xsequence/core": "workspace:*", - "@0xsequence/wallet-contracts": "^1.10.0" - }, - "peerDependencies": { - "ethers": ">=5.5 < 6" - }, - "devDependencies": { - "@0xsequence/signhub": "workspace:*", - "@0xsequence/tests": "workspace:*", - "ethers": "^5.7.2" - }, - "files": [ - "src", - "dist" - ] -} diff --git a/packages/simulator/src/geth-call.ts b/packages/simulator/src/geth-call.ts deleted file mode 100644 index 0c7206587..000000000 --- a/packages/simulator/src/geth-call.ts +++ /dev/null @@ -1,90 +0,0 @@ -import { BigNumber, BigNumberish, BytesLike, utils, providers } from 'ethers' - -export async function gethCall( - provider: providers.JsonRpcProvider, - transaction: providers.TransactionRequest, - block?: providers.BlockTag, - overrides?: Overrides -) { - const formatter = providers.JsonRpcProvider.getFormatter() - - return provider.send('eth_call', [ - formatter.transactionRequest(transaction), - formatter.blockTag(block ?? null), - ...(overrides ? [formatOverrides(overrides)] : []) - ]) -} - -export interface Overrides { - [address: string]: { - balance?: BigNumberish - nonce?: BigNumberish - code?: BytesLike | utils.Hexable | number | bigint - state?: StorageOverrides - stateDiff?: StorageOverrides - } -} - -export interface StorageOverrides { - [hash: string]: string -} - -function formatOverrides(overrides: any): Overrides { - if (typeof overrides !== 'object') { - throw new Error('overrides must be an object') - } - - const formatted: Overrides = {} - - for (const [key, value] of Object.entries(overrides)) { - if (utils.isHexString(key, 20)) { - try { - formatted[key] = providers.Formatter.check(overridesFormat, value) - } catch {} - } - } - - return formatted -} - -const overridesFormat = { - balance: skipNullish(BigNumber.from), - nonce: skipNullish(BigNumber.from), - code: skipNullish(utils.hexlify), - state: skipNullish(formatStorageOverrides), - stateDiff: skipNullish(formatStorageOverrides) -} - -function formatStorageOverrides(overrides: any): StorageOverrides { - if (typeof overrides !== 'object') { - throw new Error('storage overrides must be an object') - } - - const formatted: StorageOverrides = {} - - for (const [key, value] of Object.entries(overrides)) { - if (utils.isHexString(key, 32)) { - try { - const hash = utils.hexlify(value as any) - if (utils.isHexString(hash, 32)) { - formatted[key] = hash - } - } catch {} - } - } - - return formatted -} - -function skipNullish(formatter: (x: X) => Y): (x?: X | null) => Y | undefined { - return x => { - switch (x) { - case null: - case undefined: - return undefined - - default: - return formatter(x) - } - } -} diff --git a/packages/simulator/src/index.ts b/packages/simulator/src/index.ts deleted file mode 100644 index 2b76aac76..000000000 --- a/packages/simulator/src/index.ts +++ /dev/null @@ -1,2 +0,0 @@ -export * from './geth-call' -export * from './simulate' diff --git a/packages/simulator/src/simulate.ts b/packages/simulator/src/simulate.ts deleted file mode 100644 index e27ba5415..000000000 --- a/packages/simulator/src/simulate.ts +++ /dev/null @@ -1,28 +0,0 @@ -import { BigNumber, providers, utils } from 'ethers' -import { gethCall } from './geth-call' -import { commons } from '@0xsequence/core' - -const simulatorArtifact = require('@0xsequence/wallet-contracts/artifacts/contracts/modules/MainModuleGasEstimation.sol/MainModuleGasEstimation.json') -const simulatorInterface = new utils.Interface(simulatorArtifact.abi) -const simulatorBytecode = simulatorArtifact.deployedBytecode - -export async function simulate( - provider: providers.JsonRpcProvider, - wallet: string, - transactions: commons.transaction.Transaction[], - block?: providers.BlockTag -): Promise { - const encodedTransactions = commons.transaction.sequenceTxAbiEncode(transactions) - const data = simulatorInterface.encodeFunctionData('simulateExecute', [encodedTransactions]) - const transaction = { to: wallet, data } - const overrides = { [wallet]: { code: simulatorBytecode } } - const result = await gethCall(provider, transaction, block, overrides) - return simulatorInterface.decodeFunctionResult('simulateExecute', result)[0] -} - -export interface Result { - executed: boolean - succeeded: boolean - result: string - gasUsed: BigNumber -} diff --git a/packages/simulator/tests/sequence-simulator.spec.ts b/packages/simulator/tests/sequence-simulator.spec.ts deleted file mode 100644 index 875e28c0c..000000000 --- a/packages/simulator/tests/sequence-simulator.spec.ts +++ /dev/null @@ -1,298 +0,0 @@ -import { CallReceiverMock, HookCallerMock } from '@0xsequence/wallet-contracts' -import { LocalRelayer } from '@0xsequence/relayer' -import { ethers } from 'ethers' -import { configureLogger } from '@0xsequence/utils' - -import chaiAsPromised from 'chai-as-promised' -import * as chai from 'chai' - -const CallReceiverMockArtifact = require('@0xsequence/wallet-contracts/artifacts/contracts/mocks/CallReceiverMock.sol/CallReceiverMock.json') - -const { expect } = chai.use(chaiAsPromised) - -configureLogger({ logLevel: 'DEBUG', silence: false }) - -import { SequenceOrchestratorWrapper, Wallet, WalletV2 } from '@0xsequence/wallet' -import { simulate } from '../src' -import { encodeData } from '@0xsequence/wallet/tests/utils' -import { context } from '@0xsequence/tests' -import { commons, v2 } from '@0xsequence/core' -import { Orchestrator } from '@0xsequence/signhub' - -describe('Wallet integration', function () { - let contexts: Awaited> - let provider: ethers.providers.JsonRpcProvider - let signers: ethers.Signer[] - - let relayer: LocalRelayer - let callReceiver: CallReceiverMock - - before(async () => { - const url = 'http://127.0.0.1:10045/' - provider = new ethers.providers.JsonRpcProvider(url) - - signers = new Array(8).fill(0).map((_, i) => provider.getSigner(i)) - - contexts = await context.deploySequenceContexts(signers[0]) - relayer = new LocalRelayer(signers[0]) - - // Deploy call receiver mock - callReceiver = (await new ethers.ContractFactory( - CallReceiverMockArtifact.abi, - CallReceiverMockArtifact.bytecode, - signers[0] - ).deploy({ gasLimit: 1000000 })) as CallReceiverMock - - // Deploy local relayer - relayer = new LocalRelayer({ signer: signers[0] }) - }) - - beforeEach(async () => { - await callReceiver.setRevertFlag(false) - await callReceiver.testCall(0, []) - }) - - describe('estimate gas of transactions', () => { - const options = [ - { - name: 'single signer wallet', - getWallet: async () => { - // const pk = ethers.utils.randomBytes(32) - // const wallet = await Wallet.singleOwner(pk, context) - // return wallet.connect(ethnode.provider, relayer) - const signer = ethers.Wallet.createRandom() - const config = v2.config.ConfigCoder.fromSimple({ - threshold: 1, - checkpoint: 0, - signers: [{ weight: 1, address: signer.address }] - }) - - return Wallet.newWallet({ - context: contexts[2], - coders: v2.coders, - config, - provider, - relayer, - orchestrator: new Orchestrator([signer]), - chainId: provider.network.chainId - }) - } - }, - { - name: 'multiple signers wallet', - getWallet: async () => { - const signers = new Array(4).fill(0).map(() => ethers.Wallet.createRandom()) - const config = v2.config.ConfigCoder.fromSimple({ - threshold: 3, - checkpoint: 0, - signers: signers.map(s => ({ weight: 1, address: s.address })) - }) - - return Wallet.newWallet({ - context: contexts[2], - coders: v2.coders, - config, - provider, - relayer, - orchestrator: new Orchestrator(signers.slice(0, 3)), - chainId: provider.network.chainId - }) - } - }, - { - name: 'many multiple signers wallet', - getWallet: async () => { - const signers = new Array(111).fill(0).map(() => ethers.Wallet.createRandom()) - - const config = v2.config.ConfigCoder.fromSimple({ - threshold: 77, - checkpoint: 0, - signers: signers.map(s => ({ weight: 1, address: s.address })) - }) - - return Wallet.newWallet({ - context: contexts[2], - coders: v2.coders, - config, - provider, - relayer, - orchestrator: new Orchestrator(signers.slice(0, 77)), - chainId: provider.network.chainId - }) - } - }, - { - name: 'nested wallet', - getWallet: async () => { - const EOASigners = new Array(3).fill(0).map(() => ethers.Wallet.createRandom()) - const nestedSigners = await Promise.all( - new Array(2).fill(0).map(async () => { - const signers = new Array(3).fill(0).map(() => ethers.Wallet.createRandom()) - const config = v2.config.ConfigCoder.fromSimple({ - threshold: 2, - checkpoint: 0, - signers: signers.map(s => ({ weight: 1, address: s.address })) - }) - - const wallet = Wallet.newWallet({ - context: contexts[2], - coders: v2.coders, - config, - provider, - relayer, - orchestrator: new Orchestrator(signers.slice(0, 2)), - chainId: provider.network.chainId - }) - - await wallet.deploy() - - return wallet - }) - ) - - const config = v2.config.ConfigCoder.fromSimple({ - threshold: 2, - checkpoint: 0, - signers: [ - ...EOASigners.map(s => ({ weight: 1, address: s.address })), - ...nestedSigners.map(s => ({ weight: 1, address: s.address })) - ] - }) - - return Wallet.newWallet({ - context: contexts[2], - coders: v2.coders, - config, - provider, - relayer, - orchestrator: new Orchestrator([ - ...EOASigners.slice(0, 2), - ...nestedSigners.slice(0, 1).map(s => new SequenceOrchestratorWrapper(s)) - ]), - chainId: provider.network.chainId - }) - } - }, - { - name: 'asymetrical signers wallet', - getWallet: async () => { - const signersA = new Array(5).fill(0).map(() => ethers.Wallet.createRandom()) - const signersB = new Array(6).fill(0).map(() => ethers.Wallet.createRandom()) - - const config = v2.config.ConfigCoder.fromSimple({ - threshold: 5, - checkpoint: 0, - signers: [ - ...signersA.map(s => ({ weight: 1, address: s.address })), - ...signersB.map(s => ({ weight: 10, address: s.address })) - ] - }) - - return Wallet.newWallet({ - context: contexts[2], - coders: v2.coders, - config, - provider, - relayer, - orchestrator: new Orchestrator(signersA), - chainId: provider.network.chainId - }) - } - } - ] - - options.map(o => { - describe(`with ${o.name}`, () => { - let wallet: WalletV2 - - beforeEach(async () => { - wallet = await o.getWallet() - }) - - describe('with deployed wallet', () => { - let txs: commons.transaction.Transaction[] - - beforeEach(async () => { - await callReceiver.testCall(0, []) - await wallet.deploy() - }) - - describe('a single transaction', () => { - beforeEach(async () => { - txs = [ - { - delegateCall: false, - revertOnError: false, - gasLimit: 0, - to: callReceiver.address, - value: ethers.constants.Zero, - data: await encodeData(callReceiver, 'testCall', 14442, '0x112233') - } - ] - }) - - it('should use estimated gas for a single transaction', async () => { - const results = await simulate(provider, wallet.address, txs) - - expect(results).to.have.lengthOf(txs.length) - expect(results.every(result => result.executed)).to.be.true - expect(results.every(result => result.succeeded)).to.be.true - expect(results.every(result => result.gasUsed.gt(0))).to.be.true - }) - - it('should use estimated gas for a single failing transaction', async () => { - await callReceiver.setRevertFlag(true) - - const results = await simulate(provider, wallet.address, txs) - - expect(results).to.have.lengthOf(txs.length) - expect(results.every(result => result.executed)).to.be.true - expect(results.every(result => !result.succeeded)).to.be.true - expect(results.every(result => result.gasUsed.gt(0))).to.be.true - }) - }) - - describe('a batch of transactions', () => { - let valB: Uint8Array - - beforeEach(async () => { - await callReceiver.setRevertFlag(false) - valB = ethers.utils.randomBytes(99) - - txs = [ - { - delegateCall: false, - revertOnError: false, - gasLimit: 0, - to: callReceiver.address, - value: ethers.constants.Zero, - data: await encodeData(callReceiver, 'setRevertFlag', true) - }, - { - delegateCall: false, - revertOnError: false, - gasLimit: 0, - to: callReceiver.address, - value: ethers.constants.Zero, - data: await encodeData(callReceiver, 'testCall', 2, valB) - } - ] - }) - - it('should use estimated gas for a batch of transactions', async () => { - const results = await simulate(provider, wallet.address, txs) - - expect(results).to.have.lengthOf(txs.length) - expect(results[0].executed).to.be.true - expect(results[0].succeeded).to.be.true - expect(results[0].gasUsed.gt(0)).to.be.true - expect(results[1].executed).to.be.true - expect(results[1].succeeded).to.be.false - expect(results[1].gasUsed.gt(0)).to.be.true - }) - }) - }) - }) - }) - }) -}) diff --git a/packages/tests/CHANGELOG.md b/packages/tests/CHANGELOG.md index c916d3382..7e333c0e0 100644 --- a/packages/tests/CHANGELOG.md +++ b/packages/tests/CHANGELOG.md @@ -1,5 +1,503 @@ # @0xsequence/tests +## 2.2.14 + +### Patch Changes + +- Somnia Testnet and Monad Testnet +- Updated dependencies + - @0xsequence/core@2.2.14 + - @0xsequence/utils@2.2.14 + +## 2.2.13 + +### Patch Changes + +- Add XR1 to all networks +- Updated dependencies + - @0xsequence/core@2.2.13 + - @0xsequence/utils@2.2.13 + +## 2.2.12 + +### Patch Changes + +- Add XR1 +- Updated dependencies + - @0xsequence/core@2.2.12 + - @0xsequence/utils@2.2.12 + +## 2.2.11 + +### Patch Changes + +- Relayer updates +- Updated dependencies + - @0xsequence/core@2.2.11 + - @0xsequence/utils@2.2.11 + +## 2.2.10 + +### Patch Changes + +- Etherlink support +- Updated dependencies + - @0xsequence/core@2.2.10 + - @0xsequence/utils@2.2.10 + +## 2.2.9 + +### Patch Changes + +- Indexer gateway native token balances +- Updated dependencies + - @0xsequence/core@2.2.9 + - @0xsequence/utils@2.2.9 + +## 2.2.8 + +### Patch Changes + +- Add Moonbeam and Moonbase Alpha +- Updated dependencies + - @0xsequence/core@2.2.8 + - @0xsequence/utils@2.2.8 + +## 2.2.7 + +### Patch Changes + +- Update Builder package +- Updated dependencies + - @0xsequence/core@2.2.7 + - @0xsequence/utils@2.2.7 + +## 2.2.6 + +### Patch Changes + +- Update relayer package +- Updated dependencies + - @0xsequence/core@2.2.6 + - @0xsequence/utils@2.2.6 + +## 2.2.5 + +### Patch Changes + +- auth: fix sequence indexer gateway url +- account: immutable wallet proxy hook +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.2.5 + - @0xsequence/utils@2.2.5 + +## 2.2.4 + +### Patch Changes + +- network: update soneium mainnet block explorer url +- waas: signTypedData intent support +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.2.4 + - @0xsequence/utils@2.2.4 + +## 2.2.3 + +### Patch Changes + +- provider: updating initWallet to use connected network configs if they exist +- Updated dependencies + - @0xsequence/core@2.2.3 + - @0xsequence/utils@2.2.3 + +## 2.2.2 + +### Patch Changes + +- pass projectAccessKey to relayer at all times +- Updated dependencies + - @0xsequence/core@2.2.2 + - @0xsequence/utils@2.2.2 + +## 2.2.1 + +### Patch Changes + +- waas-ethers: sign typed data +- Updated dependencies + - @0xsequence/core@2.2.1 + - @0xsequence/utils@2.2.1 + +## 2.2.0 + +### Minor Changes + +- indexer: gateway client +- @0xsequence/builder +- upgrade puppeteer to v23.10.3 + +### Patch Changes + +- Updated dependencies +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.2.0 + - @0xsequence/utils@2.2.0 + +## 2.1.8 + +### Patch Changes + +- Add Soneium Mainnet +- Updated dependencies + - @0xsequence/core@2.1.8 + - @0xsequence/utils@2.1.8 + +## 2.1.7 + +### Patch Changes + +- guard: pass project access key to guard requests +- Updated dependencies + - @0xsequence/core@2.1.7 + - @0xsequence/utils@2.1.7 + +## 2.1.6 + +### Patch Changes + +- Add LAOS and Telos Testnet chains +- Updated dependencies + - @0xsequence/core@2.1.6 + - @0xsequence/utils@2.1.6 + +## 2.1.5 + +### Patch Changes + +- account: save presigned configuration with reference chain id 1 +- Updated dependencies + - @0xsequence/core@2.1.5 + - @0xsequence/utils@2.1.5 + +## 2.1.4 + +### Patch Changes + +- provider: pass projectAccessKey into MuxMessageProvider +- Updated dependencies + - @0xsequence/core@2.1.4 + - @0xsequence/utils@2.1.4 + +## 2.1.3 + +### Patch Changes + +- waas: time drift date fix due to strange browser quirk +- Updated dependencies + - @0xsequence/core@2.1.3 + - @0xsequence/utils@2.1.3 + +## 2.1.2 + +### Patch Changes + +- provider: export analytics correctly +- Updated dependencies + - @0xsequence/core@2.1.2 + - @0xsequence/utils@2.1.2 + +## 2.1.1 + +### Patch Changes + +- Add LAOS chain support +- Updated dependencies + - @0xsequence/core@2.1.1 + - @0xsequence/utils@2.1.1 + +## 2.1.0 + +### Minor Changes + +- account: forward project access key when estimating fees and sending transactions + +### Patch Changes + +- sessions: save signatures with reference chain id +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.1.0 + - @0xsequence/utils@2.1.0 + +## 2.0.26 + +### Patch Changes + +- account: fix chain id comparison +- Updated dependencies + - @0xsequence/core@2.0.26 + - @0xsequence/utils@2.0.26 + +## 2.0.25 + +### Patch Changes + +- skale-nebula: deploy gas limit = 10m +- Updated dependencies + - @0xsequence/core@2.0.25 + - @0xsequence/utils@2.0.25 + +## 2.0.24 + +### Patch Changes + +- sessions: arweave: configurable gateway url +- waas: use /status to get time drift before sending any intents +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.0.24 + - @0xsequence/utils@2.0.24 + +## 2.0.23 + +### Patch Changes + +- Add The Root Network support +- Updated dependencies + - @0xsequence/core@2.0.23 + - @0xsequence/utils@2.0.23 + +## 2.0.22 + +### Patch Changes + +- Add SKALE Nebula Mainnet support +- Updated dependencies + - @0xsequence/core@2.0.22 + - @0xsequence/utils@2.0.22 + +## 2.0.21 + +### Patch Changes + +- account: add publishWitnessFor +- Updated dependencies + - @0xsequence/core@2.0.21 + - @0xsequence/utils@2.0.21 + +## 2.0.20 + +### Patch Changes + +- upgrade deps, and improve waas session status handling +- Updated dependencies + - @0xsequence/core@2.0.20 + - @0xsequence/utils@2.0.20 + +## 2.0.19 + +### Patch Changes + +- Add Immutable zkEVM support +- Updated dependencies + - @0xsequence/core@2.0.19 + - @0xsequence/utils@2.0.19 + +## 2.0.18 + +### Patch Changes + +- waas: new contractCall transaction type +- sessions: add arweave owner +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.0.18 + - @0xsequence/utils@2.0.18 + +## 2.0.17 + +### Patch Changes + +- update waas auth to clear session before signIn +- Updated dependencies + - @0xsequence/core@2.0.17 + - @0xsequence/utils@2.0.17 + +## 2.0.16 + +### Patch Changes + +- Removed Astar chains +- Updated dependencies + - @0xsequence/core@2.0.16 + - @0xsequence/utils@2.0.16 + +## 2.0.15 + +### Patch Changes + +- indexer: update bindings with token balance additions +- Updated dependencies + - @0xsequence/core@2.0.15 + - @0xsequence/utils@2.0.15 + +## 2.0.14 + +### Patch Changes + +- sessions: arweave config reader +- network: add b3 and apechain mainnet configs +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.0.14 + - @0xsequence/utils@2.0.14 + +## 2.0.13 + +### Patch Changes + +- network: toy-testnet +- Updated dependencies + - @0xsequence/core@2.0.13 + - @0xsequence/utils@2.0.13 + +## 2.0.12 + +### Patch Changes + +- api: update bindings +- Updated dependencies + - @0xsequence/core@2.0.12 + - @0xsequence/utils@2.0.12 + +## 2.0.11 + +### Patch Changes + +- waas: intents test fix +- api: update bindings +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.0.11 + - @0xsequence/utils@2.0.11 + +## 2.0.10 + +### Patch Changes + +- network: soneium minato testnet +- Updated dependencies + - @0xsequence/core@2.0.10 + - @0xsequence/utils@2.0.10 + +## 2.0.9 + +### Patch Changes + +- network: fix SKALE network name +- Updated dependencies + - @0xsequence/core@2.0.9 + - @0xsequence/utils@2.0.9 + +## 2.0.8 + +### Patch Changes + +- metadata: update bindings +- Updated dependencies + - @0xsequence/core@2.0.8 + - @0xsequence/utils@2.0.8 + +## 2.0.7 + +### Patch Changes + +- wallet request handler fix +- Updated dependencies + - @0xsequence/core@2.0.7 + - @0xsequence/utils@2.0.7 + +## 2.0.6 + +### Patch Changes + +- network: matic -> pol +- Updated dependencies + - @0xsequence/core@2.0.6 + - @0xsequence/utils@2.0.6 + +## 2.0.5 + +### Patch Changes + +- provider: update databeat to 0.9.2 +- Updated dependencies + - @0xsequence/core@2.0.5 + - @0xsequence/utils@2.0.5 + +## 2.0.4 + +### Patch Changes + +- network: add skale-nebula-testnet +- Updated dependencies + - @0xsequence/core@2.0.4 + - @0xsequence/utils@2.0.4 + +## 2.0.3 + +### Patch Changes + +- waas: check session status in SequenceWaaS.isSignedIn() +- Updated dependencies + - @0xsequence/core@2.0.3 + - @0xsequence/utils@2.0.3 + +## 2.0.2 + +### Patch Changes + +- sessions: property convert serialized bignumber hex value to bigint +- Updated dependencies + - @0xsequence/core@2.0.2 + - @0xsequence/utils@2.0.2 + +## 2.0.1 + +### Patch Changes + +- waas: http signature check for authenticator requests +- provider: unwrap legacy json rpc responses +- use json replacer and reviver for bigints +- Updated dependencies +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.0.1 + - @0xsequence/utils@2.0.1 + +## 2.0.0 + +### Major Changes + +- ethers v6 + +### Patch Changes + +- Updated dependencies + - @0xsequence/core@2.0.0 + - @0xsequence/utils@2.0.0 + +## 1.10.15 + +### Patch Changes + +- utils: extractProjectIdFromAccessKey +- Updated dependencies + - @0xsequence/core@1.10.15 + ## 1.10.14 ### Patch Changes diff --git a/packages/tests/package.json b/packages/tests/package.json index c1f464435..f6f0ed810 100644 --- a/packages/tests/package.json +++ b/packages/tests/package.json @@ -1,6 +1,6 @@ { "name": "@0xsequence/tests", - "version": "1.10.14", + "version": "2.2.14", "description": "test tools for sequence.js", "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/tests", "source": "src/index.ts", @@ -11,15 +11,16 @@ "scripts": { "test": "echo 'no tests for test tools'" }, - "dependencies": { - "@0xsequence/core": "workspace:*" - }, "peerDependencies": { - "ethers": ">=5.5" + "ethers": ">=6" + }, + "dependencies": { + "@0xsequence/core": "workspace:*", + "@0xsequence/utils": "workspace:*" }, "devDependencies": { "@istanbuljs/nyc-config-typescript": "^1.0.1", - "ethers": "^5.7.2", + "ethers": "6.13.4", "web3": "^1.8.1" }, "files": [ diff --git a/packages/tests/src/builds/artifact.ts b/packages/tests/src/builds/artifact.ts index b74bbb512..bb210f5e7 100644 --- a/packages/tests/src/builds/artifact.ts +++ b/packages/tests/src/builds/artifact.ts @@ -3,7 +3,7 @@ import { ethers } from 'ethers' export type Artifact = { contractName: string sourceName: string - abi: ethers.ContractInterface + abi: ethers.InterfaceAbi bytecode: string deployedBytecode: string } diff --git a/packages/tests/src/configs/random.ts b/packages/tests/src/configs/random.ts index e25d84129..32188e8cd 100644 --- a/packages/tests/src/configs/random.ts +++ b/packages/tests/src/configs/random.ts @@ -1,17 +1,17 @@ import { v1, v2 } from '@0xsequence/core' import { ethers } from 'ethers' -import { maxForBits, randomBigNumber, randomBool } from '../utils' +import { maxForBits, randomBigInt, randomBool } from '../utils' export function genRandomV1Config( - threshold: ethers.BigNumberish = randomBigNumber(0, maxForBits(16)), - numSigners: ethers.BigNumberish = randomBigNumber(1, 24) + threshold: ethers.BigNumberish = randomBigInt(0, maxForBits(16)), + numSigners: ethers.BigNumberish = randomBigInt(1, 24) ): v1.config.WalletConfig { const signers: v1.config.AddressMember[] = [] - for (let i = ethers.constants.Zero; i.lt(numSigners); i = i.add(1)) { + for (let i = 0n; i < BigInt(numSigners); i++) { signers.push({ address: ethers.Wallet.createRandom().address, - weight: randomBigNumber(0, maxForBits(8)) + weight: randomBigInt(0, maxForBits(8)) }) } @@ -19,24 +19,24 @@ export function genRandomV1Config( } export function genRandomV2Config( - threshold: ethers.BigNumberish = randomBigNumber(0, maxForBits(16)), - checkpoint: ethers.BigNumberish = randomBigNumber(0, maxForBits(32)), - numSigners: ethers.BigNumberish = randomBigNumber(1, 24), - numSubdigests: ethers.BigNumberish = randomBigNumber(0, 24), + threshold: ethers.BigNumberish = randomBigInt(0, maxForBits(16)), + checkpoint: ethers.BigNumberish = randomBigInt(0, maxForBits(32)), + numSigners: ethers.BigNumberish = randomBigInt(1, 24), + numSubdigests: ethers.BigNumberish = randomBigInt(0, 24), useMerkleTopology: boolean = randomBool() ): v2.config.WalletConfig { const signers: v2.config.SignerLeaf[] = [] - for (let i = ethers.constants.Zero; i.lt(numSigners); i = i.add(1)) { + for (let i = 0n; i < BigInt(numSigners); i++) { signers.push({ address: ethers.Wallet.createRandom().address, - weight: randomBigNumber(0, maxForBits(8)) + weight: randomBigInt(0, maxForBits(8)) }) } const subdigests: v2.config.SubdigestLeaf[] = [] - for (let i = ethers.constants.Zero; i.lt(numSubdigests); i = i.add(1)) { + for (let i = 0n; i < BigInt(numSubdigests); i++) { subdigests.push({ - subdigest: ethers.utils.hexlify(ethers.utils.randomBytes(32)) + subdigest: ethers.hexlify(ethers.randomBytes(32)) }) } diff --git a/packages/tests/src/context/index.ts b/packages/tests/src/context/index.ts index bbf4f864e..b08d1617b 100644 --- a/packages/tests/src/context/index.ts +++ b/packages/tests/src/context/index.ts @@ -2,10 +2,19 @@ import { ethers } from 'ethers' import { deployV1Context } from './v1' import { deployV2Context } from './v2' +import { commons } from '@0xsequence/core' -export async function deploySequenceContexts(signer: ethers.Signer) { +export async function deploySequenceContexts(signer: ethers.Signer): Promise { + const { chainId } = await signer.provider!.getNetwork() + + console.time(`[${chainId}] [v1]: Finished in`) const v1 = await deployV1Context(signer) + console.timeEnd(`[${chainId}] [v1]: Finished in`) + + console.time(`[${chainId}] [v2]: Finished in`) const v2 = await deployV2Context(signer) + console.timeEnd(`[${chainId}] [v2]: Finished in`) + return { 1: v1, 2: v2 } } diff --git a/packages/tests/src/context/v1.ts b/packages/tests/src/context/v1.ts index cce948bbd..da29503fc 100644 --- a/packages/tests/src/context/v1.ts +++ b/packages/tests/src/context/v1.ts @@ -1,5 +1,7 @@ import { ethers } from 'ethers' import { isContract } from '../utils' +import { parseEther } from '@0xsequence/utils' +import { v1 } from '@0xsequence/core' // These are the Sequence v1 contracts // we use them if they are available @@ -11,15 +13,9 @@ const predefinedAddresses = { multiCallUtils: '0xd130B43062D875a4B7aF3f8fc036Bc6e9D3E1B3E' } -export async function deployV1Context(signer: ethers.Signer): Promise<{ - version: 1 - factory: string - mainModule: string - mainModuleUpgradable: string - guestModule: string - multiCallUtils: string - walletCreationCode: string -}> { +export async function deployV1Context(signer: ethers.Signer): Promise { + const { chainId } = await signer.provider!.getNetwork() + // See if signer's provider has the contracts already deployed const provider = signer.provider if (!provider) { @@ -29,8 +25,6 @@ export async function deployV1Context(signer: ethers.Signer): Promise<{ if ( await Promise.all(Object.values(predefinedAddresses).map(address => isContract(provider, address))).then(r => r.every(x => x)) ) { - console.log('Using predefined addresses for V1 contracts') - return { version: 1, @@ -44,60 +38,81 @@ export async function deployV1Context(signer: ethers.Signer): Promise<{ } } - console.log('Predefined addresses for V1 contracts not found, deploying new ones') + console.log(`[${chainId}] [v1]: Deploying context...`) + + const responses: ethers.TransactionResponse[] = [] // Try deploying the v1 contracts using the v1 singleton factory - await signer.sendTransaction({ - to: '0x9c5a87452d4FAC0cbd53BDCA580b20A45526B3AB', - value: ethers.utils.parseEther('0.02170000000014'), - gasLimit: 8000000 - }) - - await signer.provider?.sendTransaction( - '0xf9010880852416b84e01830222e08080b8b66080604052348015600f57600080fd5b50609980601d6000396000f3fe60a06020601f369081018290049091028201604052608081815260009260609284918190838280828437600092018290525084519495509392505060208401905034f5604080516001600160a01b0383168152905191935081900360200190a0505000fea26469706673582212205a310755225e3c740b2f013fb6343f4c205e7141fcdf15947f5f0e0e818727fb64736f6c634300060a00331ca01820182018201820182018201820182018201820182018201820182018201820a01820182018201820182018201820182018201820182018201820182018201820' + responses.push( + await signer.sendTransaction({ + to: '0x9c5a87452d4FAC0cbd53BDCA580b20A45526B3AB', + value: parseEther('0.02170000000014'), + gasLimit: 8000000 + }) + ) + + responses.push( + await provider.broadcastTransaction( + '0xf9010880852416b84e01830222e08080b8b66080604052348015600f57600080fd5b50609980601d6000396000f3fe60a06020601f369081018290049091028201604052608081815260009260609284918190838280828437600092018290525084519495509392505060208401905034f5604080516001600160a01b0383168152905191935081900360200190a0505000fea26469706673582212205a310755225e3c740b2f013fb6343f4c205e7141fcdf15947f5f0e0e818727fb64736f6c634300060a00331ca01820182018201820182018201820182018201820182018201820182018201820a01820182018201820182018201820182018201820182018201820182018201820' + ) ) // Deploy universal deployer - await signer.sendTransaction({ - to: '0x1b926fbb24a9f78dcdd3272f2d86f5d0660e59c0', - data: '0x608060405234801561001057600080fd5b5061013d806100206000396000f3fe60806040526004361061001e5760003560e01c80639c4ae2d014610023575b600080fd5b6100cb6004803603604081101561003957600080fd5b81019060208101813564010000000081111561005457600080fd5b82018360208201111561006657600080fd5b8035906020019184600183028401116401000000008311171561008857600080fd5b91908080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525092955050913592506100cd915050565b005b60008183516020850134f56040805173ffffffffffffffffffffffffffffffffffffffff83168152905191925081900360200190a050505056fea264697066735822122033609f614f03931b92d88c309d698449bb77efcd517328d341fa4f923c5d8c7964736f6c63430007060033', - gasLimit: 8000000 - }) + responses.push( + await signer.sendTransaction({ + to: '0x1b926fbb24a9f78dcdd3272f2d86f5d0660e59c0', + data: '0x608060405234801561001057600080fd5b5061013d806100206000396000f3fe60806040526004361061001e5760003560e01c80639c4ae2d014610023575b600080fd5b6100cb6004803603604081101561003957600080fd5b81019060208101813564010000000081111561005457600080fd5b82018360208201111561006657600080fd5b8035906020019184600183028401116401000000008311171561008857600080fd5b91908080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525092955050913592506100cd915050565b005b60008183516020850134f56040805173ffffffffffffffffffffffffffffffffffffffff83168152905191925081900360200190a050505056fea264697066735822122033609f614f03931b92d88c309d698449bb77efcd517328d341fa4f923c5d8c7964736f6c63430007060033', + gasLimit: 8000000 + }) + ) // Deploy factory - await signer.sendTransaction({ - to: '0x8a5bc19e22d6ad55a2c763b93a75d09f321fe764', - data: '0x9c4ae2d00000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001e8608060405234801561001057600080fd5b506101c8806100206000396000f3fe60806040526004361061001e5760003560e01c806332c02a1414610023575b600080fd5b61005c6004803603604081101561003957600080fd5b5073ffffffffffffffffffffffffffffffffffffffff8135169060200135610085565b6040805173ffffffffffffffffffffffffffffffffffffffff9092168252519081900360200190f35b60008060405180606001604052806028815260200161016b602891398473ffffffffffffffffffffffffffffffffffffffff166040516020018083805190602001908083835b6020831061010857805182527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe090920191602091820191016100cb565b51815160209384036101000a7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0180199092169116179052920193845250604080518085038152938201905282519294508693508401905034f594935050505056fe603a600e3d39601a805130553df3363d3d373d3d3d363d30545af43d82803e903d91601857fd5bf3a26469706673582212209b0bce93afab3297b9ebf4e58fa642ef123d74bcbd3bdb4e48b662eb12b430ca64736f6c63430007060033000000000000000000000000000000000000000000000000', - gasLimit: 8000000 - }) + responses.push( + await signer.sendTransaction({ + to: '0x8a5bc19e22d6ad55a2c763b93a75d09f321fe764', + data: '0x9c4ae2d00000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001e8608060405234801561001057600080fd5b506101c8806100206000396000f3fe60806040526004361061001e5760003560e01c806332c02a1414610023575b600080fd5b61005c6004803603604081101561003957600080fd5b5073ffffffffffffffffffffffffffffffffffffffff8135169060200135610085565b6040805173ffffffffffffffffffffffffffffffffffffffff9092168252519081900360200190f35b60008060405180606001604052806028815260200161016b602891398473ffffffffffffffffffffffffffffffffffffffff166040516020018083805190602001908083835b6020831061010857805182527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe090920191602091820191016100cb565b51815160209384036101000a7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0180199092169116179052920193845250604080518085038152938201905282519294508693508401905034f594935050505056fe603a600e3d39601a805130553df3363d3d373d3d3d363d30545af43d82803e903d91601857fd5bf3a26469706673582212209b0bce93afab3297b9ebf4e58fa642ef123d74bcbd3bdb4e48b662eb12b430ca64736f6c63430007060033000000000000000000000000000000000000000000000000', + gasLimit: 8000000 + }) + ) // Deploy mainModule - await signer.sendTransaction({ - to: '0x8a5bc19e22d6ad55a2c763b93a75d09f321fe764', - data: '0x9c4ae2d0000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002d8360c06040523480156200001157600080fd5b5060405162002d6338038062002d638339810160408190526200003491620000e2565b80600060405180606001604052806028815260200162002d3b60289139306001600160a01b03166040516020018083805190602001908083835b602083106200008f5780518252601f1990920191602091820191016200006e565b51815160209384036101000a60001901801990921691161790529201938452506040805180850381529382019052825192019190912060805250505060601b6001600160601b03191660a0525062000112565b600060208284031215620000f4578081fd5b81516001600160a01b03811681146200010b578182fd5b9392505050565b60805160a05160601c612bf862000143600039806106d55280611baa5250806106b15280611bdb5250612bf86000f3fe6080604052600436106101125760003560e01c80634fcf3eca116100a557806390042baf11610074578063b93ea7ad11610059578063b93ea7ad146103c5578063bc197c81146103e5578063f23a6e611461040557610119565b806390042baf1461039d578063affed0e0146103b057610119565b80634fcf3eca1461031d57806361c2926c1461033d5780637a9a16281461035d5780638c3f55631461037d57610119565b80631a9b2337116100e15780631a9b23371461029957806320c13b0b146102c6578063257671f5146102e65780632dd310001461030857610119565b806301ffc9a7146101f4578063025b22bc1461022a578063150b7a021461024c5780631626ba7e1461027957610119565b3661011957005b60006101486000357fffffffff0000000000000000000000000000000000000000000000000000000016610425565b905073ffffffffffffffffffffffffffffffffffffffff8116156101f1576000808273ffffffffffffffffffffffffffffffffffffffff166000366040518083838082843760405192019450600093509091505080830381855af49150503d80600081146101d2576040519150601f19603f3d011682016040523d82523d6000602084013e6101d7565b606091505b5091509150816101e957805160208201fd5b805160208201f35b50005b34801561020057600080fd5b5061021461020f366004612401565b61047b565b6040516102219190612633565b60405180910390f35b34801561023657600080fd5b5061024a610245366004612166565b610486565b005b34801561025857600080fd5b5061026c610267366004612237565b6105a7565b6040516102219190612660565b34801561028557600080fd5b5061026c6102943660046123b7565b6105d1565b3480156102a557600080fd5b506102b96102b4366004612401565b61064a565b6040516102219190612612565b3480156102d257600080fd5b5061026c6102e136600461244d565b610655565b3480156102f257600080fd5b506102fb6106af565b604051610221919061263e565b34801561031457600080fd5b506102b96106d3565b34801561032957600080fd5b5061024a610338366004612401565b6106f7565b34801561034957600080fd5b5061024a61035836600461231a565b6107d5565b34801561036957600080fd5b5061024a61037836600461234d565b61086e565b34801561038957600080fd5b506102fb6103983660046124e9565b6108ea565b6102b96103ab3660046124b6565b610916565b3480156103bc57600080fd5b506102fb6109ca565b3480156103d157600080fd5b5061024a6103e036600461241b565b6109db565b3480156103f157600080fd5b5061026c610400366004612180565b610ab4565b34801561041157600080fd5b5061026c6104203660046122a4565b610ae1565b60006104737fbe27a319efc8734e89e26ba4bc95f5c788584163b959f03fa04e2d7ab4b9a1207fffffffff000000000000000000000000000000000000000000000000000000008416610b0c565b90505b919050565b600061047382610b39565b3330146104de576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526027815260200180612b9c6027913960400191505060405180910390fd5b6104fd8173ffffffffffffffffffffffffffffffffffffffff16610b96565b610552576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526039815260200180612a826039913960400191505060405180910390fd5b61055b81610b9c565b6040805173ffffffffffffffffffffffffffffffffffffffff8316815290517f310ba5f1d2ed074b51e2eccd052a47ae9ab7c6b800d1fca3db3999d6a592ca039181900360200190a150565b7f150b7a020000000000000000000000000000000000000000000000000000000095945050505050565b600061061b6105df85610ba0565b84848080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250610c0092505050565b1561064357507f1626ba7e000000000000000000000000000000000000000000000000000000005b9392505050565b600061047382610425565b600061067f6105df86866040518083838082843760405192018290039091209350610ba092505050565b156106a757507f20c13b0b000000000000000000000000000000000000000000000000000000005b949350505050565b7f000000000000000000000000000000000000000000000000000000000000000081565b7f000000000000000000000000000000000000000000000000000000000000000081565b33301461074f576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526027815260200180612b9c6027913960400191505060405180910390fd5b600061075a82610425565b73ffffffffffffffffffffffffffffffffffffffff1614156107c7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602b8152602001806128e0602b913960400191505060405180910390fd5b6107d2816000610df8565b50565b33301461082d576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526027815260200180612b9c6027913960400191505060405180910390fd5b600061085e82604051602001610843919061277e565b60405160208183030381529060405280519060200120610ba0565b905061086a8183610e5b565b5050565b6108778261102a565b600061088f83856040516020016108439291906127c5565b905061089b8183610c00565b6108da576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016108d190612721565b60405180910390fd5b6108e48185610e5b565b50505050565b60006104737f8d0bf1fd623d628c741362c1289948e57b3e2905218c676d3e69abee36d6ae2e83610b0c565b6000333014610970576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526027815260200180612b9c6027913960400191505060405180910390fd5b81516020830134f06040805173ffffffffffffffffffffffffffffffffffffffff8316815290519192507fa506ad4e7f05eceba62a023c3219e5bd98a615f4fa87e2afb08a2da5cf62bf0c919081900360200190a1919050565b60006109d660006108ea565b905090565b333014610a33576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526027815260200180612b9c6027913960400191505060405180910390fd5b6000610a3e83610425565b73ffffffffffffffffffffffffffffffffffffffff1614610aaa576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602c8152602001806129f4602c913960400191505060405180910390fd5b61086a8282610df8565b7fbc197c810000000000000000000000000000000000000000000000000000000098975050505050505050565b7ff23a6e61000000000000000000000000000000000000000000000000000000009695505050505050565b60408051602080820194909452808201929092528051808303820181526060909201905280519101205490565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f90042baf000000000000000000000000000000000000000000000000000000001415610b8d57506001610476565b610473826110ce565b3b151590565b3055565b604080517f19010000000000000000000000000000000000000000000000000000000000006020808301919091524660228301523060601b6042830152605680830194909452825180830390940184526076909101909152815191012090565b6000806000610c0e8461120f565b909250905061ffff821660005b8551831015610dd55760008080610c32898761127d565b975060ff91821694501691506001831415610c5a57610c5189876112fe565b96509050610d7e565b82610c86576060610c6b8a88611376565b97509050610c798b82611427565b9150828501945050610d7e565b6002831415610d2d57610c9989876112fe565b965090506000610ca98a886117b1565b975061ffff1690506060610cbe8b8984611822565b98509050610ccd8c8483611911565b610d22576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260328152602001806129c26032913960400191505060405180910390fd5b505092810192610d7e565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602c8152602001806128b4602c913960400191505060405180910390fd5b848282604051602001808481526020018381526020018273ffffffffffffffffffffffffffffffffffffffff1681526020019350505050604051602081830303815290604052805190602001209450505050610c1b565b8361ffff168110158015610ded5750610ded82611b59565b979650505050505050565b61086a7fbe27a319efc8734e89e26ba4bc95f5c788584163b959f03fa04e2d7ab4b9a1207fffffffff00000000000000000000000000000000000000000000000000000000841673ffffffffffffffffffffffffffffffffffffffff8416611c37565b60005b8151811015611025576000828281518110610e7557fe5b602002602001015190506000606082604001515a1015610ec1576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016108d1906126c4565b825115610f5957826060015173ffffffffffffffffffffffffffffffffffffffff168360400151600014610ef9578360400151610efb565b5a5b8460a00151604051610f0d91906125f6565b6000604051808303818686f4925050503d8060008114610f49576040519150601f19603f3d011682016040523d82523d6000602084013e610f4e565b606091505b509092509050610fee565b826060015173ffffffffffffffffffffffffffffffffffffffff1683608001518460400151600014610f8f578460400151610f91565b5a5b908560a00151604051610fa491906125f6565b600060405180830381858888f193505050503d8060008114610fe2576040519150601f19603f3d011682016040523d82523d6000602084013e610fe7565b606091505b5090925090505b811561100f5785604051611002919061263e565b60405180910390a061101a565b61101a838783611c65565b505050600101610e5e565b505050565b60008061103683611cb5565b915091506000611045836108ea565b9050808214611080576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016108d19061268d565b6001820161108e8482611cce565b7f1f180c27086c7a39ea2a7b25239d1ab92348f07ca7bb59d1438fcf527568f88184826040516110bf9291906127de565b60405180910390a15050505050565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167fec6aba5000000000000000000000000000000000000000000000000000000000148061116157507fffffffff0000000000000000000000000000000000000000000000000000000082167f4e2312e000000000000000000000000000000000000000000000000000000000145b806111ad57507fffffffff0000000000000000000000000000000000000000000000000000000082167f150b7a0200000000000000000000000000000000000000000000000000000000145b806111f957507fffffffff0000000000000000000000000000000000000000000000000000000082167fc0ee0b8a00000000000000000000000000000000000000000000000000000000145b1561120657506001610476565b61047382611cf9565b6020810151815160f09190911c90600290811115611278576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602781526020018061292e6027913960400191505060405180910390fd5b915091565b8082016020015160f881901c9060f01c60ff166002830183811161129d57fe5b84518111156112f7576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526026815260200180612af76026913960400191505060405180910390fd5b9250925092565b8082016020015160601c6014820182811161131557fe5b835181111561136f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602381526020018061290b6023913960400191505060405180910390fd5b9250929050565b6040805160428082526080820190925260609160009190602082018180368337019050509150828401602001805160208401526020810151604084015260228101516042840152506042830190508281116113cd57fe5b835181111561136f576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526023815260200180612a5f6023913960400191505060405180910390fd5b60008151604214611483576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603a81526020018061287a603a913960400191505060405180910390fd5b60008260018451038151811061149557fe5b602001015160f81c60f81b60f81c60ff1690506000836040815181106114b757fe5b016020015160f81c905060006114cd8582611d56565b905060006114dc866020611d56565b90507f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a0811115611557576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603d81526020018061283d603d913960400191505060405180910390fd5b8260ff16601b1415801561156f57508260ff16601c14155b156115c5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603d815260200180612955603d913960400191505060405180910390fd5b60018414156116395760018784848460405160008152602001604052604051808581526020018460ff1681526020018381526020018281526020019450505050506020604051602081039080840390855afa158015611628573d6000803e3d6000fd5b50505060206040510351945061173b565b60028414156116ea5760018760405160200180807f19457468657265756d205369676e6564204d6573736167653a0a333200000000815250601c018281526020019150506040516020818303038152906040528051906020012084848460405160008152602001604052604051808581526020018460ff1681526020018381526020018281526020019450505050506020604051602081039080840390855afa158015611628573d6000803e3d6000fd5b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603c815260200180612abb603c913960400191505060405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff85166117a7576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260308152602001806129926030913960400191505060405180910390fd5b5050505092915050565b8082016020015160f01c600282018281116117c857fe5b835181111561136f576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526022815260200180612b3e6022913960400191505060405180910390fd5b606060008267ffffffffffffffff8111801561183d57600080fd5b506040519080825280601f01601f191660200182016040528015611868576020820181803683370190505b509150838501602001600060205b8581101561188f57908201518482015260208101611876565b84860160200180519390920151908501525250828201838110156118af57fe5b8451811115611909576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526021815260200180612b1d6021913960400191505060405180910390fd5b935093915050565b6000808260018451038151811061192457fe5b016020015160f81c9050600181148061193d5750600281145b15611981578373ffffffffffffffffffffffffffffffffffffffff166119638685611427565b73ffffffffffffffffffffffffffffffffffffffff16149150611b51565b6003811415611b005782517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81018452604080517f1626ba7e000000000000000000000000000000000000000000000000000000008152600481018881526024820192835286516044830152865173ffffffffffffffffffffffffffffffffffffffff891693631626ba7e938b938a9390929160640190602085019080838360005b83811015611a3b578181015183820152602001611a23565b50505050905090810190601f168015611a685780820380516001836020036101000a031916815260200191505b50935050505060206040518083038186803b158015611a8657600080fd5b505afa158015611a9a573d6000803e3d6000fd5b505050506040513d6020811015611ab057600080fd5b50519084527fffffffff00000000000000000000000000000000000000000000000000000000167f1626ba7e00000000000000000000000000000000000000000000000000000000149150611b51565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603f815260200180612a20603f913960400191505060405180910390fd5b509392505050565b604080517fff000000000000000000000000000000000000000000000000000000000000006020808301919091527fffffffffffffffffffffffffffffffffffffffff0000000000000000000000007f000000000000000000000000000000000000000000000000000000000000000060601b166021830152603582018490527f0000000000000000000000000000000000000000000000000000000000000000605580840191909152835180840390910181526075909201909252805191012073ffffffffffffffffffffffffffffffffffffffff163014919050565b6040805160208082019590955280820193909352805180840382018152606090930190528151919092012055565b826020015115611c7757805160208201fd5b7f3dbd1590ea96dd3253a91f24e64e3a502e1225d602a5731357bc12643070ccd78282604051611ca8929190612647565b60405180910390a1505050565b606081901c916bffffffffffffffffffffffff90911690565b61086a7f8d0bf1fd623d628c741362c1289948e57b3e2905218c676d3e69abee36d6ae2e8383611c37565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f025b22bc000000000000000000000000000000000000000000000000000000001415611d4d57506001610476565b61047382611dbe565b60008160200183511015611db5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603c815260200180612b60603c913960400191505060405180910390fd5b50016020015190565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f389901c7000000000000000000000000000000000000000000000000000000001415611e1257506001610476565b6104738260007fffffffff0000000000000000000000000000000000000000000000000000000082161580611e8857507fffffffff0000000000000000000000000000000000000000000000000000000082167f36e7817500000000000000000000000000000000000000000000000000000000145b15611e9557506001610476565b7f01ffc9a7000000000000000000000000000000000000000000000000000000007fffffffff00000000000000000000000000000000000000000000000000000000831614610473565b803573ffffffffffffffffffffffffffffffffffffffff8116811461047657600080fd5b600082601f830112611f13578081fd5b8135602067ffffffffffffffff80831115611f2a57fe5b611f3782838502016127ec565b83815282810190868401865b86811015612013578135890160c0807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0838e03011215611f8157898afd5b604080518281018181108a82111715611f9657fe5b8252611fa3848b01612063565b8152611fb0828501612063565b8a8201526060808501358383015260809250611fcd838601611edf565b9082015260a08481013583830152928401359289841115611fec578c8dfd5b611ffa8f8c868801016120e3565b9082015287525050509285019290850190600101611f43565b509098975050505050505050565b60008083601f840112612032578182fd5b50813567ffffffffffffffff811115612049578182fd5b602083019150836020808302850101111561136f57600080fd5b8035801515811461047657600080fd5b80357fffffffff000000000000000000000000000000000000000000000000000000008116811461047657600080fd5b60008083601f8401126120b4578182fd5b50813567ffffffffffffffff8111156120cb578182fd5b60208301915083602082850101111561136f57600080fd5b600082601f8301126120f3578081fd5b813567ffffffffffffffff81111561210757fe5b61213860207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116016127ec565b81815284602083860101111561214c578283fd5b816020850160208301379081016020019190915292915050565b600060208284031215612177578081fd5b61064382611edf565b60008060008060008060008060a0898b03121561219b578384fd5b6121a489611edf565b97506121b260208a01611edf565b9650604089013567ffffffffffffffff808211156121ce578586fd5b6121da8c838d01612021565b909850965060608b01359150808211156121f2578586fd5b6121fe8c838d01612021565b909650945060808b0135915080821115612216578384fd5b506122238b828c016120a3565b999c989b5096995094979396929594505050565b60008060008060006080868803121561224e578081fd5b61225786611edf565b945061226560208701611edf565b935060408601359250606086013567ffffffffffffffff811115612287578182fd5b612293888289016120a3565b969995985093965092949392505050565b60008060008060008060a087890312156122bc578182fd5b6122c587611edf565b95506122d360208801611edf565b94506040870135935060608701359250608087013567ffffffffffffffff8111156122fc578283fd5b61230889828a016120a3565b979a9699509497509295939492505050565b60006020828403121561232b578081fd5b813567ffffffffffffffff811115612341578182fd5b6106a784828501611f03565b600080600060608486031215612361578283fd5b833567ffffffffffffffff80821115612378578485fd5b61238487838801611f03565b94506020860135935060408601359150808211156123a0578283fd5b506123ad868287016120e3565b9150509250925092565b6000806000604084860312156123cb578283fd5b83359250602084013567ffffffffffffffff8111156123e8578283fd5b6123f4868287016120a3565b9497909650939450505050565b600060208284031215612412578081fd5b61064382612073565b6000806040838503121561242d578182fd5b61243683612073565b915061244460208401611edf565b90509250929050565b60008060008060408587031215612462578182fd5b843567ffffffffffffffff80821115612479578384fd5b612485888389016120a3565b9096509450602087013591508082111561249d578384fd5b506124aa878288016120a3565b95989497509550505050565b6000602082840312156124c7578081fd5b813567ffffffffffffffff8111156124dd578182fd5b6106a7848285016120e3565b6000602082840312156124fa578081fd5b5035919050565b6000815180845260208085018081965082840281019150828601855b8581101561259f5782840389528151805115158552858101511515868601526040808201519086015260608082015173ffffffffffffffffffffffffffffffffffffffff16908601526080808201519086015260a09081015160c09186018290529061258b818701836125ac565b9a87019a955050509084019060010161251d565b5091979650505050505050565b600081518084526125c4816020860160208601612810565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60008251612608818460208701612810565b9190910192915050565b73ffffffffffffffffffffffffffffffffffffffff91909116815260200190565b901515815260200190565b90815260200190565b6000838252604060208301526106a760408301846125ac565b7fffffffff0000000000000000000000000000000000000000000000000000000091909116815260200190565b6020808252601f908201527f4d61696e4d6f64756c65235f617574683a20494e56414c49445f4e4f4e434500604082015260600190565b60208082526024908201527f4d6f64756c6543616c6c73235f657865637574653a204e4f545f454e4f55474860408201527f5f47415300000000000000000000000000000000000000000000000000000000606082015260800190565b60208082526026908201527f4d6f64756c6543616c6c7323657865637574653a20494e56414c49445f53494760408201527f4e41545552450000000000000000000000000000000000000000000000000000606082015260800190565b600060408252600560408301527f73656c663a0000000000000000000000000000000000000000000000000000006060830152608060208301526106436080830184612501565b6000838252604060208301526106a76040830184612501565b918252602082015260400190565b60405181810167ffffffffffffffff8111828210171561280857fe5b604052919050565b60005b8381101561282b578181015183820152602001612813565b838111156108e4575050600091015256fe5369676e617475726556616c696461746f72237265636f7665725369676e65723a20696e76616c6964207369676e6174757265202773272076616c75655369676e617475726556616c696461746f72237265636f7665725369676e65723a20696e76616c6964207369676e6174757265206c656e6774684d6f64756c6541757468235f7369676e617475726556616c69646174696f6e20494e56414c49445f464c41474d6f64756c65486f6f6b732372656d6f7665486f6f6b3a20484f4f4b5f4e4f545f524547495354455245444c696242797465732372656164416464726573733a204f55545f4f465f424f554e44534c696242797465732372656164466972737455696e7431363a204f55545f4f465f424f554e44535369676e617475726556616c696461746f72237265636f7665725369676e65723a20696e76616c6964207369676e6174757265202776272076616c75655369676e617475726556616c696461746f72237265636f7665725369676e65723a20494e56414c49445f5349474e45524d6f64756c6541757468235f7369676e617475726556616c69646174696f6e3a20494e56414c49445f5349474e41545552454d6f64756c65486f6f6b7323616464486f6f6b3a20484f4f4b5f414c52454144595f524547495354455245445369676e617475726556616c696461746f7223697356616c69645369676e61747572653a20554e535550504f525445445f5349474e41545552455f545950454c696242797465732372656164427974657336363a204f55545f4f465f424f554e44534d6f64756c6555706461746523757064617465496d706c656d656e746174696f6e3a20494e56414c49445f494d504c454d454e544154494f4e5369676e617475726556616c696461746f72237265636f7665725369676e65723a20554e535550504f525445445f5349474e41545552455f545950454c69624279746573237265616455696e743855696e74383a204f55545f4f465f424f554e44534c69624279746573237265616442797465733a204f55545f4f465f424f554e44534c69624279746573237265616455696e7431363a204f55545f4f465f424f554e44534c696242797465732372656164427974657333323a20475245415445525f4f525f455155414c5f544f5f33325f4c454e4754485f52455155495245444d6f64756c6553656c6641757468236f6e6c7953656c663a204e4f545f415554484f52495a4544a2646970667358221220b34deca9dd75815e4ef8a9279e45750ec5554b22c673e160bdba849d80f5888564736f6c63430007060033603a600e3d39601a805130553df3363d3d373d3d3d363d30545af43d82803e903d91601857fd5bf3000000000000000000000000f9d09d634fb818b05149329c1dccfaea53639d960000000000000000000000000000000000000000000000000000000000', - gasLimit: 8000000 - }) + responses.push( + await signer.sendTransaction({ + to: '0x8a5bc19e22d6ad55a2c763b93a75d09f321fe764', + data: '0x9c4ae2d0000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002d8360c06040523480156200001157600080fd5b5060405162002d6338038062002d638339810160408190526200003491620000e2565b80600060405180606001604052806028815260200162002d3b60289139306001600160a01b03166040516020018083805190602001908083835b602083106200008f5780518252601f1990920191602091820191016200006e565b51815160209384036101000a60001901801990921691161790529201938452506040805180850381529382019052825192019190912060805250505060601b6001600160601b03191660a0525062000112565b600060208284031215620000f4578081fd5b81516001600160a01b03811681146200010b578182fd5b9392505050565b60805160a05160601c612bf862000143600039806106d55280611baa5250806106b15280611bdb5250612bf86000f3fe6080604052600436106101125760003560e01c80634fcf3eca116100a557806390042baf11610074578063b93ea7ad11610059578063b93ea7ad146103c5578063bc197c81146103e5578063f23a6e611461040557610119565b806390042baf1461039d578063affed0e0146103b057610119565b80634fcf3eca1461031d57806361c2926c1461033d5780637a9a16281461035d5780638c3f55631461037d57610119565b80631a9b2337116100e15780631a9b23371461029957806320c13b0b146102c6578063257671f5146102e65780632dd310001461030857610119565b806301ffc9a7146101f4578063025b22bc1461022a578063150b7a021461024c5780631626ba7e1461027957610119565b3661011957005b60006101486000357fffffffff0000000000000000000000000000000000000000000000000000000016610425565b905073ffffffffffffffffffffffffffffffffffffffff8116156101f1576000808273ffffffffffffffffffffffffffffffffffffffff166000366040518083838082843760405192019450600093509091505080830381855af49150503d80600081146101d2576040519150601f19603f3d011682016040523d82523d6000602084013e6101d7565b606091505b5091509150816101e957805160208201fd5b805160208201f35b50005b34801561020057600080fd5b5061021461020f366004612401565b61047b565b6040516102219190612633565b60405180910390f35b34801561023657600080fd5b5061024a610245366004612166565b610486565b005b34801561025857600080fd5b5061026c610267366004612237565b6105a7565b6040516102219190612660565b34801561028557600080fd5b5061026c6102943660046123b7565b6105d1565b3480156102a557600080fd5b506102b96102b4366004612401565b61064a565b6040516102219190612612565b3480156102d257600080fd5b5061026c6102e136600461244d565b610655565b3480156102f257600080fd5b506102fb6106af565b604051610221919061263e565b34801561031457600080fd5b506102b96106d3565b34801561032957600080fd5b5061024a610338366004612401565b6106f7565b34801561034957600080fd5b5061024a61035836600461231a565b6107d5565b34801561036957600080fd5b5061024a61037836600461234d565b61086e565b34801561038957600080fd5b506102fb6103983660046124e9565b6108ea565b6102b96103ab3660046124b6565b610916565b3480156103bc57600080fd5b506102fb6109ca565b3480156103d157600080fd5b5061024a6103e036600461241b565b6109db565b3480156103f157600080fd5b5061026c610400366004612180565b610ab4565b34801561041157600080fd5b5061026c6104203660046122a4565b610ae1565b60006104737fbe27a319efc8734e89e26ba4bc95f5c788584163b959f03fa04e2d7ab4b9a1207fffffffff000000000000000000000000000000000000000000000000000000008416610b0c565b90505b919050565b600061047382610b39565b3330146104de576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526027815260200180612b9c6027913960400191505060405180910390fd5b6104fd8173ffffffffffffffffffffffffffffffffffffffff16610b96565b610552576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526039815260200180612a826039913960400191505060405180910390fd5b61055b81610b9c565b6040805173ffffffffffffffffffffffffffffffffffffffff8316815290517f310ba5f1d2ed074b51e2eccd052a47ae9ab7c6b800d1fca3db3999d6a592ca039181900360200190a150565b7f150b7a020000000000000000000000000000000000000000000000000000000095945050505050565b600061061b6105df85610ba0565b84848080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250610c0092505050565b1561064357507f1626ba7e000000000000000000000000000000000000000000000000000000005b9392505050565b600061047382610425565b600061067f6105df86866040518083838082843760405192018290039091209350610ba092505050565b156106a757507f20c13b0b000000000000000000000000000000000000000000000000000000005b949350505050565b7f000000000000000000000000000000000000000000000000000000000000000081565b7f000000000000000000000000000000000000000000000000000000000000000081565b33301461074f576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526027815260200180612b9c6027913960400191505060405180910390fd5b600061075a82610425565b73ffffffffffffffffffffffffffffffffffffffff1614156107c7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602b8152602001806128e0602b913960400191505060405180910390fd5b6107d2816000610df8565b50565b33301461082d576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526027815260200180612b9c6027913960400191505060405180910390fd5b600061085e82604051602001610843919061277e565b60405160208183030381529060405280519060200120610ba0565b905061086a8183610e5b565b5050565b6108778261102a565b600061088f83856040516020016108439291906127c5565b905061089b8183610c00565b6108da576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016108d190612721565b60405180910390fd5b6108e48185610e5b565b50505050565b60006104737f8d0bf1fd623d628c741362c1289948e57b3e2905218c676d3e69abee36d6ae2e83610b0c565b6000333014610970576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526027815260200180612b9c6027913960400191505060405180910390fd5b81516020830134f06040805173ffffffffffffffffffffffffffffffffffffffff8316815290519192507fa506ad4e7f05eceba62a023c3219e5bd98a615f4fa87e2afb08a2da5cf62bf0c919081900360200190a1919050565b60006109d660006108ea565b905090565b333014610a33576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526027815260200180612b9c6027913960400191505060405180910390fd5b6000610a3e83610425565b73ffffffffffffffffffffffffffffffffffffffff1614610aaa576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602c8152602001806129f4602c913960400191505060405180910390fd5b61086a8282610df8565b7fbc197c810000000000000000000000000000000000000000000000000000000098975050505050505050565b7ff23a6e61000000000000000000000000000000000000000000000000000000009695505050505050565b60408051602080820194909452808201929092528051808303820181526060909201905280519101205490565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f90042baf000000000000000000000000000000000000000000000000000000001415610b8d57506001610476565b610473826110ce565b3b151590565b3055565b604080517f19010000000000000000000000000000000000000000000000000000000000006020808301919091524660228301523060601b6042830152605680830194909452825180830390940184526076909101909152815191012090565b6000806000610c0e8461120f565b909250905061ffff821660005b8551831015610dd55760008080610c32898761127d565b975060ff91821694501691506001831415610c5a57610c5189876112fe565b96509050610d7e565b82610c86576060610c6b8a88611376565b97509050610c798b82611427565b9150828501945050610d7e565b6002831415610d2d57610c9989876112fe565b965090506000610ca98a886117b1565b975061ffff1690506060610cbe8b8984611822565b98509050610ccd8c8483611911565b610d22576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260328152602001806129c26032913960400191505060405180910390fd5b505092810192610d7e565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602c8152602001806128b4602c913960400191505060405180910390fd5b848282604051602001808481526020018381526020018273ffffffffffffffffffffffffffffffffffffffff1681526020019350505050604051602081830303815290604052805190602001209450505050610c1b565b8361ffff168110158015610ded5750610ded82611b59565b979650505050505050565b61086a7fbe27a319efc8734e89e26ba4bc95f5c788584163b959f03fa04e2d7ab4b9a1207fffffffff00000000000000000000000000000000000000000000000000000000841673ffffffffffffffffffffffffffffffffffffffff8416611c37565b60005b8151811015611025576000828281518110610e7557fe5b602002602001015190506000606082604001515a1015610ec1576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016108d1906126c4565b825115610f5957826060015173ffffffffffffffffffffffffffffffffffffffff168360400151600014610ef9578360400151610efb565b5a5b8460a00151604051610f0d91906125f6565b6000604051808303818686f4925050503d8060008114610f49576040519150601f19603f3d011682016040523d82523d6000602084013e610f4e565b606091505b509092509050610fee565b826060015173ffffffffffffffffffffffffffffffffffffffff1683608001518460400151600014610f8f578460400151610f91565b5a5b908560a00151604051610fa491906125f6565b600060405180830381858888f193505050503d8060008114610fe2576040519150601f19603f3d011682016040523d82523d6000602084013e610fe7565b606091505b5090925090505b811561100f5785604051611002919061263e565b60405180910390a061101a565b61101a838783611c65565b505050600101610e5e565b505050565b60008061103683611cb5565b915091506000611045836108ea565b9050808214611080576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016108d19061268d565b6001820161108e8482611cce565b7f1f180c27086c7a39ea2a7b25239d1ab92348f07ca7bb59d1438fcf527568f88184826040516110bf9291906127de565b60405180910390a15050505050565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167fec6aba5000000000000000000000000000000000000000000000000000000000148061116157507fffffffff0000000000000000000000000000000000000000000000000000000082167f4e2312e000000000000000000000000000000000000000000000000000000000145b806111ad57507fffffffff0000000000000000000000000000000000000000000000000000000082167f150b7a0200000000000000000000000000000000000000000000000000000000145b806111f957507fffffffff0000000000000000000000000000000000000000000000000000000082167fc0ee0b8a00000000000000000000000000000000000000000000000000000000145b1561120657506001610476565b61047382611cf9565b6020810151815160f09190911c90600290811115611278576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602781526020018061292e6027913960400191505060405180910390fd5b915091565b8082016020015160f881901c9060f01c60ff166002830183811161129d57fe5b84518111156112f7576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526026815260200180612af76026913960400191505060405180910390fd5b9250925092565b8082016020015160601c6014820182811161131557fe5b835181111561136f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602381526020018061290b6023913960400191505060405180910390fd5b9250929050565b6040805160428082526080820190925260609160009190602082018180368337019050509150828401602001805160208401526020810151604084015260228101516042840152506042830190508281116113cd57fe5b835181111561136f576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526023815260200180612a5f6023913960400191505060405180910390fd5b60008151604214611483576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603a81526020018061287a603a913960400191505060405180910390fd5b60008260018451038151811061149557fe5b602001015160f81c60f81b60f81c60ff1690506000836040815181106114b757fe5b016020015160f81c905060006114cd8582611d56565b905060006114dc866020611d56565b90507f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a0811115611557576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603d81526020018061283d603d913960400191505060405180910390fd5b8260ff16601b1415801561156f57508260ff16601c14155b156115c5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603d815260200180612955603d913960400191505060405180910390fd5b60018414156116395760018784848460405160008152602001604052604051808581526020018460ff1681526020018381526020018281526020019450505050506020604051602081039080840390855afa158015611628573d6000803e3d6000fd5b50505060206040510351945061173b565b60028414156116ea5760018760405160200180807f19457468657265756d205369676e6564204d6573736167653a0a333200000000815250601c018281526020019150506040516020818303038152906040528051906020012084848460405160008152602001604052604051808581526020018460ff1681526020018381526020018281526020019450505050506020604051602081039080840390855afa158015611628573d6000803e3d6000fd5b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603c815260200180612abb603c913960400191505060405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff85166117a7576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260308152602001806129926030913960400191505060405180910390fd5b5050505092915050565b8082016020015160f01c600282018281116117c857fe5b835181111561136f576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526022815260200180612b3e6022913960400191505060405180910390fd5b606060008267ffffffffffffffff8111801561183d57600080fd5b506040519080825280601f01601f191660200182016040528015611868576020820181803683370190505b509150838501602001600060205b8581101561188f57908201518482015260208101611876565b84860160200180519390920151908501525250828201838110156118af57fe5b8451811115611909576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526021815260200180612b1d6021913960400191505060405180910390fd5b935093915050565b6000808260018451038151811061192457fe5b016020015160f81c9050600181148061193d5750600281145b15611981578373ffffffffffffffffffffffffffffffffffffffff166119638685611427565b73ffffffffffffffffffffffffffffffffffffffff16149150611b51565b6003811415611b005782517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81018452604080517f1626ba7e000000000000000000000000000000000000000000000000000000008152600481018881526024820192835286516044830152865173ffffffffffffffffffffffffffffffffffffffff891693631626ba7e938b938a9390929160640190602085019080838360005b83811015611a3b578181015183820152602001611a23565b50505050905090810190601f168015611a685780820380516001836020036101000a031916815260200191505b50935050505060206040518083038186803b158015611a8657600080fd5b505afa158015611a9a573d6000803e3d6000fd5b505050506040513d6020811015611ab057600080fd5b50519084527fffffffff00000000000000000000000000000000000000000000000000000000167f1626ba7e00000000000000000000000000000000000000000000000000000000149150611b51565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603f815260200180612a20603f913960400191505060405180910390fd5b509392505050565b604080517fff000000000000000000000000000000000000000000000000000000000000006020808301919091527fffffffffffffffffffffffffffffffffffffffff0000000000000000000000007f000000000000000000000000000000000000000000000000000000000000000060601b166021830152603582018490527f0000000000000000000000000000000000000000000000000000000000000000605580840191909152835180840390910181526075909201909252805191012073ffffffffffffffffffffffffffffffffffffffff163014919050565b6040805160208082019590955280820193909352805180840382018152606090930190528151919092012055565b826020015115611c7757805160208201fd5b7f3dbd1590ea96dd3253a91f24e64e3a502e1225d602a5731357bc12643070ccd78282604051611ca8929190612647565b60405180910390a1505050565b606081901c916bffffffffffffffffffffffff90911690565b61086a7f8d0bf1fd623d628c741362c1289948e57b3e2905218c676d3e69abee36d6ae2e8383611c37565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f025b22bc000000000000000000000000000000000000000000000000000000001415611d4d57506001610476565b61047382611dbe565b60008160200183511015611db5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603c815260200180612b60603c913960400191505060405180910390fd5b50016020015190565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f389901c7000000000000000000000000000000000000000000000000000000001415611e1257506001610476565b6104738260007fffffffff0000000000000000000000000000000000000000000000000000000082161580611e8857507fffffffff0000000000000000000000000000000000000000000000000000000082167f36e7817500000000000000000000000000000000000000000000000000000000145b15611e9557506001610476565b7f01ffc9a7000000000000000000000000000000000000000000000000000000007fffffffff00000000000000000000000000000000000000000000000000000000831614610473565b803573ffffffffffffffffffffffffffffffffffffffff8116811461047657600080fd5b600082601f830112611f13578081fd5b8135602067ffffffffffffffff80831115611f2a57fe5b611f3782838502016127ec565b83815282810190868401865b86811015612013578135890160c0807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0838e03011215611f8157898afd5b604080518281018181108a82111715611f9657fe5b8252611fa3848b01612063565b8152611fb0828501612063565b8a8201526060808501358383015260809250611fcd838601611edf565b9082015260a08481013583830152928401359289841115611fec578c8dfd5b611ffa8f8c868801016120e3565b9082015287525050509285019290850190600101611f43565b509098975050505050505050565b60008083601f840112612032578182fd5b50813567ffffffffffffffff811115612049578182fd5b602083019150836020808302850101111561136f57600080fd5b8035801515811461047657600080fd5b80357fffffffff000000000000000000000000000000000000000000000000000000008116811461047657600080fd5b60008083601f8401126120b4578182fd5b50813567ffffffffffffffff8111156120cb578182fd5b60208301915083602082850101111561136f57600080fd5b600082601f8301126120f3578081fd5b813567ffffffffffffffff81111561210757fe5b61213860207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116016127ec565b81815284602083860101111561214c578283fd5b816020850160208301379081016020019190915292915050565b600060208284031215612177578081fd5b61064382611edf565b60008060008060008060008060a0898b03121561219b578384fd5b6121a489611edf565b97506121b260208a01611edf565b9650604089013567ffffffffffffffff808211156121ce578586fd5b6121da8c838d01612021565b909850965060608b01359150808211156121f2578586fd5b6121fe8c838d01612021565b909650945060808b0135915080821115612216578384fd5b506122238b828c016120a3565b999c989b5096995094979396929594505050565b60008060008060006080868803121561224e578081fd5b61225786611edf565b945061226560208701611edf565b935060408601359250606086013567ffffffffffffffff811115612287578182fd5b612293888289016120a3565b969995985093965092949392505050565b60008060008060008060a087890312156122bc578182fd5b6122c587611edf565b95506122d360208801611edf565b94506040870135935060608701359250608087013567ffffffffffffffff8111156122fc578283fd5b61230889828a016120a3565b979a9699509497509295939492505050565b60006020828403121561232b578081fd5b813567ffffffffffffffff811115612341578182fd5b6106a784828501611f03565b600080600060608486031215612361578283fd5b833567ffffffffffffffff80821115612378578485fd5b61238487838801611f03565b94506020860135935060408601359150808211156123a0578283fd5b506123ad868287016120e3565b9150509250925092565b6000806000604084860312156123cb578283fd5b83359250602084013567ffffffffffffffff8111156123e8578283fd5b6123f4868287016120a3565b9497909650939450505050565b600060208284031215612412578081fd5b61064382612073565b6000806040838503121561242d578182fd5b61243683612073565b915061244460208401611edf565b90509250929050565b60008060008060408587031215612462578182fd5b843567ffffffffffffffff80821115612479578384fd5b612485888389016120a3565b9096509450602087013591508082111561249d578384fd5b506124aa878288016120a3565b95989497509550505050565b6000602082840312156124c7578081fd5b813567ffffffffffffffff8111156124dd578182fd5b6106a7848285016120e3565b6000602082840312156124fa578081fd5b5035919050565b6000815180845260208085018081965082840281019150828601855b8581101561259f5782840389528151805115158552858101511515868601526040808201519086015260608082015173ffffffffffffffffffffffffffffffffffffffff16908601526080808201519086015260a09081015160c09186018290529061258b818701836125ac565b9a87019a955050509084019060010161251d565b5091979650505050505050565b600081518084526125c4816020860160208601612810565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60008251612608818460208701612810565b9190910192915050565b73ffffffffffffffffffffffffffffffffffffffff91909116815260200190565b901515815260200190565b90815260200190565b6000838252604060208301526106a760408301846125ac565b7fffffffff0000000000000000000000000000000000000000000000000000000091909116815260200190565b6020808252601f908201527f4d61696e4d6f64756c65235f617574683a20494e56414c49445f4e4f4e434500604082015260600190565b60208082526024908201527f4d6f64756c6543616c6c73235f657865637574653a204e4f545f454e4f55474860408201527f5f47415300000000000000000000000000000000000000000000000000000000606082015260800190565b60208082526026908201527f4d6f64756c6543616c6c7323657865637574653a20494e56414c49445f53494760408201527f4e41545552450000000000000000000000000000000000000000000000000000606082015260800190565b600060408252600560408301527f73656c663a0000000000000000000000000000000000000000000000000000006060830152608060208301526106436080830184612501565b6000838252604060208301526106a76040830184612501565b918252602082015260400190565b60405181810167ffffffffffffffff8111828210171561280857fe5b604052919050565b60005b8381101561282b578181015183820152602001612813565b838111156108e4575050600091015256fe5369676e617475726556616c696461746f72237265636f7665725369676e65723a20696e76616c6964207369676e6174757265202773272076616c75655369676e617475726556616c696461746f72237265636f7665725369676e65723a20696e76616c6964207369676e6174757265206c656e6774684d6f64756c6541757468235f7369676e617475726556616c69646174696f6e20494e56414c49445f464c41474d6f64756c65486f6f6b732372656d6f7665486f6f6b3a20484f4f4b5f4e4f545f524547495354455245444c696242797465732372656164416464726573733a204f55545f4f465f424f554e44534c696242797465732372656164466972737455696e7431363a204f55545f4f465f424f554e44535369676e617475726556616c696461746f72237265636f7665725369676e65723a20696e76616c6964207369676e6174757265202776272076616c75655369676e617475726556616c696461746f72237265636f7665725369676e65723a20494e56414c49445f5349474e45524d6f64756c6541757468235f7369676e617475726556616c69646174696f6e3a20494e56414c49445f5349474e41545552454d6f64756c65486f6f6b7323616464486f6f6b3a20484f4f4b5f414c52454144595f524547495354455245445369676e617475726556616c696461746f7223697356616c69645369676e61747572653a20554e535550504f525445445f5349474e41545552455f545950454c696242797465732372656164427974657336363a204f55545f4f465f424f554e44534d6f64756c6555706461746523757064617465496d706c656d656e746174696f6e3a20494e56414c49445f494d504c454d454e544154494f4e5369676e617475726556616c696461746f72237265636f7665725369676e65723a20554e535550504f525445445f5349474e41545552455f545950454c69624279746573237265616455696e743855696e74383a204f55545f4f465f424f554e44534c69624279746573237265616442797465733a204f55545f4f465f424f554e44534c69624279746573237265616455696e7431363a204f55545f4f465f424f554e44534c696242797465732372656164427974657333323a20475245415445525f4f525f455155414c5f544f5f33325f4c454e4754485f52455155495245444d6f64756c6553656c6641757468236f6e6c7953656c663a204e4f545f415554484f52495a4544a2646970667358221220b34deca9dd75815e4ef8a9279e45750ec5554b22c673e160bdba849d80f5888564736f6c63430007060033603a600e3d39601a805130553df3363d3d373d3d3d363d30545af43d82803e903d91601857fd5bf3000000000000000000000000f9d09d634fb818b05149329c1dccfaea53639d960000000000000000000000000000000000000000000000000000000000', + gasLimit: 8000000 + }) + ) // Deploy mainModuleUpgradable - await signer.sendTransaction({ - to: '0x8A5Bc19e22D6aD55a2c763B93A75d09F321fe764', - data: '0x9c4ae2d0000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002d07608060405234801561001057600080fd5b50612ce7806100206000396000f3fe6080604052600436106101125760003560e01c806351605d80116100a557806390042baf11610074578063b93ea7ad11610059578063b93ea7ad146103d0578063bc197c81146103f0578063f23a6e611461041057610119565b806390042baf146103a8578063affed0e0146103bb57610119565b806351605d801461032657806361c2926c146103485780637a9a1628146103685780638c3f55631461038857610119565b80631a9b2337116100e15780631a9b23371461029957806320c13b0b146102c657806329561426146102e65780634fcf3eca1461030657610119565b806301ffc9a7146101f4578063025b22bc1461022a578063150b7a021461024c5780631626ba7e1461027957610119565b3661011957005b60006101486000357fffffffff0000000000000000000000000000000000000000000000000000000016610430565b905073ffffffffffffffffffffffffffffffffffffffff8116156101f1576000808273ffffffffffffffffffffffffffffffffffffffff166000366040518083838082843760405192019450600093509091505080830381855af49150503d80600081146101d2576040519150601f19603f3d011682016040523d82523d6000602084013e6101d7565b606091505b5091509150816101e957805160208201fd5b805160208201f35b50005b34801561020057600080fd5b5061021461020f3660046124d4565b610486565b60405161022191906126eb565b60405180910390f35b34801561023657600080fd5b5061024a610245366004612221565b610491565b005b34801561025857600080fd5b5061026c6102673660046122f2565b6105b2565b6040516102219190612718565b34801561028557600080fd5b5061026c61029436600461248a565b6105dc565b3480156102a557600080fd5b506102b96102b43660046124d4565b610655565b60405161022191906126ca565b3480156102d257600080fd5b5061026c6102e1366004612520565b610660565b3480156102f257600080fd5b5061024a610301366004612472565b6106ba565b34801561031257600080fd5b5061024a6103213660046124d4565b6107c8565b34801561033257600080fd5b5061033b6108a6565b60405161022191906126f6565b34801561035457600080fd5b5061024a6103633660046123d5565b6108d6565b34801561037457600080fd5b5061024a610383366004612408565b61096f565b34801561039457600080fd5b5061033b6103a3366004612472565b6109eb565b6102b96103b6366004612589565b610a17565b3480156103c757600080fd5b5061033b610acb565b3480156103dc57600080fd5b5061024a6103eb3660046124ee565b610ad7565b3480156103fc57600080fd5b5061026c61040b36600461223b565b610bb0565b34801561041c57600080fd5b5061026c61042b36600461235f565b610bdd565b600061047e7fbe27a319efc8734e89e26ba4bc95f5c788584163b959f03fa04e2d7ab4b9a1207fffffffff000000000000000000000000000000000000000000000000000000008416610c08565b90505b919050565b600061047e82610c35565b3330146104e9576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526027815260200180612c8b6027913960400191505060405180910390fd5b6105088173ffffffffffffffffffffffffffffffffffffffff16610c92565b61055d576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526039815260200180612b716039913960400191505060405180910390fd5b61056681610c98565b6040805173ffffffffffffffffffffffffffffffffffffffff8316815290517f310ba5f1d2ed074b51e2eccd052a47ae9ab7c6b800d1fca3db3999d6a592ca039181900360200190a150565b7f150b7a020000000000000000000000000000000000000000000000000000000095945050505050565b60006106266105ea85610c9c565b84848080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250610cfc92505050565b1561064e57507f1626ba7e000000000000000000000000000000000000000000000000000000005b9392505050565b600061047e82610430565b600061068a6105ea86866040518083838082843760405192018290039091209350610c9c92505050565b156106b257507f20c13b0b000000000000000000000000000000000000000000000000000000005b949350505050565b333014610712576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526027815260200180612c8b6027913960400191505060405180910390fd5b80610768576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260378152602001806129986037913960400191505060405180910390fd5b6107927fea7157fa25e3aa17d0ae2d5280fa4e24d421c61842aa85e45194e1145aa72bf882610ef4565b6040805182815290517f307ed6bd941ee9fc80f369c94af5fa11e25bab5102a6140191756c5474a30bfa9181900360200190a150565b333014610820576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526027815260200180612c8b6027913960400191505060405180910390fd5b600061082b82610430565b73ffffffffffffffffffffffffffffffffffffffff161415610898576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602b8152602001806129cf602b913960400191505060405180910390fd5b6108a3816000610ef8565b50565b60006108d17fea7157fa25e3aa17d0ae2d5280fa4e24d421c61842aa85e45194e1145aa72bf8610f5b565b905090565b33301461092e576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526027815260200180612c8b6027913960400191505060405180910390fd5b600061095f826040516020016109449190612836565b60405160208183030381529060405280519060200120610c9c565b905061096b8183610f5f565b5050565b6109788261112e565b6000610990838560405160200161094492919061287d565b905061099c8183610cfc565b6109db576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016109d2906127d9565b60405180910390fd5b6109e58185610f5f565b50505050565b600061047e7f8d0bf1fd623d628c741362c1289948e57b3e2905218c676d3e69abee36d6ae2e83610c08565b6000333014610a71576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526027815260200180612c8b6027913960400191505060405180910390fd5b81516020830134f06040805173ffffffffffffffffffffffffffffffffffffffff8316815290519192507fa506ad4e7f05eceba62a023c3219e5bd98a615f4fa87e2afb08a2da5cf62bf0c919081900360200190a1919050565b60006108d160006109eb565b333014610b2f576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526027815260200180612c8b6027913960400191505060405180910390fd5b6000610b3a83610430565b73ffffffffffffffffffffffffffffffffffffffff1614610ba6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602c815260200180612ae3602c913960400191505060405180910390fd5b61096b8282610ef8565b7fbc197c810000000000000000000000000000000000000000000000000000000098975050505050505050565b7ff23a6e61000000000000000000000000000000000000000000000000000000009695505050505050565b60408051602080820194909452808201929092528051808303820181526060909201905280519101205490565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f90042baf000000000000000000000000000000000000000000000000000000001415610c8957506001610481565b61047e826111d2565b3b151590565b3055565b604080517f19010000000000000000000000000000000000000000000000000000000000006020808301919091524660228301523060601b6042830152605680830194909452825180830390940184526076909101909152815191012090565b6000806000610d0a84611313565b909250905061ffff821660005b8551831015610ed15760008080610d2e8987611381565b975060ff91821694501691506001831415610d5657610d4d8987611402565b96509050610e7a565b82610d82576060610d678a8861147a565b97509050610d758b8261152b565b9150828501945050610e7a565b6002831415610e2957610d958987611402565b965090506000610da58a886118b5565b975061ffff1690506060610dba8b8984611926565b98509050610dc98c8483611a15565b610e1e576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526032815260200180612ab16032913960400191505060405180910390fd5b505092810192610e7a565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602c81526020018061296c602c913960400191505060405180910390fd5b848282604051602001808481526020018381526020018273ffffffffffffffffffffffffffffffffffffffff1681526020019350505050604051602081830303815290604052805190602001209450505050610d17565b8361ffff168110158015610ee95750610ee982611c5d565b979650505050505050565b9055565b61096b7fbe27a319efc8734e89e26ba4bc95f5c788584163b959f03fa04e2d7ab4b9a1207fffffffff00000000000000000000000000000000000000000000000000000000841673ffffffffffffffffffffffffffffffffffffffff8416611c9a565b5490565b60005b8151811015611129576000828281518110610f7957fe5b602002602001015190506000606082604001515a1015610fc5576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016109d29061277c565b82511561105d57826060015173ffffffffffffffffffffffffffffffffffffffff168360400151600014610ffd578360400151610fff565b5a5b8460a0015160405161101191906126ae565b6000604051808303818686f4925050503d806000811461104d576040519150601f19603f3d011682016040523d82523d6000602084013e611052565b606091505b5090925090506110f2565b826060015173ffffffffffffffffffffffffffffffffffffffff1683608001518460400151600014611093578460400151611095565b5a5b908560a001516040516110a891906126ae565b600060405180830381858888f193505050503d80600081146110e6576040519150601f19603f3d011682016040523d82523d6000602084013e6110eb565b606091505b5090925090505b8115611113578560405161110691906126f6565b60405180910390a061111e565b61111e838783611cc8565b505050600101610f62565b505050565b60008061113a83611d18565b915091506000611149836109eb565b9050808214611184576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016109d290612745565b600182016111928482611d31565b7f1f180c27086c7a39ea2a7b25239d1ab92348f07ca7bb59d1438fcf527568f88184826040516111c3929190612896565b60405180910390a15050505050565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167fec6aba5000000000000000000000000000000000000000000000000000000000148061126557507fffffffff0000000000000000000000000000000000000000000000000000000082167f4e2312e000000000000000000000000000000000000000000000000000000000145b806112b157507fffffffff0000000000000000000000000000000000000000000000000000000082167f150b7a0200000000000000000000000000000000000000000000000000000000145b806112fd57507fffffffff0000000000000000000000000000000000000000000000000000000082167fc0ee0b8a00000000000000000000000000000000000000000000000000000000145b1561130a57506001610481565b61047e82611d5c565b6020810151815160f09190911c9060029081111561137c576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526027815260200180612a1d6027913960400191505060405180910390fd5b915091565b8082016020015160f881901c9060f01c60ff16600283018381116113a157fe5b84518111156113fb576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526026815260200180612be66026913960400191505060405180910390fd5b9250925092565b8082016020015160601c6014820182811161141957fe5b8351811115611473576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806129fa6023913960400191505060405180910390fd5b9250929050565b6040805160428082526080820190925260609160009190602082018180368337019050509150828401602001805160208401526020810151604084015260228101516042840152506042830190508281116114d157fe5b8351811115611473576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526023815260200180612b4e6023913960400191505060405180910390fd5b60008151604214611587576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603a815260200180612932603a913960400191505060405180910390fd5b60008260018451038151811061159957fe5b602001015160f81c60f81b60f81c60ff1690506000836040815181106115bb57fe5b016020015160f81c905060006115d18582611db9565b905060006115e0866020611db9565b90507f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a081111561165b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603d8152602001806128f5603d913960400191505060405180910390fd5b8260ff16601b1415801561167357508260ff16601c14155b156116c9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603d815260200180612a44603d913960400191505060405180910390fd5b600184141561173d5760018784848460405160008152602001604052604051808581526020018460ff1681526020018381526020018281526020019450505050506020604051602081039080840390855afa15801561172c573d6000803e3d6000fd5b50505060206040510351945061183f565b60028414156117ee5760018760405160200180807f19457468657265756d205369676e6564204d6573736167653a0a333200000000815250601c018281526020019150506040516020818303038152906040528051906020012084848460405160008152602001604052604051808581526020018460ff1681526020018381526020018281526020019450505050506020604051602081039080840390855afa15801561172c573d6000803e3d6000fd5b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603c815260200180612baa603c913960400191505060405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff85166118ab576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526030815260200180612a816030913960400191505060405180910390fd5b5050505092915050565b8082016020015160f01c600282018281116118cc57fe5b8351811115611473576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526022815260200180612c2d6022913960400191505060405180910390fd5b606060008267ffffffffffffffff8111801561194157600080fd5b506040519080825280601f01601f19166020018201604052801561196c576020820181803683370190505b509150838501602001600060205b858110156119935790820151848201526020810161197a565b84860160200180519390920151908501525250828201838110156119b357fe5b8451811115611a0d576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526021815260200180612c0c6021913960400191505060405180910390fd5b935093915050565b60008082600184510381518110611a2857fe5b016020015160f81c90506001811480611a415750600281145b15611a85578373ffffffffffffffffffffffffffffffffffffffff16611a67868561152b565b73ffffffffffffffffffffffffffffffffffffffff16149150611c55565b6003811415611c045782517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81018452604080517f1626ba7e000000000000000000000000000000000000000000000000000000008152600481018881526024820192835286516044830152865173ffffffffffffffffffffffffffffffffffffffff891693631626ba7e938b938a9390929160640190602085019080838360005b83811015611b3f578181015183820152602001611b27565b50505050905090810190601f168015611b6c5780820380516001836020036101000a031916815260200191505b50935050505060206040518083038186803b158015611b8a57600080fd5b505afa158015611b9e573d6000803e3d6000fd5b505050506040513d6020811015611bb457600080fd5b50519084527fffffffff00000000000000000000000000000000000000000000000000000000167f1626ba7e00000000000000000000000000000000000000000000000000000000149150611c55565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603f815260200180612b0f603f913960400191505060405180910390fd5b509392505050565b6000811580159061047e5750611c927fea7157fa25e3aa17d0ae2d5280fa4e24d421c61842aa85e45194e1145aa72bf8610f5b565b909114919050565b6040805160208082019590955280820193909352805180840382018152606090930190528151919092012055565b826020015115611cda57805160208201fd5b7f3dbd1590ea96dd3253a91f24e64e3a502e1225d602a5731357bc12643070ccd78282604051611d0b9291906126ff565b60405180910390a1505050565b606081901c916bffffffffffffffffffffffff90911690565b61096b7f8d0bf1fd623d628c741362c1289948e57b3e2905218c676d3e69abee36d6ae2e8383611c9a565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f025b22bc000000000000000000000000000000000000000000000000000000001415611db057506001610481565b61047e82611e21565b60008160200183511015611e18576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603c815260200180612c4f603c913960400191505060405180910390fd5b50016020015190565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f389901c7000000000000000000000000000000000000000000000000000000001415611e7557506001610481565b61047e8260007fffffffff0000000000000000000000000000000000000000000000000000000082167f783649a6000000000000000000000000000000000000000000000000000000001415611ecd57506001610481565b61047e8260007fffffffff0000000000000000000000000000000000000000000000000000000082161580611f4357507fffffffff0000000000000000000000000000000000000000000000000000000082167f36e7817500000000000000000000000000000000000000000000000000000000145b15611f5057506001610481565b7f01ffc9a7000000000000000000000000000000000000000000000000000000007fffffffff0000000000000000000000000000000000000000000000000000000083161461047e565b803573ffffffffffffffffffffffffffffffffffffffff8116811461048157600080fd5b600082601f830112611fce578081fd5b8135602067ffffffffffffffff80831115611fe557fe5b611ff282838502016128a4565b83815282810190868401865b868110156120ce578135890160c0807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0838e0301121561203c57898afd5b604080518281018181108a8211171561205157fe5b825261205e848b0161211e565b815261206b82850161211e565b8a8201526060808501358383015260809250612088838601611f9a565b9082015260a084810135838301529284013592898411156120a7578c8dfd5b6120b58f8c8688010161219e565b9082015287525050509285019290850190600101611ffe565b509098975050505050505050565b60008083601f8401126120ed578182fd5b50813567ffffffffffffffff811115612104578182fd5b602083019150836020808302850101111561147357600080fd5b8035801515811461048157600080fd5b80357fffffffff000000000000000000000000000000000000000000000000000000008116811461048157600080fd5b60008083601f84011261216f578182fd5b50813567ffffffffffffffff811115612186578182fd5b60208301915083602082850101111561147357600080fd5b600082601f8301126121ae578081fd5b813567ffffffffffffffff8111156121c257fe5b6121f360207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116016128a4565b818152846020838601011115612207578283fd5b816020850160208301379081016020019190915292915050565b600060208284031215612232578081fd5b61064e82611f9a565b60008060008060008060008060a0898b031215612256578384fd5b61225f89611f9a565b975061226d60208a01611f9a565b9650604089013567ffffffffffffffff80821115612289578586fd5b6122958c838d016120dc565b909850965060608b01359150808211156122ad578586fd5b6122b98c838d016120dc565b909650945060808b01359150808211156122d1578384fd5b506122de8b828c0161215e565b999c989b5096995094979396929594505050565b600080600080600060808688031215612309578081fd5b61231286611f9a565b945061232060208701611f9a565b935060408601359250606086013567ffffffffffffffff811115612342578182fd5b61234e8882890161215e565b969995985093965092949392505050565b60008060008060008060a08789031215612377578182fd5b61238087611f9a565b955061238e60208801611f9a565b94506040870135935060608701359250608087013567ffffffffffffffff8111156123b7578283fd5b6123c389828a0161215e565b979a9699509497509295939492505050565b6000602082840312156123e6578081fd5b813567ffffffffffffffff8111156123fc578182fd5b6106b284828501611fbe565b60008060006060848603121561241c578283fd5b833567ffffffffffffffff80821115612433578485fd5b61243f87838801611fbe565b945060208601359350604086013591508082111561245b578283fd5b506124688682870161219e565b9150509250925092565b600060208284031215612483578081fd5b5035919050565b60008060006040848603121561249e578283fd5b83359250602084013567ffffffffffffffff8111156124bb578283fd5b6124c78682870161215e565b9497909650939450505050565b6000602082840312156124e5578081fd5b61064e8261212e565b60008060408385031215612500578182fd5b6125098361212e565b915061251760208401611f9a565b90509250929050565b60008060008060408587031215612535578182fd5b843567ffffffffffffffff8082111561254c578384fd5b6125588883890161215e565b90965094506020870135915080821115612570578384fd5b5061257d8782880161215e565b95989497509550505050565b60006020828403121561259a578081fd5b813567ffffffffffffffff8111156125b0578182fd5b6106b28482850161219e565b6000815180845260208085019450848183028601828601855b858110156126575783830389528151805115158452858101511515868501526040808201519085015260608082015173ffffffffffffffffffffffffffffffffffffffff16908501526080808201519085015260a09081015160c09185018290529061264381860183612664565b9a87019a94505050908401906001016125d5565b5090979650505050505050565b6000815180845261267c8160208601602086016128c8565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b600082516126c08184602087016128c8565b9190910192915050565b73ffffffffffffffffffffffffffffffffffffffff91909116815260200190565b901515815260200190565b90815260200190565b6000838252604060208301526106b26040830184612664565b7fffffffff0000000000000000000000000000000000000000000000000000000091909116815260200190565b6020808252601f908201527f4d61696e4d6f64756c65235f617574683a20494e56414c49445f4e4f4e434500604082015260600190565b60208082526024908201527f4d6f64756c6543616c6c73235f657865637574653a204e4f545f454e4f55474860408201527f5f47415300000000000000000000000000000000000000000000000000000000606082015260800190565b60208082526026908201527f4d6f64756c6543616c6c7323657865637574653a20494e56414c49445f53494760408201527f4e41545552450000000000000000000000000000000000000000000000000000606082015260800190565b600060408252600560408301527f73656c663a00000000000000000000000000000000000000000000000000000060608301526080602083015261064e60808301846125bc565b6000838252604060208301526106b260408301846125bc565b918252602082015260400190565b60405181810167ffffffffffffffff811182821017156128c057fe5b604052919050565b60005b838110156128e35781810151838201526020016128cb565b838111156109e5575050600091015256fe5369676e617475726556616c696461746f72237265636f7665725369676e65723a20696e76616c6964207369676e6174757265202773272076616c75655369676e617475726556616c696461746f72237265636f7665725369676e65723a20696e76616c6964207369676e6174757265206c656e6774684d6f64756c6541757468235f7369676e617475726556616c69646174696f6e20494e56414c49445f464c41474d6f64756c654175746855706772616461626c6523757064617465496d6167654861736820494e56414c49445f494d4147455f484153484d6f64756c65486f6f6b732372656d6f7665486f6f6b3a20484f4f4b5f4e4f545f524547495354455245444c696242797465732372656164416464726573733a204f55545f4f465f424f554e44534c696242797465732372656164466972737455696e7431363a204f55545f4f465f424f554e44535369676e617475726556616c696461746f72237265636f7665725369676e65723a20696e76616c6964207369676e6174757265202776272076616c75655369676e617475726556616c696461746f72237265636f7665725369676e65723a20494e56414c49445f5349474e45524d6f64756c6541757468235f7369676e617475726556616c69646174696f6e3a20494e56414c49445f5349474e41545552454d6f64756c65486f6f6b7323616464486f6f6b3a20484f4f4b5f414c52454144595f524547495354455245445369676e617475726556616c696461746f7223697356616c69645369676e61747572653a20554e535550504f525445445f5349474e41545552455f545950454c696242797465732372656164427974657336363a204f55545f4f465f424f554e44534d6f64756c6555706461746523757064617465496d706c656d656e746174696f6e3a20494e56414c49445f494d504c454d454e544154494f4e5369676e617475726556616c696461746f72237265636f7665725369676e65723a20554e535550504f525445445f5349474e41545552455f545950454c69624279746573237265616455696e743855696e74383a204f55545f4f465f424f554e44534c69624279746573237265616442797465733a204f55545f4f465f424f554e44534c69624279746573237265616455696e7431363a204f55545f4f465f424f554e44534c696242797465732372656164427974657333323a20475245415445525f4f525f455155414c5f544f5f33325f4c454e4754485f52455155495245444d6f64756c6553656c6641757468236f6e6c7953656c663a204e4f545f415554484f52495a4544a2646970667358221220aebb8d931ef86555b6441c416b208bb9fe8fe0974c5733ebbccce548296c37ce64736f6c6343000706003300000000000000000000000000000000000000000000000000', - gasLimit: 8000000 - }) + responses.push( + await signer.sendTransaction({ + to: '0x8A5Bc19e22D6aD55a2c763B93A75d09F321fe764', + data: '0x9c4ae2d0000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002d07608060405234801561001057600080fd5b50612ce7806100206000396000f3fe6080604052600436106101125760003560e01c806351605d80116100a557806390042baf11610074578063b93ea7ad11610059578063b93ea7ad146103d0578063bc197c81146103f0578063f23a6e611461041057610119565b806390042baf146103a8578063affed0e0146103bb57610119565b806351605d801461032657806361c2926c146103485780637a9a1628146103685780638c3f55631461038857610119565b80631a9b2337116100e15780631a9b23371461029957806320c13b0b146102c657806329561426146102e65780634fcf3eca1461030657610119565b806301ffc9a7146101f4578063025b22bc1461022a578063150b7a021461024c5780631626ba7e1461027957610119565b3661011957005b60006101486000357fffffffff0000000000000000000000000000000000000000000000000000000016610430565b905073ffffffffffffffffffffffffffffffffffffffff8116156101f1576000808273ffffffffffffffffffffffffffffffffffffffff166000366040518083838082843760405192019450600093509091505080830381855af49150503d80600081146101d2576040519150601f19603f3d011682016040523d82523d6000602084013e6101d7565b606091505b5091509150816101e957805160208201fd5b805160208201f35b50005b34801561020057600080fd5b5061021461020f3660046124d4565b610486565b60405161022191906126eb565b60405180910390f35b34801561023657600080fd5b5061024a610245366004612221565b610491565b005b34801561025857600080fd5b5061026c6102673660046122f2565b6105b2565b6040516102219190612718565b34801561028557600080fd5b5061026c61029436600461248a565b6105dc565b3480156102a557600080fd5b506102b96102b43660046124d4565b610655565b60405161022191906126ca565b3480156102d257600080fd5b5061026c6102e1366004612520565b610660565b3480156102f257600080fd5b5061024a610301366004612472565b6106ba565b34801561031257600080fd5b5061024a6103213660046124d4565b6107c8565b34801561033257600080fd5b5061033b6108a6565b60405161022191906126f6565b34801561035457600080fd5b5061024a6103633660046123d5565b6108d6565b34801561037457600080fd5b5061024a610383366004612408565b61096f565b34801561039457600080fd5b5061033b6103a3366004612472565b6109eb565b6102b96103b6366004612589565b610a17565b3480156103c757600080fd5b5061033b610acb565b3480156103dc57600080fd5b5061024a6103eb3660046124ee565b610ad7565b3480156103fc57600080fd5b5061026c61040b36600461223b565b610bb0565b34801561041c57600080fd5b5061026c61042b36600461235f565b610bdd565b600061047e7fbe27a319efc8734e89e26ba4bc95f5c788584163b959f03fa04e2d7ab4b9a1207fffffffff000000000000000000000000000000000000000000000000000000008416610c08565b90505b919050565b600061047e82610c35565b3330146104e9576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526027815260200180612c8b6027913960400191505060405180910390fd5b6105088173ffffffffffffffffffffffffffffffffffffffff16610c92565b61055d576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526039815260200180612b716039913960400191505060405180910390fd5b61056681610c98565b6040805173ffffffffffffffffffffffffffffffffffffffff8316815290517f310ba5f1d2ed074b51e2eccd052a47ae9ab7c6b800d1fca3db3999d6a592ca039181900360200190a150565b7f150b7a020000000000000000000000000000000000000000000000000000000095945050505050565b60006106266105ea85610c9c565b84848080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250610cfc92505050565b1561064e57507f1626ba7e000000000000000000000000000000000000000000000000000000005b9392505050565b600061047e82610430565b600061068a6105ea86866040518083838082843760405192018290039091209350610c9c92505050565b156106b257507f20c13b0b000000000000000000000000000000000000000000000000000000005b949350505050565b333014610712576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526027815260200180612c8b6027913960400191505060405180910390fd5b80610768576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260378152602001806129986037913960400191505060405180910390fd5b6107927fea7157fa25e3aa17d0ae2d5280fa4e24d421c61842aa85e45194e1145aa72bf882610ef4565b6040805182815290517f307ed6bd941ee9fc80f369c94af5fa11e25bab5102a6140191756c5474a30bfa9181900360200190a150565b333014610820576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526027815260200180612c8b6027913960400191505060405180910390fd5b600061082b82610430565b73ffffffffffffffffffffffffffffffffffffffff161415610898576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602b8152602001806129cf602b913960400191505060405180910390fd5b6108a3816000610ef8565b50565b60006108d17fea7157fa25e3aa17d0ae2d5280fa4e24d421c61842aa85e45194e1145aa72bf8610f5b565b905090565b33301461092e576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526027815260200180612c8b6027913960400191505060405180910390fd5b600061095f826040516020016109449190612836565b60405160208183030381529060405280519060200120610c9c565b905061096b8183610f5f565b5050565b6109788261112e565b6000610990838560405160200161094492919061287d565b905061099c8183610cfc565b6109db576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016109d2906127d9565b60405180910390fd5b6109e58185610f5f565b50505050565b600061047e7f8d0bf1fd623d628c741362c1289948e57b3e2905218c676d3e69abee36d6ae2e83610c08565b6000333014610a71576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526027815260200180612c8b6027913960400191505060405180910390fd5b81516020830134f06040805173ffffffffffffffffffffffffffffffffffffffff8316815290519192507fa506ad4e7f05eceba62a023c3219e5bd98a615f4fa87e2afb08a2da5cf62bf0c919081900360200190a1919050565b60006108d160006109eb565b333014610b2f576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526027815260200180612c8b6027913960400191505060405180910390fd5b6000610b3a83610430565b73ffffffffffffffffffffffffffffffffffffffff1614610ba6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602c815260200180612ae3602c913960400191505060405180910390fd5b61096b8282610ef8565b7fbc197c810000000000000000000000000000000000000000000000000000000098975050505050505050565b7ff23a6e61000000000000000000000000000000000000000000000000000000009695505050505050565b60408051602080820194909452808201929092528051808303820181526060909201905280519101205490565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f90042baf000000000000000000000000000000000000000000000000000000001415610c8957506001610481565b61047e826111d2565b3b151590565b3055565b604080517f19010000000000000000000000000000000000000000000000000000000000006020808301919091524660228301523060601b6042830152605680830194909452825180830390940184526076909101909152815191012090565b6000806000610d0a84611313565b909250905061ffff821660005b8551831015610ed15760008080610d2e8987611381565b975060ff91821694501691506001831415610d5657610d4d8987611402565b96509050610e7a565b82610d82576060610d678a8861147a565b97509050610d758b8261152b565b9150828501945050610e7a565b6002831415610e2957610d958987611402565b965090506000610da58a886118b5565b975061ffff1690506060610dba8b8984611926565b98509050610dc98c8483611a15565b610e1e576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526032815260200180612ab16032913960400191505060405180910390fd5b505092810192610e7a565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602c81526020018061296c602c913960400191505060405180910390fd5b848282604051602001808481526020018381526020018273ffffffffffffffffffffffffffffffffffffffff1681526020019350505050604051602081830303815290604052805190602001209450505050610d17565b8361ffff168110158015610ee95750610ee982611c5d565b979650505050505050565b9055565b61096b7fbe27a319efc8734e89e26ba4bc95f5c788584163b959f03fa04e2d7ab4b9a1207fffffffff00000000000000000000000000000000000000000000000000000000841673ffffffffffffffffffffffffffffffffffffffff8416611c9a565b5490565b60005b8151811015611129576000828281518110610f7957fe5b602002602001015190506000606082604001515a1015610fc5576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016109d29061277c565b82511561105d57826060015173ffffffffffffffffffffffffffffffffffffffff168360400151600014610ffd578360400151610fff565b5a5b8460a0015160405161101191906126ae565b6000604051808303818686f4925050503d806000811461104d576040519150601f19603f3d011682016040523d82523d6000602084013e611052565b606091505b5090925090506110f2565b826060015173ffffffffffffffffffffffffffffffffffffffff1683608001518460400151600014611093578460400151611095565b5a5b908560a001516040516110a891906126ae565b600060405180830381858888f193505050503d80600081146110e6576040519150601f19603f3d011682016040523d82523d6000602084013e6110eb565b606091505b5090925090505b8115611113578560405161110691906126f6565b60405180910390a061111e565b61111e838783611cc8565b505050600101610f62565b505050565b60008061113a83611d18565b915091506000611149836109eb565b9050808214611184576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016109d290612745565b600182016111928482611d31565b7f1f180c27086c7a39ea2a7b25239d1ab92348f07ca7bb59d1438fcf527568f88184826040516111c3929190612896565b60405180910390a15050505050565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167fec6aba5000000000000000000000000000000000000000000000000000000000148061126557507fffffffff0000000000000000000000000000000000000000000000000000000082167f4e2312e000000000000000000000000000000000000000000000000000000000145b806112b157507fffffffff0000000000000000000000000000000000000000000000000000000082167f150b7a0200000000000000000000000000000000000000000000000000000000145b806112fd57507fffffffff0000000000000000000000000000000000000000000000000000000082167fc0ee0b8a00000000000000000000000000000000000000000000000000000000145b1561130a57506001610481565b61047e82611d5c565b6020810151815160f09190911c9060029081111561137c576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526027815260200180612a1d6027913960400191505060405180910390fd5b915091565b8082016020015160f881901c9060f01c60ff16600283018381116113a157fe5b84518111156113fb576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526026815260200180612be66026913960400191505060405180910390fd5b9250925092565b8082016020015160601c6014820182811161141957fe5b8351811115611473576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806129fa6023913960400191505060405180910390fd5b9250929050565b6040805160428082526080820190925260609160009190602082018180368337019050509150828401602001805160208401526020810151604084015260228101516042840152506042830190508281116114d157fe5b8351811115611473576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526023815260200180612b4e6023913960400191505060405180910390fd5b60008151604214611587576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603a815260200180612932603a913960400191505060405180910390fd5b60008260018451038151811061159957fe5b602001015160f81c60f81b60f81c60ff1690506000836040815181106115bb57fe5b016020015160f81c905060006115d18582611db9565b905060006115e0866020611db9565b90507f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a081111561165b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603d8152602001806128f5603d913960400191505060405180910390fd5b8260ff16601b1415801561167357508260ff16601c14155b156116c9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603d815260200180612a44603d913960400191505060405180910390fd5b600184141561173d5760018784848460405160008152602001604052604051808581526020018460ff1681526020018381526020018281526020019450505050506020604051602081039080840390855afa15801561172c573d6000803e3d6000fd5b50505060206040510351945061183f565b60028414156117ee5760018760405160200180807f19457468657265756d205369676e6564204d6573736167653a0a333200000000815250601c018281526020019150506040516020818303038152906040528051906020012084848460405160008152602001604052604051808581526020018460ff1681526020018381526020018281526020019450505050506020604051602081039080840390855afa15801561172c573d6000803e3d6000fd5b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603c815260200180612baa603c913960400191505060405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff85166118ab576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526030815260200180612a816030913960400191505060405180910390fd5b5050505092915050565b8082016020015160f01c600282018281116118cc57fe5b8351811115611473576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526022815260200180612c2d6022913960400191505060405180910390fd5b606060008267ffffffffffffffff8111801561194157600080fd5b506040519080825280601f01601f19166020018201604052801561196c576020820181803683370190505b509150838501602001600060205b858110156119935790820151848201526020810161197a565b84860160200180519390920151908501525250828201838110156119b357fe5b8451811115611a0d576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526021815260200180612c0c6021913960400191505060405180910390fd5b935093915050565b60008082600184510381518110611a2857fe5b016020015160f81c90506001811480611a415750600281145b15611a85578373ffffffffffffffffffffffffffffffffffffffff16611a67868561152b565b73ffffffffffffffffffffffffffffffffffffffff16149150611c55565b6003811415611c045782517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81018452604080517f1626ba7e000000000000000000000000000000000000000000000000000000008152600481018881526024820192835286516044830152865173ffffffffffffffffffffffffffffffffffffffff891693631626ba7e938b938a9390929160640190602085019080838360005b83811015611b3f578181015183820152602001611b27565b50505050905090810190601f168015611b6c5780820380516001836020036101000a031916815260200191505b50935050505060206040518083038186803b158015611b8a57600080fd5b505afa158015611b9e573d6000803e3d6000fd5b505050506040513d6020811015611bb457600080fd5b50519084527fffffffff00000000000000000000000000000000000000000000000000000000167f1626ba7e00000000000000000000000000000000000000000000000000000000149150611c55565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603f815260200180612b0f603f913960400191505060405180910390fd5b509392505050565b6000811580159061047e5750611c927fea7157fa25e3aa17d0ae2d5280fa4e24d421c61842aa85e45194e1145aa72bf8610f5b565b909114919050565b6040805160208082019590955280820193909352805180840382018152606090930190528151919092012055565b826020015115611cda57805160208201fd5b7f3dbd1590ea96dd3253a91f24e64e3a502e1225d602a5731357bc12643070ccd78282604051611d0b9291906126ff565b60405180910390a1505050565b606081901c916bffffffffffffffffffffffff90911690565b61096b7f8d0bf1fd623d628c741362c1289948e57b3e2905218c676d3e69abee36d6ae2e8383611c9a565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f025b22bc000000000000000000000000000000000000000000000000000000001415611db057506001610481565b61047e82611e21565b60008160200183511015611e18576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603c815260200180612c4f603c913960400191505060405180910390fd5b50016020015190565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f389901c7000000000000000000000000000000000000000000000000000000001415611e7557506001610481565b61047e8260007fffffffff0000000000000000000000000000000000000000000000000000000082167f783649a6000000000000000000000000000000000000000000000000000000001415611ecd57506001610481565b61047e8260007fffffffff0000000000000000000000000000000000000000000000000000000082161580611f4357507fffffffff0000000000000000000000000000000000000000000000000000000082167f36e7817500000000000000000000000000000000000000000000000000000000145b15611f5057506001610481565b7f01ffc9a7000000000000000000000000000000000000000000000000000000007fffffffff0000000000000000000000000000000000000000000000000000000083161461047e565b803573ffffffffffffffffffffffffffffffffffffffff8116811461048157600080fd5b600082601f830112611fce578081fd5b8135602067ffffffffffffffff80831115611fe557fe5b611ff282838502016128a4565b83815282810190868401865b868110156120ce578135890160c0807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0838e0301121561203c57898afd5b604080518281018181108a8211171561205157fe5b825261205e848b0161211e565b815261206b82850161211e565b8a8201526060808501358383015260809250612088838601611f9a565b9082015260a084810135838301529284013592898411156120a7578c8dfd5b6120b58f8c8688010161219e565b9082015287525050509285019290850190600101611ffe565b509098975050505050505050565b60008083601f8401126120ed578182fd5b50813567ffffffffffffffff811115612104578182fd5b602083019150836020808302850101111561147357600080fd5b8035801515811461048157600080fd5b80357fffffffff000000000000000000000000000000000000000000000000000000008116811461048157600080fd5b60008083601f84011261216f578182fd5b50813567ffffffffffffffff811115612186578182fd5b60208301915083602082850101111561147357600080fd5b600082601f8301126121ae578081fd5b813567ffffffffffffffff8111156121c257fe5b6121f360207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116016128a4565b818152846020838601011115612207578283fd5b816020850160208301379081016020019190915292915050565b600060208284031215612232578081fd5b61064e82611f9a565b60008060008060008060008060a0898b031215612256578384fd5b61225f89611f9a565b975061226d60208a01611f9a565b9650604089013567ffffffffffffffff80821115612289578586fd5b6122958c838d016120dc565b909850965060608b01359150808211156122ad578586fd5b6122b98c838d016120dc565b909650945060808b01359150808211156122d1578384fd5b506122de8b828c0161215e565b999c989b5096995094979396929594505050565b600080600080600060808688031215612309578081fd5b61231286611f9a565b945061232060208701611f9a565b935060408601359250606086013567ffffffffffffffff811115612342578182fd5b61234e8882890161215e565b969995985093965092949392505050565b60008060008060008060a08789031215612377578182fd5b61238087611f9a565b955061238e60208801611f9a565b94506040870135935060608701359250608087013567ffffffffffffffff8111156123b7578283fd5b6123c389828a0161215e565b979a9699509497509295939492505050565b6000602082840312156123e6578081fd5b813567ffffffffffffffff8111156123fc578182fd5b6106b284828501611fbe565b60008060006060848603121561241c578283fd5b833567ffffffffffffffff80821115612433578485fd5b61243f87838801611fbe565b945060208601359350604086013591508082111561245b578283fd5b506124688682870161219e565b9150509250925092565b600060208284031215612483578081fd5b5035919050565b60008060006040848603121561249e578283fd5b83359250602084013567ffffffffffffffff8111156124bb578283fd5b6124c78682870161215e565b9497909650939450505050565b6000602082840312156124e5578081fd5b61064e8261212e565b60008060408385031215612500578182fd5b6125098361212e565b915061251760208401611f9a565b90509250929050565b60008060008060408587031215612535578182fd5b843567ffffffffffffffff8082111561254c578384fd5b6125588883890161215e565b90965094506020870135915080821115612570578384fd5b5061257d8782880161215e565b95989497509550505050565b60006020828403121561259a578081fd5b813567ffffffffffffffff8111156125b0578182fd5b6106b28482850161219e565b6000815180845260208085019450848183028601828601855b858110156126575783830389528151805115158452858101511515868501526040808201519085015260608082015173ffffffffffffffffffffffffffffffffffffffff16908501526080808201519085015260a09081015160c09185018290529061264381860183612664565b9a87019a94505050908401906001016125d5565b5090979650505050505050565b6000815180845261267c8160208601602086016128c8565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b600082516126c08184602087016128c8565b9190910192915050565b73ffffffffffffffffffffffffffffffffffffffff91909116815260200190565b901515815260200190565b90815260200190565b6000838252604060208301526106b26040830184612664565b7fffffffff0000000000000000000000000000000000000000000000000000000091909116815260200190565b6020808252601f908201527f4d61696e4d6f64756c65235f617574683a20494e56414c49445f4e4f4e434500604082015260600190565b60208082526024908201527f4d6f64756c6543616c6c73235f657865637574653a204e4f545f454e4f55474860408201527f5f47415300000000000000000000000000000000000000000000000000000000606082015260800190565b60208082526026908201527f4d6f64756c6543616c6c7323657865637574653a20494e56414c49445f53494760408201527f4e41545552450000000000000000000000000000000000000000000000000000606082015260800190565b600060408252600560408301527f73656c663a00000000000000000000000000000000000000000000000000000060608301526080602083015261064e60808301846125bc565b6000838252604060208301526106b260408301846125bc565b918252602082015260400190565b60405181810167ffffffffffffffff811182821017156128c057fe5b604052919050565b60005b838110156128e35781810151838201526020016128cb565b838111156109e5575050600091015256fe5369676e617475726556616c696461746f72237265636f7665725369676e65723a20696e76616c6964207369676e6174757265202773272076616c75655369676e617475726556616c696461746f72237265636f7665725369676e65723a20696e76616c6964207369676e6174757265206c656e6774684d6f64756c6541757468235f7369676e617475726556616c69646174696f6e20494e56414c49445f464c41474d6f64756c654175746855706772616461626c6523757064617465496d6167654861736820494e56414c49445f494d4147455f484153484d6f64756c65486f6f6b732372656d6f7665486f6f6b3a20484f4f4b5f4e4f545f524547495354455245444c696242797465732372656164416464726573733a204f55545f4f465f424f554e44534c696242797465732372656164466972737455696e7431363a204f55545f4f465f424f554e44535369676e617475726556616c696461746f72237265636f7665725369676e65723a20696e76616c6964207369676e6174757265202776272076616c75655369676e617475726556616c696461746f72237265636f7665725369676e65723a20494e56414c49445f5349474e45524d6f64756c6541757468235f7369676e617475726556616c69646174696f6e3a20494e56414c49445f5349474e41545552454d6f64756c65486f6f6b7323616464486f6f6b3a20484f4f4b5f414c52454144595f524547495354455245445369676e617475726556616c696461746f7223697356616c69645369676e61747572653a20554e535550504f525445445f5349474e41545552455f545950454c696242797465732372656164427974657336363a204f55545f4f465f424f554e44534d6f64756c6555706461746523757064617465496d706c656d656e746174696f6e3a20494e56414c49445f494d504c454d454e544154494f4e5369676e617475726556616c696461746f72237265636f7665725369676e65723a20554e535550504f525445445f5349474e41545552455f545950454c69624279746573237265616455696e743855696e74383a204f55545f4f465f424f554e44534c69624279746573237265616442797465733a204f55545f4f465f424f554e44534c69624279746573237265616455696e7431363a204f55545f4f465f424f554e44534c696242797465732372656164427974657333323a20475245415445525f4f525f455155414c5f544f5f33325f4c454e4754485f52455155495245444d6f64756c6553656c6641757468236f6e6c7953656c663a204e4f545f415554484f52495a4544a2646970667358221220aebb8d931ef86555b6441c416b208bb9fe8fe0974c5733ebbccce548296c37ce64736f6c6343000706003300000000000000000000000000000000000000000000000000', + gasLimit: 8000000 + }) + ) // Deploy guestModule - await signer.sendTransaction({ - to: '0x8A5Bc19e22D6aD55a2c763B93A75d09F321fe764', - data: '0x9c4ae2d0000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001dfc608060405234801561001057600080fd5b50611ddc806100206000396000f3fe60806040526004361061007b5760003560e01c80637a9a16281161004e5780637a9a1628146101255780638c3f55631461014557806390042baf14610172578063affed0e0146101925761007b565b806301ffc9a7146100805780631626ba7e146100b657806320c13b0b146100e357806361c2926c14610103575b600080fd5b34801561008c57600080fd5b506100a061009b366004611677565b6101a7565b6040516100ad91906118be565b60405180910390f35b3480156100c257600080fd5b506100d66100d136600461162d565b6101ba565b6040516100ad91906118eb565b3480156100ef57600080fd5b506100d66100fe3660046116b7565b610233565b34801561010f57600080fd5b5061012361011e366004611590565b61028d565b005b34801561013157600080fd5b506101236101403660046115c3565b6102ce565b34801561015157600080fd5b50610165610160366004611753565b6102f6565b6040516100ad91906118c9565b610185610180366004611720565b610322565b6040516100ad919061189d565b34801561019e57600080fd5b506101656103d6565b60006101b2826103e7565b90505b919050565b60006102046101c885610444565b84848080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506104a492505050565b1561022c57507f1626ba7e000000000000000000000000000000000000000000000000000000005b9392505050565b600061025d6101c88686604051808383808284376040519201829003909120935061044492505050565b1561028557507f20c13b0b000000000000000000000000000000000000000000000000000000005b949350505050565b60006102be826040516020016102a39190611a19565b60405160208183030381529060405280519060200120610444565b90506102ca818361069c565b5050565b60006102e4846040516020016102a39190611975565b90506102f0818561069c565b50505050565b60006101b27f8d0bf1fd623d628c741362c1289948e57b3e2905218c676d3e69abee36d6ae2e83610817565b600033301461037c576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526027815260200180611d806027913960400191505060405180910390fd5b81516020830134f06040805173ffffffffffffffffffffffffffffffffffffffff8316815290519192507fa506ad4e7f05eceba62a023c3219e5bd98a615f4fa87e2afb08a2da5cf62bf0c919081900360200190a1919050565b60006103e260006102f6565b905090565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f90042baf00000000000000000000000000000000000000000000000000000000141561043b575060016101b5565b6101b282610844565b604080517f19010000000000000000000000000000000000000000000000000000000000006020808301919091524660228301523060601b6042830152605680830194909452825180830390940184526076909101909152815191012090565b60008060006104b2846108a1565b909250905061ffff821660005b855183101561067957600080806104d6898761090f565b975060ff918216945016915060018314156104fe576104f58987610990565b96509050610622565b8261052a57606061050f8a88610a08565b9750905061051d8b82610ab9565b9150828501945050610622565b60028314156105d15761053d8987610990565b96509050600061054d8a88610e43565b975061ffff16905060606105628b8984610eb4565b985090506105718c8483610fa3565b6105c6576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526032815260200180611c0b6032913960400191505060405180910390fd5b505092810192610622565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602c815260200180611b28602c913960400191505060405180910390fd5b848282604051602001808481526020018381526020018273ffffffffffffffffffffffffffffffffffffffff16815260200193505050506040516020818303038152906040528051906020012094505050506104bf565b8361ffff1681101580156106915750610691826111eb565b979650505050505050565b60005b81518110156108125760008282815181106106b657fe5b6020026020010151905060006060826000015115610709576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610700906119bc565b60405180910390fd5b82604001515a1015610747576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161070090611918565b826060015173ffffffffffffffffffffffffffffffffffffffff168360800151846040015160001461077d57846040015161077f565b5a5b908560a001516040516107929190611881565b600060405180830381858888f193505050503d80600081146107d0576040519150601f19603f3d011682016040523d82523d6000602084013e6107d5565b606091505b50909250905081156107fc57856040516107ef91906118c9565b60405180910390a0610807565b6108078387836111f1565b50505060010161069f565b505050565b60408051602080820194909452808201929092528051808303820181526060909201905280519101205490565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f389901c7000000000000000000000000000000000000000000000000000000001415610898575060016101b5565b6101b282611241565b6020810151815160f09190911c9060029081111561090a576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526027815260200180611b776027913960400191505060405180910390fd5b915091565b8082016020015160f881901c9060f01c60ff166002830183811161092f57fe5b8451811115610989576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526026815260200180611cdb6026913960400191505060405180910390fd5b9250925092565b8082016020015160601c601482018281116109a757fe5b8351811115610a01576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526023815260200180611b546023913960400191505060405180910390fd5b9250929050565b604080516042808252608082019092526060916000919060208201818036833701905050915082840160200180516020840152602081015160408401526022810151604284015250604283019050828111610a5f57fe5b8351811115610a01576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526023815260200180611c7c6023913960400191505060405180910390fd5b60008151604214610b15576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603a815260200180611aee603a913960400191505060405180910390fd5b600082600184510381518110610b2757fe5b602001015160f81c60f81b60f81c60ff169050600083604081518110610b4957fe5b016020015160f81c90506000610b5f85826112c9565b90506000610b6e8660206112c9565b90507f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a0811115610be9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603d815260200180611ab1603d913960400191505060405180910390fd5b8260ff16601b14158015610c0157508260ff16601c14155b15610c57576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603d815260200180611b9e603d913960400191505060405180910390fd5b6001841415610ccb5760018784848460405160008152602001604052604051808581526020018460ff1681526020018381526020018281526020019450505050506020604051602081039080840390855afa158015610cba573d6000803e3d6000fd5b505050602060405103519450610dcd565b6002841415610d7c5760018760405160200180807f19457468657265756d205369676e6564204d6573736167653a0a333200000000815250601c018281526020019150506040516020818303038152906040528051906020012084848460405160008152602001604052604051808581526020018460ff1681526020018381526020018281526020019450505050506020604051602081039080840390855afa158015610cba573d6000803e3d6000fd5b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603c815260200180611c9f603c913960400191505060405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8516610e39576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526030815260200180611bdb6030913960400191505060405180910390fd5b5050505092915050565b8082016020015160f01c60028201828111610e5a57fe5b8351811115610a01576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526022815260200180611d226022913960400191505060405180910390fd5b606060008267ffffffffffffffff81118015610ecf57600080fd5b506040519080825280601f01601f191660200182016040528015610efa576020820181803683370190505b509150838501602001600060205b85811015610f2157908201518482015260208101610f08565b8486016020018051939092015190850152525082820183811015610f4157fe5b8451811115610f9b576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526021815260200180611d016021913960400191505060405180910390fd5b935093915050565b60008082600184510381518110610fb657fe5b016020015160f81c90506001811480610fcf5750600281145b15611013578373ffffffffffffffffffffffffffffffffffffffff16610ff58685610ab9565b73ffffffffffffffffffffffffffffffffffffffff161491506111e3565b60038114156111925782517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81018452604080517f1626ba7e000000000000000000000000000000000000000000000000000000008152600481018881526024820192835286516044830152865173ffffffffffffffffffffffffffffffffffffffff891693631626ba7e938b938a9390929160640190602085019080838360005b838110156110cd5781810151838201526020016110b5565b50505050905090810190601f1680156110fa5780820380516001836020036101000a031916815260200191505b50935050505060206040518083038186803b15801561111857600080fd5b505afa15801561112c573d6000803e3d6000fd5b505050506040513d602081101561114257600080fd5b50519084527fffffffff00000000000000000000000000000000000000000000000000000000167f1626ba7e000000000000000000000000000000000000000000000000000000001491506111e3565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603f815260200180611c3d603f913960400191505060405180910390fd5b509392505050565b50600190565b82602001511561120357805160208201fd5b7f3dbd1590ea96dd3253a91f24e64e3a502e1225d602a5731357bc12643070ccd782826040516112349291906118d2565b60405180910390a1505050565b60007fffffffff00000000000000000000000000000000000000000000000000000000821615806112b357507fffffffff0000000000000000000000000000000000000000000000000000000082167f36e7817500000000000000000000000000000000000000000000000000000000145b156112c0575060016101b5565b6101b282611331565b60008160200183511015611328576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603c815260200180611d44603c913960400191505060405180910390fd5b50016020015190565b7fffffffff0000000000000000000000000000000000000000000000000000000081167f01ffc9a70000000000000000000000000000000000000000000000000000000014919050565b803573ffffffffffffffffffffffffffffffffffffffff811681146101b557600080fd5b600082601f8301126113af578081fd5b8135602067ffffffffffffffff808311156113c657fe5b6113d38283850201611a60565b83815282810190868401865b868110156114af578135890160c0807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0838e0301121561141d57898afd5b604080518281018181108a8211171561143257fe5b825261143f848b016114bd565b815261144c8285016114bd565b8a820152606080850135838301526080925061146983860161137b565b9082015260a08481013583830152928401359289841115611488578c8dfd5b6114968f8c8688010161150d565b90820152875250505092850192908501906001016113df565b509098975050505050505050565b803580151581146101b557600080fd5b60008083601f8401126114de578182fd5b50813567ffffffffffffffff8111156114f5578182fd5b602083019150836020828501011115610a0157600080fd5b600082601f83011261151d578081fd5b813567ffffffffffffffff81111561153157fe5b61156260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601611a60565b818152846020838601011115611576578283fd5b816020850160208301379081016020019190915292915050565b6000602082840312156115a1578081fd5b813567ffffffffffffffff8111156115b7578182fd5b6102858482850161139f565b6000806000606084860312156115d7578182fd5b833567ffffffffffffffff808211156115ee578384fd5b6115fa8783880161139f565b9450602086013593506040860135915080821115611616578283fd5b506116238682870161150d565b9150509250925092565b600080600060408486031215611641578283fd5b83359250602084013567ffffffffffffffff81111561165e578283fd5b61166a868287016114cd565b9497909650939450505050565b600060208284031215611688578081fd5b81357fffffffff000000000000000000000000000000000000000000000000000000008116811461022c578182fd5b600080600080604085870312156116cc578081fd5b843567ffffffffffffffff808211156116e3578283fd5b6116ef888389016114cd565b90965094506020870135915080821115611707578283fd5b50611714878288016114cd565b95989497509550505050565b600060208284031215611731578081fd5b813567ffffffffffffffff811115611747578182fd5b6102858482850161150d565b600060208284031215611764578081fd5b5035919050565b60008282518085526020808601955080818302840101818601855b8481101561182a578583037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00189528151805115158452848101511515858501526040808201519085015260608082015173ffffffffffffffffffffffffffffffffffffffff16908501526080808201519085015260a09081015160c09185018290529061181681860183611837565b9a86019a9450505090830190600101611786565b5090979650505050505050565b6000815180845261184f816020860160208601611a84565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60008251611893818460208701611a84565b9190910192915050565b73ffffffffffffffffffffffffffffffffffffffff91909116815260200190565b901515815260200190565b90815260200190565b6000838252604060208301526102856040830184611837565b7fffffffff0000000000000000000000000000000000000000000000000000000091909116815260200190565b60208082526029908201527f47756573744d6f64756c65235f6578656375746547756573743a204e4f545f4560408201527f4e4f5547485f4741530000000000000000000000000000000000000000000000606082015260800190565b600060408252600660408301527f67756573743a000000000000000000000000000000000000000000000000000060608301526080602083015261022c608083018461176b565b60208082526033908201527f47756573744d6f64756c65235f6578656375746547756573743a2064656c656760408201527f61746543616c6c206e6f7420616c6c6f77656400000000000000000000000000606082015260800190565b600060408252600560408301527f73656c663a00000000000000000000000000000000000000000000000000000060608301526080602083015261022c608083018461176b565b60405181810167ffffffffffffffff81118282101715611a7c57fe5b604052919050565b60005b83811015611a9f578181015183820152602001611a87565b838111156102f0575050600091015256fe5369676e617475726556616c696461746f72237265636f7665725369676e65723a20696e76616c6964207369676e6174757265202773272076616c75655369676e617475726556616c696461746f72237265636f7665725369676e65723a20696e76616c6964207369676e6174757265206c656e6774684d6f64756c6541757468235f7369676e617475726556616c69646174696f6e20494e56414c49445f464c41474c696242797465732372656164416464726573733a204f55545f4f465f424f554e44534c696242797465732372656164466972737455696e7431363a204f55545f4f465f424f554e44535369676e617475726556616c696461746f72237265636f7665725369676e65723a20696e76616c6964207369676e6174757265202776272076616c75655369676e617475726556616c696461746f72237265636f7665725369676e65723a20494e56414c49445f5349474e45524d6f64756c6541757468235f7369676e617475726556616c69646174696f6e3a20494e56414c49445f5349474e41545552455369676e617475726556616c696461746f7223697356616c69645369676e61747572653a20554e535550504f525445445f5349474e41545552455f545950454c696242797465732372656164427974657336363a204f55545f4f465f424f554e44535369676e617475726556616c696461746f72237265636f7665725369676e65723a20554e535550504f525445445f5349474e41545552455f545950454c69624279746573237265616455696e743855696e74383a204f55545f4f465f424f554e44534c69624279746573237265616442797465733a204f55545f4f465f424f554e44534c69624279746573237265616455696e7431363a204f55545f4f465f424f554e44534c696242797465732372656164427974657333323a20475245415445525f4f525f455155414c5f544f5f33325f4c454e4754485f52455155495245444d6f64756c6553656c6641757468236f6e6c7953656c663a204e4f545f415554484f52495a4544a2646970667358221220f5a1de0b650baa2ee828e8766bc6dbd0c74da0cc4735a143852d24f868e4b62464736f6c6343000706003300000000', - gasLimit: 8000000 - }) + responses.push( + await signer.sendTransaction({ + to: '0x8A5Bc19e22D6aD55a2c763B93A75d09F321fe764', + data: '0x9c4ae2d0000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001dfc608060405234801561001057600080fd5b50611ddc806100206000396000f3fe60806040526004361061007b5760003560e01c80637a9a16281161004e5780637a9a1628146101255780638c3f55631461014557806390042baf14610172578063affed0e0146101925761007b565b806301ffc9a7146100805780631626ba7e146100b657806320c13b0b146100e357806361c2926c14610103575b600080fd5b34801561008c57600080fd5b506100a061009b366004611677565b6101a7565b6040516100ad91906118be565b60405180910390f35b3480156100c257600080fd5b506100d66100d136600461162d565b6101ba565b6040516100ad91906118eb565b3480156100ef57600080fd5b506100d66100fe3660046116b7565b610233565b34801561010f57600080fd5b5061012361011e366004611590565b61028d565b005b34801561013157600080fd5b506101236101403660046115c3565b6102ce565b34801561015157600080fd5b50610165610160366004611753565b6102f6565b6040516100ad91906118c9565b610185610180366004611720565b610322565b6040516100ad919061189d565b34801561019e57600080fd5b506101656103d6565b60006101b2826103e7565b90505b919050565b60006102046101c885610444565b84848080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506104a492505050565b1561022c57507f1626ba7e000000000000000000000000000000000000000000000000000000005b9392505050565b600061025d6101c88686604051808383808284376040519201829003909120935061044492505050565b1561028557507f20c13b0b000000000000000000000000000000000000000000000000000000005b949350505050565b60006102be826040516020016102a39190611a19565b60405160208183030381529060405280519060200120610444565b90506102ca818361069c565b5050565b60006102e4846040516020016102a39190611975565b90506102f0818561069c565b50505050565b60006101b27f8d0bf1fd623d628c741362c1289948e57b3e2905218c676d3e69abee36d6ae2e83610817565b600033301461037c576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526027815260200180611d806027913960400191505060405180910390fd5b81516020830134f06040805173ffffffffffffffffffffffffffffffffffffffff8316815290519192507fa506ad4e7f05eceba62a023c3219e5bd98a615f4fa87e2afb08a2da5cf62bf0c919081900360200190a1919050565b60006103e260006102f6565b905090565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f90042baf00000000000000000000000000000000000000000000000000000000141561043b575060016101b5565b6101b282610844565b604080517f19010000000000000000000000000000000000000000000000000000000000006020808301919091524660228301523060601b6042830152605680830194909452825180830390940184526076909101909152815191012090565b60008060006104b2846108a1565b909250905061ffff821660005b855183101561067957600080806104d6898761090f565b975060ff918216945016915060018314156104fe576104f58987610990565b96509050610622565b8261052a57606061050f8a88610a08565b9750905061051d8b82610ab9565b9150828501945050610622565b60028314156105d15761053d8987610990565b96509050600061054d8a88610e43565b975061ffff16905060606105628b8984610eb4565b985090506105718c8483610fa3565b6105c6576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526032815260200180611c0b6032913960400191505060405180910390fd5b505092810192610622565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602c815260200180611b28602c913960400191505060405180910390fd5b848282604051602001808481526020018381526020018273ffffffffffffffffffffffffffffffffffffffff16815260200193505050506040516020818303038152906040528051906020012094505050506104bf565b8361ffff1681101580156106915750610691826111eb565b979650505050505050565b60005b81518110156108125760008282815181106106b657fe5b6020026020010151905060006060826000015115610709576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610700906119bc565b60405180910390fd5b82604001515a1015610747576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161070090611918565b826060015173ffffffffffffffffffffffffffffffffffffffff168360800151846040015160001461077d57846040015161077f565b5a5b908560a001516040516107929190611881565b600060405180830381858888f193505050503d80600081146107d0576040519150601f19603f3d011682016040523d82523d6000602084013e6107d5565b606091505b50909250905081156107fc57856040516107ef91906118c9565b60405180910390a0610807565b6108078387836111f1565b50505060010161069f565b505050565b60408051602080820194909452808201929092528051808303820181526060909201905280519101205490565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f389901c7000000000000000000000000000000000000000000000000000000001415610898575060016101b5565b6101b282611241565b6020810151815160f09190911c9060029081111561090a576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526027815260200180611b776027913960400191505060405180910390fd5b915091565b8082016020015160f881901c9060f01c60ff166002830183811161092f57fe5b8451811115610989576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526026815260200180611cdb6026913960400191505060405180910390fd5b9250925092565b8082016020015160601c601482018281116109a757fe5b8351811115610a01576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526023815260200180611b546023913960400191505060405180910390fd5b9250929050565b604080516042808252608082019092526060916000919060208201818036833701905050915082840160200180516020840152602081015160408401526022810151604284015250604283019050828111610a5f57fe5b8351811115610a01576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526023815260200180611c7c6023913960400191505060405180910390fd5b60008151604214610b15576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603a815260200180611aee603a913960400191505060405180910390fd5b600082600184510381518110610b2757fe5b602001015160f81c60f81b60f81c60ff169050600083604081518110610b4957fe5b016020015160f81c90506000610b5f85826112c9565b90506000610b6e8660206112c9565b90507f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a0811115610be9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603d815260200180611ab1603d913960400191505060405180910390fd5b8260ff16601b14158015610c0157508260ff16601c14155b15610c57576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603d815260200180611b9e603d913960400191505060405180910390fd5b6001841415610ccb5760018784848460405160008152602001604052604051808581526020018460ff1681526020018381526020018281526020019450505050506020604051602081039080840390855afa158015610cba573d6000803e3d6000fd5b505050602060405103519450610dcd565b6002841415610d7c5760018760405160200180807f19457468657265756d205369676e6564204d6573736167653a0a333200000000815250601c018281526020019150506040516020818303038152906040528051906020012084848460405160008152602001604052604051808581526020018460ff1681526020018381526020018281526020019450505050506020604051602081039080840390855afa158015610cba573d6000803e3d6000fd5b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603c815260200180611c9f603c913960400191505060405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8516610e39576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526030815260200180611bdb6030913960400191505060405180910390fd5b5050505092915050565b8082016020015160f01c60028201828111610e5a57fe5b8351811115610a01576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526022815260200180611d226022913960400191505060405180910390fd5b606060008267ffffffffffffffff81118015610ecf57600080fd5b506040519080825280601f01601f191660200182016040528015610efa576020820181803683370190505b509150838501602001600060205b85811015610f2157908201518482015260208101610f08565b8486016020018051939092015190850152525082820183811015610f4157fe5b8451811115610f9b576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526021815260200180611d016021913960400191505060405180910390fd5b935093915050565b60008082600184510381518110610fb657fe5b016020015160f81c90506001811480610fcf5750600281145b15611013578373ffffffffffffffffffffffffffffffffffffffff16610ff58685610ab9565b73ffffffffffffffffffffffffffffffffffffffff161491506111e3565b60038114156111925782517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81018452604080517f1626ba7e000000000000000000000000000000000000000000000000000000008152600481018881526024820192835286516044830152865173ffffffffffffffffffffffffffffffffffffffff891693631626ba7e938b938a9390929160640190602085019080838360005b838110156110cd5781810151838201526020016110b5565b50505050905090810190601f1680156110fa5780820380516001836020036101000a031916815260200191505b50935050505060206040518083038186803b15801561111857600080fd5b505afa15801561112c573d6000803e3d6000fd5b505050506040513d602081101561114257600080fd5b50519084527fffffffff00000000000000000000000000000000000000000000000000000000167f1626ba7e000000000000000000000000000000000000000000000000000000001491506111e3565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603f815260200180611c3d603f913960400191505060405180910390fd5b509392505050565b50600190565b82602001511561120357805160208201fd5b7f3dbd1590ea96dd3253a91f24e64e3a502e1225d602a5731357bc12643070ccd782826040516112349291906118d2565b60405180910390a1505050565b60007fffffffff00000000000000000000000000000000000000000000000000000000821615806112b357507fffffffff0000000000000000000000000000000000000000000000000000000082167f36e7817500000000000000000000000000000000000000000000000000000000145b156112c0575060016101b5565b6101b282611331565b60008160200183511015611328576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603c815260200180611d44603c913960400191505060405180910390fd5b50016020015190565b7fffffffff0000000000000000000000000000000000000000000000000000000081167f01ffc9a70000000000000000000000000000000000000000000000000000000014919050565b803573ffffffffffffffffffffffffffffffffffffffff811681146101b557600080fd5b600082601f8301126113af578081fd5b8135602067ffffffffffffffff808311156113c657fe5b6113d38283850201611a60565b83815282810190868401865b868110156114af578135890160c0807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0838e0301121561141d57898afd5b604080518281018181108a8211171561143257fe5b825261143f848b016114bd565b815261144c8285016114bd565b8a820152606080850135838301526080925061146983860161137b565b9082015260a08481013583830152928401359289841115611488578c8dfd5b6114968f8c8688010161150d565b90820152875250505092850192908501906001016113df565b509098975050505050505050565b803580151581146101b557600080fd5b60008083601f8401126114de578182fd5b50813567ffffffffffffffff8111156114f5578182fd5b602083019150836020828501011115610a0157600080fd5b600082601f83011261151d578081fd5b813567ffffffffffffffff81111561153157fe5b61156260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601611a60565b818152846020838601011115611576578283fd5b816020850160208301379081016020019190915292915050565b6000602082840312156115a1578081fd5b813567ffffffffffffffff8111156115b7578182fd5b6102858482850161139f565b6000806000606084860312156115d7578182fd5b833567ffffffffffffffff808211156115ee578384fd5b6115fa8783880161139f565b9450602086013593506040860135915080821115611616578283fd5b506116238682870161150d565b9150509250925092565b600080600060408486031215611641578283fd5b83359250602084013567ffffffffffffffff81111561165e578283fd5b61166a868287016114cd565b9497909650939450505050565b600060208284031215611688578081fd5b81357fffffffff000000000000000000000000000000000000000000000000000000008116811461022c578182fd5b600080600080604085870312156116cc578081fd5b843567ffffffffffffffff808211156116e3578283fd5b6116ef888389016114cd565b90965094506020870135915080821115611707578283fd5b50611714878288016114cd565b95989497509550505050565b600060208284031215611731578081fd5b813567ffffffffffffffff811115611747578182fd5b6102858482850161150d565b600060208284031215611764578081fd5b5035919050565b60008282518085526020808601955080818302840101818601855b8481101561182a578583037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00189528151805115158452848101511515858501526040808201519085015260608082015173ffffffffffffffffffffffffffffffffffffffff16908501526080808201519085015260a09081015160c09185018290529061181681860183611837565b9a86019a9450505090830190600101611786565b5090979650505050505050565b6000815180845261184f816020860160208601611a84565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60008251611893818460208701611a84565b9190910192915050565b73ffffffffffffffffffffffffffffffffffffffff91909116815260200190565b901515815260200190565b90815260200190565b6000838252604060208301526102856040830184611837565b7fffffffff0000000000000000000000000000000000000000000000000000000091909116815260200190565b60208082526029908201527f47756573744d6f64756c65235f6578656375746547756573743a204e4f545f4560408201527f4e4f5547485f4741530000000000000000000000000000000000000000000000606082015260800190565b600060408252600660408301527f67756573743a000000000000000000000000000000000000000000000000000060608301526080602083015261022c608083018461176b565b60208082526033908201527f47756573744d6f64756c65235f6578656375746547756573743a2064656c656760408201527f61746543616c6c206e6f7420616c6c6f77656400000000000000000000000000606082015260800190565b600060408252600560408301527f73656c663a00000000000000000000000000000000000000000000000000000060608301526080602083015261022c608083018461176b565b60405181810167ffffffffffffffff81118282101715611a7c57fe5b604052919050565b60005b83811015611a9f578181015183820152602001611a87565b838111156102f0575050600091015256fe5369676e617475726556616c696461746f72237265636f7665725369676e65723a20696e76616c6964207369676e6174757265202773272076616c75655369676e617475726556616c696461746f72237265636f7665725369676e65723a20696e76616c6964207369676e6174757265206c656e6774684d6f64756c6541757468235f7369676e617475726556616c69646174696f6e20494e56414c49445f464c41474c696242797465732372656164416464726573733a204f55545f4f465f424f554e44534c696242797465732372656164466972737455696e7431363a204f55545f4f465f424f554e44535369676e617475726556616c696461746f72237265636f7665725369676e65723a20696e76616c6964207369676e6174757265202776272076616c75655369676e617475726556616c696461746f72237265636f7665725369676e65723a20494e56414c49445f5349474e45524d6f64756c6541757468235f7369676e617475726556616c69646174696f6e3a20494e56414c49445f5349474e41545552455369676e617475726556616c696461746f7223697356616c69645369676e61747572653a20554e535550504f525445445f5349474e41545552455f545950454c696242797465732372656164427974657336363a204f55545f4f465f424f554e44535369676e617475726556616c696461746f72237265636f7665725369676e65723a20554e535550504f525445445f5349474e41545552455f545950454c69624279746573237265616455696e743855696e74383a204f55545f4f465f424f554e44534c69624279746573237265616442797465733a204f55545f4f465f424f554e44534c69624279746573237265616455696e7431363a204f55545f4f465f424f554e44534c696242797465732372656164427974657333323a20475245415445525f4f525f455155414c5f544f5f33325f4c454e4754485f52455155495245444d6f64756c6553656c6641757468236f6e6c7953656c663a204e4f545f415554484f52495a4544a2646970667358221220f5a1de0b650baa2ee828e8766bc6dbd0c74da0cc4735a143852d24f868e4b62464736f6c6343000706003300000000', + gasLimit: 8000000 + }) + ) // Deploy multiCallUtils - await signer.sendTransaction({ - to: '0x8A5Bc19e22D6aD55a2c763B93A75d09F321fe764', - data: '0x9c4ae2d0000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002b1660c06040523480156200001157600080fd5b5060405162002ad638038062002ad68339810160408190526200003491620000cd565b8181816001600160a01b031660a0816001600160a01b031660601b8152505060405180606001604052806028815260200162002aae60289139816001600160a01b03166040516020016200008a92919062000104565b60408051601f198184030181529190528051602090910120608052506200014692505050565b80516001600160a01b0381168114620000c857600080fd5b919050565b60008060408385031215620000e0578182fd5b620000eb83620000b0565b9150620000fb60208401620000b0565b90509250929050565b60008351815b818110156200012657602081870181015185830152016200010a565b81811115620001355782828501525b509190910191825250602001919050565b60805160a05160601c61293762000177600039806106515280610b1b5250806106755280610b3f52506129376000f3fe6080604052600436106101805760003560e01c806398f9fbc4116100d6578063d1db39071161007f578063e90f13e711610059578063e90f13e714610395578063f209883a146103ea578063ffd7d741146103ff57610180565b8063d1db390714610395578063d5b5337f146103aa578063e717aba9146103ca57610180565b8063c272d5c3116100b0578063c272d5c314610333578063c39f2d5c14610348578063c66764e11461036857610180565b806398f9fbc4146102e9578063aeea5fb5146102fe578063b472f0a21461031357610180565b806348acd29f116101385780637ae99638116101125780637ae99638146102875780637f29d538146102a7578063984395bc146102c757610180565b806348acd29f14610227578063543196eb146102475780637082503b1461026757610180565b80631cd05dc4116101695780631cd05dc4146101d057806343d9c935146101f057806344d466c21461020557610180565b80630fdecfac146101855780631551f0ab146101b0575b600080fd5b34801561019157600080fd5b5061019a610420565b6040516101a79190612190565b60405180910390f35b3480156101bc57600080fd5b5061019a6101cb366004611e76565b610424565b3480156101dc57600080fd5b5061019a6101eb366004611bea565b610436565b3480156101fc57600080fd5b5061019a610448565b34801561021157600080fd5b50610225610220366004611ca4565b610450565b005b34801561023357600080fd5b5061019a610242366004611bea565b61080a565b34801561025357600080fd5b5061019a610262366004611bea565b610828565b34801561027357600080fd5b50610225610282366004611c0b565b61082c565b34801561029357600080fd5b5061019a6102a2366004611bea565b610cb0565b3480156102b357600080fd5b506102256102c2366004611e76565b610cc2565b3480156102d357600080fd5b506102dc610cfe565b6040516101a79190612000565b3480156102f557600080fd5b506102dc610d02565b34801561030a57600080fd5b5061019a610d06565b34801561031f57600080fd5b5061022561032e366004611c7b565b610d0a565b34801561033f57600080fd5b5061019a610de8565b34801561035457600080fd5b5061019a610363366004611bea565b610dec565b34801561037457600080fd5b50610388610383366004611bea565b610df0565b6040516101a791906121c5565b3480156103a157600080fd5b5061019a610e35565b3480156103b657600080fd5b5061019a6103c5366004611e76565b610e39565b3480156103d657600080fd5b5061019a6103e5366004611bea565b610e3d565b3480156103f657600080fd5b5061019a610e4f565b61041261040d366004611d34565b610e53565b6040516101a7929190612021565b4690565b60036020526000908152604090205481565b60006020819052908152604090205481565b60005a905090565b8360005b838110156104e9578185858381811061046957fe5b9050604002016000013586868481811061047f57fe5b90506040020160200160208101906104979190611bea565b6040516020016104a993929190612199565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101209150600101610454565b506000808773ffffffffffffffffffffffffffffffffffffffff166351605d8060e01b60405160200161051c9190611f54565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529082905261055491611f81565b6000604051808303816000865af19150503d8060008114610591576040519150601f19603f3d011682016040523d82523d6000602084013e610596565b606091505b50915091508180156105a9575080516020145b1561060e576000818060200190518101906105c49190611e8e565b9050838114610608576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016105ff90612543565b60405180910390fd5b50610732565b60405173ffffffffffffffffffffffffffffffffffffffff89169061069d907fff00000000000000000000000000000000000000000000000000000000000000907f00000000000000000000000000000000000000000000000000000000000000009087907f000000000000000000000000000000000000000000000000000000000000000090602001611ef0565b6040516020818303038152906040528051906020012060001c73ffffffffffffffffffffffffffffffffffffffff1614610703576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016105ff906125a0565b83156107325773ffffffffffffffffffffffffffffffffffffffff881660009081526002602052604090208390555b828873ffffffffffffffffffffffffffffffffffffffff167fb502b7446ca079086188acf3abef47c2f464f2ee9a72fcdf05ffcb74dcc17cee89898960405160200161077f9291906120c7565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152908290526107b89291612623565b60405180910390a383156108005773ffffffffffffffffffffffffffffffffffffffff8816600090815260016020908152604080832043908190558684526003909252909120555b5050505050505050565b73ffffffffffffffffffffffffffffffffffffffff8116315b919050565b3f90565b600080610838846110c3565b9150915060008046905080898960405160200161085793929190611f9d565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152919052805160209091012091505061ffff831660008767ffffffffffffffff811180156108ae57600080fd5b506040519080825280602002602001820160405280156108e857816020015b6108d5611b1c565b8152602001906001900390816108cd5790505b50905060005b8751851015610a9f57600080806109058b89611131565b995060ff9182169450169150600183141561092d576109248b896111b2565b98509050610a20565b8261095f57606061093e8c8a61122a565b9950905061094c88826112db565b91506109598f838d611665565b50610a20565b60028314156109ee576109728b896111b2565b9850905060006109828c8a6116f3565b995061ffff16905060606109978d8b84611764565b9a5090506109a6898483611853565b6109dc576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016105ff9061242c565b50506109e98e828c611665565b610a20565b6040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016105ff906121d8565b60405180604001604052808381526020018273ffffffffffffffffffffffffffffffffffffffff16815250858581518110610a5757fe5b60200260200101819052508380600101945050858282604051602001610a7f93929190612199565b6040516020818303038152906040528051906020012095505050506108ee565b888114610ad8576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016105ff906124e6565b60405173ffffffffffffffffffffffffffffffffffffffff8c1690610b67907fff00000000000000000000000000000000000000000000000000000000000000907f00000000000000000000000000000000000000000000000000000000000000009087907f000000000000000000000000000000000000000000000000000000000000000090602001611ef0565b6040516020818303038152906040528051906020012060001c73ffffffffffffffffffffffffffffffffffffffff1614610bcd576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016105ff906123a9565b828b73ffffffffffffffffffffffffffffffffffffffff167fb502b7446ca079086188acf3abef47c2f464f2ee9a72fcdf05ffcb74dcc17cee8885604051602001610c18919061212b565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815290829052610c5192916125fe565b60405180910390a38615610ca35773ffffffffffffffffffffffffffffffffffffffff8b1660008181526001602090815260408083204390819055878452600383528184205592825260029052208390555b5050505050505050505050565b60026020526000908152604090205481565b804210610cfb576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016105ff9061234c565b50565b3290565b4190565b4490565b600080610d1683611a9b565b9150915060008473ffffffffffffffffffffffffffffffffffffffff16638c3f5563846040518263ffffffff1660e01b8152600401610d559190612190565b60206040518083038186803b158015610d6d57600080fd5b505afa158015610d81573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610da59190611e8e565b905081811015610de1576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016105ff906122ef565b5050505050565b3a90565b3b90565b60408051603f833b9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682019092528181529080600060208401853c50919050565b4590565b4090565b60016020526000908152604090205481565b4290565b606080825167ffffffffffffffff81118015610e6e57600080fd5b50604051908082528060200260200182016040528015610e98578160200160208202803683370190505b509150825167ffffffffffffffff81118015610eb357600080fd5b50604051908082528060200260200182016040528015610ee757816020015b6060815260200190600190039081610ed25790505b50905060005b83518110156110bd576000848281518110610f0457fe5b60200260200101519050806000015115610f4a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016105ff90612489565b80604001515a1015610f88576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016105ff90612292565b806060015173ffffffffffffffffffffffffffffffffffffffff1681608001518260400151600014610fbe578260400151610fc0565b5a5b908360a00151604051610fd39190611f81565b600060405180830381858888f193505050503d8060008114611011576040519150601f19603f3d011682016040523d82523d6000602084013e611016565b606091505b5085848151811061102357fe5b6020026020010185858151811061103657fe5b602002602001018290528215151515815250505083828151811061105657fe5b60200260200101518061107e575084828151811061107057fe5b602002602001015160200151155b6110b4576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016105ff90612235565b50600101610eed565b50915091565b6020810151815160f09190911c9060029081111561112c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602781526020018061272b6027913960400191505060405180910390fd5b915091565b8082016020015160f881901c9060f01c60ff166002830183811161115157fe5b84518111156111ab576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602681526020018061285d6026913960400191505060405180910390fd5b9250925092565b8082016020015160601c601482018281116111c957fe5b8351811115611223576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806127086023913960400191505060405180910390fd5b9250929050565b60408051604280825260808201909252606091600091906020820181803683370190505091508284016020018051602084015260208101516040840152602281015160428401525060428301905082811161128157fe5b8351811115611223576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806127fe6023913960400191505060405180910390fd5b60008151604214611337576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603a8152602001806126ce603a913960400191505060405180910390fd5b60008260018451038151811061134957fe5b602001015160f81c60f81b60f81c60ff16905060008360408151811061136b57fe5b016020015160f81c905060006113818582611ab4565b90506000611390866020611ab4565b90507f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a081111561140b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603d815260200180612691603d913960400191505060405180910390fd5b8260ff16601b1415801561142357508260ff16601c14155b15611479576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603d815260200180612752603d913960400191505060405180910390fd5b60018414156114ed5760018784848460405160008152602001604052604051808581526020018460ff1681526020018381526020018281526020019450505050506020604051602081039080840390855afa1580156114dc573d6000803e3d6000fd5b5050506020604051035194506115ef565b600284141561159e5760018760405160200180807f19457468657265756d205369676e6564204d6573736167653a0a333200000000815250601c018281526020019150506040516020818303038152906040528051906020012084848460405160008152602001604052604051808581526020018460ff1681526020018381526020018281526020019450505050506020604051602081039080840390855afa1580156114dc573d6000803e3d6000fd5b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603c815260200180612821603c913960400191505060405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff851661165b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603081526020018061278f6030913960400191505060405180910390fd5b5050505092915050565b8173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f600ba597427f042bcd559a0d06fa1732cc104d6dd43cbe8845b5a0e804b2b39f60405160405180910390a380156116ee5773ffffffffffffffffffffffffffffffffffffffff821660009081526020819052604090204390555b505050565b8082016020015160f01c6002820182811161170a57fe5b8351811115611223576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806128a46022913960400191505060405180910390fd5b606060008267ffffffffffffffff8111801561177f57600080fd5b506040519080825280601f01601f1916602001820160405280156117aa576020820181803683370190505b509150838501602001600060205b858110156117d1579082015184820152602081016117b8565b84860160200180519390920151908501525250828201838110156117f157fe5b845181111561184b576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260218152602001806128836021913960400191505060405180910390fd5b935093915050565b6000808260018451038151811061186657fe5b016020015160f81c9050600181148061187f5750600281145b156118c3578373ffffffffffffffffffffffffffffffffffffffff166118a586856112db565b73ffffffffffffffffffffffffffffffffffffffff16149150611a93565b6003811415611a425782517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81018452604080517f1626ba7e000000000000000000000000000000000000000000000000000000008152600481018881526024820192835286516044830152865173ffffffffffffffffffffffffffffffffffffffff891693631626ba7e938b938a9390929160640190602085019080838360005b8381101561197d578181015183820152602001611965565b50505050905090810190601f1680156119aa5780820380516001836020036101000a031916815260200191505b50935050505060206040518083038186803b1580156119c857600080fd5b505afa1580156119dc573d6000803e3d6000fd5b505050506040513d60208110156119f257600080fd5b50519084527fffffffff00000000000000000000000000000000000000000000000000000000167f1626ba7e00000000000000000000000000000000000000000000000000000000149150611a93565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603f8152602001806127bf603f913960400191505060405180910390fd5b509392505050565b606081901c916bffffffffffffffffffffffff90911690565b60008160200183511015611b13576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603c8152602001806128c6603c913960400191505060405180910390fd5b50016020015190565b604080518082019091526000808252602082015290565b803573ffffffffffffffffffffffffffffffffffffffff8116811461082357600080fd5b8035801515811461082357600080fd5b600082601f830112611b77578081fd5b813567ffffffffffffffff811115611b8b57fe5b611bbc60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8401160161263c565b818152846020838601011115611bd0578283fd5b816020850160208301379081016020019190915292915050565b600060208284031215611bfb578081fd5b611c0482611b33565b9392505050565b600080600080600060a08688031215611c22578081fd5b611c2b86611b33565b94506020860135935060408601359250606086013567ffffffffffffffff811115611c54578182fd5b611c6088828901611b67565b925050611c6f60808701611b57565b90509295509295909350565b60008060408385031215611c8d578182fd5b611c9683611b33565b946020939093013593505050565b600080600080600060808688031215611cbb578081fd5b611cc486611b33565b945060208601359350604086013567ffffffffffffffff80821115611ce7578283fd5b818801915088601f830112611cfa578283fd5b813581811115611d08578384fd5b896020604083028501011115611d1c578384fd5b602083019550809450505050611c6f60608701611b57565b60006020808385031215611d46578182fd5b823567ffffffffffffffff80821115611d5d578384fd5b818501915085601f830112611d70578384fd5b813581811115611d7c57fe5b611d89848583020161263c565b81815284810190848601875b84811015611e67578135870160c0807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0838f03011215611dd3578a8bfd5b604080518281018181108b82111715611de857fe5b8252611df5848d01611b57565b8152611e02828501611b57565b8c82015260608085013583830152611e1c60808601611b33565b9082015260a08481013560808301529284013592915089831115611e3e578c8dfd5b611e4c8f8d85870101611b67565b91810191909152865250509287019290870190600101611d95565b50909998505050505050505050565b600060208284031215611e87578081fd5b5035919050565b600060208284031215611e9f578081fd5b5051919050565b60008151808452611ebe816020860160208601612660565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b7fff0000000000000000000000000000000000000000000000000000000000000094909416845260609290921b7fffffffffffffffffffffffffffffffffffffffff0000000000000000000000001660018401526015830152603582015260550190565b7fffffffff0000000000000000000000000000000000000000000000000000000091909116815260040190565b60008251611f93818460208701612660565b9190910192915050565b7f19010000000000000000000000000000000000000000000000000000000000008152600281019390935260609190911b7fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166022830152603682015260560190565b73ffffffffffffffffffffffffffffffffffffffff91909116815260200190565b604080825283519082018190526000906020906060840190828701845b8281101561205c57815115158452928401929084019060010161203e565b5050508381038285015284518082528282019080840283018401878501865b83811015611e67577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08684030185526120b5838351611ea6565b9487019492509086019060010161207b565b6020808252818101839052600090604080840186845b8781101561211e578135835273ffffffffffffffffffffffffffffffffffffffff612109868401611b33565b168386015291830191908301906001016120dd565b5090979650505050505050565b602080825282518282018190526000919060409081850190868401855b828110156121835781518051855286015173ffffffffffffffffffffffffffffffffffffffff16868501529284019290850190600101612148565b5091979650505050505050565b90815260200190565b928352602083019190915273ffffffffffffffffffffffffffffffffffffffff16604082015260600190565b600060208252611c046020830184611ea6565b6020808252603a908201527f526571756972655574696c73237075626c697368496e697469616c5369676e6560408201527f72733a20494e56414c49445f5349474e41545552455f464c4147000000000000606082015260800190565b60208082526027908201527f4d756c746943616c6c5574696c73236d756c746943616c6c3a2043414c4c5f5260408201527f4556455254454400000000000000000000000000000000000000000000000000606082015260800190565b60208082526028908201527f4d756c746943616c6c5574696c73236d756c746943616c6c3a204e4f545f454e60408201527f4f5547485f474153000000000000000000000000000000000000000000000000606082015260800190565b60208082526032908201527f526571756972655574696c7323726571756972654d696e4e6f6e63653a204e4f60408201527f4e43455f42454c4f575f52455155495245440000000000000000000000000000606082015260800190565b60208082526027908201527f526571756972655574696c7323726571756972654e6f6e457870697265643a2060408201527f4558504952454400000000000000000000000000000000000000000000000000606082015260800190565b60208082526048908201527f526571756972655574696c73237075626c697368496e697469616c5369676e6560408201527f72733a20554e45585045435445445f434f554e5445524641435455414c5f494d60608201527f4147455f48415348000000000000000000000000000000000000000000000000608082015260a00190565b60208082526032908201527f4d6f64756c6541757468235f7369676e617475726556616c69646174696f6e3a60408201527f20494e56414c49445f5349474e41545552450000000000000000000000000000606082015260800190565b60208082526032908201527f4d756c746943616c6c5574696c73236d756c746943616c6c3a2064656c65676160408201527f746543616c6c206e6f7420616c6c6f7765640000000000000000000000000000606082015260800190565b60208082526039908201527f526571756972655574696c73237075626c697368496e697469616c5369676e6560408201527f72733a20494e56414c49445f4d454d424552535f434f554e5400000000000000606082015260800190565b60208082526031908201527f526571756972655574696c73237075626c697368436f6e6669673a20554e455860408201527f5045435445445f494d4147455f48415348000000000000000000000000000000606082015260800190565b602080825260409082018190527f526571756972655574696c73237075626c697368436f6e6669673a20554e4558908201527f5045435445445f434f554e5445524641435455414c5f494d4147455f48415348606082015260800190565b600061ffff841682526040602083015261261b6040830184611ea6565b949350505050565b60008382526040602083015261261b6040830184611ea6565b60405181810167ffffffffffffffff8111828210171561265857fe5b604052919050565b60005b8381101561267b578181015183820152602001612663565b8381111561268a576000848401525b5050505056fe5369676e617475726556616c696461746f72237265636f7665725369676e65723a20696e76616c6964207369676e6174757265202773272076616c75655369676e617475726556616c696461746f72237265636f7665725369676e65723a20696e76616c6964207369676e6174757265206c656e6774684c696242797465732372656164416464726573733a204f55545f4f465f424f554e44534c696242797465732372656164466972737455696e7431363a204f55545f4f465f424f554e44535369676e617475726556616c696461746f72237265636f7665725369676e65723a20696e76616c6964207369676e6174757265202776272076616c75655369676e617475726556616c696461746f72237265636f7665725369676e65723a20494e56414c49445f5349474e45525369676e617475726556616c696461746f7223697356616c69645369676e61747572653a20554e535550504f525445445f5349474e41545552455f545950454c696242797465732372656164427974657336363a204f55545f4f465f424f554e44535369676e617475726556616c696461746f72237265636f7665725369676e65723a20554e535550504f525445445f5349474e41545552455f545950454c69624279746573237265616455696e743855696e74383a204f55545f4f465f424f554e44534c69624279746573237265616442797465733a204f55545f4f465f424f554e44534c69624279746573237265616455696e7431363a204f55545f4f465f424f554e44534c696242797465732372656164427974657333323a20475245415445525f4f525f455155414c5f544f5f33325f4c454e4754485f5245515549524544a26469706673582212200abb842b6eea58df953f048e3a9aa7589fd3ce15ca086e43b61cdb0c0c42723564736f6c63430007060033603a600e3d39601a805130553df3363d3d373d3d3d363d30545af43d82803e903d91601857fd5bf3000000000000000000000000f9d09d634fb818b05149329c1dccfaea53639d96000000000000000000000000d01f11855bccb95f88d7a48492f66410d463731300000000000000000000', - gasLimit: 8000000 - }) + responses.push( + await signer.sendTransaction({ + to: '0x8A5Bc19e22D6aD55a2c763B93A75d09F321fe764', + data: '0x9c4ae2d0000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002b1660c06040523480156200001157600080fd5b5060405162002ad638038062002ad68339810160408190526200003491620000cd565b8181816001600160a01b031660a0816001600160a01b031660601b8152505060405180606001604052806028815260200162002aae60289139816001600160a01b03166040516020016200008a92919062000104565b60408051601f198184030181529190528051602090910120608052506200014692505050565b80516001600160a01b0381168114620000c857600080fd5b919050565b60008060408385031215620000e0578182fd5b620000eb83620000b0565b9150620000fb60208401620000b0565b90509250929050565b60008351815b818110156200012657602081870181015185830152016200010a565b81811115620001355782828501525b509190910191825250602001919050565b60805160a05160601c61293762000177600039806106515280610b1b5250806106755280610b3f52506129376000f3fe6080604052600436106101805760003560e01c806398f9fbc4116100d6578063d1db39071161007f578063e90f13e711610059578063e90f13e714610395578063f209883a146103ea578063ffd7d741146103ff57610180565b8063d1db390714610395578063d5b5337f146103aa578063e717aba9146103ca57610180565b8063c272d5c3116100b0578063c272d5c314610333578063c39f2d5c14610348578063c66764e11461036857610180565b806398f9fbc4146102e9578063aeea5fb5146102fe578063b472f0a21461031357610180565b806348acd29f116101385780637ae99638116101125780637ae99638146102875780637f29d538146102a7578063984395bc146102c757610180565b806348acd29f14610227578063543196eb146102475780637082503b1461026757610180565b80631cd05dc4116101695780631cd05dc4146101d057806343d9c935146101f057806344d466c21461020557610180565b80630fdecfac146101855780631551f0ab146101b0575b600080fd5b34801561019157600080fd5b5061019a610420565b6040516101a79190612190565b60405180910390f35b3480156101bc57600080fd5b5061019a6101cb366004611e76565b610424565b3480156101dc57600080fd5b5061019a6101eb366004611bea565b610436565b3480156101fc57600080fd5b5061019a610448565b34801561021157600080fd5b50610225610220366004611ca4565b610450565b005b34801561023357600080fd5b5061019a610242366004611bea565b61080a565b34801561025357600080fd5b5061019a610262366004611bea565b610828565b34801561027357600080fd5b50610225610282366004611c0b565b61082c565b34801561029357600080fd5b5061019a6102a2366004611bea565b610cb0565b3480156102b357600080fd5b506102256102c2366004611e76565b610cc2565b3480156102d357600080fd5b506102dc610cfe565b6040516101a79190612000565b3480156102f557600080fd5b506102dc610d02565b34801561030a57600080fd5b5061019a610d06565b34801561031f57600080fd5b5061022561032e366004611c7b565b610d0a565b34801561033f57600080fd5b5061019a610de8565b34801561035457600080fd5b5061019a610363366004611bea565b610dec565b34801561037457600080fd5b50610388610383366004611bea565b610df0565b6040516101a791906121c5565b3480156103a157600080fd5b5061019a610e35565b3480156103b657600080fd5b5061019a6103c5366004611e76565b610e39565b3480156103d657600080fd5b5061019a6103e5366004611bea565b610e3d565b3480156103f657600080fd5b5061019a610e4f565b61041261040d366004611d34565b610e53565b6040516101a7929190612021565b4690565b60036020526000908152604090205481565b60006020819052908152604090205481565b60005a905090565b8360005b838110156104e9578185858381811061046957fe5b9050604002016000013586868481811061047f57fe5b90506040020160200160208101906104979190611bea565b6040516020016104a993929190612199565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101209150600101610454565b506000808773ffffffffffffffffffffffffffffffffffffffff166351605d8060e01b60405160200161051c9190611f54565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529082905261055491611f81565b6000604051808303816000865af19150503d8060008114610591576040519150601f19603f3d011682016040523d82523d6000602084013e610596565b606091505b50915091508180156105a9575080516020145b1561060e576000818060200190518101906105c49190611e8e565b9050838114610608576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016105ff90612543565b60405180910390fd5b50610732565b60405173ffffffffffffffffffffffffffffffffffffffff89169061069d907fff00000000000000000000000000000000000000000000000000000000000000907f00000000000000000000000000000000000000000000000000000000000000009087907f000000000000000000000000000000000000000000000000000000000000000090602001611ef0565b6040516020818303038152906040528051906020012060001c73ffffffffffffffffffffffffffffffffffffffff1614610703576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016105ff906125a0565b83156107325773ffffffffffffffffffffffffffffffffffffffff881660009081526002602052604090208390555b828873ffffffffffffffffffffffffffffffffffffffff167fb502b7446ca079086188acf3abef47c2f464f2ee9a72fcdf05ffcb74dcc17cee89898960405160200161077f9291906120c7565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152908290526107b89291612623565b60405180910390a383156108005773ffffffffffffffffffffffffffffffffffffffff8816600090815260016020908152604080832043908190558684526003909252909120555b5050505050505050565b73ffffffffffffffffffffffffffffffffffffffff8116315b919050565b3f90565b600080610838846110c3565b9150915060008046905080898960405160200161085793929190611f9d565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152919052805160209091012091505061ffff831660008767ffffffffffffffff811180156108ae57600080fd5b506040519080825280602002602001820160405280156108e857816020015b6108d5611b1c565b8152602001906001900390816108cd5790505b50905060005b8751851015610a9f57600080806109058b89611131565b995060ff9182169450169150600183141561092d576109248b896111b2565b98509050610a20565b8261095f57606061093e8c8a61122a565b9950905061094c88826112db565b91506109598f838d611665565b50610a20565b60028314156109ee576109728b896111b2565b9850905060006109828c8a6116f3565b995061ffff16905060606109978d8b84611764565b9a5090506109a6898483611853565b6109dc576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016105ff9061242c565b50506109e98e828c611665565b610a20565b6040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016105ff906121d8565b60405180604001604052808381526020018273ffffffffffffffffffffffffffffffffffffffff16815250858581518110610a5757fe5b60200260200101819052508380600101945050858282604051602001610a7f93929190612199565b6040516020818303038152906040528051906020012095505050506108ee565b888114610ad8576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016105ff906124e6565b60405173ffffffffffffffffffffffffffffffffffffffff8c1690610b67907fff00000000000000000000000000000000000000000000000000000000000000907f00000000000000000000000000000000000000000000000000000000000000009087907f000000000000000000000000000000000000000000000000000000000000000090602001611ef0565b6040516020818303038152906040528051906020012060001c73ffffffffffffffffffffffffffffffffffffffff1614610bcd576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016105ff906123a9565b828b73ffffffffffffffffffffffffffffffffffffffff167fb502b7446ca079086188acf3abef47c2f464f2ee9a72fcdf05ffcb74dcc17cee8885604051602001610c18919061212b565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815290829052610c5192916125fe565b60405180910390a38615610ca35773ffffffffffffffffffffffffffffffffffffffff8b1660008181526001602090815260408083204390819055878452600383528184205592825260029052208390555b5050505050505050505050565b60026020526000908152604090205481565b804210610cfb576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016105ff9061234c565b50565b3290565b4190565b4490565b600080610d1683611a9b565b9150915060008473ffffffffffffffffffffffffffffffffffffffff16638c3f5563846040518263ffffffff1660e01b8152600401610d559190612190565b60206040518083038186803b158015610d6d57600080fd5b505afa158015610d81573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610da59190611e8e565b905081811015610de1576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016105ff906122ef565b5050505050565b3a90565b3b90565b60408051603f833b9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682019092528181529080600060208401853c50919050565b4590565b4090565b60016020526000908152604090205481565b4290565b606080825167ffffffffffffffff81118015610e6e57600080fd5b50604051908082528060200260200182016040528015610e98578160200160208202803683370190505b509150825167ffffffffffffffff81118015610eb357600080fd5b50604051908082528060200260200182016040528015610ee757816020015b6060815260200190600190039081610ed25790505b50905060005b83518110156110bd576000848281518110610f0457fe5b60200260200101519050806000015115610f4a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016105ff90612489565b80604001515a1015610f88576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016105ff90612292565b806060015173ffffffffffffffffffffffffffffffffffffffff1681608001518260400151600014610fbe578260400151610fc0565b5a5b908360a00151604051610fd39190611f81565b600060405180830381858888f193505050503d8060008114611011576040519150601f19603f3d011682016040523d82523d6000602084013e611016565b606091505b5085848151811061102357fe5b6020026020010185858151811061103657fe5b602002602001018290528215151515815250505083828151811061105657fe5b60200260200101518061107e575084828151811061107057fe5b602002602001015160200151155b6110b4576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016105ff90612235565b50600101610eed565b50915091565b6020810151815160f09190911c9060029081111561112c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602781526020018061272b6027913960400191505060405180910390fd5b915091565b8082016020015160f881901c9060f01c60ff166002830183811161115157fe5b84518111156111ab576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602681526020018061285d6026913960400191505060405180910390fd5b9250925092565b8082016020015160601c601482018281116111c957fe5b8351811115611223576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806127086023913960400191505060405180910390fd5b9250929050565b60408051604280825260808201909252606091600091906020820181803683370190505091508284016020018051602084015260208101516040840152602281015160428401525060428301905082811161128157fe5b8351811115611223576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806127fe6023913960400191505060405180910390fd5b60008151604214611337576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603a8152602001806126ce603a913960400191505060405180910390fd5b60008260018451038151811061134957fe5b602001015160f81c60f81b60f81c60ff16905060008360408151811061136b57fe5b016020015160f81c905060006113818582611ab4565b90506000611390866020611ab4565b90507f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a081111561140b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603d815260200180612691603d913960400191505060405180910390fd5b8260ff16601b1415801561142357508260ff16601c14155b15611479576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603d815260200180612752603d913960400191505060405180910390fd5b60018414156114ed5760018784848460405160008152602001604052604051808581526020018460ff1681526020018381526020018281526020019450505050506020604051602081039080840390855afa1580156114dc573d6000803e3d6000fd5b5050506020604051035194506115ef565b600284141561159e5760018760405160200180807f19457468657265756d205369676e6564204d6573736167653a0a333200000000815250601c018281526020019150506040516020818303038152906040528051906020012084848460405160008152602001604052604051808581526020018460ff1681526020018381526020018281526020019450505050506020604051602081039080840390855afa1580156114dc573d6000803e3d6000fd5b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603c815260200180612821603c913960400191505060405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff851661165b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603081526020018061278f6030913960400191505060405180910390fd5b5050505092915050565b8173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f600ba597427f042bcd559a0d06fa1732cc104d6dd43cbe8845b5a0e804b2b39f60405160405180910390a380156116ee5773ffffffffffffffffffffffffffffffffffffffff821660009081526020819052604090204390555b505050565b8082016020015160f01c6002820182811161170a57fe5b8351811115611223576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806128a46022913960400191505060405180910390fd5b606060008267ffffffffffffffff8111801561177f57600080fd5b506040519080825280601f01601f1916602001820160405280156117aa576020820181803683370190505b509150838501602001600060205b858110156117d1579082015184820152602081016117b8565b84860160200180519390920151908501525250828201838110156117f157fe5b845181111561184b576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260218152602001806128836021913960400191505060405180910390fd5b935093915050565b6000808260018451038151811061186657fe5b016020015160f81c9050600181148061187f5750600281145b156118c3578373ffffffffffffffffffffffffffffffffffffffff166118a586856112db565b73ffffffffffffffffffffffffffffffffffffffff16149150611a93565b6003811415611a425782517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81018452604080517f1626ba7e000000000000000000000000000000000000000000000000000000008152600481018881526024820192835286516044830152865173ffffffffffffffffffffffffffffffffffffffff891693631626ba7e938b938a9390929160640190602085019080838360005b8381101561197d578181015183820152602001611965565b50505050905090810190601f1680156119aa5780820380516001836020036101000a031916815260200191505b50935050505060206040518083038186803b1580156119c857600080fd5b505afa1580156119dc573d6000803e3d6000fd5b505050506040513d60208110156119f257600080fd5b50519084527fffffffff00000000000000000000000000000000000000000000000000000000167f1626ba7e00000000000000000000000000000000000000000000000000000000149150611a93565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603f8152602001806127bf603f913960400191505060405180910390fd5b509392505050565b606081901c916bffffffffffffffffffffffff90911690565b60008160200183511015611b13576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603c8152602001806128c6603c913960400191505060405180910390fd5b50016020015190565b604080518082019091526000808252602082015290565b803573ffffffffffffffffffffffffffffffffffffffff8116811461082357600080fd5b8035801515811461082357600080fd5b600082601f830112611b77578081fd5b813567ffffffffffffffff811115611b8b57fe5b611bbc60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8401160161263c565b818152846020838601011115611bd0578283fd5b816020850160208301379081016020019190915292915050565b600060208284031215611bfb578081fd5b611c0482611b33565b9392505050565b600080600080600060a08688031215611c22578081fd5b611c2b86611b33565b94506020860135935060408601359250606086013567ffffffffffffffff811115611c54578182fd5b611c6088828901611b67565b925050611c6f60808701611b57565b90509295509295909350565b60008060408385031215611c8d578182fd5b611c9683611b33565b946020939093013593505050565b600080600080600060808688031215611cbb578081fd5b611cc486611b33565b945060208601359350604086013567ffffffffffffffff80821115611ce7578283fd5b818801915088601f830112611cfa578283fd5b813581811115611d08578384fd5b896020604083028501011115611d1c578384fd5b602083019550809450505050611c6f60608701611b57565b60006020808385031215611d46578182fd5b823567ffffffffffffffff80821115611d5d578384fd5b818501915085601f830112611d70578384fd5b813581811115611d7c57fe5b611d89848583020161263c565b81815284810190848601875b84811015611e67578135870160c0807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0838f03011215611dd3578a8bfd5b604080518281018181108b82111715611de857fe5b8252611df5848d01611b57565b8152611e02828501611b57565b8c82015260608085013583830152611e1c60808601611b33565b9082015260a08481013560808301529284013592915089831115611e3e578c8dfd5b611e4c8f8d85870101611b67565b91810191909152865250509287019290870190600101611d95565b50909998505050505050505050565b600060208284031215611e87578081fd5b5035919050565b600060208284031215611e9f578081fd5b5051919050565b60008151808452611ebe816020860160208601612660565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b7fff0000000000000000000000000000000000000000000000000000000000000094909416845260609290921b7fffffffffffffffffffffffffffffffffffffffff0000000000000000000000001660018401526015830152603582015260550190565b7fffffffff0000000000000000000000000000000000000000000000000000000091909116815260040190565b60008251611f93818460208701612660565b9190910192915050565b7f19010000000000000000000000000000000000000000000000000000000000008152600281019390935260609190911b7fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166022830152603682015260560190565b73ffffffffffffffffffffffffffffffffffffffff91909116815260200190565b604080825283519082018190526000906020906060840190828701845b8281101561205c57815115158452928401929084019060010161203e565b5050508381038285015284518082528282019080840283018401878501865b83811015611e67577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08684030185526120b5838351611ea6565b9487019492509086019060010161207b565b6020808252818101839052600090604080840186845b8781101561211e578135835273ffffffffffffffffffffffffffffffffffffffff612109868401611b33565b168386015291830191908301906001016120dd565b5090979650505050505050565b602080825282518282018190526000919060409081850190868401855b828110156121835781518051855286015173ffffffffffffffffffffffffffffffffffffffff16868501529284019290850190600101612148565b5091979650505050505050565b90815260200190565b928352602083019190915273ffffffffffffffffffffffffffffffffffffffff16604082015260600190565b600060208252611c046020830184611ea6565b6020808252603a908201527f526571756972655574696c73237075626c697368496e697469616c5369676e6560408201527f72733a20494e56414c49445f5349474e41545552455f464c4147000000000000606082015260800190565b60208082526027908201527f4d756c746943616c6c5574696c73236d756c746943616c6c3a2043414c4c5f5260408201527f4556455254454400000000000000000000000000000000000000000000000000606082015260800190565b60208082526028908201527f4d756c746943616c6c5574696c73236d756c746943616c6c3a204e4f545f454e60408201527f4f5547485f474153000000000000000000000000000000000000000000000000606082015260800190565b60208082526032908201527f526571756972655574696c7323726571756972654d696e4e6f6e63653a204e4f60408201527f4e43455f42454c4f575f52455155495245440000000000000000000000000000606082015260800190565b60208082526027908201527f526571756972655574696c7323726571756972654e6f6e457870697265643a2060408201527f4558504952454400000000000000000000000000000000000000000000000000606082015260800190565b60208082526048908201527f526571756972655574696c73237075626c697368496e697469616c5369676e6560408201527f72733a20554e45585045435445445f434f554e5445524641435455414c5f494d60608201527f4147455f48415348000000000000000000000000000000000000000000000000608082015260a00190565b60208082526032908201527f4d6f64756c6541757468235f7369676e617475726556616c69646174696f6e3a60408201527f20494e56414c49445f5349474e41545552450000000000000000000000000000606082015260800190565b60208082526032908201527f4d756c746943616c6c5574696c73236d756c746943616c6c3a2064656c65676160408201527f746543616c6c206e6f7420616c6c6f7765640000000000000000000000000000606082015260800190565b60208082526039908201527f526571756972655574696c73237075626c697368496e697469616c5369676e6560408201527f72733a20494e56414c49445f4d454d424552535f434f554e5400000000000000606082015260800190565b60208082526031908201527f526571756972655574696c73237075626c697368436f6e6669673a20554e455860408201527f5045435445445f494d4147455f48415348000000000000000000000000000000606082015260800190565b602080825260409082018190527f526571756972655574696c73237075626c697368436f6e6669673a20554e4558908201527f5045435445445f434f554e5445524641435455414c5f494d4147455f48415348606082015260800190565b600061ffff841682526040602083015261261b6040830184611ea6565b949350505050565b60008382526040602083015261261b6040830184611ea6565b60405181810167ffffffffffffffff8111828210171561265857fe5b604052919050565b60005b8381101561267b578181015183820152602001612663565b8381111561268a576000848401525b5050505056fe5369676e617475726556616c696461746f72237265636f7665725369676e65723a20696e76616c6964207369676e6174757265202773272076616c75655369676e617475726556616c696461746f72237265636f7665725369676e65723a20696e76616c6964207369676e6174757265206c656e6774684c696242797465732372656164416464726573733a204f55545f4f465f424f554e44534c696242797465732372656164466972737455696e7431363a204f55545f4f465f424f554e44535369676e617475726556616c696461746f72237265636f7665725369676e65723a20696e76616c6964207369676e6174757265202776272076616c75655369676e617475726556616c696461746f72237265636f7665725369676e65723a20494e56414c49445f5349474e45525369676e617475726556616c696461746f7223697356616c69645369676e61747572653a20554e535550504f525445445f5349474e41545552455f545950454c696242797465732372656164427974657336363a204f55545f4f465f424f554e44535369676e617475726556616c696461746f72237265636f7665725369676e65723a20554e535550504f525445445f5349474e41545552455f545950454c69624279746573237265616455696e743855696e74383a204f55545f4f465f424f554e44534c69624279746573237265616442797465733a204f55545f4f465f424f554e44534c69624279746573237265616455696e7431363a204f55545f4f465f424f554e44534c696242797465732372656164427974657333323a20475245415445525f4f525f455155414c5f544f5f33325f4c454e4754485f5245515549524544a26469706673582212200abb842b6eea58df953f048e3a9aa7589fd3ce15ca086e43b61cdb0c0c42723564736f6c63430007060033603a600e3d39601a805130553df3363d3d373d3d3d363d30545af43d82803e903d91601857fd5bf3000000000000000000000000f9d09d634fb818b05149329c1dccfaea53639d96000000000000000000000000d01f11855bccb95f88d7a48492f66410d463731300000000000000000000', + gasLimit: 8000000 + }) + ) + + // Wait for transaction responses to confirm + await Promise.all(responses.map(response => response.wait())) return deployV1Context(signer) } diff --git a/packages/tests/src/context/v2.ts b/packages/tests/src/context/v2.ts index a76e97fd2..2e06deb4f 100644 --- a/packages/tests/src/context/v2.ts +++ b/packages/tests/src/context/v2.ts @@ -1,24 +1,49 @@ import { ethers } from 'ethers' import { v2 } from '../builds' import { deployContract } from '../singletonFactory' +import { v2 as coreV2 } from '@0xsequence/core' + +export async function deployV2Context(signer: ethers.Signer): Promise { + const { chainId } = await signer.provider!.getNetwork() + console.log(`[${chainId}] [v2]: Deploying context...`) -export async function deployV2Context(signer: ethers.Signer) { // See if signer's provider has the contracts already deployed - const factory = await deployContract(signer, v2.factory) - const mainModuleUpgradable = await deployContract(signer, v2.mainModuleUpgradable) - const mainModule = await deployContract(signer, v2.mainModule, factory.address, mainModuleUpgradable.address) - const guestModule = await deployContract(signer, v2.guestModule) - const universalSigValidator = await deployContract(signer, v2.universalSigValidator) + + const deploymentResults: boolean[][] = [] + + const [factory, waitForFactoryDeployment] = await deployContract(signer, v2.factory) + const [mainModuleUpgradable, waitForMainModuleUpgradable] = await deployContract(signer, v2.mainModuleUpgradable) + + deploymentResults.push(await Promise.all([waitForFactoryDeployment, waitForMainModuleUpgradable])) + + const [mainModule, waitForMainModule] = await deployContract( + signer, + v2.mainModule, + await factory.getAddress(), + await mainModuleUpgradable.getAddress() + ) + + deploymentResults.push(await Promise.all([waitForMainModule])) + + const [guestModule, waitForGuestModule] = await deployContract(signer, v2.guestModule) + const [universalSigValidator, waitForUniversalSigValidator] = await deployContract(signer, v2.universalSigValidator) + + deploymentResults.push(await Promise.all([waitForGuestModule, waitForUniversalSigValidator])) + + if (deploymentResults.flat().some(r => !r)) { + throw new Error('Failed to deploy V2 context!') + } return { version: 2, - factory: factory.address, - mainModule: mainModule.address, - mainModuleUpgradable: mainModuleUpgradable.address, - guestModule: guestModule.address, - universalSigValidator: universalSigValidator.address, + factory: await factory.getAddress(), + mainModule: await mainModule.getAddress(), + mainModuleUpgradable: await mainModuleUpgradable.getAddress(), + guestModule: await guestModule.getAddress(), + universalSigValidator: await universalSigValidator.getAddress(), - walletCreationCode: '0x603a600e3d39601a805130553df3363d3d373d3d3d363d30545af43d82803e903d91601857fd5bf3' + walletCreationCode: '0x603a600e3d39601a805130553df3363d3d373d3d3d363d30545af43d82803e903d91601857fd5bf3', + proxyImplementationHook: '0x1f56dbAD5e8319F0DE9a323E24A31b5077dEB1a4' } } diff --git a/packages/tests/src/networks.ts b/packages/tests/src/networks.ts new file mode 100644 index 000000000..b23912279 --- /dev/null +++ b/packages/tests/src/networks.ts @@ -0,0 +1,52 @@ +import { ChainId, NetworkConfig, NetworkMetadata } from '../../network/src' + +export enum HardhatChainId { + HARDHAT = 31337, + HARDHAT_2 = 31338 +} + +export const hardhatNetworks: Record = { + [HardhatChainId.HARDHAT]: { + chainId: HardhatChainId.HARDHAT as any as ChainId, + name: 'hardhat', + title: 'Hardhat (local testnet)', + nativeToken: { + symbol: 'ETH', + name: 'Ether', + decimals: 18 + } + }, + [HardhatChainId.HARDHAT_2]: { + chainId: HardhatChainId.HARDHAT_2 as any as ChainId, + name: 'hardhat2', + title: 'Hardhat (local testnet)', + nativeToken: { + symbol: 'ETH', + name: 'Ether', + decimals: 18 + } + } +} + +export const hardhatNetworkConfigs: NetworkConfig[] = [ + { + ...hardhatNetworks[HardhatChainId.HARDHAT], + rpcUrl: 'http://localhost:8545', + relayer: { + url: 'http://localhost:3000', + provider: { + url: 'http://localhost:8545' + } + } + }, + { + ...hardhatNetworks[HardhatChainId.HARDHAT_2], + rpcUrl: 'http://localhost:9545', + relayer: { + url: 'http://localhost:3000', + provider: { + url: 'http://localhost:9545' + } + } + } +] diff --git a/packages/tests/src/singletonFactory.ts b/packages/tests/src/singletonFactory.ts index ff9431dee..9e15ae26f 100644 --- a/packages/tests/src/singletonFactory.ts +++ b/packages/tests/src/singletonFactory.ts @@ -5,7 +5,7 @@ import { isContract } from './utils' export const deployment = { tx: '0xf9016c8085174876e8008303c4d88080b90154608060405234801561001057600080fd5b50610134806100206000396000f3fe6080604052348015600f57600080fd5b506004361060285760003560e01c80634af63f0214602d575b600080fd5b60cf60048036036040811015604157600080fd5b810190602081018135640100000000811115605b57600080fd5b820183602082011115606c57600080fd5b80359060200191846001830284011164010000000083111715608d57600080fd5b91908080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250929550509135925060eb915050565b604080516001600160a01b039092168252519081900360200190f35b6000818351602085016000f5939250505056fea26469706673582212206b44f8a82cb6b156bfcc3dc6aadd6df4eefd204bc928a4397fd15dacf6d5320564736f6c634300060200331b83247000822470', deployer: '0xBb6e024b9cFFACB947A71991E386681B1Cd1477D', - funding: '24700000000000000' + funding: 24700000000000000n } export const address = '0xce0042B868300000d44A59004Da54A005ffdcf9f' @@ -42,14 +42,18 @@ export async function mustExistEIP2470(signer: ethers.Signer): Promise tx.wait()) } - await provider.sendTransaction(deployment.tx) + const res = await provider.broadcastTransaction(deployment.tx) + await res.wait() + if (!(await isContract(provider, address))) { throw new Error('EIP2470 deployment failed') } @@ -58,22 +62,28 @@ export async function mustExistEIP2470(signer: ethers.Signer): Promise { +export async function deployContract( + signer: ethers.Signer, + artifact: Artifact, + ...args: any[] +): Promise<[ethers.Contract, Promise]> { const provider = signer.provider if (!provider) throw new Error('signer has no provider') const singletonFactory = await mustExistEIP2470(signer) const factory = new ethers.ContractFactory(artifact.abi, artifact.bytecode) - const data = factory.getDeployTransaction(...args).data + + const data = (await factory.getDeployTransaction(...args)).data + if (!data) throw new Error('no deploy data') - const address = ethers.utils.getAddress( - ethers.utils.hexDataSlice( - ethers.utils.keccak256( - ethers.utils.solidityPack( + const address = ethers.getAddress( + ethers.dataSlice( + ethers.keccak256( + ethers.solidityPacked( ['bytes1', 'address', 'bytes32', 'bytes32'], - ['0xff', singletonFactory.address, ethers.constants.HashZero, ethers.utils.keccak256(data)] + ['0xff', await singletonFactory.getAddress(), ethers.ZeroHash, ethers.keccak256(data)] ) ), 12 @@ -81,15 +91,16 @@ export async function deployContract(signer: ethers.Signer, artifact: Artifact, ) if (await isContract(provider, address)) { - return new ethers.Contract(address, artifact.abi, signer) + return [new ethers.Contract(address, artifact.abi, signer), Promise.resolve(true)] } - const maxGasLimit = await provider.getBlock('latest').then(b => b.gasLimit.div(2)) - await singletonFactory.deploy(data, ethers.constants.HashZero, { gasLimit: maxGasLimit }).then((tx: any) => tx.wait()) + const maxGasLimit = await provider.getBlock('latest').then(b => (b?.gasLimit ? b.gasLimit / 2n : 0n)) + const tx = await singletonFactory.deploy(data, ethers.ZeroHash, { gasLimit: maxGasLimit }) - if (!(await isContract(provider, address))) { - throw new Error('contract deployment failed') - } + // if (!(await isContract(provider, address))) { + // throw new Error('contract deployment failed') + // } + const waitPromise = tx.wait().then(() => isContract(provider, address)) - return new ethers.Contract(address, artifact.abi, signer) + return [new ethers.Contract(address, artifact.abi, signer), waitPromise] } diff --git a/packages/tests/src/utils.ts b/packages/tests/src/utils.ts index 00924003a..dcff3bd0e 100644 --- a/packages/tests/src/utils.ts +++ b/packages/tests/src/utils.ts @@ -1,37 +1,35 @@ import { ethers } from 'ethers' import { Artifact } from './builds' +import { MAX_UINT_256 } from '@0xsequence/utils' -export function deployContract(signer: ethers.Signer, artifact: Artifact, ...args: any[]): Promise { +export function deployContract(signer: ethers.Signer, artifact: Artifact, ...args: any[]) { const factory = new ethers.ContractFactory(artifact.abi, artifact.bytecode, signer) return factory.deploy(...args) } -export function randomBigNumber( - min: ethers.BigNumberish = 0, - max: ethers.BigNumberish = ethers.constants.MaxUint256 -): ethers.BigNumber { - const randomHex = ethers.utils.hexlify(ethers.utils.randomBytes(32)) - const randomBn = ethers.BigNumber.from(randomHex) - const minBn = ethers.BigNumber.from(min) - const maxBn = ethers.BigNumber.from(max) - const range = maxBn.sub(minBn) +export function randomBigInt(min: ethers.BigNumberish = 0, max: ethers.BigNumberish = MAX_UINT_256): bigint { + const randomHex = ethers.hexlify(ethers.randomBytes(32)) + const randomNumber = BigInt(randomHex) + const minNumber = BigInt(min) + const maxNumber = BigInt(max) + const range = maxNumber - minNumber - if (range.isNegative() || range.isZero()) { + if (range <= 0n) { throw new Error('max must be greater than min') } - return randomBn.mod(range).add(minBn) + return (randomNumber % range) + minNumber } -export function maxForBits(bits: number): ethers.BigNumber { - return ethers.BigNumber.from(2).pow(bits).sub(1) +export function maxForBits(bits: number): bigint { + return 2n ** BigInt(bits) - 1n } export function randomBool(): boolean { return Math.random() >= 0.5 } -export async function isContract(provider: ethers.providers.Provider, address: string): Promise { +export async function isContract(provider: ethers.Provider, address: string): Promise { const c = await provider.getCode(address) - return ethers.utils.arrayify(c).length > 0 + return ethers.getBytes(c).length > 0 } diff --git a/packages/utils/CHANGELOG.md b/packages/utils/CHANGELOG.md index 953ae4755..39b857bc3 100644 --- a/packages/utils/CHANGELOG.md +++ b/packages/utils/CHANGELOG.md @@ -1,5 +1,331 @@ # @0xsequence/utils +## 2.2.14 + +### Patch Changes + +- Somnia Testnet and Monad Testnet + +## 2.2.13 + +### Patch Changes + +- Add XR1 to all networks + +## 2.2.12 + +### Patch Changes + +- Add XR1 + +## 2.2.11 + +### Patch Changes + +- Relayer updates + +## 2.2.10 + +### Patch Changes + +- Etherlink support + +## 2.2.9 + +### Patch Changes + +- Indexer gateway native token balances + +## 2.2.8 + +### Patch Changes + +- Add Moonbeam and Moonbase Alpha + +## 2.2.7 + +### Patch Changes + +- Update Builder package + +## 2.2.6 + +### Patch Changes + +- Update relayer package + +## 2.2.5 + +### Patch Changes + +- auth: fix sequence indexer gateway url +- account: immutable wallet proxy hook + +## 2.2.4 + +### Patch Changes + +- network: update soneium mainnet block explorer url +- waas: signTypedData intent support + +## 2.2.3 + +### Patch Changes + +- provider: updating initWallet to use connected network configs if they exist + +## 2.2.2 + +### Patch Changes + +- pass projectAccessKey to relayer at all times + +## 2.2.1 + +### Patch Changes + +- waas-ethers: sign typed data + +## 2.2.0 + +### Minor Changes + +- indexer: gateway client +- @0xsequence/builder +- upgrade puppeteer to v23.10.3 + +## 2.1.8 + +### Patch Changes + +- Add Soneium Mainnet + +## 2.1.7 + +### Patch Changes + +- guard: pass project access key to guard requests + +## 2.1.6 + +### Patch Changes + +- Add LAOS and Telos Testnet chains + +## 2.1.5 + +### Patch Changes + +- account: save presigned configuration with reference chain id 1 + +## 2.1.4 + +### Patch Changes + +- provider: pass projectAccessKey into MuxMessageProvider + +## 2.1.3 + +### Patch Changes + +- waas: time drift date fix due to strange browser quirk + +## 2.1.2 + +### Patch Changes + +- provider: export analytics correctly + +## 2.1.1 + +### Patch Changes + +- Add LAOS chain support + +## 2.1.0 + +### Minor Changes + +- account: forward project access key when estimating fees and sending transactions + +### Patch Changes + +- sessions: save signatures with reference chain id + +## 2.0.26 + +### Patch Changes + +- account: fix chain id comparison + +## 2.0.25 + +### Patch Changes + +- skale-nebula: deploy gas limit = 10m + +## 2.0.24 + +### Patch Changes + +- sessions: arweave: configurable gateway url +- waas: use /status to get time drift before sending any intents + +## 2.0.23 + +### Patch Changes + +- Add The Root Network support + +## 2.0.22 + +### Patch Changes + +- Add SKALE Nebula Mainnet support + +## 2.0.21 + +### Patch Changes + +- account: add publishWitnessFor + +## 2.0.20 + +### Patch Changes + +- upgrade deps, and improve waas session status handling + +## 2.0.19 + +### Patch Changes + +- Add Immutable zkEVM support + +## 2.0.18 + +### Patch Changes + +- waas: new contractCall transaction type +- sessions: add arweave owner + +## 2.0.17 + +### Patch Changes + +- update waas auth to clear session before signIn + +## 2.0.16 + +### Patch Changes + +- Removed Astar chains + +## 2.0.15 + +### Patch Changes + +- indexer: update bindings with token balance additions + +## 2.0.14 + +### Patch Changes + +- sessions: arweave config reader +- network: add b3 and apechain mainnet configs + +## 2.0.13 + +### Patch Changes + +- network: toy-testnet + +## 2.0.12 + +### Patch Changes + +- api: update bindings + +## 2.0.11 + +### Patch Changes + +- waas: intents test fix +- api: update bindings + +## 2.0.10 + +### Patch Changes + +- network: soneium minato testnet + +## 2.0.9 + +### Patch Changes + +- network: fix SKALE network name + +## 2.0.8 + +### Patch Changes + +- metadata: update bindings + +## 2.0.7 + +### Patch Changes + +- wallet request handler fix + +## 2.0.6 + +### Patch Changes + +- network: matic -> pol + +## 2.0.5 + +### Patch Changes + +- provider: update databeat to 0.9.2 + +## 2.0.4 + +### Patch Changes + +- network: add skale-nebula-testnet + +## 2.0.3 + +### Patch Changes + +- waas: check session status in SequenceWaaS.isSignedIn() + +## 2.0.2 + +### Patch Changes + +- sessions: property convert serialized bignumber hex value to bigint + +## 2.0.1 + +### Patch Changes + +- waas: http signature check for authenticator requests +- provider: unwrap legacy json rpc responses +- use json replacer and reviver for bigints + +## 2.0.0 + +### Major Changes + +- ethers v6 + +## 1.10.15 + +### Patch Changes + +- utils: extractProjectIdFromAccessKey + ## 1.10.14 ### Patch Changes diff --git a/packages/utils/package.json b/packages/utils/package.json index 2c3f14ec2..4d29411ab 100644 --- a/packages/utils/package.json +++ b/packages/utils/package.json @@ -1,6 +1,6 @@ { "name": "@0xsequence/utils", - "version": "1.10.14", + "version": "2.2.14", "description": "utils sub-package for Sequence", "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/utils", "source": "src/index.ts", @@ -13,14 +13,14 @@ "test:file": "NODE_OPTIONS='--import tsx' mocha --timeout 30000", "typecheck": "tsc --noEmit" }, + "peerDependencies": { + "ethers": ">=6" + }, "dependencies": { "js-base64": "^3.7.2" }, - "peerDependencies": { - "ethers": ">=5.5 < 6" - }, "devDependencies": { - "ethers": "^5.7.2" + "ethers": "6.13.4" }, "files": [ "src", diff --git a/packages/utils/src/base64.ts b/packages/utils/src/base64.ts index 098abf26a..63f63ca84 100644 --- a/packages/utils/src/base64.ts +++ b/packages/utils/src/base64.ts @@ -1,11 +1,12 @@ import { Base64 } from 'js-base64' +import { bigintReplacer, bigintReviver } from './bigint' export const base64Encode = (val: string): string => { return Base64.encode(val, true) } export const base64EncodeObject = (obj: any): string => { - return Base64.encode(JSON.stringify(obj), true) + return Base64.encode(JSON.stringify(obj, bigintReplacer), true) } export const base64Decode = (encodedString: string): string | undefined => { @@ -19,5 +20,5 @@ export const base64DecodeObject = (encodedObject: string | null): T | u if (encodedObject === null || encodedObject === undefined) { return undefined } - return JSON.parse(Base64.decode(encodedObject)) as T + return JSON.parse(Base64.decode(encodedObject), bigintReviver) as T } diff --git a/packages/utils/src/big-number.ts b/packages/utils/src/big-number.ts deleted file mode 100644 index e5ae37e34..000000000 --- a/packages/utils/src/big-number.ts +++ /dev/null @@ -1,14 +0,0 @@ -import { BigNumber, BigNumberish, utils } from 'ethers' - -// ethers implement this method but doesn't exports it -export function isBigNumberish(value: any): value is BigNumberish { - return ( - value != null && - (BigNumber.isBigNumber(value) || - (typeof value === 'number' && value % 1 === 0) || - (typeof value === 'string' && !!value.match(/^-?[0-9]+$/)) || - utils.isHexString(value) || - typeof value === 'bigint' || - utils.isBytes(value)) - ) -} diff --git a/packages/utils/src/bigint.ts b/packages/utils/src/bigint.ts new file mode 100644 index 000000000..bdde5fac9 --- /dev/null +++ b/packages/utils/src/bigint.ts @@ -0,0 +1,107 @@ +import { ethers } from 'ethers' + +export const MAX_UINT_256 = BigInt('0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff') + +// ethers implement this method but doesn't exports it +export const isBigNumberish = (value: any): value is ethers.BigNumberish => { + return ( + value != null && + ((typeof value === 'number' && value % 1 === 0) || + (typeof value === 'string' && !!value.match(/^-?[0-9]+$/)) || + ethers.isHexString(value) || + typeof value === 'bigint') + ) +} + +// Even length zero-padded hex string with 0x prefix +export const toHexString = (value: bigint): string => { + const result = value.toString(16) + + return `${result.length % 2 === 0 ? '0x' : '0x0'}${result}` +} + +export const parseUnits = (value: string, decimals: number = 18): bigint => { + let [integer, fraction = '0'] = value.split('.') + + const negative = integer.startsWith('-') + if (negative) { + integer = integer.slice(1) + } + + // trim trailing zeros. + fraction = fraction.replace(/(0+)$/, '') + + // round off if the fraction is larger than the number of decimals. + if (decimals === 0) { + integer = `${Math.round(Number(`${integer}.${fraction}`))}` + fraction = '' + } else if (fraction.length > decimals) { + const [left, unit, right] = [ + fraction.slice(0, decimals - 1), + fraction.slice(decimals - 1, decimals), + fraction.slice(decimals) + ] + + const rounded = Math.round(Number(`${unit}.${right}`)) + if (rounded > 9) { + fraction = `${BigInt(left) + 1n}0`.padStart(left.length + 1, '0') + } else { + fraction = `${left}${rounded}` + } + + if (fraction.length > decimals) { + fraction = fraction.slice(1) + integer = `${BigInt(integer) + 1n}` + } + + fraction = fraction.slice(0, decimals) + } else { + fraction = fraction.padEnd(decimals, '0') + } + + return BigInt(`${negative ? '-' : ''}${integer}${fraction}`) +} + +export const parseEther = (value: string): bigint => parseUnits(value, 18) + +export const formatUnits = (value: bigint, decimals: number = 18): string => { + let display = value.toString() + + const negative = display.startsWith('-') + if (negative) { + display = display.slice(1) + } + + display = display.padStart(decimals, '0') + + const integer = display.slice(0, display.length - decimals) + let fraction = display.slice(display.length - decimals) + + fraction = fraction.replace(/(0+)$/, '') + return `${negative ? '-' : ''}${integer || '0'}${fraction ? `.${fraction}` : ''}` +} + +export const formatEther = (value: bigint): string => formatUnits(value, 18) + +// JSON.stringify doesn't handle BigInts, so we need to replace them with objects +export const bigintReplacer = (key: string, value: any): any => { + if (typeof value === 'bigint') { + return { $bigint: value.toString() } + } + + return value +} + +// JSON.parse will need to convert our serialized bigints back into BigInt +export const bigintReviver = (key: string, value: any): any => { + if (value !== null && typeof value === 'object' && '$bigint' in value && typeof value.$bigint === 'string') { + return BigInt(value.$bigint) + } + + // BigNumber compatibility with older versions of sequence.js with ethers v5 + if (value !== null && typeof value === 'object' && value.type === 'BigNumber' && ethers.isHexString(value.hex)) { + return BigInt(value.hex) + } + + return value +} diff --git a/packages/utils/src/digest.ts b/packages/utils/src/digest.ts index 970dd4355..3f0f95eed 100644 --- a/packages/utils/src/digest.ts +++ b/packages/utils/src/digest.ts @@ -1,18 +1,18 @@ import { ethers } from 'ethers' -export const encodeMessageDigest = (message: string | Uint8Array) => { +export const encodeMessageDigest = (message: string | ethers.BytesLike) => { if (typeof message === 'string') { - return ethers.utils.arrayify(ethers.utils.keccak256(ethers.utils.toUtf8Bytes(message))) + return ethers.getBytes(ethers.id(message)) } else { - return ethers.utils.arrayify(ethers.utils.keccak256(message)) + return ethers.getBytes(ethers.keccak256(message)) } } // packMessageData encodes the specified data ready for the Sequence Wallet contracts. export const packMessageData = (walletAddress: string, chainId: ethers.BigNumberish, digest: ethers.BytesLike): string => { - return ethers.utils.solidityPack(['string', 'uint256', 'address', 'bytes32'], ['\x19\x01', chainId, walletAddress, digest]) + return ethers.solidityPacked(['string', 'uint256', 'address', 'bytes32'], ['\x19\x01', chainId, walletAddress, digest]) } export const subDigestOf = (address: string, chainId: ethers.BigNumberish, digest: ethers.BytesLike): string => { - return ethers.utils.keccak256(packMessageData(address, chainId, digest)) + return ethers.keccak256(packMessageData(address, chainId, digest)) } diff --git a/packages/utils/src/index.ts b/packages/utils/src/index.ts index b030d27ac..35394e9d6 100644 --- a/packages/utils/src/index.ts +++ b/packages/utils/src/index.ts @@ -1,6 +1,6 @@ export * from './access-key' export * from './base64' -export * from './big-number' +export * from './bigint' export * from './digest' export * from './is-node-or-browser' export * from './jwt-decode' diff --git a/packages/utils/src/merkle.ts b/packages/utils/src/merkle.ts index 6767fbc7f..9e1750d8d 100644 --- a/packages/utils/src/merkle.ts +++ b/packages/utils/src/merkle.ts @@ -1,4 +1,4 @@ -import { BigNumberish, utils } from 'ethers' +import { ethers } from 'ethers' import { MerkleTree } from './merkletree' export type ToLeaf = (element: T) => string @@ -42,8 +42,8 @@ export class MerkleTreeGenerator { export type SaleItemsElement = { address: string - tokenId: BigNumberish + tokenId: ethers.BigNumberish } export const getSaleItemsLeaf: ToLeaf = element => - utils.solidityKeccak256(['address', 'uint256'], [element.address.toLowerCase(), element.tokenId]) + ethers.solidityPackedKeccak256(['address', 'uint256'], [element.address.toLowerCase(), element.tokenId]) diff --git a/packages/utils/src/merkletree/Base.ts b/packages/utils/src/merkletree/Base.ts index 71dd9549e..2e172c0ad 100644 --- a/packages/utils/src/merkletree/Base.ts +++ b/packages/utils/src/merkletree/Base.ts @@ -85,7 +85,7 @@ export class Base { static bufferify(value: Uint8Array | string): Uint8Array { if (typeof value === 'string') { - return ethers.utils.arrayify(value) + return ethers.getBytes(value) } return value } @@ -95,9 +95,7 @@ export class Base { } static bufferToHex(value: Uint8Array, withPrefix: boolean = true): string { - const prefixed = ethers.utils.hexlify(value, { - allowMissingPrefix: true - }) + const prefixed = ethers.hexlify(value) return withPrefix ? prefixed : prefixed.substring(2) } diff --git a/packages/utils/src/merkletree/MerkleTree.ts b/packages/utils/src/merkletree/MerkleTree.ts index bccea58d9..823d57ed8 100644 --- a/packages/utils/src/merkletree/MerkleTree.ts +++ b/packages/utils/src/merkletree/MerkleTree.ts @@ -26,7 +26,7 @@ export class MerkleTree extends Base { this.sortLeaves = !!options.sortLeaves this.sortPairs = !!options.sortPairs - this.hashFn = Base.bufferifyFn(ethers.utils.keccak256) + this.hashFn = Base.bufferifyFn(ethers.keccak256) this.processLeaves(leaves) } @@ -75,7 +75,7 @@ export class MerkleTree extends Base { combined.sort(Base.compare) } - const hash = this.hashFn(ethers.utils.concat(combined)) + const hash = this.hashFn(ethers.concat(combined)) this.layers[layerIndex].push(hash) } @@ -173,11 +173,11 @@ export class MerkleTree extends Base { } else { buffers.push(data, hash) } - hash = this.hashFn(ethers.utils.concat(buffers)) + hash = this.hashFn(ethers.concat(buffers)) } else { buffers.push(hash) buffers[isLeftNode ? 'unshift' : 'push'](data) - hash = this.hashFn(ethers.utils.concat(buffers)) + hash = this.hashFn(ethers.concat(buffers)) } } diff --git a/packages/utils/src/network.ts b/packages/utils/src/network.ts index a2400e3c6..f2db0fe47 100644 --- a/packages/utils/src/network.ts +++ b/packages/utils/src/network.ts @@ -1,27 +1,41 @@ import { ethers } from 'ethers' -export const getEthersConnectionInfo = (url: string, projectAccessKey?: string, jwt?: string): ethers.utils.ConnectionInfo => { - const headers: { - [key: string]: string | number - } = {} +// export const getEthersConnectionInfo = (url: string, projectAccessKey?: string, jwt?: string): ConnectionInfo => { +// const headers: { +// [key: string]: string | number +// } = {} - if (jwt && jwt.length > 0) { - headers['Authorization'] = `BEARER ${jwt}` - } - if (projectAccessKey && projectAccessKey.length > 0) { - headers['X-Access-Key'] = projectAccessKey +// if (jwt && jwt.length > 0) { +// headers['Authorization'] = `BEARER ${jwt}` +// } +// if (projectAccessKey && projectAccessKey.length > 0) { +// headers['X-Access-Key'] = projectAccessKey +// } + +// return { +// url, +// headers, +// skipFetchSetup: true, +// fetchOptions: { +// mode: 'cors', +// cache: 'force-cache', +// credentials: 'same-origin', +// redirect: 'follow', +// referrer: 'client' +// } +// } +// } + +export const getFetchRequest = (url: string, projectAccessKey?: string, jwt?: string): ethers.FetchRequest => { + const req = new ethers.FetchRequest(url) + + if (jwt) { + req.setHeader('Authorization', `BEARER ${jwt}`) } - return { - url, - headers, - skipFetchSetup: true, - fetchOptions: { - mode: 'cors', - cache: 'force-cache', - credentials: 'same-origin', - redirect: 'follow', - referrer: 'client' - } + if (projectAccessKey) { + req.setHeader('X-Access-Key', projectAccessKey) } + + return req } diff --git a/packages/utils/src/promise-cache.ts b/packages/utils/src/promise-cache.ts index 0504adda8..091cabed6 100644 --- a/packages/utils/src/promise-cache.ts +++ b/packages/utils/src/promise-cache.ts @@ -13,7 +13,7 @@ export class PromiseCache { task: (...args: S) => Promise, ...args: S ): Promise { - key = `${key}:${ethers.utils.keccak256(ethers.utils.toUtf8Bytes(JSON.stringify(args, deterministically)))}` + key = `${key}:${ethers.id(JSON.stringify(args, deterministically))}` let entry = this.cache.get(key) diff --git a/packages/utils/src/typed-data.ts b/packages/utils/src/typed-data.ts index 5481cdef9..df973cbaf 100644 --- a/packages/utils/src/typed-data.ts +++ b/packages/utils/src/typed-data.ts @@ -16,9 +16,9 @@ export const encodeTypedDataHash = (typedData: TypedData): string => { // the hash encoder below delete types['EIP712Domain'] - return ethers.utils._TypedDataEncoder.hash(typedData.domain, types, typedData.message) + return ethers.TypedDataEncoder.hash(typedData.domain, types, typedData.message) } export const encodeTypedDataDigest = (typedData: TypedData): Uint8Array => { - return ethers.utils.arrayify(encodeTypedDataHash(typedData)) + return ethers.getBytes(encodeTypedDataHash(typedData)) } diff --git a/packages/utils/src/types.ts b/packages/utils/src/types.ts index 63814fd59..4ee14d682 100644 --- a/packages/utils/src/types.ts +++ b/packages/utils/src/types.ts @@ -1,12 +1,8 @@ -import { utils } from 'ethers' +import { ethers } from 'ethers' -type Deferrable = utils.Deferrable +const { defineProperties, resolveProperties } = ethers -const { defineReadOnly, getStatic, resolveProperties, checkProperties, shallowCopy, deepCopy } = utils - -export type { Deferrable } - -export { defineReadOnly, getStatic, resolveProperties, checkProperties, shallowCopy, deepCopy } +export { defineProperties, resolveProperties } export type Optionals = Omit< T, diff --git a/packages/utils/tests/bigint.spec.ts b/packages/utils/tests/bigint.spec.ts new file mode 100644 index 000000000..eb543da18 --- /dev/null +++ b/packages/utils/tests/bigint.spec.ts @@ -0,0 +1,57 @@ +import { expect } from 'chai' + +import { formatUnits, parseUnits, toHexString, MAX_UINT_256 } from '../src/bigint' +import { bigintReplacer, bigintReviver } from '../dist/0xsequence-utils.cjs' + +describe('bigint', () => { + it('should convert bigint to hex string', () => { + expect(toHexString(0n)).to.equal('0x00') + expect(toHexString(15n)).to.equal('0x0f') + expect(toHexString(16n)).to.equal('0x10') + expect(toHexString(255n)).to.equal('0xff') + expect(toHexString(256n)).to.equal('0x0100') + expect(toHexString(1234n)).to.equal('0x04d2') + expect(toHexString(MAX_UINT_256)).to.equal('0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff') + }) + + it('should parseUnits', () => { + expect(parseUnits('1.234', 3)).to.equal(1234n) + expect(parseUnits('1', 3)).to.equal(1000n) + expect(parseUnits('.123', 3)).to.equal(123n) + expect(parseUnits('1.', 3)).to.equal(1000n) + expect(parseUnits('1.234000', 3)).to.equal(1234n) + expect(parseUnits('-1.234', 3)).to.equal(-1234n) + expect(parseUnits('1.2345', 4)).to.equal(12345n) + expect(parseUnits('1', 18)).to.equal(1000000000000000000n) + + // Test padding decimals + expect(parseUnits('1.2', 4)).to.equal(12000n) + + expect(parseUnits('1.234', 0)).to.equal(1n) + }) + + it('should formatUnits', () => { + expect(formatUnits(1234n, 3)).to.equal('1.234') + + // Test stripping trailing zeros - keeps last + expect(formatUnits(1000n, 3)).to.equal('1') + + expect(formatUnits(123n, 3)).to.equal('0.123') + expect(formatUnits(1234n, 3)).to.equal('1.234') + expect(formatUnits(-1234n, 3)).to.equal('-1.234') + expect(formatUnits(1234n, 0)).to.equal('1234') + expect(formatUnits(1234n, 4)).to.equal('0.1234') + expect(formatUnits(1234n, 5)).to.equal('0.01234') + }) + + it('should serialize and deserialize bigints', () => { + const s = JSON.stringify({ value: 1234n }, bigintReplacer) + const d = JSON.parse(s, bigintReviver) + + expect(s).to.equal('{"value":{"$bigint":"1234"}}') + expect(d).to.deep.equal({ value: 1234n }) + + // BigNumber compatibility with ethers v5 + expect(JSON.parse('{"value":{"type":"BigNumber","hex":"0x04d2"}}', bigintReviver)).to.deep.equal({ value: 1234n }) + }) +}) diff --git a/packages/utils/tests/merkle.spec.ts b/packages/utils/tests/merkle.spec.ts index 0713189ef..174bc440d 100644 --- a/packages/utils/tests/merkle.spec.ts +++ b/packages/utils/tests/merkle.spec.ts @@ -1,13 +1,13 @@ import { expect } from 'chai' import { MerkleTreeGenerator, SaleItemsElement, getSaleItemsLeaf } from '@0xsequence/utils' -import { BigNumber, Wallet, constants, utils } from 'ethers' +import { ethers } from 'ethers' describe('merkle', function () { - const addrs = Array.from({ length: 10 }, () => Wallet.createRandom().address) - const elements: SaleItemsElement[] = addrs.map(addr => ({ address: addr, tokenId: BigNumber.from(1) })) + const addrs = Array.from({ length: 10 }, () => ethers.Wallet.createRandom().address) + const elements: SaleItemsElement[] = addrs.map(addr => ({ address: addr, tokenId: 1 })) it('generates tree, root and proof for custom elements', () => { - const getLeaf = (element: string) => utils.solidityKeccak256(['address'], [element.toLowerCase()]) + const getLeaf = (element: string) => ethers.solidityPackedKeccak256(['address'], [element.toLowerCase()]) const merkleGenerator = new MerkleTreeGenerator(addrs, getLeaf) expect(merkleGenerator.generateRoot()).to.be.a('string') const proof = merkleGenerator.generateProof(addrs[0]) @@ -26,8 +26,8 @@ describe('merkle', function () { it('errors when invalid element', () => { const merkleGenerator = new MerkleTreeGenerator(elements, getSaleItemsLeaf) const invalidElement: SaleItemsElement = { - address: Wallet.createRandom().address, - tokenId: constants.Zero + address: ethers.Wallet.createRandom().address, + tokenId: 0 } expect(() => merkleGenerator.generateProof(invalidElement)).to.throw('Element not found') }) diff --git a/packages/waas-ethers/CHANGELOG.md b/packages/waas-ethers/CHANGELOG.md index 7154395e1..3f39f55ae 100644 --- a/packages/waas-ethers/CHANGELOG.md +++ b/packages/waas-ethers/CHANGELOG.md @@ -1,5 +1,452 @@ # @0xsequence/waas-ethers +## 2.2.14 + +### Patch Changes + +- Somnia Testnet and Monad Testnet +- Updated dependencies + - @0xsequence/waas@2.2.14 + +## 2.2.13 + +### Patch Changes + +- Add XR1 to all networks +- Updated dependencies + - @0xsequence/waas@2.2.13 + +## 2.2.12 + +### Patch Changes + +- Add XR1 +- Updated dependencies + - @0xsequence/waas@2.2.12 + +## 2.2.11 + +### Patch Changes + +- Relayer updates +- Updated dependencies + - @0xsequence/waas@2.2.11 + +## 2.2.10 + +### Patch Changes + +- Etherlink support +- Updated dependencies + - @0xsequence/waas@2.2.10 + +## 2.2.9 + +### Patch Changes + +- Indexer gateway native token balances +- Updated dependencies + - @0xsequence/waas@2.2.9 + +## 2.2.8 + +### Patch Changes + +- Add Moonbeam and Moonbase Alpha +- Updated dependencies + - @0xsequence/waas@2.2.8 + +## 2.2.7 + +### Patch Changes + +- Update Builder package +- Updated dependencies + - @0xsequence/waas@2.2.7 + +## 2.2.6 + +### Patch Changes + +- Update relayer package +- Updated dependencies + - @0xsequence/waas@2.2.6 + +## 2.2.5 + +### Patch Changes + +- auth: fix sequence indexer gateway url +- account: immutable wallet proxy hook +- Updated dependencies +- Updated dependencies + - @0xsequence/waas@2.2.5 + +## 2.2.4 + +### Patch Changes + +- network: update soneium mainnet block explorer url +- waas: signTypedData intent support +- Updated dependencies +- Updated dependencies + - @0xsequence/waas@2.2.4 + +## 2.2.3 + +### Patch Changes + +- provider: updating initWallet to use connected network configs if they exist +- Updated dependencies + - @0xsequence/waas@2.2.3 + +## 2.2.2 + +### Patch Changes + +- pass projectAccessKey to relayer at all times +- Updated dependencies + - @0xsequence/waas@2.2.2 + +## 2.2.1 + +### Patch Changes + +- waas-ethers: sign typed data +- Updated dependencies + - @0xsequence/waas@2.2.1 + +## 2.2.0 + +### Minor Changes + +- indexer: gateway client +- @0xsequence/builder +- upgrade puppeteer to v23.10.3 + +### Patch Changes + +- Updated dependencies +- Updated dependencies +- Updated dependencies + - @0xsequence/waas@2.2.0 + +## 2.1.8 + +### Patch Changes + +- Add Soneium Mainnet +- Updated dependencies + - @0xsequence/waas@2.1.8 + +## 2.1.7 + +### Patch Changes + +- guard: pass project access key to guard requests +- Updated dependencies + - @0xsequence/waas@2.1.7 + +## 2.1.6 + +### Patch Changes + +- Add LAOS and Telos Testnet chains +- Updated dependencies + - @0xsequence/waas@2.1.6 + +## 2.1.5 + +### Patch Changes + +- account: save presigned configuration with reference chain id 1 +- Updated dependencies + - @0xsequence/waas@2.1.5 + +## 2.1.4 + +### Patch Changes + +- provider: pass projectAccessKey into MuxMessageProvider +- Updated dependencies + - @0xsequence/waas@2.1.4 + +## 2.1.3 + +### Patch Changes + +- waas: time drift date fix due to strange browser quirk +- Updated dependencies + - @0xsequence/waas@2.1.3 + +## 2.1.2 + +### Patch Changes + +- provider: export analytics correctly +- Updated dependencies + - @0xsequence/waas@2.1.2 + +## 2.1.1 + +### Patch Changes + +- Add LAOS chain support +- Updated dependencies + - @0xsequence/waas@2.1.1 + +## 2.1.0 + +### Minor Changes + +- account: forward project access key when estimating fees and sending transactions + +### Patch Changes + +- sessions: save signatures with reference chain id +- Updated dependencies +- Updated dependencies + - @0xsequence/waas@2.1.0 + +## 2.0.26 + +### Patch Changes + +- account: fix chain id comparison +- Updated dependencies + - @0xsequence/waas@2.0.26 + +## 2.0.25 + +### Patch Changes + +- skale-nebula: deploy gas limit = 10m +- Updated dependencies + - @0xsequence/waas@2.0.25 + +## 2.0.24 + +### Patch Changes + +- sessions: arweave: configurable gateway url +- waas: use /status to get time drift before sending any intents +- Updated dependencies +- Updated dependencies + - @0xsequence/waas@2.0.24 + +## 2.0.23 + +### Patch Changes + +- Add The Root Network support +- Updated dependencies + - @0xsequence/waas@2.0.23 + +## 2.0.22 + +### Patch Changes + +- Add SKALE Nebula Mainnet support +- Updated dependencies + - @0xsequence/waas@2.0.22 + +## 2.0.21 + +### Patch Changes + +- account: add publishWitnessFor +- Updated dependencies + - @0xsequence/waas@2.0.21 + +## 2.0.20 + +### Patch Changes + +- upgrade deps, and improve waas session status handling +- Updated dependencies + - @0xsequence/waas@2.0.20 + +## 2.0.19 + +### Patch Changes + +- Add Immutable zkEVM support +- Updated dependencies + - @0xsequence/waas@2.0.19 + +## 2.0.18 + +### Patch Changes + +- waas: new contractCall transaction type +- sessions: add arweave owner +- Updated dependencies +- Updated dependencies + - @0xsequence/waas@2.0.18 + +## 2.0.17 + +### Patch Changes + +- update waas auth to clear session before signIn +- Updated dependencies + - @0xsequence/waas@2.0.17 + +## 2.0.16 + +### Patch Changes + +- Removed Astar chains +- Updated dependencies + - @0xsequence/waas@2.0.16 + +## 2.0.15 + +### Patch Changes + +- indexer: update bindings with token balance additions +- Updated dependencies + - @0xsequence/waas@2.0.15 + +## 2.0.14 + +### Patch Changes + +- sessions: arweave config reader +- network: add b3 and apechain mainnet configs +- Updated dependencies +- Updated dependencies + - @0xsequence/waas@2.0.14 + +## 2.0.13 + +### Patch Changes + +- network: toy-testnet +- Updated dependencies + - @0xsequence/waas@2.0.13 + +## 2.0.12 + +### Patch Changes + +- api: update bindings +- Updated dependencies + - @0xsequence/waas@2.0.12 + +## 2.0.11 + +### Patch Changes + +- waas: intents test fix +- api: update bindings +- Updated dependencies +- Updated dependencies + - @0xsequence/waas@2.0.11 + +## 2.0.10 + +### Patch Changes + +- network: soneium minato testnet +- Updated dependencies + - @0xsequence/waas@2.0.10 + +## 2.0.9 + +### Patch Changes + +- network: fix SKALE network name +- Updated dependencies + - @0xsequence/waas@2.0.9 + +## 2.0.8 + +### Patch Changes + +- metadata: update bindings +- Updated dependencies + - @0xsequence/waas@2.0.8 + +## 2.0.7 + +### Patch Changes + +- wallet request handler fix +- Updated dependencies + - @0xsequence/waas@2.0.7 + +## 2.0.6 + +### Patch Changes + +- network: matic -> pol +- Updated dependencies + - @0xsequence/waas@2.0.6 + +## 2.0.5 + +### Patch Changes + +- provider: update databeat to 0.9.2 +- Updated dependencies + - @0xsequence/waas@2.0.5 + +## 2.0.4 + +### Patch Changes + +- network: add skale-nebula-testnet +- Updated dependencies + - @0xsequence/waas@2.0.4 + +## 2.0.3 + +### Patch Changes + +- waas: check session status in SequenceWaaS.isSignedIn() +- Updated dependencies + - @0xsequence/waas@2.0.3 + +## 2.0.2 + +### Patch Changes + +- sessions: property convert serialized bignumber hex value to bigint +- Updated dependencies + - @0xsequence/waas@2.0.2 + +## 2.0.1 + +### Patch Changes + +- waas: http signature check for authenticator requests +- provider: unwrap legacy json rpc responses +- use json replacer and reviver for bigints +- Updated dependencies +- Updated dependencies +- Updated dependencies + - @0xsequence/waas@2.0.1 + +## 2.0.0 + +### Major Changes + +- ethers v6 + +### Patch Changes + +- Updated dependencies + - @0xsequence/waas@2.0.0 + +## 1.10.15 + +### Patch Changes + +- utils: extractProjectIdFromAccessKey +- Updated dependencies + - @0xsequence/waas@1.10.15 + ## 1.10.14 ### Patch Changes diff --git a/packages/waas-ethers/package.json b/packages/waas-ethers/package.json index b952ef4d7..93630990d 100644 --- a/packages/waas-ethers/package.json +++ b/packages/waas-ethers/package.json @@ -1,6 +1,6 @@ { "name": "@0xsequence/waas-ethers", - "version": "1.10.14", + "version": "2.2.14", "description": "waas ethers wrapper", "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/waas", "source": "src/index.ts", @@ -13,11 +13,14 @@ "test:file": "NODE_OPTIONS='--import tsx' mocha -timeout 300000", "typecheck": "tsc --noEmit" }, + "peerDependencies": { + "ethers": ">=6" + }, "dependencies": { "@0xsequence/waas": "workspace:*" }, - "peerDependencies": { - "ethers": ">=5.5" + "devDependencies": { + "ethers": "6.13.4" }, "files": [ "src", diff --git a/packages/waas-ethers/src/signer.ts b/packages/waas-ethers/src/signer.ts index 7afeaca8b..fcf5c5b48 100644 --- a/packages/waas-ethers/src/signer.ts +++ b/packages/waas-ethers/src/signer.ts @@ -1,10 +1,10 @@ -import { BigNumber, ethers } from 'ethers' +import { ethers } from 'ethers' import { CommonAuthArgs, ExtendedSequenceConfig, SequenceWaaS, SequenceConfig, networks, store } from '@0xsequence/waas' -export class SequenceSigner extends ethers.Signer { +export class SequenceSigner extends ethers.AbstractSigner { constructor( private readonly sequence: SequenceWaaS, - readonly provider?: ethers.providers.BaseProvider + readonly provider: ethers.Provider | null = null ) { super() } @@ -12,7 +12,7 @@ export class SequenceSigner extends ethers.Signer { public static fromConfig( config: SequenceConfig & Partial, store?: store.Store, - provider?: ethers.providers.BaseProvider + provider: ethers.Provider | null = null ): SequenceSigner { return new SequenceSigner(new SequenceWaaS(config, store), provider) } @@ -33,12 +33,12 @@ export class SequenceSigner extends ethers.Signer { async getSimpleNetwork(): Promise { if (this.provider) { - return this.provider.getNetwork().then(n => n.chainId) + return this.provider.getNetwork().then(n => Number(n.chainId)) } return undefined } - async signMessage(message: ethers.utils.Bytes | string, authArgs?: CommonAuthArgs): Promise { + async signMessage(message: ethers.BytesLike, authArgs?: CommonAuthArgs): Promise { await this._ensureNetworkValid(false) const args = { @@ -49,19 +49,36 @@ export class SequenceSigner extends ethers.Signer { return this.sequence.signMessage(args).then(response => response.data.signature) } - async signTransaction(_transaction: ethers.utils.Deferrable): Promise { + async signTypedData( + domain: ethers.TypedDataDomain, + types: Record, + value: Record, + authArgs?: CommonAuthArgs + ): Promise { + await this._ensureNetworkValid(false) + + const args = { + typedData: { + domain, + types, + message: value + }, + network: await this.getSimpleNetwork(), + ...authArgs + } + return this.sequence.signTypedData(args).then(response => response.data.signature) + } + + async signTransaction(_transaction: ethers.TransactionRequest): Promise { // Not supported. Use sendTransaction or signMessage instead. throw new Error('SequenceSigner does not support signTransaction') } - async sendTransaction( - transaction: ethers.utils.Deferrable, - authArgs?: CommonAuthArgs - ): Promise { + async sendTransaction(transaction: ethers.TransactionRequest, authArgs?: CommonAuthArgs): Promise { await this._ensureNetworkValid(true) const args = { - transactions: [await ethers.utils.resolveProperties(transaction)], + transactions: [await ethers.resolveProperties(transaction)], network: await this.getSimpleNetwork(), ...authArgs } @@ -76,59 +93,59 @@ export class SequenceSigner extends ethers.Signer { // Success const { txHash } = response.data // eslint-disable-next-line @typescript-eslint/no-extra-non-null-assertion - return this.provider!!.getTransaction(txHash) + return this.provider!.getTransaction(txHash) as Promise } // Impossible throw new Error('Unknown return value') } - connect(provider: ethers.providers.BaseProvider, sequence?: SequenceWaaS): SequenceSigner { + connect(provider: ethers.Provider, sequence?: SequenceWaaS) { return new SequenceSigner(sequence ?? this.sequence, provider) } // // Provider required // - async getBalance(blockTag?: ethers.providers.BlockTag): Promise { - await this._ensureNetworkValid(true) - return super.getBalance(blockTag) - } - async getTransactionCount(_blockTag?: ethers.providers.BlockTag): Promise { + async getTransactionCount(_blockTag?: ethers.BlockTag): Promise { throw new Error('SequenceSigner does not support getTransactionCount') } - async estimateGas(transaction: ethers.utils.Deferrable): Promise { + async estimateGas(transaction: ethers.TransactionRequest): Promise { await this._ensureNetworkValid(true) //FIXME This won't be accurate return super.estimateGas(transaction) } - async call( - transaction: ethers.utils.Deferrable, - blockTag?: ethers.providers.BlockTag - ): Promise { + async call(transaction: ethers.TransactionRequest, blockTag?: ethers.BlockTag): Promise { await this._ensureNetworkValid(true) - return super.call(transaction, blockTag) + return super.call({ ...transaction, blockTag }) } - async getChainId(): Promise { - await this._ensureNetworkValid(true) // Prevent mismatched configurations - return super.getChainId() - } + // XXX: These methods are not supported by AbstractProvider - async getGasPrice(): Promise { - await this._ensureNetworkValid(true) - return super.getGasPrice() - } + // async getBalance(blockTag?: ethers.BlockTag): Promise { + // await this._ensureNetworkValid(true) + // return super.getBalance(blockTag) + // } - async getFeeData(): Promise { - await this._ensureNetworkValid(true) - return super.getFeeData() - } + // async getChainId(): Promise { + // await this._ensureNetworkValid(true) // Prevent mismatched configurations + // return super.getChainId() + // } + + // async getGasPrice(): Promise { + // await this._ensureNetworkValid(true) + // return super.getGasPrice() + // } + + // async getFeeData(): Promise { + // await this._ensureNetworkValid(true) + // return super.getFeeData() + // } - async resolveName(name: string): Promise { + async resolveName(name: string): Promise { await this._ensureNetworkValid(true) return super.resolveName(name) } diff --git a/packages/waas/CHANGELOG.md b/packages/waas/CHANGELOG.md index 198c456ad..419647f50 100644 --- a/packages/waas/CHANGELOG.md +++ b/packages/waas/CHANGELOG.md @@ -1,5 +1,555 @@ # @0xsequence/waas +## 2.2.14 + +### Patch Changes + +- Somnia Testnet and Monad Testnet +- Updated dependencies + - @0xsequence/core@2.2.14 + - @0xsequence/network@2.2.14 + - @0xsequence/utils@2.2.14 + +## 2.2.13 + +### Patch Changes + +- Add XR1 to all networks +- Updated dependencies + - @0xsequence/core@2.2.13 + - @0xsequence/network@2.2.13 + - @0xsequence/utils@2.2.13 + +## 2.2.12 + +### Patch Changes + +- Add XR1 +- Updated dependencies + - @0xsequence/core@2.2.12 + - @0xsequence/network@2.2.12 + - @0xsequence/utils@2.2.12 + +## 2.2.11 + +### Patch Changes + +- Relayer updates +- Updated dependencies + - @0xsequence/core@2.2.11 + - @0xsequence/network@2.2.11 + - @0xsequence/utils@2.2.11 + +## 2.2.10 + +### Patch Changes + +- Etherlink support +- Updated dependencies + - @0xsequence/core@2.2.10 + - @0xsequence/network@2.2.10 + - @0xsequence/utils@2.2.10 + +## 2.2.9 + +### Patch Changes + +- Indexer gateway native token balances +- Updated dependencies + - @0xsequence/core@2.2.9 + - @0xsequence/network@2.2.9 + - @0xsequence/utils@2.2.9 + +## 2.2.8 + +### Patch Changes + +- Add Moonbeam and Moonbase Alpha +- Updated dependencies + - @0xsequence/core@2.2.8 + - @0xsequence/network@2.2.8 + - @0xsequence/utils@2.2.8 + +## 2.2.7 + +### Patch Changes + +- Update Builder package +- Updated dependencies + - @0xsequence/core@2.2.7 + - @0xsequence/network@2.2.7 + - @0xsequence/utils@2.2.7 + +## 2.2.6 + +### Patch Changes + +- Update relayer package +- Updated dependencies + - @0xsequence/core@2.2.6 + - @0xsequence/network@2.2.6 + - @0xsequence/utils@2.2.6 + +## 2.2.5 + +### Patch Changes + +- auth: fix sequence indexer gateway url +- account: immutable wallet proxy hook +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.2.5 + - @0xsequence/network@2.2.5 + - @0xsequence/utils@2.2.5 + +## 2.2.4 + +### Patch Changes + +- network: update soneium mainnet block explorer url +- waas: signTypedData intent support +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.2.4 + - @0xsequence/network@2.2.4 + - @0xsequence/utils@2.2.4 + +## 2.2.3 + +### Patch Changes + +- provider: updating initWallet to use connected network configs if they exist +- Updated dependencies + - @0xsequence/core@2.2.3 + - @0xsequence/network@2.2.3 + - @0xsequence/utils@2.2.3 + +## 2.2.2 + +### Patch Changes + +- pass projectAccessKey to relayer at all times +- Updated dependencies + - @0xsequence/core@2.2.2 + - @0xsequence/network@2.2.2 + - @0xsequence/utils@2.2.2 + +## 2.2.1 + +### Patch Changes + +- waas-ethers: sign typed data +- Updated dependencies + - @0xsequence/core@2.2.1 + - @0xsequence/network@2.2.1 + - @0xsequence/utils@2.2.1 + +## 2.2.0 + +### Minor Changes + +- indexer: gateway client +- @0xsequence/builder +- upgrade puppeteer to v23.10.3 + +### Patch Changes + +- Updated dependencies +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.2.0 + - @0xsequence/network@2.2.0 + - @0xsequence/utils@2.2.0 + +## 2.1.8 + +### Patch Changes + +- Add Soneium Mainnet +- Updated dependencies + - @0xsequence/core@2.1.8 + - @0xsequence/network@2.1.8 + - @0xsequence/utils@2.1.8 + +## 2.1.7 + +### Patch Changes + +- guard: pass project access key to guard requests +- Updated dependencies + - @0xsequence/core@2.1.7 + - @0xsequence/network@2.1.7 + - @0xsequence/utils@2.1.7 + +## 2.1.6 + +### Patch Changes + +- Add LAOS and Telos Testnet chains +- Updated dependencies + - @0xsequence/core@2.1.6 + - @0xsequence/network@2.1.6 + - @0xsequence/utils@2.1.6 + +## 2.1.5 + +### Patch Changes + +- account: save presigned configuration with reference chain id 1 +- Updated dependencies + - @0xsequence/core@2.1.5 + - @0xsequence/network@2.1.5 + - @0xsequence/utils@2.1.5 + +## 2.1.4 + +### Patch Changes + +- provider: pass projectAccessKey into MuxMessageProvider +- Updated dependencies + - @0xsequence/core@2.1.4 + - @0xsequence/network@2.1.4 + - @0xsequence/utils@2.1.4 + +## 2.1.3 + +### Patch Changes + +- waas: time drift date fix due to strange browser quirk +- Updated dependencies + - @0xsequence/core@2.1.3 + - @0xsequence/network@2.1.3 + - @0xsequence/utils@2.1.3 + +## 2.1.2 + +### Patch Changes + +- provider: export analytics correctly +- Updated dependencies + - @0xsequence/core@2.1.2 + - @0xsequence/network@2.1.2 + - @0xsequence/utils@2.1.2 + +## 2.1.1 + +### Patch Changes + +- Add LAOS chain support +- Updated dependencies + - @0xsequence/core@2.1.1 + - @0xsequence/network@2.1.1 + - @0xsequence/utils@2.1.1 + +## 2.1.0 + +### Minor Changes + +- account: forward project access key when estimating fees and sending transactions + +### Patch Changes + +- sessions: save signatures with reference chain id +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.1.0 + - @0xsequence/network@2.1.0 + - @0xsequence/utils@2.1.0 + +## 2.0.26 + +### Patch Changes + +- account: fix chain id comparison +- Updated dependencies + - @0xsequence/core@2.0.26 + - @0xsequence/network@2.0.26 + - @0xsequence/utils@2.0.26 + +## 2.0.25 + +### Patch Changes + +- skale-nebula: deploy gas limit = 10m +- Updated dependencies + - @0xsequence/core@2.0.25 + - @0xsequence/network@2.0.25 + - @0xsequence/utils@2.0.25 + +## 2.0.24 + +### Patch Changes + +- sessions: arweave: configurable gateway url +- waas: use /status to get time drift before sending any intents +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.0.24 + - @0xsequence/network@2.0.24 + - @0xsequence/utils@2.0.24 + +## 2.0.23 + +### Patch Changes + +- Add The Root Network support +- Updated dependencies + - @0xsequence/core@2.0.23 + - @0xsequence/network@2.0.23 + - @0xsequence/utils@2.0.23 + +## 2.0.22 + +### Patch Changes + +- Add SKALE Nebula Mainnet support +- Updated dependencies + - @0xsequence/core@2.0.22 + - @0xsequence/network@2.0.22 + - @0xsequence/utils@2.0.22 + +## 2.0.21 + +### Patch Changes + +- account: add publishWitnessFor +- Updated dependencies + - @0xsequence/core@2.0.21 + - @0xsequence/network@2.0.21 + - @0xsequence/utils@2.0.21 + +## 2.0.20 + +### Patch Changes + +- upgrade deps, and improve waas session status handling +- Updated dependencies + - @0xsequence/core@2.0.20 + - @0xsequence/network@2.0.20 + - @0xsequence/utils@2.0.20 + +## 2.0.19 + +### Patch Changes + +- Add Immutable zkEVM support +- Updated dependencies + - @0xsequence/core@2.0.19 + - @0xsequence/network@2.0.19 + - @0xsequence/utils@2.0.19 + +## 2.0.18 + +### Patch Changes + +- waas: new contractCall transaction type +- sessions: add arweave owner +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.0.18 + - @0xsequence/network@2.0.18 + - @0xsequence/utils@2.0.18 + +## 2.0.17 + +### Patch Changes + +- update waas auth to clear session before signIn +- Updated dependencies + - @0xsequence/core@2.0.17 + - @0xsequence/network@2.0.17 + - @0xsequence/utils@2.0.17 + +## 2.0.16 + +### Patch Changes + +- Removed Astar chains +- Updated dependencies + - @0xsequence/core@2.0.16 + - @0xsequence/network@2.0.16 + - @0xsequence/utils@2.0.16 + +## 2.0.15 + +### Patch Changes + +- indexer: update bindings with token balance additions +- Updated dependencies + - @0xsequence/core@2.0.15 + - @0xsequence/network@2.0.15 + - @0xsequence/utils@2.0.15 + +## 2.0.14 + +### Patch Changes + +- sessions: arweave config reader +- network: add b3 and apechain mainnet configs +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.0.14 + - @0xsequence/network@2.0.14 + - @0xsequence/utils@2.0.14 + +## 2.0.13 + +### Patch Changes + +- network: toy-testnet +- Updated dependencies + - @0xsequence/core@2.0.13 + - @0xsequence/network@2.0.13 + - @0xsequence/utils@2.0.13 + +## 2.0.12 + +### Patch Changes + +- api: update bindings +- Updated dependencies + - @0xsequence/core@2.0.12 + - @0xsequence/network@2.0.12 + - @0xsequence/utils@2.0.12 + +## 2.0.11 + +### Patch Changes + +- waas: intents test fix +- api: update bindings +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.0.11 + - @0xsequence/network@2.0.11 + - @0xsequence/utils@2.0.11 + +## 2.0.10 + +### Patch Changes + +- network: soneium minato testnet +- Updated dependencies + - @0xsequence/core@2.0.10 + - @0xsequence/network@2.0.10 + - @0xsequence/utils@2.0.10 + +## 2.0.9 + +### Patch Changes + +- network: fix SKALE network name +- Updated dependencies + - @0xsequence/core@2.0.9 + - @0xsequence/network@2.0.9 + - @0xsequence/utils@2.0.9 + +## 2.0.8 + +### Patch Changes + +- metadata: update bindings +- Updated dependencies + - @0xsequence/core@2.0.8 + - @0xsequence/network@2.0.8 + - @0xsequence/utils@2.0.8 + +## 2.0.7 + +### Patch Changes + +- wallet request handler fix +- Updated dependencies + - @0xsequence/core@2.0.7 + - @0xsequence/network@2.0.7 + - @0xsequence/utils@2.0.7 + +## 2.0.6 + +### Patch Changes + +- network: matic -> pol +- Updated dependencies + - @0xsequence/core@2.0.6 + - @0xsequence/network@2.0.6 + - @0xsequence/utils@2.0.6 + +## 2.0.5 + +### Patch Changes + +- provider: update databeat to 0.9.2 +- Updated dependencies + - @0xsequence/core@2.0.5 + - @0xsequence/network@2.0.5 + - @0xsequence/utils@2.0.5 + +## 2.0.4 + +### Patch Changes + +- network: add skale-nebula-testnet +- Updated dependencies + - @0xsequence/core@2.0.4 + - @0xsequence/network@2.0.4 + - @0xsequence/utils@2.0.4 + +## 2.0.3 + +### Patch Changes + +- waas: check session status in SequenceWaaS.isSignedIn() +- Updated dependencies + - @0xsequence/core@2.0.3 + - @0xsequence/network@2.0.3 + - @0xsequence/utils@2.0.3 + +## 2.0.2 + +### Patch Changes + +- sessions: property convert serialized bignumber hex value to bigint +- Updated dependencies + - @0xsequence/core@2.0.2 + - @0xsequence/network@2.0.2 + - @0xsequence/utils@2.0.2 + +## 2.0.1 + +### Patch Changes + +- waas: http signature check for authenticator requests +- provider: unwrap legacy json rpc responses +- use json replacer and reviver for bigints +- Updated dependencies +- Updated dependencies +- Updated dependencies + - @0xsequence/core@2.0.1 + - @0xsequence/network@2.0.1 + - @0xsequence/utils@2.0.1 + +## 2.0.0 + +### Major Changes + +- ethers v6 + +### Patch Changes + +- Updated dependencies + - @0xsequence/core@2.0.0 + - @0xsequence/network@2.0.0 + - @0xsequence/utils@2.0.0 + +## 1.10.15 + +### Patch Changes + +- utils: extractProjectIdFromAccessKey +- Updated dependencies + - @0xsequence/core@1.10.15 + - @0xsequence/network@1.10.15 + ## 1.10.14 ### Patch Changes diff --git a/packages/waas/package.json b/packages/waas/package.json index 4cf3ea798..191af4d61 100644 --- a/packages/waas/package.json +++ b/packages/waas/package.json @@ -1,6 +1,6 @@ { "name": "@0xsequence/waas", - "version": "1.10.14", + "version": "2.2.14", "description": "waas session client", "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/waas", "source": "src/index.ts", @@ -17,6 +17,7 @@ "dependencies": { "@0xsequence/core": "workspace:*", "@0xsequence/network": "workspace:*", + "@0xsequence/utils": "workspace:*", "@aws-sdk/client-cognito-identity-provider": "^3.445.0", "idb": "^7.1.1", "json-canonicalize": "^1.0.6", @@ -27,10 +28,11 @@ "dist" ], "peerDependencies": { - "ethers": ">=5.5" + "ethers": ">=6" }, "devDependencies": { "@types/jwt-decode": "^3.1.0", + "ethers": "6.13.4", "fake-indexeddb": "^4.0.1" }, "preconstruct": { diff --git a/packages/waas/src/auth.ts b/packages/waas/src/auth.ts index 9e2dc5549..20ede1d45 100644 --- a/packages/waas/src/auth.ts +++ b/packages/waas/src/auth.ts @@ -10,13 +10,17 @@ import { newSessionFromSessionId } from './session' import { LocalStore, Store, StoreObj } from './store' import { GetTransactionReceiptArgs, - SendDelayedEncodeArgs, + SendContractCallArgs, SendERC1155Args, SendERC20Args, SendERC721Args, SendTransactionsArgs, SignedIntent, - SignMessageArgs + SignMessageArgs, + getTimeDrift, + updateTimeDrift, + getLocalTime, + SignTypedDataArgs } from './intents' import { FeeOptionsResponse, @@ -32,12 +36,15 @@ import { isMaySentTransactionResponse, isSessionAuthProofResponse, isSignedMessageResponse, + isSignedTypedDataResponse, isTimedOutTransactionResponse, isValidationRequiredResponse, MaySentTransactionResponse, - SignedMessageResponse + SignedMessageResponse, + SignedTypedDataResponse } from './intents/responses' import { WaasAuthenticator, AnswerIncorrectError, Chain, EmailAlreadyInUseError, Session } from './clients/authenticator.gen' +import { NoPrivateKeyError } from './errors' import { SimpleNetwork, WithSimpleNetwork } from './networks' import { EmailAuth } from './email' import { ethers } from 'ethers' @@ -54,6 +61,7 @@ export type SequenceConfig = { projectAccessKey: string waasConfigKey: string network?: SimpleNetwork + disableHttpSignatureCheck?: boolean } export type ExtendedSequenceConfig = { @@ -82,24 +90,6 @@ export type SignInResponse = { email?: string } -function encodeHex(data: string | Uint8Array) { - return ( - '0x' + - Array.from(typeof data === 'string' ? new TextEncoder().encode(data) : data, byte => byte.toString(16).padStart(2, '0')).join( - '' - ) - ) -} - -function decodeHex(hex: string) { - return new Uint8Array( - hex - .substring(2) - .match(/.{1,2}/g)! - .map(byte => parseInt(byte, 16)) - ) -} - export type ValidationArgs = { onValidationRequired?: () => boolean } @@ -145,6 +135,32 @@ export function defaultArgsOrFail( return preconfig as Required & Required & ExtendedSequenceConfig } +const jwksDev = { + keys: [ + { + alg: 'RS256', + e: 'AQAB', + kid: '9LkLZyHdNq1N2aeHMlC5jw', + kty: 'RSA', + n: 'qllUB_ERsOjbKx4SirGow4XDov05lQyhiF7Duo4sPkH9CwMN11OqhLuIqeIXPq0rPNIXGP99A7riXTcpRNk-5ZNL29zs-Xjj3idp7nZQZLIU1CBQErTcbxbwUYp8Q46k7lJXVlMmwoLQvQAgH8BZLuSe-Xk1tye0mDC-bHvmrMfqm2zmuWeDnZercU3Jg2iYwyPrjKWx7YSBSMTXTKPGndws4m3s3XIEpI2alLcLLWsPQk2UjIlux6I7vLwvjM_BgjFhYHqgg1tgZUPn_Xxt4wvhobF8UIacRVmGcuyYBnhRxKnBQhEClGSBVtnFYYBSvRjTgliOwf3DhFoXdnmyPQ', + use: 'sig' + } + ] +} + +const jwksProd = { + keys: [ + { + alg: 'RS256', + e: 'AQAB', + kid: 'nWh-_3nQ1lnhhI1ZSQTQmw', + kty: 'RSA', + n: 'pECaEq2k0k22J9e7hFLAFmKbzPLlWToUJJmFeWAdEiU4zpW17EUEOyfjRzjgBewc7KFJQEblC3eTD7Vc5bh9-rafPEj8LaKyZzzS5Y9ZATXhlMo5Pnlar3BrTm48XcnT6HnLsvDeJHUVbrYd1JyE1kqeTjUKWvgKX4mgIJiuYhpdzbOC22cPaWb1dYCVhArDVAPHGqaEwRjX7JneETdY5hLJ6JhsAws706W7fwfNKddPQo2mY95S9q8HFxMr5EaXEMmhwxk8nT5k-Ouar2dobMXRMmQiEZSt9fJaGKlK7KWJSnbPOVa2cZud1evs1Rz2SdCSA2bhuZ6NnZCxkqnagw', + use: 'sig' + } + ] +} + export class SequenceWaaS { private waas: SequenceWaaSBase private client: WaasAuthenticator @@ -163,6 +179,9 @@ export class SequenceWaaS { // The last Date header value returned by the server, used for users with desynchronised clocks private lastDate: Date | undefined + // Flag for disabling consequent requests if signature verification fails + private signatureVerificationFailed: boolean = false + constructor( config: SequenceConfig & Partial, private readonly store: Store = new LocalStore(), @@ -171,10 +190,91 @@ export class SequenceWaaS { ) { this.config = defaultArgsOrFail(config) this.waas = new SequenceWaaSBase({ network: 1, ...config }, this.store, this.cryptoBackend, this.secureStoreBackend) - this.client = new WaasAuthenticator(this.config.rpcServer, this.fetch.bind(this)) + this.client = new WaasAuthenticator(this.config.rpcServer, this._fetch) + this.deviceName = new StoreObj(this.store, '@0xsequence.waas.auth.deviceName', undefined) } + _fetch = (input: RequestInfo, init?: RequestInit): Promise => { + if (this.signatureVerificationFailed) { + throw new Error('Signature verification failed') + } + + if (this.cryptoBackend && this.config.disableHttpSignatureCheck !== true && init?.headers) { + const headers: { [key: string]: any } = {} + + headers['Accept-Signature'] = 'sig=();alg="rsa-v1_5-sha256"' + + init!.headers = { ...init!.headers, ...headers } + } + + const response = fetch(input, init) + + if (this.cryptoBackend && this.config.disableHttpSignatureCheck !== true) { + response.then(async r => { + try { + const clone = r.clone() + const responseBodyText = await clone.text() + + const contentDigest = r.headers.get('Content-Digest') + const signatureInput = r.headers.get('Signature-Input') + const signature = r.headers.get('Signature') + + if (!contentDigest) { + throw new Error('Content-Digest header not set') + } + if (!signatureInput) { + throw new Error('Signature-Input header not set') + } + if (!signature) { + throw new Error('Signature header not set') + } + + const contentDigestSha = contentDigest.match(':(.*):')?.[1] + + if (!contentDigestSha) { + throw new Error('Content digest not found') + } + + const responseBodyTextUint8Array = new TextEncoder().encode(responseBodyText) + const responseBodyTextDigest = await this.cryptoBackend!.digest('SHA-256', responseBodyTextUint8Array) + const base64EncodedDigest = btoa(String.fromCharCode(...responseBodyTextDigest)) + + if (contentDigestSha !== base64EncodedDigest) { + throw new Error('Digest mismatch') + } + + // we're removing the first 4 characters from signatureInput to trim the sig= prefix + const message = `"content-digest": ${contentDigest}\n"@signature-params": ${signatureInput.substring(4)}` + + const algo = { name: 'RSASSA-PKCS1-v1_5', hash: 'SHA-256' } + + const jwks = r.url.includes('dev-waas') ? jwksDev : jwksProd + + const key = await this.cryptoBackend!.importKey('jwk', jwks.keys[0], algo, false, ['verify']) + + const sig = signature.match(':(.*):')?.[1] + + if (!sig) { + throw new Error('Signature not found') + } + const signatureBuffer = Uint8Array.from(atob(sig), c => c.charCodeAt(0)) + + const verifyResult = await this.cryptoBackend!.verify(algo, key, signatureBuffer, new TextEncoder().encode(message)) + + if (!verifyResult) { + throw new Error('Signature verification failed, consequent requests will fail') + } + } catch (e) { + this.signatureVerificationFailed = true + throw e + } + }) + } + + return response + } + public get email() { if (this.emailClient) { return this.emailClient @@ -239,6 +339,17 @@ export class SequenceWaaS { } } + private async updateTimeDrift() { + if (getTimeDrift() === undefined) { + const res = await fetch(`${this.config.rpcServer}/status`) + const date = res.headers.get('Date') + if (!date) { + throw new Error('failed to get Date header value from /status') + } + updateTimeDrift(new Date(date)) + } + } + private async sendIntent(intent: SignedIntent) { const sessionId = await this.waas.getSessionId() if (!sessionId) { @@ -262,7 +373,13 @@ export class SequenceWaaS { return this.waas.isSignedIn() } - signIn(creds: Identity, sessionName: string): Promise { + async signIn(creds: Identity, sessionName: string): Promise { + // We clear and drop session regardless of whether it's signed in or not + const currentSessionId = await this.waas.getSessionId() + if (currentSessionId) { + await this.dropSession({ sessionId: currentSessionId, strict: false }) + } + const isEmailAuth = 'email' in creds if (isEmailAuth && this.emailAuthCodeRequiredCallback.length == 0) { return Promise.reject('Missing emailAuthCodeRequired callback') @@ -329,6 +446,8 @@ export class SequenceWaaS { } async initAuth(identity: Identity): Promise { + await this.updateTimeDrift() + if ('guest' in identity && identity.guest) { return this.initGuestAuth() } else if ('idToken' in identity) { @@ -392,6 +511,15 @@ export class SequenceWaaS { challenge: Challenge, opts?: { sessionName?: string; forceCreateAccount?: boolean } ): Promise { + await this.updateTimeDrift() + + // initAuth can start while user is already signed in and continue with linkAccount method, + // but it can't be used to completeAuth while user is already signed in. In this + // case we should throw an error. + const isSignedIn = await this.isSignedIn() + if (isSignedIn) { + throw new Error('You are already signed in. Use dropSession to sign out from current session first.') + } if (!opts) { opts = {} } @@ -424,7 +552,7 @@ export class SequenceWaaS { } } - async registerSession(intent: SignedIntent, name: string) { + private async registerSession(intent: SignedIntent, name: string) { try { const res = await this.client.registerSession({ intent, friendlyName: name }, this.headers()) return res @@ -447,10 +575,12 @@ export class SequenceWaaS { async getSessionHash() { const sessionId = (await this.waas.getSessionId()).toLowerCase() - return ethers.utils.keccak256(ethers.utils.toUtf8Bytes(sessionId)) + return ethers.id(sessionId) } async dropSession({ sessionId, strict }: { sessionId?: string; strict?: boolean } = {}) { + await this.updateTimeDrift() + const thisSessionId = await this.waas.getSessionId() if (!thisSessionId) { throw new Error('session not open') @@ -478,14 +608,27 @@ export class SequenceWaaS { throw new Error('No secure store available') } - const session = await newSessionFromSessionId(thisSessionId, this.cryptoBackend, this.secureStoreBackend) - session.clear() + try { + const session = await newSessionFromSessionId(thisSessionId, this.cryptoBackend, this.secureStoreBackend) + session.clear() + } catch (error) { + if (error instanceof NoPrivateKeyError) { + // If no private key is found, we can't clear the session properly + // but we can still clean up other session data which will log us out + } else { + throw error + } + } + await this.waas.completeSignOut() await this.deviceName.set(undefined) + updateTimeDrift(undefined) } } async listSessions(): Promise { + await this.updateTimeDrift() + const sessionId = await this.waas.getSessionId() if (!sessionId) { throw new Error('session not open') @@ -506,6 +649,8 @@ export class SequenceWaaS { } async validateSession(args?: ValidationArgs) { + await this.updateTimeDrift() + if (await this.isSessionValid()) { return true } @@ -514,6 +659,8 @@ export class SequenceWaaS { } async finishValidateSession(challenge: string): Promise { + await this.updateTimeDrift() + const intent = await this.waas.finishValidateSession(this.validationRequiredSalt, challenge) const result = await this.sendIntent(intent) @@ -526,6 +673,8 @@ export class SequenceWaaS { } async isSessionValid(): Promise { + await this.updateTimeDrift() + const intent = await this.waas.getSession() const result = await this.sendIntent(intent) @@ -537,9 +686,9 @@ export class SequenceWaaS { } async waitForSessionValid(timeout: number = 600000, pollRate: number = 2000) { - const start = Date.now() + const start = getLocalTime() - while (Date.now() - start < timeout) { + while (getLocalTime() - start < timeout) { if (await this.isSessionValid()) { return true } @@ -551,11 +700,15 @@ export class SequenceWaaS { } async sessionAuthProof({ nonce, network, validation }: { nonce?: string; network?: string; validation?: ValidationArgs }) { + await this.updateTimeDrift() + const intent = await this.waas.sessionAuthProof({ nonce, network }) return await this.trySendIntent({ validation }, intent, isSessionAuthProofResponse) } async listAccounts() { + await this.updateTimeDrift() + const intent = await this.waas.listAccounts() const res = await this.sendIntent(intent) @@ -567,6 +720,8 @@ export class SequenceWaaS { } async linkAccount(challenge: Challenge) { + await this.updateTimeDrift() + const intent = await this.waas.linkAccount(challenge.getIntentParams()) const res = await this.sendIntent(intent) @@ -578,11 +733,15 @@ export class SequenceWaaS { } async removeAccount(accountId: string) { + await this.updateTimeDrift() + const intent = await this.waas.removeAccount({ accountId }) await this.sendIntent(intent) } async getIdToken(args?: { nonce?: string }): Promise { + await this.updateTimeDrift() + const intent = await this.waas.getIdToken({ nonce: args?.nonce }) const res = await this.sendIntent(intent) @@ -629,10 +788,19 @@ export class SequenceWaaS { } async signMessage(args: WithSimpleNetwork & CommonAuthArgs): Promise { + await this.updateTimeDrift() + const intent = await this.waas.signMessage(await this.useIdentifier(args)) return this.trySendIntent(args, intent, isSignedMessageResponse) } + async signTypedData(args: WithSimpleNetwork & CommonAuthArgs): Promise { + await this.updateTimeDrift() + + const intent = await this.waas.signTypedData(await this.useIdentifier(args)) + return this.trySendIntent(args, intent, isSignedTypedDataResponse) + } + private async trySendTransactionIntent( intent: SignedIntent, args: CommonAuthArgs @@ -656,31 +824,43 @@ export class SequenceWaaS { } async sendTransaction(args: WithSimpleNetwork & CommonAuthArgs): Promise { + await this.updateTimeDrift() + const intent = await this.waas.sendTransaction(await this.useIdentifier(args)) return this.trySendTransactionIntent(intent, args) } async sendERC20(args: WithSimpleNetwork & CommonAuthArgs): Promise { + await this.updateTimeDrift() + const intent = await this.waas.sendERC20(await this.useIdentifier(args)) return this.trySendTransactionIntent(intent, args) } async sendERC721(args: WithSimpleNetwork & CommonAuthArgs): Promise { + await this.updateTimeDrift() + const intent = await this.waas.sendERC721(await this.useIdentifier(args)) return this.trySendTransactionIntent(intent, args) } async sendERC1155(args: WithSimpleNetwork & CommonAuthArgs): Promise { + await this.updateTimeDrift() + const intent = await this.waas.sendERC1155(await this.useIdentifier(args)) return this.trySendTransactionIntent(intent, args) } - async callContract(args: WithSimpleNetwork & CommonAuthArgs): Promise { + async callContract(args: WithSimpleNetwork & CommonAuthArgs): Promise { + await this.updateTimeDrift() + const intent = await this.waas.callContract(await this.useIdentifier(args)) return this.trySendTransactionIntent(intent, args) } async feeOptions(args: WithSimpleNetwork & CommonAuthArgs): Promise { + await this.updateTimeDrift() + const intent = await this.waas.feeOptions(await this.useIdentifier(args)) return this.trySendIntent(args, intent, isFeeOptionsResponse) } @@ -707,7 +887,7 @@ export class SequenceWaaS { // Special version of fetch that keeps track of the last seen Date header async fetch(input: RequestInfo, init?: RequestInit) { - const res = await globalThis.fetch(input, init) + const res = await fetch(input, init) const headerValue = res.headers.get('date') if (headerValue) { this.lastDate = new Date(headerValue) diff --git a/packages/waas/src/base.ts b/packages/waas/src/base.ts index de6fa2139..f494c7486 100644 --- a/packages/waas/src/base.ts +++ b/packages/waas/src/base.ts @@ -13,8 +13,8 @@ import { listSessions, openSession, OpenSessionArgs, - sendDelayedEncode, - SendDelayedEncodeArgs, + sendContractCall, + SendContractCallArgs, sendERC1155, SendERC1155Args, sendERC20, @@ -28,6 +28,8 @@ import { signIntent, signMessage, SignMessageArgs, + signTypedData, + SignTypedDataArgs, validateSession } from './intents' import { LocalStore, Store, StoreObj } from './store' @@ -47,12 +49,14 @@ import { IntentDataOpenSession, IntentDataSendTransaction, IntentDataSignMessage, + IntentDataSignTypedData, IntentDataValidateSession } from './clients/intent.gen' import { getDefaultSubtleCryptoBackend, SubtleCryptoBackend } from './subtle-crypto' import { getDefaultSecureStoreBackend, SecureStoreBackend } from './secure-store' import { ethers } from 'ethers' import { ChallengeIntentParams } from './challenge' +import { NoPrivateKeyError } from './errors' type Status = 'pending' | 'signed-in' | 'signed-out' @@ -152,8 +156,16 @@ export class SequenceWaaSBase { throw new Error('session not open') } - const session = await newSessionFromSessionId(sessionId, this.cryptoBackend, this.secureStoreBackend) - return signIntent(session, intent) + try { + const session = await newSessionFromSessionId(sessionId, this.cryptoBackend, this.secureStoreBackend) + return signIntent(session, intent) + } catch (error) { + if (error instanceof NoPrivateKeyError) { + await this.completeSignOut() + throw new Error('No private key found, logging out') + } + throw error + } } public async signUsingSessionKey(message: string | Uint8Array) { @@ -162,8 +174,16 @@ export class SequenceWaaSBase { throw new Error('session not open') } - const signer = await newSessionFromSessionId(sessionId, this.cryptoBackend, this.secureStoreBackend) - return signer.sign(message) + try { + const signer = await newSessionFromSessionId(sessionId, this.cryptoBackend, this.secureStoreBackend) + return signer.sign(message) + } catch (error) { + if (error instanceof NoPrivateKeyError) { + await this.completeSignOut() + throw new Error('No private key found, logging out') + } + throw error + } } private gettingSessionIdPromise: Promise | undefined @@ -253,7 +273,7 @@ export class SequenceWaaSBase { async initiateIdTokenAuth(idToken: string, exp?: number): Promise> { const sessionId = await this.getSessionId() - const idTokenHash = ethers.utils.keccak256(ethers.utils.toUtf8Bytes(idToken)) + const idTokenHash = ethers.id(idToken) const intent = await initiateAuth({ sessionId, identityType: IdentityType.OIDC, @@ -266,7 +286,7 @@ export class SequenceWaaSBase { async initiateStytchAuth(idToken: string, exp?: number): Promise> { const sessionId = await this.getSessionId() - const idTokenHash = ethers.utils.keccak256(ethers.utils.toUtf8Bytes(idToken)) + const idTokenHash = ethers.id(idToken) const intent = await initiateAuth({ sessionId, identityType: IdentityType.Stytch, @@ -279,7 +299,7 @@ export class SequenceWaaSBase { async initiatePlayFabAuth(titleId: string, sessionTicket: string): Promise> { const sessionId = await this.getSessionId() - const ticketHash = ethers.utils.keccak256(ethers.utils.toUtf8Bytes(sessionTicket)) + const ticketHash = ethers.id(sessionTicket) const intent = await initiateAuth({ sessionId, identityType: IdentityType.PlayFab, @@ -422,6 +442,28 @@ export class SequenceWaaSBase { return this.signIntent(packet) } + /** + * This method can be used to sign typed data using waas API. It can only be used + * after successfully signing in with the `signIn` and `completeSignIn` methods. + * + * The method does not sign the typed data. It only returns a payload + * that must be sent to the waas API to complete the sign process. + * + * @param chainId The network on which the typed data will be signed + * @param typedData The typed data that will be signed + * @return a payload that must be sent to the waas API to complete sign process + */ + async signTypedData(args: WithSimpleNetwork & ExtraArgs): Promise> { + const packet = signTypedData({ + chainId: toNetworkID(args.network || this.config.network), + ...args, + lifespan: args.lifespan ?? DEFAULT_LIFESPAN, + wallet: await this.getWalletAddress() + }) + + return this.signIntent(packet) + } + /** * This method can be used to send transactions to the waas API. It can only be used * after successfully signing in with the `signIn` and `completeSignIn` methods. @@ -481,9 +523,9 @@ export class SequenceWaaSBase { } async callContract( - args: WithSimpleNetwork & ExtraTransactionArgs + args: WithSimpleNetwork & ExtraTransactionArgs ): Promise> { - const intent = sendDelayedEncode(await this.commonArgs(args)) + const intent = sendContractCall(await this.commonArgs(args)) return this.signIntent(intent) } diff --git a/packages/waas/src/challenge.ts b/packages/waas/src/challenge.ts index 9effd946f..b23e5ada8 100644 --- a/packages/waas/src/challenge.ts +++ b/packages/waas/src/challenge.ts @@ -22,7 +22,7 @@ export class GuestChallenge extends Challenge { } getIntentParams(): ChallengeIntentParams { - const answer = ethers.utils.keccak256(ethers.utils.toUtf8Bytes(this.challenge + this.sessionId)) + const answer = ethers.id(this.challenge + this.sessionId) return { identityType: IdentityType.Guest, verifier: this.sessionId, @@ -55,7 +55,7 @@ export class EmailChallenge extends Challenge { } setAnswer(answer: string): void { - this.hashedAnswer = ethers.utils.keccak256(ethers.utils.toUtf8Bytes(this.challenge + answer)) + this.hashedAnswer = ethers.id(this.challenge + answer) } withAnswer(answer: string) { @@ -72,7 +72,7 @@ export class IdTokenChallenge extends Challenge { getIntentParams(): ChallengeIntentParams { const decoded = jwtDecode(this.idToken) - const idTokenHash = ethers.utils.keccak256(ethers.utils.toUtf8Bytes(this.idToken)) + const idTokenHash = ethers.id(this.idToken) return { identityType: IdentityType.OIDC, verifier: `${idTokenHash};${decoded.exp}`, @@ -107,7 +107,7 @@ export class PlayFabChallenge extends Challenge { } getIntentParams(): ChallengeIntentParams { - const ticketHash = ethers.utils.keccak256(ethers.utils.toUtf8Bytes(this.sessionTicket)) + const ticketHash = ethers.id(this.sessionTicket) return { identityType: IdentityType.PlayFab, verifier: `${this.titleId}|${ticketHash}`, diff --git a/packages/waas/src/clients/authenticator.gen.ts b/packages/waas/src/clients/authenticator.gen.ts index fa192f665..e9d06f9b6 100644 --- a/packages/waas/src/clients/authenticator.gen.ts +++ b/packages/waas/src/clients/authenticator.gen.ts @@ -1,7 +1,7 @@ /* eslint-disable */ -// sequence-waas-authenticator v0.1.0 35f86317a98af91896d1114ad52dd22102d9de9f +// sequence-waas-authenticator v0.1.0 562a7e7a15dc77925b3f241a08d83c8c548ba5c3 // -- -// Code generated by webrpc-gen@v0.18.8 with typescript generator. DO NOT EDIT. +// Code generated by webrpc-gen@v0.19.3 with typescript generator. DO NOT EDIT. // // webrpc-gen -schema=authenticator.ridl -target=typescript -client -out=./clients/authenticator.gen.ts @@ -12,7 +12,7 @@ export const WebRPCVersion = 'v1' export const WebRPCSchemaVersion = 'v0.1.0' // Schema hash generated from your RIDL schema -export const WebRPCSchemaHash = '35f86317a98af91896d1114ad52dd22102d9de9f' +export const WebRPCSchemaHash = '562a7e7a15dc77925b3f241a08d83c8c548ba5c3' // // Types @@ -29,12 +29,17 @@ export enum IntentName { sessionAuthProof = 'sessionAuthProof', feeOptions = 'feeOptions', signMessage = 'signMessage', + signTypedData = 'signTypedData', sendTransaction = 'sendTransaction', getTransactionReceipt = 'getTransactionReceipt', federateAccount = 'federateAccount', removeAccount = 'removeAccount', listAccounts = 'listAccounts', - getIdToken = 'getIdToken' + getIdToken = 'getIdToken', + adoptChildWallet = 'adoptChildWallet', + getAdopter = 'getAdopter', + confirmIntent = 'confirmIntent', + getConfirmationStatus = 'getConfirmationStatus' } export enum IntentResponseCode { @@ -47,6 +52,7 @@ export enum IntentResponseCode { validationFinished = 'validationFinished', sessionAuthProof = 'sessionAuthProof', signedMessage = 'signedMessage', + signedTypedData = 'signedTypedData', feeOptions = 'feeOptions', transactionReceipt = 'transactionReceipt', transactionFailed = 'transactionFailed', @@ -54,7 +60,10 @@ export enum IntentResponseCode { accountList = 'accountList', accountFederated = 'accountFederated', accountRemoved = 'accountRemoved', - idToken = 'idToken' + idToken = 'idToken', + adopter = 'adopter', + childWalletAdopted = 'childWalletAdopted', + confirmationRequired = 'confirmationRequired' } export enum IdentityType { @@ -85,6 +94,11 @@ export interface IntentResponse { data: any } +export enum Migration { + OIDCToStytch = 'OIDCToStytch', + OIDCToEmail = 'OIDCToEmail' +} + export interface Version { webrpcVersion: string schemaVersion: string @@ -210,6 +224,11 @@ export interface VerificationContext { expiresAt: string } +export interface Page { + limit?: number + after?: string +} + export interface WaasAuthenticator { registerSession(args: RegisterSessionArgs, headers?: object, signal?: AbortSignal): Promise sendIntent(args: SendIntentArgs, headers?: object, signal?: AbortSignal): Promise @@ -245,6 +264,12 @@ export interface WaasAuthenticatorAdmin { getTenant(args: GetTenantArgs, headers?: object, signal?: AbortSignal): Promise createTenant(args: CreateTenantArgs, headers?: object, signal?: AbortSignal): Promise updateTenant(args: UpdateTenantArgs, headers?: object, signal?: AbortSignal): Promise + nextMigrationBatch(args: NextMigrationBatchArgs, headers?: object, signal?: AbortSignal): Promise + processMigrationBatch( + args: ProcessMigrationBatchArgs, + headers?: object, + signal?: AbortSignal + ): Promise } export interface VersionArgs {} @@ -293,6 +318,26 @@ export interface UpdateTenantArgs { export interface UpdateTenantReturn { tenant: Tenant } +export interface NextMigrationBatchArgs { + migration: Migration + projectId: number + page: Page +} + +export interface NextMigrationBatchReturn { + page: Page + items: Array +} +export interface ProcessMigrationBatchArgs { + migration: Migration + projectId: number + items: Array +} + +export interface ProcessMigrationBatchReturn { + logs: { [key: string]: Array } + errors: { [key: string]: string } +} // // Client @@ -461,6 +506,46 @@ export class WaasAuthenticatorAdmin implements WaasAuthenticatorAdmin { } ) } + + nextMigrationBatch = ( + args: NextMigrationBatchArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('NextMigrationBatch'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + page: _data.page, + items: >_data.items + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } + + processMigrationBatch = ( + args: ProcessMigrationBatchArgs, + headers?: object, + signal?: AbortSignal + ): Promise => { + return this.fetch(this.url('ProcessMigrationBatch'), createHTTPRequest(args, headers, signal)).then( + res => { + return buildResponse(res).then(_data => { + return { + logs: <{ [key: string]: Array }>_data.logs, + errors: <{ [key: string]: string }>_data.errors + } + }) + }, + error => { + throw WebrpcRequestFailedError.new({ cause: `fetch(): ${error.message || ''}` }) + } + ) + } } const createHTTPRequest = (body: object = {}, headers: object = {}, signal: AbortSignal | null = null): object => { diff --git a/packages/waas/src/clients/intent.gen.ts b/packages/waas/src/clients/intent.gen.ts index eb258e382..0cd21e215 100644 --- a/packages/waas/src/clients/intent.gen.ts +++ b/packages/waas/src/clients/intent.gen.ts @@ -1,5 +1,5 @@ /* eslint-disable */ -// sequence-waas-intents v0.1.0 1fe0a24abef81231c54c0886157c65ef738d5ed6 +// sequence-waas-intents v0.1.0 2ceeffac8ca0cebead69d58a1aa7a27d30ecb864 // -- // Code generated by webrpc-gen@v0.19.3 with typescript generator. DO NOT EDIT. // @@ -12,7 +12,7 @@ export const WebRPCVersion = 'v1' export const WebRPCSchemaVersion = 'v0.1.0' // Schema hash generated from your RIDL schema -export const WebRPCSchemaHash = '1fe0a24abef81231c54c0886157c65ef738d5ed6' +export const WebRPCSchemaHash = '2ceeffac8ca0cebead69d58a1aa7a27d30ecb864' // // Types @@ -29,12 +29,17 @@ export enum IntentName { sessionAuthProof = 'sessionAuthProof', feeOptions = 'feeOptions', signMessage = 'signMessage', + signTypedData = 'signTypedData', sendTransaction = 'sendTransaction', getTransactionReceipt = 'getTransactionReceipt', federateAccount = 'federateAccount', removeAccount = 'removeAccount', listAccounts = 'listAccounts', - getIdToken = 'getIdToken' + getIdToken = 'getIdToken', + adoptChildWallet = 'adoptChildWallet', + getAdopter = 'getAdopter', + confirmIntent = 'confirmIntent', + getConfirmationStatus = 'getConfirmationStatus' } export enum TransactionType { @@ -42,7 +47,8 @@ export enum TransactionType { erc20send = 'erc20send', erc721send = 'erc721send', erc1155send = 'erc1155send', - delayedEncode = 'delayedEncode' + delayedEncode = 'delayedEncode', + contractCall = 'contractCall' } export enum IntentResponseCode { @@ -55,6 +61,7 @@ export enum IntentResponseCode { validationFinished = 'validationFinished', sessionAuthProof = 'sessionAuthProof', signedMessage = 'signedMessage', + signedTypedData = 'signedTypedData', feeOptions = 'feeOptions', transactionReceipt = 'transactionReceipt', transactionFailed = 'transactionFailed', @@ -62,7 +69,10 @@ export enum IntentResponseCode { accountList = 'accountList', accountFederated = 'accountFederated', accountRemoved = 'accountRemoved', - idToken = 'idToken' + idToken = 'idToken', + adopter = 'adopter', + childWalletAdopted = 'childWalletAdopted', + confirmationRequired = 'confirmationRequired' } export enum FeeTokenType { @@ -80,6 +90,10 @@ export enum IdentityType { Stytch = 'Stytch' } +export enum ChallengeType { + EmailOTP = 'EmailOTP' +} + export interface Intent { version: string name: IntentName @@ -149,6 +163,12 @@ export interface IntentDataSignMessage { message: string } +export interface IntentDataSignTypedData { + network: string + wallet: string + typedData: any +} + export interface IntentDataFeeOptions { network: string wallet: string @@ -187,19 +207,52 @@ export interface IntentDataRemoveAccount { accountId: string } +export interface IntentDataAdoptChildWallet { + network: string + wallet: string + adopter: string + adopterProof: AdopterProof +} + +export interface AdopterProof { + message: string + signature: string +} + export interface IntentDataGetIdToken { sessionId: string wallet: string nonce?: string } +export interface IntentDataGetAdopter { + wallet: string +} + +export interface IntentDataConfirmIntent { + wallet: string + confirmationID: string + challengeAnswer: string +} + +export interface IntentDataGetConfirmationStatus { + wallet: string + confirmationID: string +} + export interface TransactionRaw { type: string to: string - value: string + value?: string data: string } +export interface AbiData { + abi: string + func?: string + args: Array +} + export interface TransactionERC20 { type: string tokenAddress: string @@ -228,6 +281,13 @@ export interface TransactionDelayedEncode { data: any } +export interface TransactionContractCall { + type: string + to: string + value?: string + data: AbiData +} + export interface TransactionERC1155 { type: string tokenAddress: string @@ -292,6 +352,11 @@ export interface IntentResponseSignedMessage { message: string } +export interface IntentResponseSignedTypedData { + signature: string + encodedTypedData: string +} + export interface FeeOption { token: FeeToken to: string @@ -346,6 +411,22 @@ export interface IntentResponseIdToken { expiresIn: number } +export interface IntentResponseChildWalletAdopted { + adopterAddress: string +} + +export interface IntentResponseAdopter { + adopterAddress: string +} + +export interface IntentResponseConfirmationRequired { + confirmationId: string + salt: string + challengeType: ChallengeType + challengeDestination?: string + expiresIn: number +} + export interface Account { id: string type: IdentityType diff --git a/packages/waas/src/errors.ts b/packages/waas/src/errors.ts new file mode 100644 index 000000000..72bda9328 --- /dev/null +++ b/packages/waas/src/errors.ts @@ -0,0 +1,6 @@ +export class NoPrivateKeyError extends Error { + constructor() { + super('No private key found') + this.name = 'NoPrivateKeyError' + } +} diff --git a/packages/waas/src/index.ts b/packages/waas/src/index.ts index 64a374543..ce0c84498 100644 --- a/packages/waas/src/index.ts +++ b/packages/waas/src/index.ts @@ -5,8 +5,8 @@ export * from './challenge' export * as store from './store' export * as networks from './networks' -export type { Transaction } from './intents/transactions' -export { erc20, erc721, erc1155, delayedEncode } from './intents/transactions' +export type { Transaction, ContractCallArguments } from './intents/transactions' +export { erc20, erc721, erc1155, delayedEncode, contractCall } from './intents/transactions' export type { SecureStoreBackend } from './secure-store' diff --git a/packages/waas/src/intents/base.ts b/packages/waas/src/intents/base.ts index 856248e38..0f9caecbf 100644 --- a/packages/waas/src/intents/base.ts +++ b/packages/waas/src/intents/base.ts @@ -11,9 +11,46 @@ export type SignedIntent = Omit & { data: T } const INTENTS_VERSION = 1 const VERSION = `${INTENTS_VERSION} (Web ${PACKAGE_VERSION})` +let timeDrift: number | undefined +const timeDriftKey = '@sequence.timeDrift' + +function isSessionStorageAvailable() { + return typeof window === 'object' && typeof window.sessionStorage === 'object' +} + +export function getLocalTime() { + return new Date().getTime() +} + +export function getTimeDrift() { + if (isSessionStorageAvailable()) { + const drift = window.sessionStorage.getItem(timeDriftKey) + if (drift) { + return parseInt(drift, 10) + } + } + return timeDrift +} + +export function updateTimeDrift(serverTime?: Date) { + if (!serverTime) { + timeDrift = undefined + if (isSessionStorageAvailable()) { + window.sessionStorage.removeItem(timeDriftKey) + } + return + } + + timeDrift = (getLocalTime() - serverTime.getTime()) / 1000 + if (isSessionStorageAvailable()) { + window.sessionStorage.setItem(timeDriftKey, timeDrift.toString(10)) + } +} + export function makeIntent(name: IntentName, lifespan: number, data: T): Intent { - const issuedAt = Math.floor(Date.now() / 1000) - const expiresAt = issuedAt + lifespan + const drift = Math.abs(Math.floor(getTimeDrift() || 0)) + const issuedAt = Math.floor(getLocalTime() / 1000 - drift) + const expiresAt = issuedAt + lifespan + 2 * drift return { version: VERSION, issuedAt, @@ -37,12 +74,12 @@ export async function signIntent(session: Session, intent: Intent): Promis } } -export function hashIntent(intent: Intent): ethers.Bytes { +export function hashIntent(intent: Intent): Uint8Array { // Discard all fields other than the explicitly listed const { version, issuedAt, expiresAt, name, data } = intent const hashableIntent = { version, issuedAt, expiresAt, name, data } - const encoded = ethers.utils.toUtf8Bytes(canonicalize(hashableIntent)) - return ethers.utils.arrayify(ethers.utils.keccak256(encoded)) + const encoded = ethers.toUtf8Bytes(canonicalize(hashableIntent)) + return ethers.getBytes(ethers.keccak256(encoded)) } export function changeIntentTime(intent: SignedIntent, now: Date): Intent { diff --git a/packages/waas/src/intents/messages.ts b/packages/waas/src/intents/messages.ts index 7caca8c94..b8869bf2c 100644 --- a/packages/waas/src/intents/messages.ts +++ b/packages/waas/src/intents/messages.ts @@ -1,5 +1,5 @@ import { ethers } from 'ethers' -import { IntentDataSignMessage, IntentName } from '../clients/intent.gen' +import { IntentDataSignMessage, IntentDataSignTypedData, IntentName } from '../clients/intent.gen' import { Intent, makeIntent } from './base' interface BaseArgs { @@ -16,6 +16,23 @@ export function signMessage({ wallet, chainId, message, lifespan }: SignMessageA return makeIntent(IntentName.signMessage, lifespan, { wallet, network: chainId.toString(), - message: message.startsWith('0x') ? message : ethers.utils.hexlify(ethers.utils.toUtf8Bytes(message)) + message: message.startsWith('0x') ? message : ethers.hexlify(ethers.toUtf8Bytes(message)) + }) +} + +export type SignTypedDataArgs = { + typedData: any +} + +export function signTypedData({ + wallet, + chainId, + typedData, + lifespan +}: SignTypedDataArgs & BaseArgs): Intent { + return makeIntent(IntentName.signTypedData, lifespan, { + wallet, + network: chainId.toString(), + typedData }) } diff --git a/packages/waas/src/intents/responses.ts b/packages/waas/src/intents/responses.ts index faa72f452..17d47bf96 100644 --- a/packages/waas/src/intents/responses.ts +++ b/packages/waas/src/intents/responses.ts @@ -107,6 +107,14 @@ export type SignedMessageResponse = { } } +export type SignedTypedDataResponse = { + code: 'signedTypedData' + data: { + typedData: any + signature: string + } +} + export type SessionAuthProofResponse = { code: 'sessionAuthProof' data: { @@ -204,6 +212,17 @@ export function isSignedMessageResponse(receipt: any): receipt is SignedMessageR ) } +export function isSignedTypedDataResponse(receipt: any): receipt is SignedTypedDataResponse { + return ( + typeof receipt === 'object' && + typeof receipt.code === 'string' && + receipt.code === 'signedTypedData' && + typeof receipt.data === 'object' && + typeof receipt.data.encodedTypedData === 'string' && + typeof receipt.data.signature === 'string' + ) +} + export function isSessionAuthProofResponse(receipt: any): receipt is SessionAuthProofResponse { return ( typeof receipt === 'object' && diff --git a/packages/waas/src/intents/transactions.ts b/packages/waas/src/intents/transactions.ts index c341f6c0a..86bdb8fca 100644 --- a/packages/waas/src/intents/transactions.ts +++ b/packages/waas/src/intents/transactions.ts @@ -3,6 +3,7 @@ import { IntentDataGetTransactionReceipt, IntentDataSendTransaction, IntentDataFeeOptions, + TransactionContractCall, TransactionDelayedEncode, TransactionERC1155, TransactionERC20, @@ -14,6 +15,7 @@ import { FeeTokenType } from '../clients/intent.gen' import { ethers } from 'ethers' +import { toHexString } from '@0xsequence/utils' interface BaseArgs { lifespan: number @@ -58,6 +60,24 @@ export type SendERC1155Args = TransactionFeeArgs & { data?: string } +export type SendContractCallArgs = TransactionFeeArgs & { + chainId: number + to: string + value?: ethers.BigNumberish + abi: string + func?: string + args: ContractCallArguments[] +} + +export type ContractCallArguments = + | string + | { + abi: string + func?: string + args: ContractCallArguments[] + } + +// Deprecated: please use SendContractCallArgs instead export type SendDelayedEncodeArgs = TransactionFeeArgs & { chainId: number to: string @@ -79,7 +99,7 @@ export function feeOptions({ wallet, network: chainId.toString(), transactions: transactions.map(tx => { - if (!tx.to || tx.to === ethers.constants.AddressZero) { + if (!tx.to || tx.to === ethers.ZeroAddress) { throw new Error('Contract creation not supported') } @@ -90,8 +110,8 @@ export function feeOptions({ return { type: 'transaction', to: tx.to, - value: ethers.BigNumber.from(tx.value || 0).toHexString(), - data: ethers.utils.hexlify(tx.data || []) + value: toHexString(BigInt(tx.value || 0)), + data: ethers.hexlify(tx.data || '0x') } }) }) @@ -111,7 +131,7 @@ export function sendTransactions({ wallet, network: chainId.toString(), transactions: withTransactionFee(transactions, transactionsFeeOption).map(tx => { - if (!tx.to || tx.to === ethers.constants.AddressZero) { + if (!tx.to || tx.to === ethers.ZeroAddress) { throw new Error('Contract creation not supported') } @@ -122,8 +142,8 @@ export function sendTransactions({ return { type: 'transaction', to: tx.to, - value: ethers.BigNumber.from(tx.value || 0).toHexString(), - data: ethers.utils.hexlify(tx.data || []) + value: toHexString(BigInt(tx.value || 0)), + data: ethers.hexlify(tx.data || '0x') } }), transactionsFeeQuote @@ -210,7 +230,7 @@ export function sendERC721({ token, to, id, safe, data, ...args }: SendERC721Arg export function sendERC1155({ token, to, values, data, ...args }: SendERC1155Args & BaseArgs): Intent { const vals = values.map(v => ({ id: v.id, - amount: ethers.BigNumber.from(v.amount).toString() + amount: BigInt(v.amount).toString() })) return sendTransactions({ @@ -219,6 +239,27 @@ export function sendERC1155({ token, to, values, data, ...args }: SendERC1155Arg }) } +export function sendContractCall({ + to, + value, + abi, + func, + args, + ...otherArgs +}: SendContractCallArgs & BaseArgs): Intent { + return sendTransactions({ + transactions: [ + contractCall({ + to, + value: BigInt(value || 0).toString(), + data: { abi, func, args } + }) + ], + ...otherArgs + }) +} + +// Deprecated please use sendContractCall instead export function sendDelayedEncode({ to, value, @@ -231,7 +272,7 @@ export function sendDelayedEncode({ transactions: [ delayedEncode({ to, - value: ethers.BigNumber.from(value).toString(), + value: BigInt(value).toString(), data: { abi, func, args } }) ], @@ -240,12 +281,13 @@ export function sendDelayedEncode({ } export type Transaction = - | ethers.providers.TransactionRequest + | ethers.TransactionRequest | TransactionRaw | TransactionERC20 | TransactionERC721 | TransactionERC1155 - | TransactionDelayedEncode + | TransactionContractCall + | TransactionDelayedEncode // deprecated TransactionDelayedEncode export function transaction(data: Omit): Transaction { return { type: 'transaction', ...data } @@ -298,7 +340,7 @@ export function erc1155(data: Omit | Omit ({ id: v.id, - amount: ethers.BigNumber.from(v.amount).toString() + amount: v.amount.toString() })), tokenAddress: sendERC1155Args.token, to: sendERC1155Args.to, @@ -309,7 +351,7 @@ export function erc1155(data: Omit | Omit ({ id: v.id, - amount: ethers.BigNumber.from(v.amount).toString() + amount: v.amount })), tokenAddress: transactionERC1155.tokenAddress, to: transactionERC1155.to, @@ -320,6 +362,34 @@ export function erc1155(data: Omit | Omit | Omit): Transaction { + const sendContractCallArgs = data as Omit + const transactionContractCall = data as Omit + + if (sendContractCallArgs.abi !== undefined) { + return { + type: 'contractCall', + to: sendContractCallArgs.to, + value: toHexString(BigInt(sendContractCallArgs.value || 0)), + data: { + abi: sendContractCallArgs.abi, + func: sendContractCallArgs.func, + args: sendContractCallArgs.args + } + } + } else if (transactionContractCall.data !== undefined) { + return { + type: 'contractCall', + to: transactionContractCall.to, + value: transactionContractCall.value, + data: transactionContractCall.data + } + } else { + throw new Error('Invalid contract transaction') + } +} + +// Deprecated export function delayedEncode( data: Omit | Omit ): Transaction { @@ -330,7 +400,7 @@ export function delayedEncode( return { type: 'delayedEncode', to: sendDelayedEncodeArgs.to, - value: ethers.BigNumber.from(sendDelayedEncodeArgs.value).toString(), + value: toHexString(BigInt(sendDelayedEncodeArgs.value)), data: { abi: sendDelayedEncodeArgs.abi, func: sendDelayedEncodeArgs.func, @@ -378,6 +448,6 @@ export function combineTransactionIntents(intents: Intent { if (typeof message === 'string') { if (message.startsWith('0x')) { message = message.slice(2) - message = ethers.utils.arrayify(message) + message = ethers.getBytes(message) } else { message = encoder.encode(message) } } const signatureBuff = await cryptoBackend.sign({ name: 'ECDSA', hash: { name: 'SHA-256' } }, keys.privateKey, message) - return ethers.utils.hexlify(new Uint8Array(signatureBuff)) + return ethers.hexlify(new Uint8Array(signatureBuff)) }, clear: async () => { await secureStoreBackend.delete(idbName, idbStoreName, sessionId) @@ -88,5 +89,5 @@ async function pubKeyToSessionId(cryptoBackend: SubtleCryptoBackend, pubKey: Cry pubKeyTypedRaw[0] = KeyTypes.ECDSAP256R1 pubKeyTypedRaw.set(new Uint8Array(pubKeyRaw), 1) - return ethers.utils.hexlify(pubKeyTypedRaw) + return ethers.hexlify(pubKeyTypedRaw) } diff --git a/packages/waas/src/subtle-crypto.ts b/packages/waas/src/subtle-crypto.ts index 838c743f0..a03fc89ab 100644 --- a/packages/waas/src/subtle-crypto.ts +++ b/packages/waas/src/subtle-crypto.ts @@ -11,6 +11,14 @@ export interface SubtleCryptoBackend { keyUsages: KeyUsage[] ): Promise + importKey( + format: 'jwk', + keyData: JsonWebKey, + algorithm: AlgorithmIdentifier | RsaHashedImportParams | EcKeyImportParams | HmacImportParams | AesKeyAlgorithm, + extractable: boolean, + keyUsages: ReadonlyArray + ): Promise + // exportKey is used to export a key pair. The `format` argument is used to // specify the format of the exported key. The `key` argument is the key pair // to export. In general we'll use `format: 'raw'` and `key: `. @@ -63,7 +71,7 @@ export class WindowSubtleCryptoBackend implements SubtleCryptoBackend { } } - async generateKey( + generateKey( algorithm: RsaHashedKeyGenParams | EcKeyGenParams, extractable: boolean, keyUsages: KeyUsage[] @@ -71,6 +79,16 @@ export class WindowSubtleCryptoBackend implements SubtleCryptoBackend { return window.crypto.subtle.generateKey(algorithm, extractable, keyUsages) } + importKey( + format: 'jwk', + keyData: JsonWebKey, + algorithm: AlgorithmIdentifier | RsaHashedImportParams | EcKeyImportParams | HmacImportParams | AesKeyAlgorithm, + extractable: boolean, + keyUsages: ReadonlyArray + ): Promise { + return window.crypto.subtle.importKey(format, keyData, algorithm, extractable, keyUsages) + } + async exportKey(format: Exclude, key: CryptoKey): Promise { const keyData = await window.crypto.subtle.exportKey(format, key) return new Uint8Array(keyData) @@ -86,7 +104,7 @@ export class WindowSubtleCryptoBackend implements SubtleCryptoBackend { return new Uint8Array(signature) } - async verify( + verify( algorithm: AlgorithmIdentifier | RsaPssParams | EcdsaParams, key: CryptoKey, signature: Uint8Array, diff --git a/packages/waas/tests/intents.spec.ts b/packages/waas/tests/intents.spec.ts index 643c8f8ea..95088cd95 100644 --- a/packages/waas/tests/intents.spec.ts +++ b/packages/waas/tests/intents.spec.ts @@ -2,7 +2,7 @@ import * as chai from 'chai' import { ethers } from 'ethers' import { Intent, signIntent } from '../src/intents' -import { IntentDataSendTransaction, IntentDataSignMessage } from '../src/clients/intent.gen' +import { IntentName, IntentDataSendTransaction, IntentDataSignMessage } from '../src/clients/intent.gen' import { newSECP256K1SessionFromPrivateKey } from '../src/session' import { getDefaultSecureStoreBackend } from '../src/secure-store' @@ -14,7 +14,7 @@ describe('Payloads', () => { it('Should sign a payload', async () => { const intent: Intent = { version: '1', - name: 'sendTransactions', + name: IntentName.sendTransaction, issuedAt: 1600000000, expiresAt: 1600000000 + 86400, data: { @@ -24,7 +24,7 @@ describe('Payloads', () => { transactions: [ { type: 'erc20send', - token: ethers.constants.AddressZero, + token: ethers.ZeroAddress, to: '0x0dc9603d4da53841C1C83f3B550C6143e60e0425', value: '0' } @@ -45,14 +45,14 @@ describe('Payloads', () => { expect(signedIntent.signatures.length).to.equal(1) expect(signedIntent.signatures[0].sessionId).to.equal(await session.sessionId()) expect(signedIntent.signatures[0].signature).to.equal( - '0x14682ca0eb116109cdf1d0bad6a84e29787787b4a1779d2b43c28d8705ade929267474e8a7725d5e7540ded2010897d3ecaad32b27c75fbfb4f63ff1cf1a948a1c' + '0x0707e5b0a66bc2aa536cd6dfd0ad3f7859ac3a864f9be1d351b450e704b4cf3548b19ffd72f956e1448b0298b862c95489daeb00c0f0686a8c76f22908bf29801b' ) }) it('Should sign a message payload', async () => { const intent: Intent = { version: '1', - name: 'sendTransactions', + name: IntentName.sendTransaction, issuedAt: 1600000000, expiresAt: 1600000000 + 86400, data: { @@ -75,14 +75,14 @@ describe('Payloads', () => { expect(signedIntent.signatures.length).to.equal(1) expect(signedIntent.signatures[0].sessionId).to.equal(await session.sessionId()) expect(signedIntent.signatures[0].signature).to.equal( - '0x768b25315317e551ed7b540e73fdf69d8816dcc763a50c648cf2966849f089a2495103f06c876c502bfb33cb348c4b77ffe39bbd6483b932b806a5817374f9ea1c' + '0xf21bd58b31a490895c64eec3848465dc89426a208b2a480013e0f779003474d41be802c900c03841a467e6598785e8e7c29b506ff78ec7d08cdccba2be7ecc8c1c' ) }) it('Should sign transaction payload', async () => { const intent: Intent = { version: '1', - name: 'sendTransactions', + name: IntentName.sendTransaction, issuedAt: 1600000000, expiresAt: 1600000000 + 86400, data: { @@ -127,19 +127,16 @@ describe('Payloads', () => { data: '0x223344' }, { - type: 'delayedEncode', + type: 'contractCall', to: '0x140d72763D1ce39Ad4E2e73EC6e8FC53E5b73B64', - value: '0', data: { - abi: '[{"inputs":[{"internalType":"uint256","name":"_orderId","type":"uint256"},{"internalType":"uint256","name":"_maxCost","type":"uint256"},{"internalType":"address[]","name":"_fees","type":"address[]"},{"internalType":"bytes","name":"_data","type":"bytes"}],"name":"fillOrKillOrder","outputs":[],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_val","type":"uint256"},{"internalType":"string","name":"_data","type":"string"}],"name":"notExpired","outputs":[],"stateMutability":"view","type":"function"},{"inputs":[],"name":"otherMethods","outputs":[],"stateMutability":"nonpayable","type":"function"}]', - func: 'fillOrKillOrder', + abi: 'fillOrKillOrder(uint256 orderId, uint256 maxCost, address[] fees, bytes data)', args: [ '48774435471364917511246724398022004900255301025912680232738918790354204737320', '1000000000000000000', - '["0x8541D65829f98f7D71A4655cCD7B2bB8494673bF"]', + ['0x8541D65829f98f7D71A4655cCD7B2bB8494673bF'], { abi: 'notExpired(uint256,string)', - func: 'notExpired', args: ['1600000000', 'Nov 1st, 2020'] } ] @@ -162,7 +159,7 @@ describe('Payloads', () => { expect(signedIntent.signatures.length).to.equal(1) expect(signedIntent.signatures[0].sessionId).to.equal(await session.sessionId()) expect(signedIntent.signatures[0].signature).to.equal( - '0x98dd84b3d4fe077b2f55e2839609b226d8119b9b0ee10756122615a5d68746bf60596069a305a7533123f212b576d16f3f14ad06faed9fc005c32a28bf8bafb21b' + '0x692c5c4c969f54dc96b216e41a80b5366829754e652a5a6b499aa7b4fb3c086664cbf282568c863030c4183ae0c05a2861bfb5de1e76fea94f71796ff6cd1c9f1c' ) }) }) diff --git a/packages/wallet/CHANGELOG.md b/packages/wallet/CHANGELOG.md index b2486b92d..841b4fc33 100644 --- a/packages/wallet/CHANGELOG.md +++ b/packages/wallet/CHANGELOG.md @@ -1,5 +1,712 @@ # @0xsequence/wallet +## 2.2.14 + +### Patch Changes + +- Somnia Testnet and Monad Testnet +- Updated dependencies + - @0xsequence/abi@2.2.14 + - @0xsequence/core@2.2.14 + - @0xsequence/network@2.2.14 + - @0xsequence/relayer@2.2.14 + - @0xsequence/signhub@2.2.14 + - @0xsequence/utils@2.2.14 + +## 2.2.13 + +### Patch Changes + +- Add XR1 to all networks +- Updated dependencies + - @0xsequence/abi@2.2.13 + - @0xsequence/core@2.2.13 + - @0xsequence/network@2.2.13 + - @0xsequence/relayer@2.2.13 + - @0xsequence/signhub@2.2.13 + - @0xsequence/utils@2.2.13 + +## 2.2.12 + +### Patch Changes + +- Add XR1 +- Updated dependencies + - @0xsequence/abi@2.2.12 + - @0xsequence/core@2.2.12 + - @0xsequence/network@2.2.12 + - @0xsequence/relayer@2.2.12 + - @0xsequence/signhub@2.2.12 + - @0xsequence/utils@2.2.12 + +## 2.2.11 + +### Patch Changes + +- Relayer updates +- Updated dependencies + - @0xsequence/abi@2.2.11 + - @0xsequence/core@2.2.11 + - @0xsequence/network@2.2.11 + - @0xsequence/relayer@2.2.11 + - @0xsequence/signhub@2.2.11 + - @0xsequence/utils@2.2.11 + +## 2.2.10 + +### Patch Changes + +- Etherlink support +- Updated dependencies + - @0xsequence/abi@2.2.10 + - @0xsequence/core@2.2.10 + - @0xsequence/network@2.2.10 + - @0xsequence/relayer@2.2.10 + - @0xsequence/signhub@2.2.10 + - @0xsequence/utils@2.2.10 + +## 2.2.9 + +### Patch Changes + +- Indexer gateway native token balances +- Updated dependencies + - @0xsequence/abi@2.2.9 + - @0xsequence/core@2.2.9 + - @0xsequence/network@2.2.9 + - @0xsequence/relayer@2.2.9 + - @0xsequence/signhub@2.2.9 + - @0xsequence/utils@2.2.9 + +## 2.2.8 + +### Patch Changes + +- Add Moonbeam and Moonbase Alpha +- Updated dependencies + - @0xsequence/abi@2.2.8 + - @0xsequence/core@2.2.8 + - @0xsequence/network@2.2.8 + - @0xsequence/relayer@2.2.8 + - @0xsequence/signhub@2.2.8 + - @0xsequence/utils@2.2.8 + +## 2.2.7 + +### Patch Changes + +- Update Builder package +- Updated dependencies + - @0xsequence/abi@2.2.7 + - @0xsequence/core@2.2.7 + - @0xsequence/network@2.2.7 + - @0xsequence/relayer@2.2.7 + - @0xsequence/signhub@2.2.7 + - @0xsequence/utils@2.2.7 + +## 2.2.6 + +### Patch Changes + +- Update relayer package +- Updated dependencies + - @0xsequence/abi@2.2.6 + - @0xsequence/core@2.2.6 + - @0xsequence/network@2.2.6 + - @0xsequence/relayer@2.2.6 + - @0xsequence/signhub@2.2.6 + - @0xsequence/utils@2.2.6 + +## 2.2.5 + +### Patch Changes + +- auth: fix sequence indexer gateway url +- account: immutable wallet proxy hook +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.2.5 + - @0xsequence/core@2.2.5 + - @0xsequence/network@2.2.5 + - @0xsequence/relayer@2.2.5 + - @0xsequence/signhub@2.2.5 + - @0xsequence/utils@2.2.5 + +## 2.2.4 + +### Patch Changes + +- network: update soneium mainnet block explorer url +- waas: signTypedData intent support +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.2.4 + - @0xsequence/core@2.2.4 + - @0xsequence/network@2.2.4 + - @0xsequence/relayer@2.2.4 + - @0xsequence/signhub@2.2.4 + - @0xsequence/utils@2.2.4 + +## 2.2.3 + +### Patch Changes + +- provider: updating initWallet to use connected network configs if they exist +- Updated dependencies + - @0xsequence/abi@2.2.3 + - @0xsequence/core@2.2.3 + - @0xsequence/network@2.2.3 + - @0xsequence/relayer@2.2.3 + - @0xsequence/signhub@2.2.3 + - @0xsequence/utils@2.2.3 + +## 2.2.2 + +### Patch Changes + +- pass projectAccessKey to relayer at all times +- Updated dependencies + - @0xsequence/abi@2.2.2 + - @0xsequence/core@2.2.2 + - @0xsequence/network@2.2.2 + - @0xsequence/relayer@2.2.2 + - @0xsequence/signhub@2.2.2 + - @0xsequence/utils@2.2.2 + +## 2.2.1 + +### Patch Changes + +- waas-ethers: sign typed data +- Updated dependencies + - @0xsequence/abi@2.2.1 + - @0xsequence/core@2.2.1 + - @0xsequence/network@2.2.1 + - @0xsequence/relayer@2.2.1 + - @0xsequence/signhub@2.2.1 + - @0xsequence/utils@2.2.1 + +## 2.2.0 + +### Minor Changes + +- indexer: gateway client +- @0xsequence/builder +- upgrade puppeteer to v23.10.3 + +### Patch Changes + +- Updated dependencies +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.2.0 + - @0xsequence/core@2.2.0 + - @0xsequence/network@2.2.0 + - @0xsequence/relayer@2.2.0 + - @0xsequence/signhub@2.2.0 + - @0xsequence/utils@2.2.0 + +## 2.1.8 + +### Patch Changes + +- Add Soneium Mainnet +- Updated dependencies + - @0xsequence/abi@2.1.8 + - @0xsequence/core@2.1.8 + - @0xsequence/network@2.1.8 + - @0xsequence/relayer@2.1.8 + - @0xsequence/signhub@2.1.8 + - @0xsequence/utils@2.1.8 + +## 2.1.7 + +### Patch Changes + +- guard: pass project access key to guard requests +- Updated dependencies + - @0xsequence/abi@2.1.7 + - @0xsequence/core@2.1.7 + - @0xsequence/network@2.1.7 + - @0xsequence/relayer@2.1.7 + - @0xsequence/signhub@2.1.7 + - @0xsequence/utils@2.1.7 + +## 2.1.6 + +### Patch Changes + +- Add LAOS and Telos Testnet chains +- Updated dependencies + - @0xsequence/abi@2.1.6 + - @0xsequence/core@2.1.6 + - @0xsequence/network@2.1.6 + - @0xsequence/relayer@2.1.6 + - @0xsequence/signhub@2.1.6 + - @0xsequence/utils@2.1.6 + +## 2.1.5 + +### Patch Changes + +- account: save presigned configuration with reference chain id 1 +- Updated dependencies + - @0xsequence/abi@2.1.5 + - @0xsequence/core@2.1.5 + - @0xsequence/network@2.1.5 + - @0xsequence/relayer@2.1.5 + - @0xsequence/signhub@2.1.5 + - @0xsequence/utils@2.1.5 + +## 2.1.4 + +### Patch Changes + +- provider: pass projectAccessKey into MuxMessageProvider +- Updated dependencies + - @0xsequence/abi@2.1.4 + - @0xsequence/core@2.1.4 + - @0xsequence/network@2.1.4 + - @0xsequence/relayer@2.1.4 + - @0xsequence/signhub@2.1.4 + - @0xsequence/utils@2.1.4 + +## 2.1.3 + +### Patch Changes + +- waas: time drift date fix due to strange browser quirk +- Updated dependencies + - @0xsequence/abi@2.1.3 + - @0xsequence/core@2.1.3 + - @0xsequence/network@2.1.3 + - @0xsequence/relayer@2.1.3 + - @0xsequence/signhub@2.1.3 + - @0xsequence/utils@2.1.3 + +## 2.1.2 + +### Patch Changes + +- provider: export analytics correctly +- Updated dependencies + - @0xsequence/abi@2.1.2 + - @0xsequence/core@2.1.2 + - @0xsequence/network@2.1.2 + - @0xsequence/relayer@2.1.2 + - @0xsequence/signhub@2.1.2 + - @0xsequence/utils@2.1.2 + +## 2.1.1 + +### Patch Changes + +- Add LAOS chain support +- Updated dependencies + - @0xsequence/abi@2.1.1 + - @0xsequence/core@2.1.1 + - @0xsequence/network@2.1.1 + - @0xsequence/relayer@2.1.1 + - @0xsequence/signhub@2.1.1 + - @0xsequence/utils@2.1.1 + +## 2.1.0 + +### Minor Changes + +- account: forward project access key when estimating fees and sending transactions + +### Patch Changes + +- sessions: save signatures with reference chain id +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.1.0 + - @0xsequence/core@2.1.0 + - @0xsequence/network@2.1.0 + - @0xsequence/relayer@2.1.0 + - @0xsequence/signhub@2.1.0 + - @0xsequence/utils@2.1.0 + +## 2.0.26 + +### Patch Changes + +- account: fix chain id comparison +- Updated dependencies + - @0xsequence/abi@2.0.26 + - @0xsequence/core@2.0.26 + - @0xsequence/network@2.0.26 + - @0xsequence/relayer@2.0.26 + - @0xsequence/signhub@2.0.26 + - @0xsequence/utils@2.0.26 + +## 2.0.25 + +### Patch Changes + +- skale-nebula: deploy gas limit = 10m +- Updated dependencies + - @0xsequence/abi@2.0.25 + - @0xsequence/core@2.0.25 + - @0xsequence/network@2.0.25 + - @0xsequence/relayer@2.0.25 + - @0xsequence/signhub@2.0.25 + - @0xsequence/utils@2.0.25 + +## 2.0.24 + +### Patch Changes + +- sessions: arweave: configurable gateway url +- waas: use /status to get time drift before sending any intents +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.24 + - @0xsequence/core@2.0.24 + - @0xsequence/network@2.0.24 + - @0xsequence/relayer@2.0.24 + - @0xsequence/signhub@2.0.24 + - @0xsequence/utils@2.0.24 + +## 2.0.23 + +### Patch Changes + +- Add The Root Network support +- Updated dependencies + - @0xsequence/abi@2.0.23 + - @0xsequence/core@2.0.23 + - @0xsequence/network@2.0.23 + - @0xsequence/relayer@2.0.23 + - @0xsequence/signhub@2.0.23 + - @0xsequence/utils@2.0.23 + +## 2.0.22 + +### Patch Changes + +- Add SKALE Nebula Mainnet support +- Updated dependencies + - @0xsequence/abi@2.0.22 + - @0xsequence/core@2.0.22 + - @0xsequence/network@2.0.22 + - @0xsequence/relayer@2.0.22 + - @0xsequence/signhub@2.0.22 + - @0xsequence/utils@2.0.22 + +## 2.0.21 + +### Patch Changes + +- account: add publishWitnessFor +- Updated dependencies + - @0xsequence/abi@2.0.21 + - @0xsequence/core@2.0.21 + - @0xsequence/network@2.0.21 + - @0xsequence/relayer@2.0.21 + - @0xsequence/signhub@2.0.21 + - @0xsequence/utils@2.0.21 + +## 2.0.20 + +### Patch Changes + +- upgrade deps, and improve waas session status handling +- Updated dependencies + - @0xsequence/abi@2.0.20 + - @0xsequence/core@2.0.20 + - @0xsequence/network@2.0.20 + - @0xsequence/relayer@2.0.20 + - @0xsequence/signhub@2.0.20 + - @0xsequence/utils@2.0.20 + +## 2.0.19 + +### Patch Changes + +- Add Immutable zkEVM support +- Updated dependencies + - @0xsequence/abi@2.0.19 + - @0xsequence/core@2.0.19 + - @0xsequence/network@2.0.19 + - @0xsequence/relayer@2.0.19 + - @0xsequence/signhub@2.0.19 + - @0xsequence/utils@2.0.19 + +## 2.0.18 + +### Patch Changes + +- waas: new contractCall transaction type +- sessions: add arweave owner +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.18 + - @0xsequence/core@2.0.18 + - @0xsequence/network@2.0.18 + - @0xsequence/relayer@2.0.18 + - @0xsequence/signhub@2.0.18 + - @0xsequence/utils@2.0.18 + +## 2.0.17 + +### Patch Changes + +- update waas auth to clear session before signIn +- Updated dependencies + - @0xsequence/abi@2.0.17 + - @0xsequence/core@2.0.17 + - @0xsequence/network@2.0.17 + - @0xsequence/relayer@2.0.17 + - @0xsequence/signhub@2.0.17 + - @0xsequence/utils@2.0.17 + +## 2.0.16 + +### Patch Changes + +- Removed Astar chains +- Updated dependencies + - @0xsequence/abi@2.0.16 + - @0xsequence/core@2.0.16 + - @0xsequence/network@2.0.16 + - @0xsequence/relayer@2.0.16 + - @0xsequence/signhub@2.0.16 + - @0xsequence/utils@2.0.16 + +## 2.0.15 + +### Patch Changes + +- indexer: update bindings with token balance additions +- Updated dependencies + - @0xsequence/abi@2.0.15 + - @0xsequence/core@2.0.15 + - @0xsequence/network@2.0.15 + - @0xsequence/relayer@2.0.15 + - @0xsequence/signhub@2.0.15 + - @0xsequence/utils@2.0.15 + +## 2.0.14 + +### Patch Changes + +- sessions: arweave config reader +- network: add b3 and apechain mainnet configs +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.14 + - @0xsequence/core@2.0.14 + - @0xsequence/network@2.0.14 + - @0xsequence/relayer@2.0.14 + - @0xsequence/signhub@2.0.14 + - @0xsequence/utils@2.0.14 + +## 2.0.13 + +### Patch Changes + +- network: toy-testnet +- Updated dependencies + - @0xsequence/abi@2.0.13 + - @0xsequence/core@2.0.13 + - @0xsequence/network@2.0.13 + - @0xsequence/relayer@2.0.13 + - @0xsequence/signhub@2.0.13 + - @0xsequence/utils@2.0.13 + +## 2.0.12 + +### Patch Changes + +- api: update bindings +- Updated dependencies + - @0xsequence/abi@2.0.12 + - @0xsequence/core@2.0.12 + - @0xsequence/network@2.0.12 + - @0xsequence/relayer@2.0.12 + - @0xsequence/signhub@2.0.12 + - @0xsequence/utils@2.0.12 + +## 2.0.11 + +### Patch Changes + +- waas: intents test fix +- api: update bindings +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.11 + - @0xsequence/core@2.0.11 + - @0xsequence/network@2.0.11 + - @0xsequence/relayer@2.0.11 + - @0xsequence/signhub@2.0.11 + - @0xsequence/utils@2.0.11 + +## 2.0.10 + +### Patch Changes + +- network: soneium minato testnet +- Updated dependencies + - @0xsequence/abi@2.0.10 + - @0xsequence/core@2.0.10 + - @0xsequence/network@2.0.10 + - @0xsequence/relayer@2.0.10 + - @0xsequence/signhub@2.0.10 + - @0xsequence/utils@2.0.10 + +## 2.0.9 + +### Patch Changes + +- network: fix SKALE network name +- Updated dependencies + - @0xsequence/abi@2.0.9 + - @0xsequence/core@2.0.9 + - @0xsequence/network@2.0.9 + - @0xsequence/relayer@2.0.9 + - @0xsequence/signhub@2.0.9 + - @0xsequence/utils@2.0.9 + +## 2.0.8 + +### Patch Changes + +- metadata: update bindings +- Updated dependencies + - @0xsequence/abi@2.0.8 + - @0xsequence/core@2.0.8 + - @0xsequence/network@2.0.8 + - @0xsequence/relayer@2.0.8 + - @0xsequence/signhub@2.0.8 + - @0xsequence/utils@2.0.8 + +## 2.0.7 + +### Patch Changes + +- wallet request handler fix +- Updated dependencies + - @0xsequence/abi@2.0.7 + - @0xsequence/core@2.0.7 + - @0xsequence/network@2.0.7 + - @0xsequence/relayer@2.0.7 + - @0xsequence/signhub@2.0.7 + - @0xsequence/utils@2.0.7 + +## 2.0.6 + +### Patch Changes + +- network: matic -> pol +- Updated dependencies + - @0xsequence/abi@2.0.6 + - @0xsequence/core@2.0.6 + - @0xsequence/network@2.0.6 + - @0xsequence/relayer@2.0.6 + - @0xsequence/signhub@2.0.6 + - @0xsequence/utils@2.0.6 + +## 2.0.5 + +### Patch Changes + +- provider: update databeat to 0.9.2 +- Updated dependencies + - @0xsequence/abi@2.0.5 + - @0xsequence/core@2.0.5 + - @0xsequence/network@2.0.5 + - @0xsequence/relayer@2.0.5 + - @0xsequence/signhub@2.0.5 + - @0xsequence/utils@2.0.5 + +## 2.0.4 + +### Patch Changes + +- network: add skale-nebula-testnet +- Updated dependencies + - @0xsequence/abi@2.0.4 + - @0xsequence/core@2.0.4 + - @0xsequence/network@2.0.4 + - @0xsequence/relayer@2.0.4 + - @0xsequence/signhub@2.0.4 + - @0xsequence/utils@2.0.4 + +## 2.0.3 + +### Patch Changes + +- waas: check session status in SequenceWaaS.isSignedIn() +- Updated dependencies + - @0xsequence/abi@2.0.3 + - @0xsequence/core@2.0.3 + - @0xsequence/network@2.0.3 + - @0xsequence/relayer@2.0.3 + - @0xsequence/signhub@2.0.3 + - @0xsequence/utils@2.0.3 + +## 2.0.2 + +### Patch Changes + +- sessions: property convert serialized bignumber hex value to bigint +- Updated dependencies + - @0xsequence/abi@2.0.2 + - @0xsequence/core@2.0.2 + - @0xsequence/network@2.0.2 + - @0xsequence/relayer@2.0.2 + - @0xsequence/signhub@2.0.2 + - @0xsequence/utils@2.0.2 + +## 2.0.1 + +### Patch Changes + +- waas: http signature check for authenticator requests +- provider: unwrap legacy json rpc responses +- use json replacer and reviver for bigints +- Updated dependencies +- Updated dependencies +- Updated dependencies + - @0xsequence/abi@2.0.1 + - @0xsequence/core@2.0.1 + - @0xsequence/network@2.0.1 + - @0xsequence/relayer@2.0.1 + - @0xsequence/signhub@2.0.1 + - @0xsequence/utils@2.0.1 + +## 2.0.0 + +### Major Changes + +- ethers v6 + +### Patch Changes + +- Updated dependencies + - @0xsequence/abi@2.0.0 + - @0xsequence/core@2.0.0 + - @0xsequence/network@2.0.0 + - @0xsequence/relayer@2.0.0 + - @0xsequence/signhub@2.0.0 + - @0xsequence/utils@2.0.0 + +## 1.10.15 + +### Patch Changes + +- utils: extractProjectIdFromAccessKey +- Updated dependencies + - @0xsequence/abi@1.10.15 + - @0xsequence/core@1.10.15 + - @0xsequence/network@1.10.15 + - @0xsequence/relayer@1.10.15 + - @0xsequence/signhub@1.10.15 + - @0xsequence/utils@1.10.15 + ## 1.10.14 ### Patch Changes diff --git a/packages/wallet/package.json b/packages/wallet/package.json index 998d8307b..9443f3b34 100644 --- a/packages/wallet/package.json +++ b/packages/wallet/package.json @@ -1,6 +1,6 @@ { "name": "@0xsequence/wallet", - "version": "1.10.14", + "version": "2.2.14", "description": "wallet sub-package for Sequence", "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/wallet", "source": "src/index.ts", @@ -16,6 +16,9 @@ "start:hardhat2": "hardhat node --hostname 0.0.0.0 --port 7047 --config ./hardhat2.config.js", "typecheck": "tsc --noEmit" }, + "peerDependencies": { + "ethers": ">=6" + }, "dependencies": { "@0xsequence/abi": "workspace:*", "@0xsequence/core": "workspace:*", @@ -24,15 +27,12 @@ "@0xsequence/relayer": "workspace:*", "@0xsequence/utils": "workspace:*" }, - "peerDependencies": { - "ethers": ">=5.5 < 6" - }, "devDependencies": { - "@0xsequence/ethauth": "^0.8.1", + "@0xsequence/ethauth": "^1.0.0", "@0xsequence/tests": "workspace:*", - "@0xsequence/wallet-contracts": "^2.0.0", + "@0xsequence/wallet-contracts": "^3.0.1", "@istanbuljs/nyc-config-typescript": "^1.0.1", - "ethers": "^5.7.2", + "ethers": "6.13.4", "web3": "^1.8.1" }, "files": [ diff --git a/packages/wallet/src/orchestrator/wrapper.ts b/packages/wallet/src/orchestrator/wrapper.ts index 04b306122..db4cdfa33 100644 --- a/packages/wallet/src/orchestrator/wrapper.ts +++ b/packages/wallet/src/orchestrator/wrapper.ts @@ -28,7 +28,7 @@ export class SequenceOrchestratorWrapper implements signers.SapientSigner { return this.wallet.decorateTransactions(bundle) } - sign(message: ethers.utils.BytesLike, metadata: object): Promise { + sign(message: ethers.BytesLike, metadata: object): Promise { if (!commons.isWalletSignRequestMetadata(metadata)) { throw new Error('SequenceOrchestratorWrapper only supports nested Sequence signatures') } @@ -40,7 +40,7 @@ export class SequenceOrchestratorWrapper implements signers.SapientSigner { notifyStatusChange(_i: string, _s: Status, _m: object): void {} - suffix(): ethers.utils.BytesLike { - return [3] + suffix(): ethers.BytesLike { + return new Uint8Array([3]) } } diff --git a/packages/wallet/src/signer.ts b/packages/wallet/src/signer.ts index 5d8ef9b0b..c30aeee03 100644 --- a/packages/wallet/src/signer.ts +++ b/packages/wallet/src/signer.ts @@ -1,16 +1,15 @@ -import { BytesLike, Signer as AbstractSigner, providers, TypedDataDomain, TypedDataField, ethers } from 'ethers' +import { ethers } from 'ethers' import { NetworkConfig, ChainIdLike } from '@0xsequence/network' import { FeeQuote, Relayer } from '@0xsequence/relayer' -import { Deferrable } from '@0xsequence/utils' import { commons } from '@0xsequence/core' // TODO: Move to account ? -export abstract class Signer extends AbstractSigner { +export abstract class Signer extends ethers.AbstractSigner { static isSequenceSigner(cand: any): cand is Signer { return isSequenceSigner(cand) } - abstract getProvider(chainId?: number): Promise + abstract getProvider(chainId?: number): Promise abstract getRelayer(chainId?: number): Promise // abstract getWalletContext(): Promise @@ -24,21 +23,26 @@ export abstract class Signer extends AbstractSigner { abstract getSigners(): Promise // signMessage ..... - abstract signMessage(message: BytesLike, chainId?: ChainIdLike, allSigners?: boolean, isDigest?: boolean): Promise + abstract signMessage( + message: ethers.BytesLike, + chainId?: ChainIdLike, + allSigners?: boolean, + isDigest?: boolean + ): Promise // signTypedData .. abstract signTypedData( - domain: TypedDataDomain, - types: Record>, + domain: ethers.TypedDataDomain, + types: Record>, message: Record, - chainId: ChainIdLike, + chainId?: ChainIdLike, allSigners?: boolean ): Promise // sendTransaction takes an unsigned transaction, or list of unsigned transactions, and then has it signed by // the signer, and finally sends it to the relayer for submission to an Ethereum network. abstract sendTransaction( - transaction: Deferrable, + transaction: commons.transaction.Transactionish, chainId?: ChainIdLike, allSigners?: boolean, quote?: FeeQuote @@ -47,7 +51,7 @@ export abstract class Signer extends AbstractSigner { // sendTransactionBatch provides the ability to send an array/batch of transactions as a single native on-chain transaction. // This method works identically to sendTransaction but offers a different syntax for convience, readability and type clarity. abstract sendTransactionBatch( - transactions: Deferrable, + transactions: ethers.TransactionRequest[] | commons.transaction.Transaction[], chainId?: ChainIdLike, allSigners?: boolean, quote?: FeeQuote @@ -57,7 +61,7 @@ export abstract class Signer extends AbstractSigner { // is like calling just sendTransaction(..) above. Also note that sendSignedTransactions is identical // to calling getRelayer().relay(signedTxs), but included in this interface for convenience. abstract signTransactions( - txs: Deferrable, + txs: commons.transaction.Transactionish, chainId?: ChainIdLike, allSigners?: boolean ): Promise @@ -85,7 +89,7 @@ export abstract class Signer extends AbstractSigner { export type SignedTransactionsCallback = (signedTxs: commons.transaction.SignedTransactionBundle, metaTxnHash: string) => void -export function isSequenceSigner(signer: AbstractSigner): signer is Signer { +export function isSequenceSigner(signer: any): signer is Signer { const cand = signer as Signer return cand && cand.updateConfig !== undefined && cand.publishConfig !== undefined && cand.getWalletConfig !== undefined } diff --git a/packages/wallet/src/utils.ts b/packages/wallet/src/utils.ts index 52a855ed1..9f4abf784 100644 --- a/packages/wallet/src/utils.ts +++ b/packages/wallet/src/utils.ts @@ -1,20 +1,15 @@ -import { ethers, utils } from 'ethers' +import { ethers } from 'ethers' -export async function resolveArrayProperties( - object: Readonly> | Readonly>[] -): Promise { +export async function resolveArrayProperties(object: Readonly | Readonly[]): Promise { if (Array.isArray(object)) { // T must include array type - return Promise.all(object.map(o => utils.resolveProperties(o))) as any + return Promise.all(object.map(o => ethers.resolveProperties(o))) as any } - return utils.resolveProperties(object) + return ethers.resolveProperties(object) } -export async function findLatestLog( - provider: ethers.providers.Provider, - filter: ethers.providers.Filter -): Promise { +export async function findLatestLog(provider: ethers.Provider, filter: ethers.Filter): Promise { const toBlock = filter.toBlock === 'latest' ? await provider.getBlockNumber() : (filter.toBlock as number) const fromBlock = filter.fromBlock as number diff --git a/packages/wallet/src/wallet.ts b/packages/wallet/src/wallet.ts index 57c7c33bd..554ad292a 100644 --- a/packages/wallet/src/wallet.ts +++ b/packages/wallet/src/wallet.ts @@ -1,7 +1,8 @@ import { ethers } from 'ethers' import { commons, v1, v2 } from '@0xsequence/core' +import { ChainId } from '@0xsequence/network' import { SignatureOrchestrator, SignerState, Status } from '@0xsequence/signhub' -import { Deferrable, subDigestOf } from '@0xsequence/utils' +import { encodeTypedDataDigest, subDigestOf } from '@0xsequence/utils' import { FeeQuote, Relayer } from '@0xsequence/relayer' import { walletContracts } from '@0xsequence/abi' @@ -27,7 +28,7 @@ export type WalletOptions< orchestrator: SignatureOrchestrator reader?: commons.reader.Reader - provider?: ethers.providers.Provider + provider?: ethers.Provider relayer?: Relayer } @@ -37,8 +38,8 @@ const statusToSignatureParts = (status: Status) => { for (const signer of Object.keys(status.signers)) { const value = status.signers[signer] if (value.state === SignerState.SIGNED) { - const suffix = ethers.utils.arrayify(value.suffix) - const suffixed = ethers.utils.solidityPack(['bytes', 'bytes'], [value.signature, suffix]) + const suffix = ethers.getBytes(value.suffix) + const suffixed = ethers.solidityPacked(['bytes', 'bytes'], [value.signature, suffix]) parts.set(signer, { signature: suffixed, isDynamic: suffix.length !== 1 || suffix[0] !== 2 }) } @@ -61,13 +62,12 @@ export class Wallet< Y extends commons.config.Config = commons.config.Config, T extends commons.signature.Signature = commons.signature.Signature, Z extends commons.signature.UnrecoveredSignature = commons.signature.UnrecoveredSignature -> extends ethers.Signer { +> extends ethers.AbstractSigner { public context: commons.context.WalletContext public config: Y public address: string - public chainId: ethers.BigNumberish + public chainId: bigint - public provider?: ethers.providers.Provider public relayer?: Relayer public coders: { @@ -79,19 +79,20 @@ export class Wallet< private _reader?: commons.reader.Reader constructor(options: WalletOptions) { - if (ethers.constants.Zero.eq(options.chainId) && !options.coders.signature.supportsNoChainId) { + const chainId = BigInt(options.chainId) + + if (chainId === 0n && !options.coders.signature.supportsNoChainId) { throw new Error(`Sequence version ${options.config.version} doesn't support chainId 0`) } - super() + super(options.provider ?? null) this.context = options.context this.config = options.config this.orchestrator = options.orchestrator this.coders = options.coders this.address = options.address - this.chainId = options.chainId - this.provider = options.provider + this.chainId = chainId this.relayer = options.relayer this._reader = options.reader @@ -181,7 +182,14 @@ export class Wallet< throw new Error(`First address of config ${imageHash} doesn't match wallet address ${this.address}`) } - const bundle = Wallet.buildDeployTransaction(this.context, imageHash) + let gasLimit: bigint | undefined + switch (this.chainId) { + case BigInt(ChainId.SKALE_NEBULA): + gasLimit = 10000000n + break + } + + const bundle = Wallet.buildDeployTransaction(this.context, imageHash, gasLimit) if (metadata?.includeChildren) { const childBundle = await this.orchestrator.buildDeployTransaction(metadata) if (childBundle) { @@ -192,7 +200,7 @@ export class Wallet< return bundle } - async deploy(metadata?: commons.WalletDeployMetadata): Promise { + async deploy(metadata?: commons.WalletDeployMetadata): Promise { const deployTx = await this.buildDeployTransaction(metadata) if (deployTx === undefined) { // Already deployed @@ -203,7 +211,7 @@ export class Wallet< ...deployTx, chainId: this.chainId, intent: { - id: ethers.utils.hexlify(ethers.utils.randomBytes(32)), + id: ethers.hexlify(ethers.randomBytes(32)), wallet: this.address } }) @@ -211,17 +219,18 @@ export class Wallet< static buildDeployTransaction( context: commons.context.WalletContext, - imageHash: string + imageHash: string, + gasLimit: ethers.BigNumberish = 100000n ): commons.transaction.TransactionBundle { - const factoryInterface = new ethers.utils.Interface(walletContracts.factory.abi) + const factoryInterface = new ethers.Interface(walletContracts.factory.abi) return { entrypoint: context.guestModule, transactions: [ { to: context.factory, - data: factoryInterface.encodeFunctionData(factoryInterface.getFunction('deploy'), [context.mainModule, imageHash]), - gasLimit: 100000, + data: factoryInterface.encodeFunctionData(factoryInterface.getFunction('deploy')!, [context.mainModule, imageHash]), + gasLimit, delegateCall: false, revertOnError: true, value: 0 @@ -240,13 +249,13 @@ export class Wallet< return this.coders.config.update.buildTransaction(this.address, config, this.context) } - async getNonce(space: ethers.BigNumberish = 0): Promise { + async getNonce(space: ethers.BigNumberish = 0): Promise { const nonce = await this.reader().nonce(this.address, space) if (nonce === undefined) throw new Error('Unable to determine nonce') - return nonce + return Number(nonce) } - async signDigest(digest: ethers.utils.BytesLike, metadata?: object): Promise { + async signDigest(digest: ethers.BytesLike, metadata?: object): Promise { // The subdigest may be statically defined on the configuration // in that case we just encode the proof, no need to sign anything const subdigest = subDigestOf(this.address, this.chainId, digest) @@ -267,7 +276,7 @@ export class Wallet< // We ask the orchestrator to sign the digest, as soon as we have enough signature parts // to reach the threshold we returns true, that means the orchestrator will stop asking // and we can encode the final signature - const subdigestBytes = ethers.utils.arrayify(subdigest) + const subdigestBytes = ethers.getBytes(subdigest) const signature = await this.orchestrator.signMessage({ candidates: this.coders.config.signersOf(this.config).map(s => s.address), message: subdigestBytes, @@ -287,7 +296,17 @@ export class Wallet< } signMessage(message: ethers.BytesLike): Promise { - return this.signDigest(ethers.utils.keccak256(message), { message }) + return this.signDigest(ethers.keccak256(message), { message }) + } + + // XXX This method is not implemented in the original code but required by the AbstractSigner interface + signTypedData( + domain: ethers.TypedDataDomain, + types: Record, + value: Record + ): Promise { + const digest = encodeTypedDataDigest({ domain, types, message: value }) + return this.signDigest(digest) } signTransactionBundle(bundle: commons.transaction.TransactionBundle): Promise { @@ -305,7 +324,7 @@ export class Wallet< if (nonce && (nonce as any).space !== undefined) { // specified nonce "space" - spaceValue = ethers.BigNumber.from((nonce as any).space) + spaceValue = BigInt((nonce as any).space) } else if (nonce === undefined) { // default is random, aka parallel return this.randomNonce() @@ -324,13 +343,13 @@ export class Wallet< // Generate nonce with random space randomNonce(): ethers.BigNumberish { - const randomNonceSpace = ethers.BigNumber.from(ethers.utils.hexlify(ethers.utils.randomBytes(12))) + const randomNonceSpace = BigInt(ethers.hexlify(ethers.randomBytes(12))) const randomNonce = commons.transaction.encodeNonce(randomNonceSpace, 0) return randomNonce } async signTransactions( - txs: Deferrable, + txs: commons.transaction.Transactionish, nonce?: ethers.BigNumberish | { space: ethers.BigNumberish } | { serial: boolean }, metadata?: object ): Promise { @@ -377,7 +396,7 @@ export class Wallet< async sendSignedTransaction( signedBundle: commons.transaction.IntendedTransactionBundle, quote?: FeeQuote - ): Promise { + ): Promise { if (!this.relayer) throw new Error('Wallet sendTransaction requires a relayer') return this.relayer.relay(signedBundle, quote) } @@ -389,13 +408,13 @@ export class Wallet< // By default, nonces are generated randomly and assigned so transactioned can be executed // in parallel. However, if you'd like to execute serially, pass { serial: true } as an option. async sendTransaction( - txs: Deferrable, + txs: commons.transaction.Transactionish, options?: { quote?: FeeQuote nonce?: ethers.BigNumberish serial?: boolean } - ): Promise { + ): Promise { let nonce: ethers.BigNumberish | { serial: boolean } if (options?.nonce !== undefined) { // specific nonce is used @@ -413,7 +432,7 @@ export class Wallet< return this.sendSignedTransaction(decorated, options?.quote) } - async fillGasLimits(txs: Deferrable): Promise { + async fillGasLimits(txs: commons.transaction.Transactionish): Promise { const transaction = await resolveArrayProperties(txs) const transactions = commons.transaction.fromTransactionish(this.address, transaction) const relayer = this.relayer @@ -421,18 +440,31 @@ export class Wallet< const simulations = await relayer.simulate(this.address, ...transactions) return transactions.map((tx, i) => { - const gasLimit = tx.gasLimit ? ethers.BigNumber.from(tx.gasLimit).toNumber() : simulations[i].gasLimit + const gasLimit = tx.gasLimit ? Number(tx.gasLimit) : simulations[i].gasLimit return { ...tx, ...simulations[i], gasLimit } }) } - connect(provider: ethers.providers.Provider, relayer?: Relayer): Wallet { - this.provider = provider - this.relayer = relayer - return this + connect(provider: ethers.Provider, relayer?: Relayer): Wallet { + return new Wallet({ + // Sequence version configurator + coders: this.coders, + + context: this.context, + config: this.config, + + chainId: this.chainId, + address: this.address, + + orchestrator: this.orchestrator, + reader: this._reader, + + provider, + relayer: relayer ?? this.relayer + }) } - signTransaction(transaction: ethers.utils.Deferrable): Promise { + signTransaction(transaction: ethers.TransactionRequest): Promise { throw new Error('Method not implemented.') } } diff --git a/packages/wallet/tests/utils/deploy-wallet-context.ts b/packages/wallet/tests/utils/deploy-wallet-context.ts index 97c5374fc..d09ee6160 100644 --- a/packages/wallet/tests/utils/deploy-wallet-context.ts +++ b/packages/wallet/tests/utils/deploy-wallet-context.ts @@ -1,13 +1,6 @@ import { ethers } from 'ethers' -import { - Factory, - GuestModule, - MainModule, - MainModuleUpgradable, - SequenceUtils, - RequireFreshSigner -} from '@0xsequence/wallet-contracts' +import { Factory, GuestModule, MainModule, MainModuleUpgradable, SequenceUtils } from '@0xsequence/wallet-contracts' const FactoryArtifact = require('@0xsequence/wallet-contracts/artifacts/contracts/Factory.sol/Factory.json') const GuestModuleArtifact = require('@0xsequence/wallet-contracts/artifacts/contracts/modules/GuestModule.sol/GuestModule.json') @@ -18,7 +11,7 @@ const RequireFreshSignerArtifact = require('@0xsequence/wallet-contracts/artifac export async function deployWalletContext( signer: ethers.Signer -): Promise<[Factory, MainModule, MainModuleUpgradable, GuestModule, SequenceUtils, RequireFreshSigner]> { +): Promise<[Factory, MainModule, MainModuleUpgradable, GuestModule, SequenceUtils, ethers.BaseContract]> { const factory = (await new ethers.ContractFactory( FactoryArtifact.abi, FactoryArtifact.bytecode, @@ -47,11 +40,11 @@ export async function deployWalletContext( signer ).deploy(factory.address, mainModule.address)) as unknown as SequenceUtils - const requireFreshSigner = (await new ethers.ContractFactory( + const requireFreshSigner = await new ethers.ContractFactory( RequireFreshSignerArtifact.abi, RequireFreshSignerArtifact.bytecode, signer - ).deploy(sequenceUtils.address)) as unknown as RequireFreshSigner + ).deploy(sequenceUtils.address) return [factory, mainModule, mainModuleUpgradable, guestModule, sequenceUtils, requireFreshSigner] } diff --git a/packages/wallet/tests/utils/index.ts b/packages/wallet/tests/utils/index.ts index 6e42022cf..f2d264926 100644 --- a/packages/wallet/tests/utils/index.ts +++ b/packages/wallet/tests/utils/index.ts @@ -1,5 +1,5 @@ import { ethers } from 'ethers' export async function encodeData(contract: ethers.Contract, method: string, ...args: any): Promise { - return (await contract.populateTransaction[method](...args)).data! + return (await contract[method].populateTransaction(...args)).data! } diff --git a/packages/wallet/tests/wallet.spec.ts b/packages/wallet/tests/wallet.spec.ts index 3c77c3a53..99b571799 100644 --- a/packages/wallet/tests/wallet.spec.ts +++ b/packages/wallet/tests/wallet.spec.ts @@ -8,6 +8,8 @@ import { ethers } from 'ethers' import { SequenceOrchestratorWrapper, Wallet } from '../src/index' import { Orchestrator, SignatureOrchestrator, signers as hubsigners } from '@0xsequence/signhub' import { LocalRelayer } from '@0xsequence/relayer' +import { parseEther } from '@0xsequence/utils' +import { JsonRpcHandler } from '@0xsequence/network' const { expect } = chai @@ -17,30 +19,33 @@ type Coders = { } describe('Wallet (primitive)', () => { - let provider: ethers.providers.JsonRpcProvider + let provider: ethers.BrowserProvider let signers: ethers.Signer[] let contexts: Awaited> let relayer: LocalRelayer before(async () => { - provider = new ethers.providers.Web3Provider(hardhat.network.provider as any) - signers = new Array(8).fill(0).map((_, i) => provider.getSigner(i)) + // const rpc = new ethers.JsonRpcProvider('http://127.0.0.1:8545') + // provider = new ethers.BrowserProvider(new JsonRpcHandler(rpc)) + provider = new ethers.BrowserProvider(new JsonRpcHandler(hardhat.network.provider), undefined, { cacheTimeout: -1 }) + signers = await Promise.all(new Array(8).fill(0).map((_, i) => provider.getSigner(i))) contexts = await context.deploySequenceContexts(signers[0]) relayer = new LocalRelayer(signers[0]) }) - ;( - [ - { - version: 1, - coders: { signature: v1.signature.SignatureCoder, config: v1.config.ConfigCoder } - }, - { - version: 2, - coders: { signature: v2.signature.SignatureCoder, config: v2.config.ConfigCoder } - } - ] as { version: number; coders: Coders }[] - ).map(({ version, coders }) => { + + const config: { version: keyof typeof contexts; coders: Coders }[] = [ + { + version: 1, + coders: { signature: v1.signature.SignatureCoder, config: v1.config.ConfigCoder } + }, + { + version: 2, + coders: { signature: v2.signature.SignatureCoder, config: v2.config.ConfigCoder } + } + ] + + config.map(({ version, coders }) => { describe(`Using v${version} version`, () => { it('Should deploy a new wallet', async () => { const signer = ethers.Wallet.createRandom() @@ -51,12 +56,14 @@ describe('Wallet (primitive)', () => { signers: [{ address: signer.address, weight: 1 }] }) + const network = await provider.getNetwork() + const wallet = Wallet.newWallet({ coders: coders, context: contexts[version], config, orchestrator: new Orchestrator([new hubsigners.SignerWrapper(signer)]), - chainId: provider.network.chainId, + chainId: network.chainId, provider, relayer }) @@ -67,6 +74,7 @@ describe('Wallet (primitive)', () => { }) it('Should deploy children', async () => { + const network = await provider.getNetwork() const nestedSigner = ethers.Wallet.createRandom() const nestedConfig = coders.config.fromSimple({ threshold: 1, @@ -79,7 +87,7 @@ describe('Wallet (primitive)', () => { context: contexts[version], config: nestedConfig, orchestrator: nestedOrchestrator, - chainId: provider.network.chainId, + chainId: network.chainId, provider, relayer }) @@ -94,7 +102,7 @@ describe('Wallet (primitive)', () => { context: contexts[version], config, orchestrator, - chainId: provider.network.chainId, + chainId: network.chainId, provider, relayer }) @@ -107,13 +115,13 @@ describe('Wallet (primitive)', () => { }) describe('Nonce selection', async () => { - let signer: ethers.Wallet + let signer: ethers.HDNodeWallet let wallet: Wallet - let getNonce: (response: ethers.providers.TransactionResponse) => { space: ethers.BigNumber; nonce: ethers.BigNumber } + let getNonce: (response: ethers.TransactionResponse) => { space: bigint; nonce: bigint } before(async () => { - const mainModule = new ethers.utils.Interface(walletContracts.mainModule.abi) + const mainModule = new ethers.Interface(walletContracts.mainModule.abi) getNonce = ({ data }) => { const [_, encoded] = mainModule.decodeFunctionData('execute', data) @@ -123,6 +131,8 @@ describe('Wallet (primitive)', () => { signer = ethers.Wallet.createRandom() + const network = await provider.getNetwork() + wallet = Wallet.newWallet({ coders, context: contexts[version], @@ -131,15 +141,15 @@ describe('Wallet (primitive)', () => { checkpoint: 0, signers: [{ weight: 1, address: signer.address }] }), - chainId: provider.network.chainId, + chainId: network.chainId, orchestrator: new Orchestrator([signer]), provider, relayer }) - await wallet.deploy({ includeChildren: true, ignoreDeployed: true }) + await wallet.deploy({ includeChildren: true, ignoreDeployed: true }).then(tx => tx!.wait()) - await (await signers[0].sendTransaction({ to: wallet.address, value: ethers.utils.parseEther('1') })).wait() + await signers[0].sendTransaction({ to: wallet.address, value: parseEther('1') }).then(tx => tx.wait()) }) it('Should use explicitly set nonces', async () => { @@ -150,8 +160,8 @@ describe('Wallet (primitive)', () => { let { space, nonce } = getNonce(response) - expect(space.eq(6492)).to.be.true - expect(nonce.eq(0)).to.be.true + expect(space).to.equal(6492n) + expect(nonce).to.equal(0n) await response.wait() @@ -164,8 +174,10 @@ describe('Wallet (primitive)', () => { space = encoded.space nonce = encoded.nonce - expect(space.eq(6492)).to.be.true - expect(nonce.eq(1)).to.be.true + await response.wait() + + expect(space).to.equal(6492n) + expect(nonce).to.equal(1n) }) it('Should select random nonces by default', async () => { @@ -173,8 +185,8 @@ describe('Wallet (primitive)', () => { const { space: firstSpace, nonce: firstNonce } = getNonce(response) - expect(firstSpace.eq(0)).to.be.false - expect(firstNonce.eq(0)).to.be.true + expect(firstSpace).to.not.equal(0n) + expect(firstNonce).to.equal(0n) // not necessary, parallel execution is ok: // await response.wait() @@ -183,10 +195,10 @@ describe('Wallet (primitive)', () => { const { space: secondSpace, nonce: secondNonce } = getNonce(response) - expect(secondSpace.eq(0)).to.be.false - expect(secondNonce.eq(0)).to.be.true + expect(secondSpace).to.not.equal(0n) + expect(secondNonce).to.equal(0n) - expect(secondSpace.eq(firstSpace)).to.be.false + expect(secondSpace).to.not.equal(firstSpace) }) it('Should respect the serial option', async () => { @@ -194,8 +206,8 @@ describe('Wallet (primitive)', () => { let { space, nonce } = getNonce(response) - expect(space.eq(0)).to.be.true - expect(nonce.eq(0)).to.be.true + expect(space).to.equal(0n) + expect(nonce).to.equal(0n) await response.wait() @@ -205,8 +217,10 @@ describe('Wallet (primitive)', () => { space = encoded.space nonce = encoded.nonce - expect(space.eq(0)).to.be.true - expect(nonce.eq(1)).to.be.true + await response.wait() + + expect(space).to.equal(0n) + expect(nonce).to.equal(1n) }) }) @@ -302,6 +316,8 @@ describe('Wallet (primitive)', () => { { name: '1/1 signer (nested)', signers: async () => { + const network = await provider.getNetwork() + const nestedSigner = ethers.Wallet.createRandom() const nestedConfig = coders.config.fromSimple({ @@ -316,7 +332,7 @@ describe('Wallet (primitive)', () => { context: contexts[version], config: nestedConfig, orchestrator: nestedOrchestrator, - chainId: provider.network.chainId, + chainId: network.chainId, provider, relayer }) @@ -338,6 +354,7 @@ describe('Wallet (primitive)', () => { { name: '1/1 signer (undeployed nested)', signers: async () => { + const network = await provider.getNetwork() const nestedSigner = ethers.Wallet.createRandom() const nestedConfig = coders.config.fromSimple({ @@ -352,7 +369,7 @@ describe('Wallet (primitive)', () => { context: contexts[version], config: nestedConfig, orchestrator: nestedOrchestrator, - chainId: provider.network.chainId, + chainId: network.chainId, provider, relayer }) @@ -384,12 +401,13 @@ describe('Wallet (primitive)', () => { // Skip this as we cannot validate a message with an undeployed nested wallet if (name !== '1/1 signer (undeployed nested)') { it('Should sign and validate a message', async () => { + const network = await provider.getNetwork() const wallet = Wallet.newWallet({ coders: coders, context: contexts[version], config, orchestrator, - chainId: provider.network.chainId, + chainId: network.chainId, provider, relayer }) @@ -397,12 +415,10 @@ describe('Wallet (primitive)', () => { await wallet.deploy() expect(await wallet.reader().isDeployed(wallet.address)).to.be.true - const message = ethers.utils.toUtf8Bytes( - `This is a random message: ${ethers.utils.hexlify(ethers.utils.randomBytes(96))}` - ) + const message = ethers.toUtf8Bytes(`This is a random message: ${ethers.hexlify(ethers.randomBytes(96))}`) const signature = await wallet.signMessage(message) - const digest = ethers.utils.keccak256(message) + const digest = ethers.keccak256(message) expect(await wallet.reader().isValidSignature(wallet.address, digest, signature)).to.be.true }) @@ -430,12 +446,14 @@ describe('Wallet (primitive)', () => { let wallet: Wallet beforeEach(async () => { + const network = await provider.getNetwork() + wallet = Wallet.newWallet({ coders: coders, context: contexts[version], config, orchestrator, - chainId: provider.network.chainId, + chainId: network.chainId, provider, relayer }) @@ -444,15 +462,17 @@ describe('Wallet (primitive)', () => { }) it('Should send an empty list of transactions', async () => { - await wallet.sendTransaction([]) + await wallet.sendTransaction([]).then(tx => tx.wait()) }) it('Should send a transaction with an empty call', async () => { - await wallet.sendTransaction([ - { - to: ethers.Wallet.createRandom().address - } - ]) + await wallet + .sendTransaction([ + { + to: ethers.Wallet.createRandom().address + } + ]) + .then(tx => tx.wait()) }) it('Should build and execute a wallet update transaction', async () => { @@ -491,98 +511,103 @@ describe('Wallet (primitive)', () => { const prevImplentation = await wallet.reader().implementation(wallet.address) - await wallet.sendTransaction(updateTx.transactions) + await wallet.sendTransaction(updateTx.transactions).then(tx => tx.wait()) expect(await wallet.reader().imageHash(wallet.address)).to.equal(coders.config.imageHashOf(newConfig)) expect(await wallet.reader().implementation(wallet.address)).to.not.equal(prevImplentation) }) describe('parallel transactions', async () => { - let testAccount: ethers.providers.JsonRpcSigner + let testAccount: ethers.JsonRpcSigner let testAccountAddress: string - let toBalanceBefore: ethers.BigNumber + let toBalanceBefore: bigint beforeEach(async () => { - testAccount = provider.getSigner(5) + testAccount = await provider.getSigner(5) testAccountAddress = await testAccount.getAddress() - const ethAmount = ethers.utils.parseEther('100') - const txResp = await testAccount.sendTransaction({ - to: await wallet.getAddress(), - value: ethAmount - }) - await provider.getTransactionReceipt(txResp.hash) + const ethAmount = parseEther('100') + const txResp = await testAccount + .sendTransaction({ + to: await wallet.getAddress(), + value: ethAmount + }) + .then(tx => tx.wait()) toBalanceBefore = await provider.getBalance(testAccountAddress) }) it('Should send an async transaction', async () => { - const ethAmount = ethers.utils.parseEther('1.0') + const ethAmount = parseEther('1.0') - const tx: ethers.providers.TransactionRequest = { + const tx: ethers.TransactionRequest = { to: testAccountAddress, value: ethAmount } - await wallet.sendTransaction(tx) + await wallet.sendTransaction(tx).then(tx => tx.wait()) const toBalanceAfter = await provider.getBalance(testAccountAddress) - const sent = toBalanceAfter.sub(toBalanceBefore) - expect(sent.toString()).to.be.eq(ethAmount.toString()) + const sent = toBalanceAfter - toBalanceBefore + expect(sent).to.be.equal(ethAmount) }) it('Should send two async transactions at once', async () => { - const ethAmount1 = ethers.utils.parseEther('1.0') - const ethAmount2 = ethers.utils.parseEther('2.0') - const ethAmount3 = ethers.utils.parseEther('5.0') + const ethAmount1 = parseEther('1.0') + const ethAmount2 = parseEther('2.0') + const ethAmount3 = parseEther('5.0') - const tx1: ethers.providers.TransactionRequest = { + const tx1: ethers.TransactionRequest = { to: testAccountAddress, value: ethAmount1 } - const tx2: ethers.providers.TransactionRequest = { + const tx2: ethers.TransactionRequest = { to: testAccountAddress, value: ethAmount2 } - const tx3: ethers.providers.TransactionRequest = { + const tx3: ethers.TransactionRequest = { to: testAccountAddress, value: ethAmount3 } // Send txns in parallel, but independently - await Promise.all([wallet.sendTransaction(tx1), wallet.sendTransaction(tx2), wallet.sendTransaction(tx3)]) + await Promise.all([ + wallet.sendTransaction(tx1).then(tx => tx.wait()), + wallet.sendTransaction(tx2).then(tx => tx.wait()), + wallet.sendTransaction(tx3).then(tx => tx.wait()) + ]) const toBalanceAfter = await provider.getBalance(testAccountAddress) - const sent = toBalanceAfter.sub(toBalanceBefore) - expect(sent.toString()).to.be.eq(ethAmount1.add(ethAmount2).add(ethAmount3).toString()) + const sent = toBalanceAfter - toBalanceBefore + expect(sent).to.be.equal(ethAmount1 + ethAmount2 + ethAmount3) }) it('Should send multiple async transactions in one batch, async', async () => { - const ethAmount1 = ethers.utils.parseEther('1.0') - const ethAmount2 = ethers.utils.parseEther('2.0') - const ethAmount3 = ethers.utils.parseEther('5.0') + const ethAmount1 = parseEther('1.0') + const ethAmount2 = parseEther('2.0') + const ethAmount3 = parseEther('5.0') - const tx1: ethers.providers.TransactionRequest = { + const tx1: ethers.TransactionRequest = { to: testAccountAddress, value: ethAmount1 } - const tx2: ethers.providers.TransactionRequest = { + const tx2: ethers.TransactionRequest = { to: testAccountAddress, value: ethAmount2 } - const tx3: ethers.providers.TransactionRequest = { + const tx3: ethers.TransactionRequest = { to: testAccountAddress, value: ethAmount3 } // Send txns in parallel, but independently - await wallet.sendTransaction([tx1, tx2, tx3]) + await wallet.sendTransaction([tx1, tx2, tx3]).then(tx => tx.wait()) const toBalanceAfter = await provider.getBalance(testAccountAddress) - const sent = toBalanceAfter.sub(toBalanceBefore) - expect(sent.toString()).to.be.eq(ethAmount1.add(ethAmount2).add(ethAmount3).toString()) + const sent = toBalanceAfter - toBalanceBefore + expect(sent).to.be.equal(ethAmount1 + ethAmount2 + ethAmount3) }) }) }) diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 2efb44ed3..81891927c 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -5,6 +5,7 @@ settings: excludeLinksFromLockfile: false overrides: + bufferutil: ^4.0.8 node-forge@<1.0.0: '>=1.0.0' node-forge@<1.3.0: '>=1.3.0' got@<11.8.5: '>=11.8.5' @@ -26,21 +27,18 @@ importers: '@0xsequence/deployer': specifier: workspace:* version: link:packages/deployer - '@0xsequence/estimator': - specifier: workspace:* - version: link:packages/estimator '@0xsequence/guard': specifier: workspace:* version: link:packages/guard '@0xsequence/indexer': specifier: workspace:* version: link:packages/indexer + '@0xsequence/marketplace': + specifier: workspace:* + version: link:packages/marketplace '@0xsequence/metadata': specifier: workspace:* version: link:packages/metadata - '@0xsequence/multicall': - specifier: workspace:* - version: link:packages/multicall '@0xsequence/network': specifier: workspace:* version: link:packages/network @@ -50,9 +48,6 @@ importers: '@0xsequence/relayer': specifier: workspace:* version: link:packages/relayer - '@0xsequence/simulator': - specifier: workspace:* - version: link:packages/simulator '@0xsequence/utils': specifier: workspace:* version: link:packages/utils @@ -61,109 +56,112 @@ importers: version: link:packages/wallet '@babel/core': specifier: ^7.21.4 - version: 7.23.9 + version: 7.25.9 '@babel/plugin-transform-class-properties': specifier: ^7.23.3 - version: 7.23.3(@babel/core@7.23.9) + version: 7.25.9(@babel/core@7.25.9) '@babel/preset-env': specifier: ^7.21.4 - version: 7.23.9(@babel/core@7.23.9) + version: 7.25.9(@babel/core@7.25.9) '@babel/preset-typescript': specifier: ^7.21.4 - version: 7.23.3(@babel/core@7.23.9) + version: 7.25.9(@babel/core@7.25.9) '@babel/runtime': specifier: ^7.21.0 - version: 7.23.9 + version: 7.25.9 '@changesets/changelog-github': specifier: ^0.5.0 version: 0.5.0 '@changesets/cli': specifier: ^2.26.1 - version: 2.27.1 + version: 2.27.9 + '@nomicfoundation/hardhat-toolbox': + specifier: ^5.0.0 + version: 5.0.0(akrrydpj7boegc4sfckiephn7m) '@preconstruct/cli': - specifier: ^2.8.1 - version: 2.8.3 + specifier: ^2.8.9 + version: 2.8.9 '@types/chai': specifier: ^4.3.11 - version: 4.3.12 + version: 4.3.20 '@types/chai-as-promised': specifier: ^7.1.8 version: 7.1.8 '@types/mocha': specifier: ^10.0.6 - version: 10.0.6 + version: 10.0.9 '@types/node': - specifier: ^20.10.4 - version: 20.11.20 + specifier: ^22.7.9 + version: 22.7.9 '@typescript-eslint/eslint-plugin': - specifier: ^6.13.2 - version: 6.21.0(@typescript-eslint/parser@6.21.0)(eslint@8.57.0)(typescript@5.3.3) + specifier: ^8.11.0 + version: 8.11.0(@typescript-eslint/parser@8.11.0(eslint@8.57.1)(typescript@5.6.3))(eslint@8.57.1)(typescript@5.6.3) '@typescript-eslint/parser': - specifier: ^6.13.2 - version: 6.21.0(eslint@8.57.0)(typescript@5.3.3) + specifier: ^8.11.0 + version: 8.11.0(eslint@8.57.1)(typescript@5.6.3) ava: - specifier: ^6.0.1 - version: 6.1.1 + specifier: ^6.1.3 + version: 6.1.3 chai: specifier: ^4.3.10 - version: 4.4.1 + version: 4.5.0 chai-as-promised: specifier: ^7.1.1 - version: 7.1.1(chai@4.4.1) + version: 7.1.2(chai@4.5.0) concurrently: - specifier: ^8.2.2 - version: 8.2.2 + specifier: ^9.0.1 + version: 9.0.1 eslint: specifier: ^8.39.0 - version: 8.57.0 + version: 8.57.1 eslint-config-prettier: specifier: ^9.1.0 - version: 9.1.0(eslint@8.57.0) + version: 9.1.0(eslint@8.57.1) eslint-plugin-import: specifier: ^2.27.5 - version: 2.29.1(@typescript-eslint/parser@6.21.0)(eslint@8.57.0) + version: 2.31.0(@typescript-eslint/parser@8.11.0(eslint@8.57.1)(typescript@5.6.3))(eslint@8.57.1) eslint-plugin-prettier: specifier: ^5.0.1 - version: 5.1.3(eslint-config-prettier@9.1.0)(eslint@8.57.0)(prettier@3.2.5) + version: 5.2.1(eslint-config-prettier@9.1.0(eslint@8.57.1))(eslint@8.57.1)(prettier@3.3.3) ethers: - specifier: ^5.7.2 - version: 5.7.2 + specifier: 6.13.4 + version: 6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10) express: specifier: ^4.18.2 - version: 4.18.2(supports-color@6.1.0) + version: 4.21.1(supports-color@6.1.0) hardhat: - specifier: ^2.20.1 - version: 2.20.1(ts-node@10.9.2)(typescript@5.3.3) + specifier: ^2.22.14 + version: 2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10) husky: specifier: ^8.0.0 version: 8.0.3 mocha: specifier: ^10.1.0 - version: 10.3.0 + version: 10.7.3 nyc: - specifier: ^15.1.0 - version: 15.1.0 + specifier: ^17.1.0 + version: 17.1.0 prettier: specifier: ^3.0.0 - version: 3.2.5 + version: 3.3.3 puppeteer: - specifier: ^21.6.0 - version: 21.11.0(typescript@5.3.3) + specifier: ^23.10.3 + version: 23.10.3(bufferutil@4.0.8)(typescript@5.6.3)(utf-8-validate@5.0.10) rimraf: - specifier: ^5.0.5 - version: 5.0.5 + specifier: ^6.0.1 + version: 6.0.1 ts-node: specifier: ^10.9.2 - version: 10.9.2(@types/node@20.11.20)(typescript@5.3.3) + version: 10.9.2(@types/node@22.7.9)(typescript@5.6.3) tsx: - specifier: ^4.6.2 - version: 4.7.1 + specifier: ^4.19.1 + version: 4.19.1 typescript: - specifier: ~5.3.3 - version: 5.3.3 + specifier: ~5.6.3 + version: 5.6.3 wait-on: - specifier: ^7.2.0 - version: 7.2.0 + specifier: ^8.0.1 + version: 8.0.1 packages/0xsequence: dependencies: @@ -194,9 +192,6 @@ importers: '@0xsequence/migration': specifier: workspace:* version: link:../migration - '@0xsequence/multicall': - specifier: workspace:* - version: link:../multicall '@0xsequence/network': specifier: workspace:* version: link:../network @@ -223,35 +218,35 @@ importers: specifier: workspace:* version: link:../tests '@0xsequence/wallet-contracts': - specifier: ^2.0.0 - version: 2.0.0(@ethersproject/abi@5.7.0)(@ethersproject/bytes@5.7.0)(@ethersproject/providers@5.7.2)(typechain@5.2.0)(typescript@5.3.3) + specifier: ^3.0.1 + version: 3.0.1(bufferutil@4.0.8)(typechain@8.3.2(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@6.0.3) '@babel/plugin-transform-runtime': specifier: ^7.19.6 - version: 7.23.9(@babel/core@7.23.9) + version: 7.25.9(@babel/core@7.25.9) babel-loader: specifier: ^9.1.0 - version: 9.1.3(@babel/core@7.23.9)(webpack@5.90.3) + version: 9.2.1(@babel/core@7.25.9)(webpack@5.95.0) ethers: - specifier: ^5.7.2 - version: 5.7.2 + specifier: 6.13.4 + version: 6.13.4(bufferutil@4.0.8)(utf-8-validate@6.0.3) ganache: specifier: ^7.5.0 version: 7.9.2 hardhat: - specifier: ^2.20.1 - version: 2.20.1(ts-node@10.9.2)(typescript@5.3.3) + specifier: ^2.22.14 + version: 2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@6.0.3) html-webpack-plugin: specifier: ^5.3.1 - version: 5.6.0(webpack@5.90.3) + version: 5.6.3(webpack@5.95.0) webpack: specifier: ^5.65.0 - version: 5.90.3(webpack-cli@4.10.0) + version: 5.95.0(webpack-cli@4.10.0) webpack-cli: specifier: ^4.6.0 - version: 4.10.0(webpack-dev-server@3.11.3)(webpack@5.90.3) + version: 4.10.0(webpack-dev-server@3.11.3)(webpack@5.95.0) webpack-dev-server: specifier: ^3.11.2 - version: 3.11.3(webpack-cli@4.10.0)(webpack@5.90.3) + version: 3.11.3(bufferutil@4.0.8)(utf-8-validate@6.0.3)(webpack-cli@4.10.0)(webpack@5.95.0) packages/abi: {} @@ -281,9 +276,6 @@ importers: '@0xsequence/wallet': specifier: workspace:* version: link:../wallet - ethers: - specifier: ^5.5.2 - version: 5.7.2 devDependencies: '@0xsequence/signhub': specifier: workspace:* @@ -294,6 +286,9 @@ importers: '@istanbuljs/nyc-config-typescript': specifier: ^1.0.2 version: 1.0.2(nyc@15.1.0) + ethers: + specifier: 6.13.4 + version: 6.13.4(bufferutil@4.0.8)(utf-8-validate@6.0.3) nyc: specifier: ^15.1.0 version: 15.1.0 @@ -315,8 +310,8 @@ importers: specifier: workspace:* version: link:../core '@0xsequence/ethauth': - specifier: ^0.8.1 - version: 0.8.1(ethers@5.7.2) + specifier: ^1.0.0 + version: 1.0.0(ethers@6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10)) '@0xsequence/indexer': specifier: workspace:* version: link:../indexer @@ -346,33 +341,38 @@ importers: specifier: workspace:* version: link:../tests '@0xsequence/wallet-contracts': - specifier: ^1.10.0 - version: 1.10.0 + specifier: ^3.0.1 + version: 3.0.1(bufferutil@4.0.8)(typechain@8.3.2(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10) concurrently: - specifier: ^7.5.0 - version: 7.6.0 + specifier: ^9.0.1 + version: 9.0.1 ethers: - specifier: ^5.7.2 - version: 5.7.2 + specifier: 6.13.4 + version: 6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10) hardhat: - specifier: ^2.20.1 - version: 2.20.1(ts-node@10.9.2)(typescript@5.3.3) + specifier: ^2.22.14 + version: 2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10) mockttp: specifier: ^3.6.0 - version: 3.10.1 + version: 3.15.3(bufferutil@4.0.8)(utf-8-validate@5.0.10) + + packages/builder: {} packages/core: dependencies: '@0xsequence/abi': specifier: workspace:* version: link:../abi - ethers: - specifier: '>=5.5' - version: 5.7.2 + '@0xsequence/utils': + specifier: workspace:* + version: link:../utils devDependencies: '@istanbuljs/nyc-config-typescript': specifier: ^1.0.2 version: 1.0.2(nyc@15.1.0) + ethers: + specifier: 6.13.4 + version: 6.13.4(bufferutil@4.0.8)(utf-8-validate@6.0.3) nyc: specifier: ^15.1.0 version: 15.1.0 @@ -383,61 +383,15 @@ importers: specifier: workspace:* version: link:../utils devDependencies: - '@ethersproject/abi': - specifier: ^5.7.0 - version: 5.7.0 - '@ethersproject/providers': - specifier: ^5.7.2 - version: 5.7.2 - '@nomiclabs/hardhat-ethers': - specifier: ^2.2.1 - version: 2.2.3(ethers@5.7.2)(hardhat@2.20.1) - '@nomiclabs/hardhat-web3': - specifier: ^2.0.0 - version: 2.0.0(hardhat@2.20.1)(web3@1.10.4) - '@typechain/ethers-v5': - specifier: ^10.1.1 - version: 10.2.1(@ethersproject/abi@5.7.0)(@ethersproject/providers@5.7.2)(ethers@5.7.2)(typechain@8.3.2)(typescript@5.3.3) dotenv: specifier: ^16.0.3 version: 16.4.5 ethers: - specifier: ^5.7.2 - version: 5.7.2 + specifier: 6.13.4 + version: 6.13.4(bufferutil@4.0.8)(utf-8-validate@6.0.3) typechain: specifier: ^8.1.1 - version: 8.3.2(typescript@5.3.3) - - packages/estimator: - dependencies: - '@0xsequence/abi': - specifier: workspace:* - version: link:../abi - '@0xsequence/core': - specifier: workspace:* - version: link:../core - '@0xsequence/utils': - specifier: workspace:* - version: link:../utils - '@0xsequence/wallet-contracts': - specifier: ^1.10.0 - version: 1.10.0 - devDependencies: - '@0xsequence/signhub': - specifier: workspace:* - version: link:../signhub - '@0xsequence/tests': - specifier: workspace:* - version: link:../tests - '@ethersproject/abstract-signer': - specifier: ^5.7.0 - version: 5.7.0 - '@ethersproject/properties': - specifier: ^5.7.0 - version: 5.7.0 - ethers: - specifier: ^5.7.2 - version: 5.7.2 + version: 8.3.2(typescript@5.6.3) packages/guard: dependencies: @@ -453,12 +407,15 @@ importers: '@0xsequence/utils': specifier: workspace:* version: link:../utils + devDependencies: ethers: - specifier: ^5.7.2 - version: 5.7.2 + specifier: 6.13.4 + version: 6.13.4(bufferutil@4.0.8)(utf-8-validate@6.0.3) packages/indexer: {} + packages/marketplace: {} + packages/metadata: {} packages/migration: @@ -472,57 +429,17 @@ importers: '@0xsequence/wallet': specifier: workspace:* version: link:../wallet - ethers: - specifier: ^5.5.2 - version: 5.7.2 devDependencies: '@istanbuljs/nyc-config-typescript': specifier: ^1.0.2 version: 1.0.2(nyc@15.1.0) + ethers: + specifier: 6.13.4 + version: 6.13.4(bufferutil@4.0.8)(utf-8-validate@6.0.3) nyc: specifier: ^15.1.0 version: 15.1.0 - packages/multicall: - dependencies: - '@0xsequence/abi': - specifier: workspace:* - version: link:../abi - '@0xsequence/network': - specifier: workspace:* - version: link:../network - '@0xsequence/utils': - specifier: workspace:* - version: link:../utils - devDependencies: - '@0xsequence/wallet-contracts': - specifier: ^2.0.0 - version: 2.0.0(@ethersproject/abi@5.7.0)(@ethersproject/bytes@5.7.0)(@ethersproject/providers@5.7.2)(typechain@5.2.0)(typescript@5.3.3) - '@ethersproject/providers': - specifier: ^5.7.2 - version: 5.7.2 - '@types/web3-provider-engine': - specifier: ^14.0.1 - version: 14.0.4 - eth-json-rpc-middleware: - specifier: ^9.0.1 - version: 9.0.1 - ethers: - specifier: ^5.7.2 - version: 5.7.2 - ganache: - specifier: ^7.5.0 - version: 7.9.2 - json-rpc-engine: - specifier: ^6.1.0 - version: 6.1.0 - web3: - specifier: ^1.8.1 - version: 1.10.4 - web3-provider-engine: - specifier: ^16.0.4 - version: 16.0.7 - packages/network: dependencies: '@0xsequence/core': @@ -539,8 +456,8 @@ importers: version: link:../utils devDependencies: ethers: - specifier: ^5.7.2 - version: 5.7.2 + specifier: 6.13.4 + version: 6.13.4(bufferutil@4.0.8)(utf-8-validate@6.0.3) packages/provider: dependencies: @@ -572,8 +489,8 @@ importers: specifier: workspace:* version: link:../wallet '@databeat/tracker': - specifier: ^0.9.1 - version: 0.9.1 + specifier: ^0.9.3 + version: 0.9.3 eventemitter2: specifier: ^6.4.5 version: 6.4.9 @@ -585,11 +502,11 @@ importers: specifier: ^0.10.0 version: 0.10.7 ethers: - specifier: ^5.7.2 - version: 5.7.2 + specifier: 6.13.4 + version: 6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10) hardhat: - specifier: ^2.20.1 - version: 2.20.1(ts-node@10.9.2)(typescript@5.3.3) + specifier: ^2.22.14 + version: 2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10) packages/react-native: dependencies: @@ -619,11 +536,11 @@ importers: specifier: workspace:* version: link:../tests '@0xsequence/wallet-contracts': - specifier: ^1.10.0 - version: 1.10.0 + specifier: ^3.0.1 + version: 3.0.1(bufferutil@4.0.8)(typechain@8.3.2(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@6.0.3) ethers: - specifier: ^5.7.2 - version: 5.7.2 + specifier: 6.13.4 + version: 6.13.4(bufferutil@4.0.8)(utf-8-validate@6.0.3) packages/replacer: dependencies: @@ -634,8 +551,8 @@ importers: specifier: workspace:* version: link:../core ethers: - specifier: '>=5.5' - version: 5.7.2 + specifier: '>=6' + version: 6.13.4(bufferutil@4.0.8)(utf-8-validate@6.0.3) packages/sessions: dependencies: @@ -648,9 +565,9 @@ importers: '@0xsequence/replacer': specifier: workspace:* version: link:../replacer - ethers: - specifier: ^5.5.2 - version: 5.7.2 + '@0xsequence/utils': + specifier: workspace:* + version: link:../utils idb: specifier: ^7.1.1 version: 7.1.1 @@ -664,6 +581,9 @@ importers: '@istanbuljs/nyc-config-typescript': specifier: ^1.0.2 version: 1.0.2(nyc@15.1.0) + ethers: + specifier: 6.13.4 + version: 6.13.4(bufferutil@4.0.8)(utf-8-validate@6.0.3) fake-indexeddb: specifier: ^4.0.1 version: 4.0.2 @@ -676,51 +596,35 @@ importers: '@0xsequence/core': specifier: workspace:* version: link:../core - ethers: - specifier: ^5.5.2 - version: 5.7.2 devDependencies: '@istanbuljs/nyc-config-typescript': specifier: ^1.0.2 version: 1.0.2(nyc@15.1.0) + ethers: + specifier: 6.13.4 + version: 6.13.4(bufferutil@4.0.8)(utf-8-validate@6.0.3) nyc: specifier: ^15.1.0 version: 15.1.0 - packages/simulator: - dependencies: - '@0xsequence/core': - specifier: workspace:* - version: link:../core - '@0xsequence/wallet-contracts': - specifier: ^1.10.0 - version: 1.10.0 - devDependencies: - '@0xsequence/signhub': - specifier: workspace:* - version: link:../signhub - '@0xsequence/tests': - specifier: workspace:* - version: link:../tests - ethers: - specifier: ^5.7.2 - version: 5.7.2 - packages/tests: dependencies: '@0xsequence/core': specifier: workspace:* version: link:../core + '@0xsequence/utils': + specifier: workspace:* + version: link:../utils devDependencies: '@istanbuljs/nyc-config-typescript': specifier: ^1.0.1 - version: 1.0.2(nyc@15.1.0) + version: 1.0.2(nyc@17.1.0) ethers: - specifier: ^5.7.2 - version: 5.7.2 + specifier: 6.13.4 + version: 6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10) web3: specifier: ^1.8.1 - version: 1.10.4 + version: 1.10.4(bufferutil@4.0.8)(utf-8-validate@5.0.10) packages/utils: dependencies: @@ -729,8 +633,8 @@ importers: version: 3.7.7 devDependencies: ethers: - specifier: ^5.7.2 - version: 5.7.2 + specifier: 6.13.4 + version: 6.13.4(bufferutil@4.0.8)(utf-8-validate@6.0.3) packages/waas: dependencies: @@ -740,12 +644,12 @@ importers: '@0xsequence/network': specifier: workspace:* version: link:../network + '@0xsequence/utils': + specifier: workspace:* + version: link:../utils '@aws-sdk/client-cognito-identity-provider': specifier: ^3.445.0 - version: 3.521.0 - ethers: - specifier: '>=5.5' - version: 5.7.2 + version: 3.678.0 idb: specifier: ^7.1.1 version: 7.1.1 @@ -759,6 +663,9 @@ importers: '@types/jwt-decode': specifier: ^3.1.0 version: 3.1.0 + ethers: + specifier: 6.13.4 + version: 6.13.4(bufferutil@4.0.8)(utf-8-validate@6.0.3) fake-indexeddb: specifier: ^4.0.1 version: 4.0.2 @@ -768,9 +675,10 @@ importers: '@0xsequence/waas': specifier: workspace:* version: link:../waas + devDependencies: ethers: - specifier: '>=5.5' - version: 5.7.2 + specifier: 6.13.4 + version: 6.13.4(bufferutil@4.0.8)(utf-8-validate@6.0.3) packages/wallet: dependencies: @@ -794,420 +702,330 @@ importers: version: link:../utils devDependencies: '@0xsequence/ethauth': - specifier: ^0.8.1 - version: 0.8.1(ethers@5.7.2) + specifier: ^1.0.0 + version: 1.0.0(ethers@6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10)) '@0xsequence/tests': specifier: workspace:* version: link:../tests '@0xsequence/wallet-contracts': - specifier: ^2.0.0 - version: 2.0.0(@ethersproject/abi@5.7.0)(@ethersproject/bytes@5.7.0)(@ethersproject/providers@5.7.2)(typechain@5.2.0)(typescript@5.3.3) + specifier: ^3.0.1 + version: 3.0.1(bufferutil@4.0.8)(typechain@8.3.2(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10) '@istanbuljs/nyc-config-typescript': specifier: ^1.0.1 - version: 1.0.2(nyc@15.1.0) + version: 1.0.2(nyc@17.1.0) ethers: - specifier: ^5.7.2 - version: 5.7.2 + specifier: 6.13.4 + version: 6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10) web3: specifier: ^1.8.1 - version: 1.10.4 + version: 1.10.4(bufferutil@4.0.8)(utf-8-validate@5.0.10) packages: - '@0xsequence/ethauth@0.8.1': - resolution: {integrity: sha512-P21cxRSS+2mDAqFVAJt0lwQFtbObX+Ewlj8DMyDELp81+QbfHFh6LCyu8dTXNdBx6UbmRFOCSBno5Txd50cJPQ==} + '@0xsequence/ethauth@1.0.0': + resolution: {integrity: sha512-piihXzbS8Sq7P670a+GyTm3igTJL3Ts6pqjJcC0Sv86yqeK6QD0pzJP4APP+/IQa5k+0s2l1SeZwMjR7gSPtCA==} peerDependencies: - ethers: '>=5.5' + ethers: '>=6' - '@0xsequence/wallet-contracts@1.10.0': - resolution: {integrity: sha512-NfPBJkp6/ApjVuTqQMgJvpN5lWyNc9bHm9ZITEi3X3nREf5126RLEXCyThChapkmcglHnQn+ndA8j6bfcpFEAg==} + '@0xsequence/wallet-contracts@3.0.1': + resolution: {integrity: sha512-ZvZdXPE1KOYVjl9J6UdN/eBqEmuYHvlO4EUxDxG7VqCgrSiVP9S8k+mEN4aUMzOiYGwKcYY/HIkD211mvxseZQ==} - '@0xsequence/wallet-contracts@2.0.0': - resolution: {integrity: sha512-PbKedYnBxgS7Qb5ca/xHUt++TmKK3yKIpVR1fX7HtAJiYOMSoZX4pVIFylUr6N7uBNpsPurFWCx7jTK+hBZnNA==} + '@adraffy/ens-normalize@1.10.1': + resolution: {integrity: sha512-96Z2IP3mYmF1Xg2cDm8f1gWGf/HUVedQ3FMifV4kG/PQ4yEP51xDtRAEfhVNt5f/uzpNkZHwWQuUcu6D6K+Ekw==} - '@aashutoshrathi/word-wrap@1.2.6': - resolution: {integrity: sha512-1Yjs2SvM8TflER/OD3cOjhWWOZb58A2t7wpE2S9XfBYTiIl+XFhQG2bjy4Pu1I+EAlCNUzRDYDdFwFYUKvXcIA==} - engines: {node: '>=0.10.0'} - - '@ampproject/remapping@2.2.1': - resolution: {integrity: sha512-lFMjJTrFL3j7L9yBxwYfCq2k6qqwHyzuUl/XBnif78PWTJYyL/dfowQHWE3sp6U6ZzqWiiIZnpTMO96zhkjwtg==} + '@ampproject/remapping@2.3.0': + resolution: {integrity: sha512-30iZtAPgz+LTIYoeivqYo853f02jBYSd5uGnGpkFV0M3xOt9aN73erkgYAmZU43x4VfqcnLxW9Kpg3R5LC4YYw==} engines: {node: '>=6.0.0'} - '@aws-crypto/crc32@3.0.0': - resolution: {integrity: sha512-IzSgsrxUcsrejQbPVilIKy16kAT52EwB6zSaI+M3xxIhKh5+aldEyvI+z6erM7TCLB2BJsFrtHjp6/4/sr+3dA==} - - '@aws-crypto/ie11-detection@3.0.0': - resolution: {integrity: sha512-341lBBkiY1DfDNKai/wXM3aujNBkXR7tq1URPQDL9wi3AUbI80NR74uF1TXHMm7po1AcnFk8iu2S2IeU/+/A+Q==} + '@aws-crypto/sha256-browser@5.2.0': + resolution: {integrity: sha512-AXfN/lGotSQwu6HNcEsIASo7kWXZ5HYWvfOmSNKDsEqC4OashTp8alTmaz+F7TC2L083SFv5RdB+qU3Vs1kZqw==} - '@aws-crypto/sha256-browser@3.0.0': - resolution: {integrity: sha512-8VLmW2B+gjFbU5uMeqtQM6Nj0/F1bro80xQXCW6CQBWgosFWXTx77aeOF5CAIAmbOK64SdMBJdNr6J41yP5mvQ==} + '@aws-crypto/sha256-js@5.2.0': + resolution: {integrity: sha512-FFQQyu7edu4ufvIZ+OadFpHHOt+eSTBaYaki44c+akjg7qZg9oOQeLlk77F6tSYqjDAFClrHJk9tMf0HdVyOvA==} + engines: {node: '>=16.0.0'} - '@aws-crypto/sha256-js@3.0.0': - resolution: {integrity: sha512-PnNN7os0+yd1XvXAy23CFOmTbMaDxgxXtTKHybrJ39Y8kGzBATgBFibWJKH6BhytLI/Zyszs87xCOBNyBig6vQ==} + '@aws-crypto/supports-web-crypto@5.2.0': + resolution: {integrity: sha512-iAvUotm021kM33eCdNfwIN//F77/IADDSs58i+MDaOqFrVjZo9bAal0NK7HurRuWLLpF1iLX7gbWrjHjeo+YFg==} - '@aws-crypto/supports-web-crypto@3.0.0': - resolution: {integrity: sha512-06hBdMwUAb2WFTuGG73LSC0wfPu93xWwo5vL2et9eymgmu3Id5vFAHBbajVWiGhPO37qcsdCap/FqXvJGJWPIg==} + '@aws-crypto/util@5.2.0': + resolution: {integrity: sha512-4RkU9EsI6ZpBve5fseQlGNUWKMa1RLPQ1dnjnQoe07ldfIzcsGb5hC5W0Dm7u423KWzawlrpbjXBrXCEv9zazQ==} - '@aws-crypto/util@3.0.0': - resolution: {integrity: sha512-2OJlpeJpCR48CC8r+uKVChzs9Iungj9wkZrl8Z041DWEWvyIHILYKCPNzJghKsivj+S3mLo6BVc7mBNzdxA46w==} + '@aws-sdk/client-cognito-identity-provider@3.678.0': + resolution: {integrity: sha512-dIfTuBoDvEjoPku043AdEWqcsPHkD6qLOvRUBf0I3YpAcZwdhXVJ1Z76KP16IwKHxLOszVx5U3BYOg0zuTmTag==} + engines: {node: '>=16.0.0'} - '@aws-sdk/client-cognito-identity-provider@3.521.0': - resolution: {integrity: sha512-lDM8eAc9hkVoxatHk5hpLNv/G0z0e/LBoH763aXcy8C35fncURRS2pOXbmOHp2gC5kOsTmIwhHOcyBHg3aw6WA==} - engines: {node: '>=14.0.0'} - - '@aws-sdk/client-sso-oidc@3.521.0': - resolution: {integrity: sha512-MhX0CjV/543MR7DRPr3lA4ZDpGGKopp8cyV4EkSGXB7LMN//eFKKDhuZDlpgWU+aFe2A3DIqlNJjqgs08W0cSA==} - engines: {node: '>=14.0.0'} + '@aws-sdk/client-sso-oidc@3.678.0': + resolution: {integrity: sha512-sgj9Y4zGiwLePLDjqhGoghoZgseh88JkKkwWH558IIte/cf/ix7ezOvptnA0WUlI5Z/329LtkN6O8TRqSJ7MWw==} + engines: {node: '>=16.0.0'} peerDependencies: - '@aws-sdk/credential-provider-node': ^3.521.0 + '@aws-sdk/client-sts': ^3.678.0 - '@aws-sdk/client-sso@3.521.0': - resolution: {integrity: sha512-aEx8kEvWmTwCja6hvIZd5PvxHsI1HQZkckXhw1UrkDPnfcAwQoQAgselI7D+PVT5qQDIjXRm0NpsvBLaLj6jZw==} - engines: {node: '>=14.0.0'} + '@aws-sdk/client-sso@3.678.0': + resolution: {integrity: sha512-5Fg2BkR1En8iBbiZ18STvLDGPK9Re5MyCmX+hfIhQzPsEf1FRkAkOluEXX79aBva8iWn2oCD/xKBUku4x3eusw==} + engines: {node: '>=16.0.0'} - '@aws-sdk/client-sts@3.521.0': - resolution: {integrity: sha512-f1J5NDbntcwIHJqhks89sQvk7UXPmN0X0BZ2mgpj6pWP+NlPqy+1t1bia8qRhEuNITaEigoq6rqe9xaf4FdY9A==} - engines: {node: '>=14.0.0'} - peerDependencies: - '@aws-sdk/credential-provider-node': ^3.521.0 + '@aws-sdk/client-sts@3.678.0': + resolution: {integrity: sha512-oRtDnbqIuTbBq0xd7XlaugDA41EqRFzWLpPNr4uwkH8L7xwtIByfJG/qXx2OtOiFFasAhMWJLu/DDqWZyp819A==} + engines: {node: '>=16.0.0'} - '@aws-sdk/core@3.521.0': - resolution: {integrity: sha512-KovKmW7yg/P2HVG2dhV2DAJLyoeGelgsnSGHaktXo/josJ3vDGRNqqRSgVaqKFxnD98dPEMLrjkzZumNUNGvLw==} - engines: {node: '>=14.0.0'} + '@aws-sdk/core@3.678.0': + resolution: {integrity: sha512-ZTzybFZqSaPQymgRkTl08vk6xilaxr8LnJOc0h3KhcHLK4TJmdOcxqPpa6QxrBKcn2rmxzGiPRbAHLGI+BIxBw==} + engines: {node: '>=16.0.0'} - '@aws-sdk/credential-provider-env@3.521.0': - resolution: {integrity: sha512-OwblTJNdDAoqYVwcNfhlKDp5z+DINrjBfC6ZjNdlJpTXgxT3IqzuilTJTlydQ+2eG7aXfV9OwTVRQWdCmzFuKA==} - engines: {node: '>=14.0.0'} + '@aws-sdk/credential-provider-env@3.678.0': + resolution: {integrity: sha512-29uhXAB7uJqHtvJ2U3pi1YkMfv0WefW9EmSMoFAunjudXXBVktwTlWg0lyCM+KHrGKLkQyfs5UF/A9IelS8tdQ==} + engines: {node: '>=16.0.0'} - '@aws-sdk/credential-provider-http@3.521.0': - resolution: {integrity: sha512-yJM1yNGj2XFH8v6/ffWrFY5nC3/2+8qZ8c4mMMwZru8bYXeuSV4+NNfE59HUWvkAF7xP76u4gr4I8kNrMPTlfg==} - engines: {node: '>=14.0.0'} + '@aws-sdk/credential-provider-http@3.678.0': + resolution: {integrity: sha512-EvpmP0nc7ddRp0qwJOSu0uBXa+MMk4+OLlyEJcdaHnZI4/BoyVWr5fJUD5eQYZk11LZPZSvnsliYXWwLyVNXHQ==} + engines: {node: '>=16.0.0'} - '@aws-sdk/credential-provider-ini@3.521.0': - resolution: {integrity: sha512-HuhP1AlKgvBBxUIwxL/2DsDemiuwgbz1APUNSeJhDBF6JyZuxR0NU8zEZkvH9b4ukTcmcKGABpY0Wex4rAh3xw==} - engines: {node: '>=14.0.0'} + '@aws-sdk/credential-provider-ini@3.678.0': + resolution: {integrity: sha512-8kHy7V5rRO73EpBCUclykP9T/QIBVi0SkQsc88ZRxpdh59/JY2N6DT5khMTzrz9+Vvlw3FDMJN4AI/qWjJHhdw==} + engines: {node: '>=16.0.0'} + peerDependencies: + '@aws-sdk/client-sts': ^3.678.0 - '@aws-sdk/credential-provider-node@3.521.0': - resolution: {integrity: sha512-N9SR4gWI10qh4V2myBcTw8IlX3QpsMMxa4Q8d/FHiAX6eNV7e6irXkXX8o7+J1gtCRy1AtBMqAdGsve4GVqYMQ==} - engines: {node: '>=14.0.0'} + '@aws-sdk/credential-provider-node@3.678.0': + resolution: {integrity: sha512-KGRBVD/oNr/aD+Wy5zc5AjfeSv5b4ahAu5eAUbOz+eGjGpGgrMtjY+R2rDY/3i3wFj9/DvOIfFGeZQMwtDzIuA==} + engines: {node: '>=16.0.0'} - '@aws-sdk/credential-provider-process@3.521.0': - resolution: {integrity: sha512-EcJjcrpdklxbRAFFgSLk6QGVtvnfZ80ItfZ47VL9LkhWcDAkQ1Oi0esHq+zOgvjb7VkCyD3Q9CyEwT6MlJsriA==} - engines: {node: '>=14.0.0'} + '@aws-sdk/credential-provider-process@3.678.0': + resolution: {integrity: sha512-5TpzzHKwPOvUJig0bvTt+brtXfLPaSVLwea9re+XGrS5T6Hz65IaX2RL6uY1GQ0UVOqgwQ5nAti1WOfBoSJ5BA==} + engines: {node: '>=16.0.0'} - '@aws-sdk/credential-provider-sso@3.521.0': - resolution: {integrity: sha512-GAfc0ji+fC2k9VngYM3zsS1J5ojfWg0WUOBzavvHzkhx/O3CqOt82Vfikg3PvemAp9yOgKPMaasTHVeipNLBBQ==} - engines: {node: '>=14.0.0'} + '@aws-sdk/credential-provider-sso@3.678.0': + resolution: {integrity: sha512-PXydLUsLYd1rkhZ7zwf0613u5sofxIEhh7C1QGP1MSY3L1jt8bu7pZIcMzubfvmaGZI5k84aHhhjQEiAJUxIMg==} + engines: {node: '>=16.0.0'} - '@aws-sdk/credential-provider-web-identity@3.521.0': - resolution: {integrity: sha512-ZPPJqdbPOE4BkdrPrYBtsWg0Zy5b+GY1sbMWLQt0tcISgN5EIoePCS2pGNWnBUmBT+mibMQCVv9fOQpqzRkvAw==} - engines: {node: '>=14.0.0'} + '@aws-sdk/credential-provider-web-identity@3.678.0': + resolution: {integrity: sha512-fcYZjTTFcef99l+BhcEAhHS4tEK1kE6Xj5Zz5lT4tFA07BkQt3d6kUKRVVfJnsbcHH4RDBUCnLhU8HPfc/kvjA==} + engines: {node: '>=16.0.0'} + peerDependencies: + '@aws-sdk/client-sts': ^3.678.0 - '@aws-sdk/middleware-host-header@3.521.0': - resolution: {integrity: sha512-Bc4stnMtVAdqosYI1wedFK9tffclCuwpOK/JA4bxbnvSyP1kz4s1HBVT9OOMzdLRLWLwVj/RslXKfSbzOUP7ug==} - engines: {node: '>=14.0.0'} + '@aws-sdk/middleware-host-header@3.667.0': + resolution: {integrity: sha512-Z7fIAMQnPegs7JjAQvlOeWXwpMRfegh5eCoIP6VLJIeR6DLfYKbP35JBtt98R6DXslrN2RsbTogjbxPEDQfw1w==} + engines: {node: '>=16.0.0'} - '@aws-sdk/middleware-logger@3.521.0': - resolution: {integrity: sha512-JJ4nyYvLu3RyyNHo74Rlx6WKxJsAixWCEnnFb6IGRUHvsG+xBGU7HF5koY2log8BqlDLrt4ZUaV/CGy5Dp8Mfg==} - engines: {node: '>=14.0.0'} + '@aws-sdk/middleware-logger@3.667.0': + resolution: {integrity: sha512-PtTRNpNm/5c746jRgZCNg4X9xEJIwggkGJrF0GP9AB1ANg4pc/sF2Fvn1NtqPe9wtQ2stunJprnm5WkCHN7QiA==} + engines: {node: '>=16.0.0'} - '@aws-sdk/middleware-recursion-detection@3.521.0': - resolution: {integrity: sha512-1m5AsC55liTlaYMjc4pIQfjfBHG9LpWgubSl4uUxJSdI++zdA/SRBwXl40p7Ac/y5esweluhWabyiv1g/W4+Xg==} - engines: {node: '>=14.0.0'} + '@aws-sdk/middleware-recursion-detection@3.667.0': + resolution: {integrity: sha512-U5glWD3ehFohzpUpopLtmqAlDurGWo2wRGPNgi4SwhWU7UDt6LS7E/UvJjqC0CUrjlzOw+my2A+Ncf+fisMhxQ==} + engines: {node: '>=16.0.0'} - '@aws-sdk/middleware-user-agent@3.521.0': - resolution: {integrity: sha512-+hmQjWDG93wCcJn5QY2MkzAL1aG5wl3FJ/ud2nQOu/Gx7d4QVT/B6VJwoG6GSPVuVPZwzne5n9zPVst6RmWJGA==} - engines: {node: '>=14.0.0'} + '@aws-sdk/middleware-user-agent@3.678.0': + resolution: {integrity: sha512-tg9cC5COgGP0cznD2ys9kxPtVeKUygPZshDWXLAfA/cH/4m2ZUBvoEVv1SxkIbvOjnPwa976rdPLQUwRZvsL0g==} + engines: {node: '>=16.0.0'} - '@aws-sdk/region-config-resolver@3.521.0': - resolution: {integrity: sha512-eC2T62nFgQva9Q0Sqoc9xsYyyH9EN2rJtmUKkWsBMf77atpmajAYRl5B/DzLwGHlXGsgVK2tJdU5wnmpQCEwEQ==} - engines: {node: '>=14.0.0'} + '@aws-sdk/region-config-resolver@3.667.0': + resolution: {integrity: sha512-iNr+JhhA902JMKHG9IwT9YdaEx6KGl6vjAL5BRNeOjfj4cZYMog6Lz/IlfOAltMtT0w88DAHDEFrBd2uO0l2eg==} + engines: {node: '>=16.0.0'} - '@aws-sdk/token-providers@3.521.0': - resolution: {integrity: sha512-63XxPOn13j87yPWKm6UXOPdMZIMyEyCDJzmlxnIACP8m20S/c6b8xLJ4fE/PUlD0MTKxpFeQbandq5OhnLsWSQ==} - engines: {node: '>=14.0.0'} + '@aws-sdk/token-providers@3.667.0': + resolution: {integrity: sha512-ZecJlG8p6D4UTYlBHwOWX6nknVtw/OBJ3yPXTSajBjhUlj9lE2xvejI8gl4rqkyLXk7z3bki+KR4tATbMaM9yg==} + engines: {node: '>=16.0.0'} + peerDependencies: + '@aws-sdk/client-sso-oidc': ^3.667.0 - '@aws-sdk/types@3.521.0': - resolution: {integrity: sha512-H9I3Lut0F9d+kTibrhnTRqDRzhxf/vrDu12FUdTXVZEvVAQ7w9yrVHAZx8j2e8GWegetsQsNitO3KMrj4dA4pw==} - engines: {node: '>=14.0.0'} + '@aws-sdk/types@3.667.0': + resolution: {integrity: sha512-gYq0xCsqFfQaSL/yT1Gl1vIUjtsg7d7RhnUfsXaHt8xTxOKRTdH9GjbesBjXOzgOvB0W0vfssfreSNGFlOOMJg==} + engines: {node: '>=16.0.0'} - '@aws-sdk/util-endpoints@3.521.0': - resolution: {integrity: sha512-lO5+1LeAZycDqgNjQyZdPSdXFQKXaW5bRuQ3UIT3bOCcUAbDI0BYXlPm1huPNTCEkI9ItnDCbISbV0uF901VXw==} - engines: {node: '>=14.0.0'} + '@aws-sdk/util-endpoints@3.667.0': + resolution: {integrity: sha512-X22SYDAuQJWnkF1/q17pkX3nGw5XMD9YEUbmt87vUnRq7iyJ3JOpl6UKOBeUBaL838wA5yzdbinmCITJ/VZ1QA==} + engines: {node: '>=16.0.0'} - '@aws-sdk/util-locate-window@3.495.0': - resolution: {integrity: sha512-MfaPXT0kLX2tQaR90saBT9fWQq2DHqSSJRzW+MZWsmF+y5LGCOhO22ac/2o6TKSQm7h0HRc2GaADqYYYor62yg==} - engines: {node: '>=14.0.0'} + '@aws-sdk/util-locate-window@3.568.0': + resolution: {integrity: sha512-3nh4TINkXYr+H41QaPelCceEB2FXP3fxp93YZXB/kqJvX0U9j0N0Uk45gvsjmEPzG8XxkPEeLIfT2I1M7A6Lig==} + engines: {node: '>=16.0.0'} - '@aws-sdk/util-user-agent-browser@3.521.0': - resolution: {integrity: sha512-2t3uW6AXOvJ5iiI1JG9zPqKQDc/TRFa+v13aqT5KKw9h3WHFyRUpd4sFQL6Ul0urrq2Zg9cG4NHBkei3k9lsHA==} + '@aws-sdk/util-user-agent-browser@3.675.0': + resolution: {integrity: sha512-HW4vGfRiX54RLcsYjLuAhcBBJ6lRVEZd7njfGpAwBB9s7BH8t48vrpYbyA5XbbqbTvXfYBnugQCUw9HWjEa1ww==} - '@aws-sdk/util-user-agent-node@3.521.0': - resolution: {integrity: sha512-g4KMEiyLc8DG21eMrp6fJUdfQ9F0fxfCNMDRgf0SE/pWI/u4vuWR2n8obLwq1pMVx7Ksva1NO3dc+a3Rgr0hag==} - engines: {node: '>=14.0.0'} + '@aws-sdk/util-user-agent-node@3.678.0': + resolution: {integrity: sha512-bKRemCdHMPAlEYE9KuQiMQG9/b4n8C+9DlJAL/X00Q7Zvm9Gv6h0+i5EZ+Xx8sbHq5oUv9a4W4tb+nkUZ0ltpw==} + engines: {node: '>=16.0.0'} peerDependencies: aws-crt: '>=1.0.0' peerDependenciesMeta: aws-crt: optional: true - '@aws-sdk/util-utf8-browser@3.259.0': - resolution: {integrity: sha512-UvFa/vR+e19XookZF8RzFZBrw2EUkQWxiBW0yYQAhvk3C+QVGl0H3ouca8LDBlBfQKXwmW3huo/59H8rwb1wJw==} - - '@babel/code-frame@7.23.5': - resolution: {integrity: sha512-CgH3s1a96LipHCmSUmYFPwY7MNx8C3avkq7i4Wl3cfa662ldtUe4VM1TPXX70pfmrlWTb6jLqTYrZyT2ZTJBgA==} + '@babel/code-frame@7.25.9': + resolution: {integrity: sha512-z88xeGxnzehn2sqZ8UdGQEvYErF1odv2CftxInpSYJt6uHuPe9YjahKZITGs3l5LeI9d2ROG+obuDAoSlqbNfQ==} engines: {node: '>=6.9.0'} - '@babel/compat-data@7.23.5': - resolution: {integrity: sha512-uU27kfDRlhfKl+w1U6vp16IuvSLtjAxdArVXPa9BvLkrr7CYIsxH5adpHObeAGY/41+syctUWOZ140a2Rvkgjw==} + '@babel/compat-data@7.25.9': + resolution: {integrity: sha512-yD+hEuJ/+wAJ4Ox2/rpNv5HIuPG82x3ZlQvYVn8iYCprdxzE7P1udpGF1jyjQVBU4dgznN+k2h103vxZ7NdPyw==} engines: {node: '>=6.9.0'} - '@babel/core@7.23.9': - resolution: {integrity: sha512-5q0175NOjddqpvvzU+kDiSOAk4PfdO6FvwCWoQ6RO7rTzEe8vlo+4HVfcnAREhD4npMs0e9uZypjTwzZPCf/cw==} + '@babel/core@7.25.9': + resolution: {integrity: sha512-WYvQviPw+Qyib0v92AwNIrdLISTp7RfDkM7bPqBvpbnhY4wq8HvHBZREVdYDXk98C8BkOIVnHAY3yvj7AVISxQ==} engines: {node: '>=6.9.0'} - '@babel/generator@7.23.6': - resolution: {integrity: sha512-qrSfCYxYQB5owCmGLbl8XRpX1ytXlpueOb0N0UmQwA073KZxejgQTzAmJezxvpwQD9uGtK2shHdi55QT+MbjIw==} + '@babel/generator@7.25.9': + resolution: {integrity: sha512-omlUGkr5EaoIJrhLf9CJ0TvjBRpd9+AXRG//0GEQ9THSo8wPiTlbpy1/Ow8ZTrbXpjd9FHXfbFQx32I04ht0FA==} engines: {node: '>=6.9.0'} - '@babel/helper-annotate-as-pure@7.22.5': - resolution: {integrity: sha512-LvBTxu8bQSQkcyKOU+a1btnNFQ1dMAd0R6PyW3arXes06F6QLWLIrd681bxRPIXlrMGR3XYnW9JyML7dP3qgxg==} + '@babel/helper-annotate-as-pure@7.25.9': + resolution: {integrity: sha512-gv7320KBUFJz1RnylIg5WWYPRXKZ884AGkYpgpWW02TH66Dl+HaC1t1CKd0z3R4b6hdYEcmrNZHUmfCP+1u3/g==} engines: {node: '>=6.9.0'} - '@babel/helper-builder-binary-assignment-operator-visitor@7.22.15': - resolution: {integrity: sha512-QkBXwGgaoC2GtGZRoma6kv7Szfv06khvhFav67ZExau2RaXzy8MpHSMO2PNoP2XtmQphJQRHFfg77Bq731Yizw==} + '@babel/helper-builder-binary-assignment-operator-visitor@7.25.9': + resolution: {integrity: sha512-C47lC7LIDCnz0h4vai/tpNOI95tCd5ZT3iBt/DBH5lXKHZsyNQv18yf1wIIg2ntiQNgmAvA+DgZ82iW8Qdym8g==} engines: {node: '>=6.9.0'} - '@babel/helper-compilation-targets@7.23.6': - resolution: {integrity: sha512-9JB548GZoQVmzrFgp8o7KxdgkTGm6xs9DW0o/Pim72UDjzr5ObUQ6ZzYPqA+g9OTS2bBQoctLJrky0RDCAWRgQ==} + '@babel/helper-compilation-targets@7.25.9': + resolution: {integrity: sha512-j9Db8Suy6yV/VHa4qzrj9yZfZxhLWQdVnRlXxmKLYlhWUVB1sB2G5sxuWYXk/whHD9iW76PmNzxZ4UCnTQTVEQ==} engines: {node: '>=6.9.0'} - '@babel/helper-create-class-features-plugin@7.23.10': - resolution: {integrity: sha512-2XpP2XhkXzgxecPNEEK8Vz8Asj9aRxt08oKOqtiZoqV2UGZ5T+EkyP9sXQ9nwMxBIG34a7jmasVqoMop7VdPUw==} + '@babel/helper-create-class-features-plugin@7.25.9': + resolution: {integrity: sha512-UTZQMvt0d/rSz6KI+qdu7GQze5TIajwTS++GUozlw8VBJDEOAqSXwm1WvmYEZwqdqSGQshRocPDqrt4HBZB3fQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0 - '@babel/helper-create-regexp-features-plugin@7.22.15': - resolution: {integrity: sha512-29FkPLFjn4TPEa3RE7GpW+qbE8tlsu3jntNYNfcGsc49LphF1PQIiD+vMZ1z1xVOKt+93khA9tc2JBs3kBjA7w==} + '@babel/helper-create-regexp-features-plugin@7.25.9': + resolution: {integrity: sha512-ORPNZ3h6ZRkOyAa/SaHU+XsLZr0UQzRwuDQ0cczIA17nAzZ+85G5cVkOJIj7QavLZGSe8QXUmNFxSZzjcZF9bw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0 - '@babel/helper-define-polyfill-provider@0.5.0': - resolution: {integrity: sha512-NovQquuQLAQ5HuyjCz7WQP9MjRj7dx++yspwiyUiGl9ZyadHRSql1HZh5ogRd8W8w6YM6EQ/NTB8rgjLt5W65Q==} + '@babel/helper-define-polyfill-provider@0.6.2': + resolution: {integrity: sha512-LV76g+C502biUK6AyZ3LK10vDpDyCzZnhZFXkH1L75zHPj68+qc8Zfpx2th+gzwA2MzyK+1g/3EPl62yFnVttQ==} peerDependencies: '@babel/core': ^7.4.0 || ^8.0.0-0 <8.0.0 - '@babel/helper-environment-visitor@7.22.20': - resolution: {integrity: sha512-zfedSIzFhat/gFhWfHtgWvlec0nqB9YEIVrpuwjruLlXfUSnA8cJB0miHKwqDnQ7d32aKo2xt88/xZptwxbfhA==} - engines: {node: '>=6.9.0'} - - '@babel/helper-function-name@7.23.0': - resolution: {integrity: sha512-OErEqsrxjZTJciZ4Oo+eoZqeW9UIiOcuYKRJA4ZAgV9myA+pOXhhmpfNCKjEH/auVfEYVFJ6y1Tc4r0eIApqiw==} + '@babel/helper-member-expression-to-functions@7.25.9': + resolution: {integrity: sha512-wbfdZ9w5vk0C0oyHqAJbc62+vet5prjj01jjJ8sKn3j9h3MQQlflEdXYvuqRWjHnM12coDEqiC1IRCi0U/EKwQ==} engines: {node: '>=6.9.0'} - '@babel/helper-hoist-variables@7.22.5': - resolution: {integrity: sha512-wGjk9QZVzvknA6yKIUURb8zY3grXCcOZt+/7Wcy8O2uctxhplmUPkOdlgoNhmdVee2c92JXbf1xpMtVNbfoxRw==} + '@babel/helper-module-imports@7.25.9': + resolution: {integrity: sha512-tnUA4RsrmflIM6W6RFTLFSXITtl0wKjgpnLgXyowocVPrbYrLUXSBXDgTs8BlbmIzIdlBySRQjINYs2BAkiLtw==} engines: {node: '>=6.9.0'} - '@babel/helper-member-expression-to-functions@7.23.0': - resolution: {integrity: sha512-6gfrPwh7OuT6gZyJZvd6WbTfrqAo7vm4xCzAXOusKqq/vWdKXphTpj5klHKNmRUU6/QRGlBsyU9mAIPaWHlqJA==} - engines: {node: '>=6.9.0'} - - '@babel/helper-module-imports@7.22.15': - resolution: {integrity: sha512-0pYVBnDKZO2fnSPCrgM/6WMc7eS20Fbok+0r88fp+YtWVLZrp4CkafFGIp+W0VKw4a22sgebPT99y+FDNMdP4w==} - engines: {node: '>=6.9.0'} - - '@babel/helper-module-transforms@7.23.3': - resolution: {integrity: sha512-7bBs4ED9OmswdfDzpz4MpWgSrV7FXlc3zIagvLFjS5H+Mk7Snr21vQ6QwrsoCGMfNC4e4LQPdoULEt4ykz0SRQ==} + '@babel/helper-module-transforms@7.25.9': + resolution: {integrity: sha512-TvLZY/F3+GvdRYFZFyxMvnsKi+4oJdgZzU3BoGN9Uc2d9C6zfNwJcKKhjqLAhK8i46mv93jsO74fDh3ih6rpHA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0 - '@babel/helper-optimise-call-expression@7.22.5': - resolution: {integrity: sha512-HBwaojN0xFRx4yIvpwGqxiV2tUfl7401jlok564NgB9EHS1y6QT17FmKWm4ztqjeVdXLuC4fSvHc5ePpQjoTbw==} + '@babel/helper-optimise-call-expression@7.25.9': + resolution: {integrity: sha512-FIpuNaz5ow8VyrYcnXQTDRGvV6tTjkNtCK/RYNDXGSLlUD6cBuQTSw43CShGxjvfBTfcUA/r6UhUCbtYqkhcuQ==} engines: {node: '>=6.9.0'} - '@babel/helper-plugin-utils@7.22.5': - resolution: {integrity: sha512-uLls06UVKgFG9QD4OeFYLEGteMIAa5kpTPcFL28yuCIIzsf6ZyKZMllKVOCZFhiZ5ptnwX4mtKdWCBE/uT4amg==} + '@babel/helper-plugin-utils@7.25.9': + resolution: {integrity: sha512-kSMlyUVdWe25rEsRGviIgOWnoT/nfABVWlqt9N19/dIPWViAOW2s9wznP5tURbs/IDuNk4gPy3YdYRgH3uxhBw==} engines: {node: '>=6.9.0'} - '@babel/helper-remap-async-to-generator@7.22.20': - resolution: {integrity: sha512-pBGyV4uBqOns+0UvhsTO8qgl8hO89PmiDYv+/COyp1aeMcmfrfruz+/nCMFiYyFF/Knn0yfrC85ZzNFjembFTw==} + '@babel/helper-remap-async-to-generator@7.25.9': + resolution: {integrity: sha512-IZtukuUeBbhgOcaW2s06OXTzVNJR0ybm4W5xC1opWFFJMZbwRj5LCk+ByYH7WdZPZTt8KnFwA8pvjN2yqcPlgw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0 - '@babel/helper-replace-supers@7.22.20': - resolution: {integrity: sha512-qsW0In3dbwQUbK8kejJ4R7IHVGwHJlV6lpG6UA7a9hSa2YEiAib+N1T2kr6PEeUT+Fl7najmSOS6SmAwCHK6Tw==} + '@babel/helper-replace-supers@7.25.9': + resolution: {integrity: sha512-IiDqTOTBQy0sWyeXyGSC5TBJpGFXBkRynjBeXsvbhQFKj2viwJC76Epz35YLU1fpe/Am6Vppb7W7zM4fPQzLsQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0 - '@babel/helper-simple-access@7.22.5': - resolution: {integrity: sha512-n0H99E/K+Bika3++WNL17POvo4rKWZ7lZEp1Q+fStVbUi8nxPQEBOlTmCOxW/0JsS56SKKQ+ojAe2pHKJHN35w==} - engines: {node: '>=6.9.0'} - - '@babel/helper-skip-transparent-expression-wrappers@7.22.5': - resolution: {integrity: sha512-tK14r66JZKiC43p8Ki33yLBVJKlQDFoA8GYN67lWCDCqoL6EMMSuM9b+Iff2jHaM/RRFYl7K+iiru7hbRqNx8Q==} + '@babel/helper-simple-access@7.25.9': + resolution: {integrity: sha512-c6WHXuiaRsJTyHYLJV75t9IqsmTbItYfdj99PnzYGQZkYKvan5/2jKJ7gu31J3/BJ/A18grImSPModuyG/Eo0Q==} engines: {node: '>=6.9.0'} - '@babel/helper-split-export-declaration@7.22.6': - resolution: {integrity: sha512-AsUnxuLhRYsisFiaJwvp1QF+I3KjD5FOxut14q/GzovUe6orHLesW2C7d754kRm53h5gqrz6sFl6sxc4BVtE/g==} + '@babel/helper-skip-transparent-expression-wrappers@7.25.9': + resolution: {integrity: sha512-K4Du3BFa3gvyhzgPcntrkDgZzQaq6uozzcpGbOO1OEJaI+EJdqWIMTLgFgQf6lrfiDFo5FU+BxKepI9RmZqahA==} engines: {node: '>=6.9.0'} - '@babel/helper-string-parser@7.23.4': - resolution: {integrity: sha512-803gmbQdqwdf4olxrX4AJyFBV/RTr3rSmOj0rKwesmzlfhYNDEs+/iOcznzpNWlJlIlTJC2QfPFcHB6DlzdVLQ==} + '@babel/helper-string-parser@7.25.9': + resolution: {integrity: sha512-4A/SCr/2KLd5jrtOMFzaKjVtAei3+2r/NChoBNoZ3EyP/+GlhoaEGoWOZUmFmoITP7zOJyHIMm+DYRd8o3PvHA==} engines: {node: '>=6.9.0'} - '@babel/helper-validator-identifier@7.22.20': - resolution: {integrity: sha512-Y4OZ+ytlatR8AI+8KZfKuL5urKp7qey08ha31L8b3BwewJAoJamTzyvxPR/5D+KkdJCGPq/+8TukHBlY10FX9A==} + '@babel/helper-validator-identifier@7.25.9': + resolution: {integrity: sha512-Ed61U6XJc3CVRfkERJWDz4dJwKe7iLmmJsbOGu9wSloNSFttHV0I8g6UAgb7qnK5ly5bGLPd4oXZlxCdANBOWQ==} engines: {node: '>=6.9.0'} - '@babel/helper-validator-option@7.23.5': - resolution: {integrity: sha512-85ttAOMLsr53VgXkTbkx8oA6YTfT4q7/HzXSLEYmjcSTJPMPQtvq1BD79Byep5xMUYbGRzEpDsjUf3dyp54IKw==} + '@babel/helper-validator-option@7.25.9': + resolution: {integrity: sha512-e/zv1co8pp55dNdEcCynfj9X7nyUKUXoUEwfXqaZt0omVOmDe9oOTdKStH4GmAw6zxMFs50ZayuMfHDKlO7Tfw==} engines: {node: '>=6.9.0'} - '@babel/helper-wrap-function@7.22.20': - resolution: {integrity: sha512-pms/UwkOpnQe/PDAEdV/d7dVCoBbB+R4FvYoHGZz+4VPcg7RtYy2KP7S2lbuWM6FCSgob5wshfGESbC/hzNXZw==} + '@babel/helper-wrap-function@7.25.9': + resolution: {integrity: sha512-ETzz9UTjQSTmw39GboatdymDq4XIQbR8ySgVrylRhPOFpsd+JrKHIuF0de7GCWmem+T4uC5z7EZguod7Wj4A4g==} engines: {node: '>=6.9.0'} - '@babel/helpers@7.23.9': - resolution: {integrity: sha512-87ICKgU5t5SzOT7sBMfCOZQ2rHjRU+Pcb9BoILMYz600W6DkVRLFBPwQ18gwUVvggqXivaUakpnxWQGbpywbBQ==} + '@babel/helpers@7.25.9': + resolution: {integrity: sha512-oKWp3+usOJSzDZOucZUAMayhPz/xVjzymyDzUN8dk0Wd3RWMlGLXi07UCQ/CgQVb8LvXx3XBajJH4XGgkt7H7g==} engines: {node: '>=6.9.0'} - '@babel/highlight@7.23.4': - resolution: {integrity: sha512-acGdbYSfp2WheJoJm/EBBBLh/ID8KDc64ISZ9DYtBmC8/Q204PZJLHyzeB5qMzJ5trcOkybd78M4x2KWsUq++A==} + '@babel/highlight@7.25.9': + resolution: {integrity: sha512-llL88JShoCsth8fF8R4SJnIn+WLvR6ccFxu1H3FlMhDontdcmZWf2HgIZ7AIqV3Xcck1idlohrN4EUBQz6klbw==} engines: {node: '>=6.9.0'} - '@babel/parser@7.23.9': - resolution: {integrity: sha512-9tcKgqKbs3xGJ+NtKF2ndOBBLVwPjl1SHxPQkd36r3Dlirw3xWUeGaTbqr7uGZcTaxkVNwc+03SVP7aCdWrTlA==} + '@babel/parser@7.25.9': + resolution: {integrity: sha512-aI3jjAAO1fh7vY/pBGsn1i9LDbRP43+asrRlkPuTXW5yHXtd1NgTEMudbBoDDxrf1daEEfPJqR+JBMakzrR4Dg==} engines: {node: '>=6.0.0'} hasBin: true - '@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression@7.23.3': - resolution: {integrity: sha512-iRkKcCqb7iGnq9+3G6rZ+Ciz5VywC4XNRHe57lKM+jOeYAoR0lVqdeeDRfh0tQcTfw/+vBhHn926FmQhLtlFLQ==} + '@babel/plugin-bugfix-firefox-class-in-computed-class-key@7.25.9': + resolution: {integrity: sha512-ZkRyVkThtxQ/J6nv3JFYv1RYY+JT5BvU0y3k5bWrmuG4woXypRa4PXmm9RhOwodRkYFWqC0C0cqcJ4OqR7kW+g==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0 - '@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining@7.23.3': - resolution: {integrity: sha512-WwlxbfMNdVEpQjZmK5mhm7oSwD3dS6eU+Iwsi4Knl9wAletWem7kaRsGOG+8UEbRyqxY4SS5zvtfXwX+jMxUwQ==} - engines: {node: '>=6.9.0'} - peerDependencies: - '@babel/core': ^7.13.0 - - '@babel/plugin-bugfix-v8-static-class-fields-redefine-readonly@7.23.7': - resolution: {integrity: sha512-LlRT7HgaifEpQA1ZgLVOIJZZFVPWN5iReq/7/JixwBtwcoeVGDBD53ZV28rrsLYOZs1Y/EHhA8N/Z6aazHR8cw==} + '@babel/plugin-bugfix-safari-class-field-initializer-scope@7.25.9': + resolution: {integrity: sha512-MrGRLZxLD/Zjj0gdU15dfs+HH/OXvnw/U4jJD8vpcP2CJQapPEv1IWwjc/qMg7ItBlPwSv1hRBbb7LeuANdcnw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0 - '@babel/plugin-proposal-private-property-in-object@7.21.0-placeholder-for-preset-env.2': - resolution: {integrity: sha512-SOSkfJDddaM7mak6cPEpswyTRnuRltl429hMraQEglW+OkovnCzsiszTmsrlY//qLFjCpQDFRvjdm2wA5pPm9w==} + '@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression@7.25.9': + resolution: {integrity: sha512-2qUwwfAFpJLZqxd02YW9btUCZHl+RFvdDkNfZwaIJrvB8Tesjsk8pEQkTvGwZXLqXUx/2oyY3ySRhm6HOXuCug==} engines: {node: '>=6.9.0'} peerDependencies: - '@babel/core': ^7.0.0-0 - - '@babel/plugin-syntax-async-generators@7.8.4': - resolution: {integrity: sha512-tycmZxkGfZaxhMRbXlPXuVFpdWlXpir2W4AMhSJgRKzk/eDlIXOhb2LHWoLpDF7TEHylV5zNhykX6KAgHJmTNw==} - peerDependencies: - '@babel/core': ^7.0.0-0 - - '@babel/plugin-syntax-class-properties@7.12.13': - resolution: {integrity: sha512-fm4idjKla0YahUNgFNLCB0qySdsoPiZP3iQE3rky0mBUtMZ23yDJ9SJdg6dXTSDnulOVqiF3Hgr9nbXvXTQZYA==} - peerDependencies: - '@babel/core': ^7.0.0-0 + '@babel/core': ^7.0.0 - '@babel/plugin-syntax-class-static-block@7.14.5': - resolution: {integrity: sha512-b+YyPmr6ldyNnM6sqYeMWE+bgJcJpO6yS4QD7ymxgH34GBPNDM/THBh8iunyvKIZztiwLH4CJZ0RxTk9emgpjw==} + '@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining@7.25.9': + resolution: {integrity: sha512-6xWgLZTJXwilVjlnV7ospI3xi+sl8lN8rXXbBD6vYn3UYDlGsag8wrZkKcSI8G6KgqKP7vNFaDgeDnfAABq61g==} engines: {node: '>=6.9.0'} peerDependencies: - '@babel/core': ^7.0.0-0 - - '@babel/plugin-syntax-dynamic-import@7.8.3': - resolution: {integrity: sha512-5gdGbFon+PszYzqs83S3E5mpi7/y/8M9eC90MRTZfduQOYW76ig6SOSPNe41IG5LoP3FGBn2N0RjVDSQiS94kQ==} - peerDependencies: - '@babel/core': ^7.0.0-0 - - '@babel/plugin-syntax-export-namespace-from@7.8.3': - resolution: {integrity: sha512-MXf5laXo6c1IbEbegDmzGPwGNTsHZmEy6QGznu5Sh2UCWvueywb2ee+CCE4zQiZstxU9BMoQO9i6zUFSY0Kj0Q==} - peerDependencies: - '@babel/core': ^7.0.0-0 + '@babel/core': ^7.13.0 - '@babel/plugin-syntax-import-assertions@7.23.3': - resolution: {integrity: sha512-lPgDSU+SJLK3xmFDTV2ZRQAiM7UuUjGidwBywFavObCiZc1BeAAcMtHJKUya92hPHO+at63JJPLygilZard8jw==} + '@babel/plugin-bugfix-v8-static-class-fields-redefine-readonly@7.25.9': + resolution: {integrity: sha512-aLnMXYPnzwwqhYSCyXfKkIkYgJ8zv9RK+roo9DkTXz38ynIhd9XCbN08s3MGvqL2MYGVUGdRQLL/JqBIeJhJBg==} engines: {node: '>=6.9.0'} peerDependencies: - '@babel/core': ^7.0.0-0 + '@babel/core': ^7.0.0 - '@babel/plugin-syntax-import-attributes@7.23.3': - resolution: {integrity: sha512-pawnE0P9g10xgoP7yKr6CK63K2FMsTE+FZidZO/1PwRdzmAPVs+HS1mAURUsgaoxammTJvULUdIkEK0gOcU2tA==} + '@babel/plugin-proposal-private-property-in-object@7.21.0-placeholder-for-preset-env.2': + resolution: {integrity: sha512-SOSkfJDddaM7mak6cPEpswyTRnuRltl429hMraQEglW+OkovnCzsiszTmsrlY//qLFjCpQDFRvjdm2wA5pPm9w==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-syntax-import-meta@7.10.4': - resolution: {integrity: sha512-Yqfm+XDx0+Prh3VSeEQCPU81yC+JWZ2pDPFSS4ZdpfZhp4MkFMaDC1UqseovEKwSUpnIL7+vK+Clp7bfh0iD7g==} - peerDependencies: - '@babel/core': ^7.0.0-0 - - '@babel/plugin-syntax-json-strings@7.8.3': - resolution: {integrity: sha512-lY6kdGpWHvjoe2vk4WrAapEuBR69EMxZl+RoGRhrFGNYVK8mOPAW8VfbT/ZgrFbXlDNiiaxQnAtgVCZ6jv30EA==} - peerDependencies: - '@babel/core': ^7.0.0-0 - - '@babel/plugin-syntax-jsx@7.23.3': - resolution: {integrity: sha512-EB2MELswq55OHUoRZLGg/zC7QWUKfNLpE57m/S2yr1uEneIgsTgrSzXP3NXEsMkVn76OlaVVnzN+ugObuYGwhg==} + '@babel/plugin-syntax-import-assertions@7.25.9': + resolution: {integrity: sha512-4GHX5uzr5QMOOuzV0an9MFju4hKlm0OyePl/lHhcsTVae5t/IKVHnb8W67Vr6FuLlk5lPqLB7n7O+K5R46emYg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-syntax-logical-assignment-operators@7.10.4': - resolution: {integrity: sha512-d8waShlpFDinQ5MtvGU9xDAOzKH47+FFoney2baFIoMr952hKOLp1HR7VszoZvOsV/4+RRszNY7D17ba0te0ig==} - peerDependencies: - '@babel/core': ^7.0.0-0 - - '@babel/plugin-syntax-nullish-coalescing-operator@7.8.3': - resolution: {integrity: sha512-aSff4zPII1u2QD7y+F8oDsz19ew4IGEJg9SVW+bqwpwtfFleiQDMdzA/R+UlWDzfnHFCxxleFT0PMIrR36XLNQ==} - peerDependencies: - '@babel/core': ^7.0.0-0 - - '@babel/plugin-syntax-numeric-separator@7.10.4': - resolution: {integrity: sha512-9H6YdfkcK/uOnY/K7/aA2xpzaAgkQn37yzWUMRK7OaPOqOpGS1+n0H5hxT9AUw9EsSjPW8SVyMJwYRtWs3X3ug==} - peerDependencies: - '@babel/core': ^7.0.0-0 - - '@babel/plugin-syntax-object-rest-spread@7.8.3': - resolution: {integrity: sha512-XoqMijGZb9y3y2XskN+P1wUGiVwWZ5JmoDRwx5+3GmEplNyVM2s2Dg8ILFQm8rWM48orGy5YpI5Bl8U1y7ydlA==} - peerDependencies: - '@babel/core': ^7.0.0-0 - - '@babel/plugin-syntax-optional-catch-binding@7.8.3': - resolution: {integrity: sha512-6VPD0Pc1lpTqw0aKoeRTMiB+kWhAoT24PA+ksWSBrFtl5SIRVpZlwN3NNPQjehA2E/91FV3RjLWoVTglWcSV3Q==} - peerDependencies: - '@babel/core': ^7.0.0-0 - - '@babel/plugin-syntax-optional-chaining@7.8.3': - resolution: {integrity: sha512-KoK9ErH1MBlCPxV0VANkXW2/dw4vlbGDrFgz8bmUsBGYkFRcbRwMh6cIJubdPrkxRwuGdtCk0v/wPTKbQgBjkg==} - peerDependencies: - '@babel/core': ^7.0.0-0 - - '@babel/plugin-syntax-private-property-in-object@7.14.5': - resolution: {integrity: sha512-0wVnp9dxJ72ZUJDV27ZfbSj6iHLoytYZmh3rFcxNnvsJF3ktkzLDZPy/mA17HGsaQT3/DQsWYX1f1QGWkCoVUg==} + '@babel/plugin-syntax-import-attributes@7.25.9': + resolution: {integrity: sha512-u3EN9ub8LyYvgTnrgp8gboElouayiwPdnM7x5tcnW3iSt09/lQYPwMNK40I9IUxo7QOZhAsPHCmmuO7EPdruqg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-syntax-top-level-await@7.14.5': - resolution: {integrity: sha512-hx++upLv5U1rgYfwe1xBQUhRmU41NEvpUvrp8jkrSCdvGSnM5/qdRMtylJ6PG5OFkBaHkbTAKTnd3/YyESRHFw==} + '@babel/plugin-syntax-jsx@7.25.9': + resolution: {integrity: sha512-ld6oezHQMZsZfp6pWtbjaNDF2tiiCYYDqQszHt5VV437lewP9aSi2Of99CK0D0XB21k7FLgnLcmQKyKzynfeAA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-syntax-typescript@7.23.3': - resolution: {integrity: sha512-9EiNjVJOMwCO+43TqoTrgQ8jMwcAd0sWyXi9RPfIsLTj4R2MADDDQXELhffaUx/uJv2AYcxBgPwH6j4TIA4ytQ==} + '@babel/plugin-syntax-typescript@7.25.9': + resolution: {integrity: sha512-hjMgRy5hb8uJJjUcdWunWVcoi9bGpJp8p5Ol1229PoN6aytsLwNMgmdftO23wnCLMfVmTwZDWMPNq/D1SY60JQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 @@ -1218,308 +1036,314 @@ packages: peerDependencies: '@babel/core': ^7.0.0 - '@babel/plugin-transform-arrow-functions@7.23.3': - resolution: {integrity: sha512-NzQcQrzaQPkaEwoTm4Mhyl8jI1huEL/WWIEvudjTCMJ9aBZNpsJbMASx7EQECtQQPS/DcnFpo0FIh3LvEO9cxQ==} + '@babel/plugin-transform-arrow-functions@7.25.9': + resolution: {integrity: sha512-6jmooXYIwn9ca5/RylZADJ+EnSxVUS5sjeJ9UPk6RWRzXCmOJCy6dqItPJFpw2cuCangPK4OYr5uhGKcmrm5Qg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-async-generator-functions@7.23.9': - resolution: {integrity: sha512-8Q3veQEDGe14dTYuwagbRtwxQDnytyg1JFu4/HwEMETeofocrB0U0ejBJIXoeG/t2oXZ8kzCyI0ZZfbT80VFNQ==} + '@babel/plugin-transform-async-generator-functions@7.25.9': + resolution: {integrity: sha512-RXV6QAzTBbhDMO9fWwOmwwTuYaiPbggWQ9INdZqAYeSHyG7FzQ+nOZaUUjNwKv9pV3aE4WFqFm1Hnbci5tBCAw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-async-to-generator@7.23.3': - resolution: {integrity: sha512-A7LFsKi4U4fomjqXJlZg/u0ft/n8/7n7lpffUP/ZULx/DtV9SGlNKZolHH6PE8Xl1ngCc0M11OaeZptXVkfKSw==} + '@babel/plugin-transform-async-to-generator@7.25.9': + resolution: {integrity: sha512-NT7Ejn7Z/LjUH0Gv5KsBCxh7BH3fbLTV0ptHvpeMvrt3cPThHfJfst9Wrb7S8EvJ7vRTFI7z+VAvFVEQn/m5zQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-block-scoped-functions@7.23.3': - resolution: {integrity: sha512-vI+0sIaPIO6CNuM9Kk5VmXcMVRiOpDh7w2zZt9GXzmE/9KD70CUEVhvPR/etAeNK/FAEkhxQtXOzVF3EuRL41A==} + '@babel/plugin-transform-block-scoped-functions@7.25.9': + resolution: {integrity: sha512-toHc9fzab0ZfenFpsyYinOX0J/5dgJVA2fm64xPewu7CoYHWEivIWKxkK2rMi4r3yQqLnVmheMXRdG+k239CgA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-block-scoping@7.23.4': - resolution: {integrity: sha512-0QqbP6B6HOh7/8iNR4CQU2Th/bbRtBp4KS9vcaZd1fZ0wSh5Fyssg0UCIHwxh+ka+pNDREbVLQnHCMHKZfPwfw==} + '@babel/plugin-transform-block-scoping@7.25.9': + resolution: {integrity: sha512-1F05O7AYjymAtqbsFETboN1NvBdcnzMerO+zlMyJBEz6WkMdejvGWw9p05iTSjC85RLlBseHHQpYaM4gzJkBGg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-class-properties@7.23.3': - resolution: {integrity: sha512-uM+AN8yCIjDPccsKGlw271xjJtGii+xQIF/uMPS8H15L12jZTsLfF4o5vNO7d/oUguOyfdikHGc/yi9ge4SGIg==} + '@babel/plugin-transform-class-properties@7.25.9': + resolution: {integrity: sha512-bbMAII8GRSkcd0h0b4X+36GksxuheLFjP65ul9w6C3KgAamI3JqErNgSrosX6ZPj+Mpim5VvEbawXxJCyEUV3Q==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-class-static-block@7.23.4': - resolution: {integrity: sha512-nsWu/1M+ggti1SOALj3hfx5FXzAY06fwPJsUZD4/A5e1bWi46VUIWtD+kOX6/IdhXGsXBWllLFDSnqSCdUNydQ==} + '@babel/plugin-transform-class-static-block@7.25.9': + resolution: {integrity: sha512-UIf+72C7YJ+PJ685/PpATbCz00XqiFEzHX5iysRwfvNT0Ko+FaXSvRgLytFSp8xUItrG9pFM/KoBBZDrY/cYyg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.12.0 - '@babel/plugin-transform-classes@7.23.8': - resolution: {integrity: sha512-yAYslGsY1bX6Knmg46RjiCiNSwJKv2IUC8qOdYKqMMr0491SXFhcHqOdRDeCRohOOIzwN/90C6mQ9qAKgrP7dg==} + '@babel/plugin-transform-classes@7.25.9': + resolution: {integrity: sha512-mD8APIXmseE7oZvZgGABDyM34GUmK45Um2TXiBUt7PnuAxrgoSVf123qUzPxEr/+/BHrRn5NMZCdE2m/1F8DGg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-computed-properties@7.23.3': - resolution: {integrity: sha512-dTj83UVTLw/+nbiHqQSFdwO9CbTtwq1DsDqm3CUEtDrZNET5rT5E6bIdTlOftDTDLMYxvxHNEYO4B9SLl8SLZw==} + '@babel/plugin-transform-computed-properties@7.25.9': + resolution: {integrity: sha512-HnBegGqXZR12xbcTHlJ9HGxw1OniltT26J5YpfruGqtUHlz/xKf/G2ak9e+t0rVqrjXa9WOhvYPz1ERfMj23AA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-destructuring@7.23.3': - resolution: {integrity: sha512-n225npDqjDIr967cMScVKHXJs7rout1q+tt50inyBCPkyZ8KxeI6d+GIbSBTT/w/9WdlWDOej3V9HE5Lgk57gw==} + '@babel/plugin-transform-destructuring@7.25.9': + resolution: {integrity: sha512-WkCGb/3ZxXepmMiX101nnGiU+1CAdut8oHyEOHxkKuS1qKpU2SMXE2uSvfz8PBuLd49V6LEsbtyPhWC7fnkgvQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-dotall-regex@7.23.3': - resolution: {integrity: sha512-vgnFYDHAKzFaTVp+mneDsIEbnJ2Np/9ng9iviHw3P/KVcgONxpNULEW/51Z/BaFojG2GI2GwwXck5uV1+1NOYQ==} + '@babel/plugin-transform-dotall-regex@7.25.9': + resolution: {integrity: sha512-t7ZQ7g5trIgSRYhI9pIJtRl64KHotutUJsh4Eze5l7olJv+mRSg4/MmbZ0tv1eeqRbdvo/+trvJD/Oc5DmW2cA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-duplicate-keys@7.23.3': - resolution: {integrity: sha512-RrqQ+BQmU3Oyav3J+7/myfvRCq7Tbz+kKLLshUmMwNlDHExbGL7ARhajvoBJEvc+fCguPPu887N+3RRXBVKZUA==} + '@babel/plugin-transform-duplicate-keys@7.25.9': + resolution: {integrity: sha512-LZxhJ6dvBb/f3x8xwWIuyiAHy56nrRG3PeYTpBkkzkYRRQ6tJLu68lEF5VIqMUZiAV7a8+Tb78nEoMCMcqjXBw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-dynamic-import@7.23.4': - resolution: {integrity: sha512-V6jIbLhdJK86MaLh4Jpghi8ho5fGzt3imHOBu/x0jlBaPYqDoWz4RDXjmMOfnh+JWNaQleEAByZLV0QzBT4YQQ==} + '@babel/plugin-transform-duplicate-named-capturing-groups-regex@7.25.9': + resolution: {integrity: sha512-0UfuJS0EsXbRvKnwcLjFtJy/Sxc5J5jhLHnFhy7u4zih97Hz6tJkLU+O+FMMrNZrosUPxDi6sYxJ/EA8jDiAog==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0 + + '@babel/plugin-transform-dynamic-import@7.25.9': + resolution: {integrity: sha512-GCggjexbmSLaFhqsojeugBpeaRIgWNTcgKVq/0qIteFEqY2A+b9QidYadrWlnbWQUrW5fn+mCvf3tr7OeBFTyg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-exponentiation-operator@7.23.3': - resolution: {integrity: sha512-5fhCsl1odX96u7ILKHBj4/Y8vipoqwsJMh4csSA8qFfxrZDEA4Ssku2DyNvMJSmZNOEBT750LfFPbtrnTP90BQ==} + '@babel/plugin-transform-exponentiation-operator@7.25.9': + resolution: {integrity: sha512-KRhdhlVk2nObA5AYa7QMgTMTVJdfHprfpAk4DjZVtllqRg9qarilstTKEhpVjyt+Npi8ThRyiV8176Am3CodPA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-export-namespace-from@7.23.4': - resolution: {integrity: sha512-GzuSBcKkx62dGzZI1WVgTWvkkz84FZO5TC5T8dl/Tht/rAla6Dg/Mz9Yhypg+ezVACf/rgDuQt3kbWEv7LdUDQ==} + '@babel/plugin-transform-export-namespace-from@7.25.9': + resolution: {integrity: sha512-2NsEz+CxzJIVOPx2o9UsW1rXLqtChtLoVnwYHHiB04wS5sgn7mrV45fWMBX0Kk+ub9uXytVYfNP2HjbVbCB3Ww==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-for-of@7.23.6': - resolution: {integrity: sha512-aYH4ytZ0qSuBbpfhuofbg/e96oQ7U2w1Aw/UQmKT+1l39uEhUPoFS3fHevDc1G0OvewyDudfMKY1OulczHzWIw==} + '@babel/plugin-transform-for-of@7.25.9': + resolution: {integrity: sha512-LqHxduHoaGELJl2uhImHwRQudhCM50pT46rIBNvtT/Oql3nqiS3wOwP+5ten7NpYSXrrVLgtZU3DZmPtWZo16A==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-function-name@7.23.3': - resolution: {integrity: sha512-I1QXp1LxIvt8yLaib49dRW5Okt7Q4oaxao6tFVKS/anCdEOMtYwWVKoiOA1p34GOWIZjUK0E+zCp7+l1pfQyiw==} + '@babel/plugin-transform-function-name@7.25.9': + resolution: {integrity: sha512-8lP+Yxjv14Vc5MuWBpJsoUCd3hD6V9DgBon2FVYL4jJgbnVQ9fTgYmonchzZJOVNgzEgbxp4OwAf6xz6M/14XA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-json-strings@7.23.4': - resolution: {integrity: sha512-81nTOqM1dMwZ/aRXQ59zVubN9wHGqk6UtqRK+/q+ciXmRy8fSolhGVvG09HHRGo4l6fr/c4ZhXUQH0uFW7PZbg==} + '@babel/plugin-transform-json-strings@7.25.9': + resolution: {integrity: sha512-xoTMk0WXceiiIvsaquQQUaLLXSW1KJ159KP87VilruQm0LNNGxWzahxSS6T6i4Zg3ezp4vA4zuwiNUR53qmQAw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-literals@7.23.3': - resolution: {integrity: sha512-wZ0PIXRxnwZvl9AYpqNUxpZ5BiTGrYt7kueGQ+N5FiQ7RCOD4cm8iShd6S6ggfVIWaJf2EMk8eRzAh52RfP4rQ==} + '@babel/plugin-transform-literals@7.25.9': + resolution: {integrity: sha512-9N7+2lFziW8W9pBl2TzaNht3+pgMIRP74zizeCSrtnSKVdUl8mAjjOP2OOVQAfZ881P2cNjDj1uAMEdeD50nuQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-logical-assignment-operators@7.23.4': - resolution: {integrity: sha512-Mc/ALf1rmZTP4JKKEhUwiORU+vcfarFVLfcFiolKUo6sewoxSEgl36ak5t+4WamRsNr6nzjZXQjM35WsU+9vbg==} + '@babel/plugin-transform-logical-assignment-operators@7.25.9': + resolution: {integrity: sha512-wI4wRAzGko551Y8eVf6iOY9EouIDTtPb0ByZx+ktDGHwv6bHFimrgJM/2T021txPZ2s4c7bqvHbd+vXG6K948Q==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-member-expression-literals@7.23.3': - resolution: {integrity: sha512-sC3LdDBDi5x96LA+Ytekz2ZPk8i/Ck+DEuDbRAll5rknJ5XRTSaPKEYwomLcs1AA8wg9b3KjIQRsnApj+q51Ag==} + '@babel/plugin-transform-member-expression-literals@7.25.9': + resolution: {integrity: sha512-PYazBVfofCQkkMzh2P6IdIUaCEWni3iYEerAsRWuVd8+jlM1S9S9cz1dF9hIzyoZ8IA3+OwVYIp9v9e+GbgZhA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-modules-amd@7.23.3': - resolution: {integrity: sha512-vJYQGxeKM4t8hYCKVBlZX/gtIY2I7mRGFNcm85sgXGMTBcoV3QdVtdpbcWEbzbfUIUZKwvgFT82mRvaQIebZzw==} + '@babel/plugin-transform-modules-amd@7.25.9': + resolution: {integrity: sha512-g5T11tnI36jVClQlMlt4qKDLlWnG5pP9CSM4GhdRciTNMRgkfpo5cR6b4rGIOYPgRRuFAvwjPQ/Yk+ql4dyhbw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-modules-commonjs@7.23.3': - resolution: {integrity: sha512-aVS0F65LKsdNOtcz6FRCpE4OgsP2OFnW46qNxNIX9h3wuzaNcSQsJysuMwqSibC98HPrf2vCgtxKNwS0DAlgcA==} + '@babel/plugin-transform-modules-commonjs@7.25.9': + resolution: {integrity: sha512-dwh2Ol1jWwL2MgkCzUSOvfmKElqQcuswAZypBSUsScMXvgdT8Ekq5YA6TtqpTVWH+4903NmboMuH1o9i8Rxlyg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-modules-systemjs@7.23.9': - resolution: {integrity: sha512-KDlPRM6sLo4o1FkiSlXoAa8edLXFsKKIda779fbLrvmeuc3itnjCtaO6RrtoaANsIJANj+Vk1zqbZIMhkCAHVw==} + '@babel/plugin-transform-modules-systemjs@7.25.9': + resolution: {integrity: sha512-hyss7iIlH/zLHaehT+xwiymtPOpsiwIIRlCAOwBB04ta5Tt+lNItADdlXw3jAWZ96VJ2jlhl/c+PNIQPKNfvcA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-modules-umd@7.23.3': - resolution: {integrity: sha512-zHsy9iXX2nIsCBFPud3jKn1IRPWg3Ing1qOZgeKV39m1ZgIdpJqvlWVeiHBZC6ITRG0MfskhYe9cLgntfSFPIg==} + '@babel/plugin-transform-modules-umd@7.25.9': + resolution: {integrity: sha512-bS9MVObUgE7ww36HEfwe6g9WakQ0KF07mQF74uuXdkoziUPfKyu/nIm663kz//e5O1nPInPFx36z7WJmJ4yNEw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-named-capturing-groups-regex@7.22.5': - resolution: {integrity: sha512-YgLLKmS3aUBhHaxp5hi1WJTgOUb/NCuDHzGT9z9WTt3YG+CPRhJs6nprbStx6DnWM4dh6gt7SU3sZodbZ08adQ==} + '@babel/plugin-transform-named-capturing-groups-regex@7.25.9': + resolution: {integrity: sha512-oqB6WHdKTGl3q/ItQhpLSnWWOpjUJLsOCLVyeFgeTktkBSCiurvPOsyt93gibI9CmuKvTUEtWmG5VhZD+5T/KA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0 - '@babel/plugin-transform-new-target@7.23.3': - resolution: {integrity: sha512-YJ3xKqtJMAT5/TIZnpAR3I+K+WaDowYbN3xyxI8zxx/Gsypwf9B9h0VB+1Nh6ACAAPRS5NSRje0uVv5i79HYGQ==} + '@babel/plugin-transform-new-target@7.25.9': + resolution: {integrity: sha512-U/3p8X1yCSoKyUj2eOBIx3FOn6pElFOKvAAGf8HTtItuPyB+ZeOqfn+mvTtg9ZlOAjsPdK3ayQEjqHjU/yLeVQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-nullish-coalescing-operator@7.23.4': - resolution: {integrity: sha512-jHE9EVVqHKAQx+VePv5LLGHjmHSJR76vawFPTdlxR/LVJPfOEGxREQwQfjuZEOPTwG92X3LINSh3M40Rv4zpVA==} + '@babel/plugin-transform-nullish-coalescing-operator@7.25.9': + resolution: {integrity: sha512-ENfftpLZw5EItALAD4WsY/KUWvhUlZndm5GC7G3evUsVeSJB6p0pBeLQUnRnBCBx7zV0RKQjR9kCuwrsIrjWog==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-numeric-separator@7.23.4': - resolution: {integrity: sha512-mps6auzgwjRrwKEZA05cOwuDc9FAzoyFS4ZsG/8F43bTLf/TgkJg7QXOrPO1JO599iA3qgK9MXdMGOEC8O1h6Q==} + '@babel/plugin-transform-numeric-separator@7.25.9': + resolution: {integrity: sha512-TlprrJ1GBZ3r6s96Yq8gEQv82s8/5HnCVHtEJScUj90thHQbwe+E5MLhi2bbNHBEJuzrvltXSru+BUxHDoog7Q==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-object-rest-spread@7.23.4': - resolution: {integrity: sha512-9x9K1YyeQVw0iOXJlIzwm8ltobIIv7j2iLyP2jIhEbqPRQ7ScNgwQufU2I0Gq11VjyG4gI4yMXt2VFags+1N3g==} + '@babel/plugin-transform-object-rest-spread@7.25.9': + resolution: {integrity: sha512-fSaXafEE9CVHPweLYw4J0emp1t8zYTXyzN3UuG+lylqkvYd7RMrsOQ8TYx5RF231be0vqtFC6jnx3UmpJmKBYg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-object-super@7.23.3': - resolution: {integrity: sha512-BwQ8q0x2JG+3lxCVFohg+KbQM7plfpBwThdW9A6TMtWwLsbDA01Ek2Zb/AgDN39BiZsExm4qrXxjk+P1/fzGrA==} + '@babel/plugin-transform-object-super@7.25.9': + resolution: {integrity: sha512-Kj/Gh+Rw2RNLbCK1VAWj2U48yxxqL2x0k10nPtSdRa0O2xnHXalD0s+o1A6a0W43gJ00ANo38jxkQreckOzv5A==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-optional-catch-binding@7.23.4': - resolution: {integrity: sha512-XIq8t0rJPHf6Wvmbn9nFxU6ao4c7WhghTR5WyV8SrJfUFzyxhCm4nhC+iAp3HFhbAKLfYpgzhJ6t4XCtVwqO5A==} + '@babel/plugin-transform-optional-catch-binding@7.25.9': + resolution: {integrity: sha512-qM/6m6hQZzDcZF3onzIhZeDHDO43bkNNlOX0i8n3lR6zLbu0GN2d8qfM/IERJZYauhAHSLHy39NF0Ctdvcid7g==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-optional-chaining@7.23.4': - resolution: {integrity: sha512-ZU8y5zWOfjM5vZ+asjgAPwDaBjJzgufjES89Rs4Lpq63O300R/kOz30WCLo6BxxX6QVEilwSlpClnG5cZaikTA==} + '@babel/plugin-transform-optional-chaining@7.25.9': + resolution: {integrity: sha512-6AvV0FsLULbpnXeBjrY4dmWF8F7gf8QnvTEoO/wX/5xm/xE1Xo8oPuD3MPS+KS9f9XBEAWN7X1aWr4z9HdOr7A==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-parameters@7.23.3': - resolution: {integrity: sha512-09lMt6UsUb3/34BbECKVbVwrT9bO6lILWln237z7sLaWnMsTi7Yc9fhX5DLpkJzAGfaReXI22wP41SZmnAA3Vw==} + '@babel/plugin-transform-parameters@7.25.9': + resolution: {integrity: sha512-wzz6MKwpnshBAiRmn4jR8LYz/g8Ksg0o80XmwZDlordjwEk9SxBzTWC7F5ef1jhbrbOW2DJ5J6ayRukrJmnr0g==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-private-methods@7.23.3': - resolution: {integrity: sha512-UzqRcRtWsDMTLrRWFvUBDwmw06tCQH9Rl1uAjfh6ijMSmGYQ+fpdB+cnqRC8EMh5tuuxSv0/TejGL+7vyj+50g==} + '@babel/plugin-transform-private-methods@7.25.9': + resolution: {integrity: sha512-D/JUozNpQLAPUVusvqMxyvjzllRaF8/nSrP1s2YGQT/W4LHK4xxsMcHjhOGTS01mp9Hda8nswb+FblLdJornQw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-private-property-in-object@7.23.4': - resolution: {integrity: sha512-9G3K1YqTq3F4Vt88Djx1UZ79PDyj+yKRnUy7cZGSMe+a7jkwD259uKKuUzQlPkGam7R+8RJwh5z4xO27fA1o2A==} + '@babel/plugin-transform-private-property-in-object@7.25.9': + resolution: {integrity: sha512-Evf3kcMqzXA3xfYJmZ9Pg1OvKdtqsDMSWBDzZOPLvHiTt36E75jLDQo5w1gtRU95Q4E5PDttrTf25Fw8d/uWLw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-property-literals@7.23.3': - resolution: {integrity: sha512-jR3Jn3y7cZp4oEWPFAlRsSWjxKe4PZILGBSd4nis1TsC5qeSpb+nrtihJuDhNI7QHiVbUaiXa0X2RZY3/TI6Nw==} + '@babel/plugin-transform-property-literals@7.25.9': + resolution: {integrity: sha512-IvIUeV5KrS/VPavfSM/Iu+RE6llrHrYIKY1yfCzyO/lMXHQ+p7uGhonmGVisv6tSBSVgWzMBohTcvkC9vQcQFA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-regenerator@7.23.3': - resolution: {integrity: sha512-KP+75h0KghBMcVpuKisx3XTu9Ncut8Q8TuvGO4IhY+9D5DFEckQefOuIsB/gQ2tG71lCke4NMrtIPS8pOj18BQ==} + '@babel/plugin-transform-regenerator@7.25.9': + resolution: {integrity: sha512-vwDcDNsgMPDGP0nMqzahDWE5/MLcX8sv96+wfX7as7LoF/kr97Bo/7fI00lXY4wUXYfVmwIIyG80fGZ1uvt2qg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-reserved-words@7.23.3': - resolution: {integrity: sha512-QnNTazY54YqgGxwIexMZva9gqbPa15t/x9VS+0fsEFWplwVpXYZivtgl43Z1vMpc1bdPP2PP8siFeVcnFvA3Cg==} + '@babel/plugin-transform-reserved-words@7.25.9': + resolution: {integrity: sha512-7DL7DKYjn5Su++4RXu8puKZm2XBPHyjWLUidaPEkCUBbE7IPcsrkRHggAOOKydH1dASWdcUBxrkOGNxUv5P3Jg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-runtime@7.23.9': - resolution: {integrity: sha512-A7clW3a0aSjm3ONU9o2HAILSegJCYlEZmOhmBRReVtIpY/Z/p7yIZ+wR41Z+UipwdGuqwtID/V/dOdZXjwi9gQ==} + '@babel/plugin-transform-runtime@7.25.9': + resolution: {integrity: sha512-nZp7GlEl+yULJrClz0SwHPqir3lc0zsPrDHQUcxGspSL7AKrexNSEfTbfqnDNJUO13bgKyfuOLMF8Xqtu8j3YQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-shorthand-properties@7.23.3': - resolution: {integrity: sha512-ED2fgqZLmexWiN+YNFX26fx4gh5qHDhn1O2gvEhreLW2iI63Sqm4llRLCXALKrCnbN4Jy0VcMQZl/SAzqug/jg==} + '@babel/plugin-transform-shorthand-properties@7.25.9': + resolution: {integrity: sha512-MUv6t0FhO5qHnS/W8XCbHmiRWOphNufpE1IVxhK5kuN3Td9FT1x4rx4K42s3RYdMXCXpfWkGSbCSd0Z64xA7Ng==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-spread@7.23.3': - resolution: {integrity: sha512-VvfVYlrlBVu+77xVTOAoxQ6mZbnIq5FM0aGBSFEcIh03qHf+zNqA4DC/3XMUozTg7bZV3e3mZQ0i13VB6v5yUg==} + '@babel/plugin-transform-spread@7.25.9': + resolution: {integrity: sha512-oNknIB0TbURU5pqJFVbOOFspVlrpVwo2H1+HUIsVDvp5VauGGDP1ZEvO8Nn5xyMEs3dakajOxlmkNW7kNgSm6A==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-sticky-regex@7.23.3': - resolution: {integrity: sha512-HZOyN9g+rtvnOU3Yh7kSxXrKbzgrm5X4GncPY1QOquu7epga5MxKHVpYu2hvQnry/H+JjckSYRb93iNfsioAGg==} + '@babel/plugin-transform-sticky-regex@7.25.9': + resolution: {integrity: sha512-WqBUSgeVwucYDP9U/xNRQam7xV8W5Zf+6Eo7T2SRVUFlhRiMNFdFz58u0KZmCVVqs2i7SHgpRnAhzRNmKfi2uA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-template-literals@7.23.3': - resolution: {integrity: sha512-Flok06AYNp7GV2oJPZZcP9vZdszev6vPBkHLwxwSpaIqx75wn6mUd3UFWsSsA0l8nXAKkyCmL/sR02m8RYGeHg==} + '@babel/plugin-transform-template-literals@7.25.9': + resolution: {integrity: sha512-o97AE4syN71M/lxrCtQByzphAdlYluKPDBzDVzMmfCobUjjhAryZV0AIpRPrxN0eAkxXO6ZLEScmt+PNhj2OTw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-typeof-symbol@7.23.3': - resolution: {integrity: sha512-4t15ViVnaFdrPC74be1gXBSMzXk3B4Us9lP7uLRQHTFpV5Dvt33pn+2MyyNxmN3VTTm3oTrZVMUmuw3oBnQ2oQ==} + '@babel/plugin-transform-typeof-symbol@7.25.9': + resolution: {integrity: sha512-v61XqUMiueJROUv66BVIOi0Fv/CUuZuZMl5NkRoCVxLAnMexZ0A3kMe7vvZ0nulxMuMp0Mk6S5hNh48yki08ZA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-typescript@7.23.6': - resolution: {integrity: sha512-6cBG5mBvUu4VUD04OHKnYzbuHNP8huDsD3EDqqpIpsswTDoqHCjLoHb6+QgsV1WsT2nipRqCPgxD3LXnEO7XfA==} + '@babel/plugin-transform-typescript@7.25.9': + resolution: {integrity: sha512-7PbZQZP50tzv2KGGnhh82GSyMB01yKY9scIjf1a+GfZCtInOWqUH5+1EBU4t9fyR5Oykkkc9vFTs4OHrhHXljQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-unicode-escapes@7.23.3': - resolution: {integrity: sha512-OMCUx/bU6ChE3r4+ZdylEqAjaQgHAgipgW8nsCfu5pGqDcFytVd91AwRvUJSBZDz0exPGgnjoqhgRYLRjFZc9Q==} + '@babel/plugin-transform-unicode-escapes@7.25.9': + resolution: {integrity: sha512-s5EDrE6bW97LtxOcGj1Khcx5AaXwiMmi4toFWRDP9/y0Woo6pXC+iyPu/KuhKtfSrNFd7jJB+/fkOtZy6aIC6Q==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-unicode-property-regex@7.23.3': - resolution: {integrity: sha512-KcLIm+pDZkWZQAFJ9pdfmh89EwVfmNovFBcXko8szpBeF8z68kWIPeKlmSOkT9BXJxs2C0uk+5LxoxIv62MROA==} + '@babel/plugin-transform-unicode-property-regex@7.25.9': + resolution: {integrity: sha512-Jt2d8Ga+QwRluxRQ307Vlxa6dMrYEMZCgGxoPR8V52rxPyldHu3hdlHspxaqYmE7oID5+kB+UKUB/eWS+DkkWg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-unicode-regex@7.23.3': - resolution: {integrity: sha512-wMHpNA4x2cIA32b/ci3AfwNgheiva2W0WUKWTK7vBHBhDKfPsc5cFGNWm69WBqpwd86u1qwZ9PWevKqm1A3yAw==} + '@babel/plugin-transform-unicode-regex@7.25.9': + resolution: {integrity: sha512-yoxstj7Rg9dlNn9UQxzk4fcNivwv4nUYz7fYXBaKxvw/lnmPuOm/ikoELygbYq68Bls3D/D+NBPHiLwZdZZ4HA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-unicode-sets-regex@7.23.3': - resolution: {integrity: sha512-W7lliA/v9bNR83Qc3q1ip9CQMZ09CcHDbHfbLRDNuAhn1Mvkr1ZNF7hPmztMQvtTGVLJ9m8IZqWsTkXOml8dbw==} + '@babel/plugin-transform-unicode-sets-regex@7.25.9': + resolution: {integrity: sha512-8BYqO3GeVNHtx69fdPshN3fnzUNLrWdHhk/icSwigksJGczKSizZ+Z6SBCxTs723Fr5VSNorTIK7a+R2tISvwQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0 - '@babel/preset-env@7.23.9': - resolution: {integrity: sha512-3kBGTNBBk9DQiPoXYS0g0BYlwTQYUTifqgKTjxUwEUkduRT2QOa0FPGBJ+NROQhGyYO5BuTJwGvBnqKDykac6A==} + '@babel/preset-env@7.25.9': + resolution: {integrity: sha512-XqDEt+hfsQukahSX9JOBDHhpUHDhj2zGSxoqWQFCMajOSBnbhBdgON/bU/5PkBA1yX5tqW6tTzuIPVsZTQ7h5Q==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 @@ -1529,36 +1353,33 @@ packages: peerDependencies: '@babel/core': ^7.0.0-0 || ^8.0.0-0 <8.0.0 - '@babel/preset-typescript@7.23.3': - resolution: {integrity: sha512-17oIGVlqz6CchO9RFYn5U6ZpWRZIngayYCtrPRSgANSwC2V1Jb+iP74nVxzzXJte8b8BYxrL1yY96xfhTBrNNQ==} + '@babel/preset-typescript@7.25.9': + resolution: {integrity: sha512-XWxw1AcKk36kgxf4C//fl0ikjLeqGUWn062/Fd8GtpTfDJOX6Ud95FK+4JlDA36BX4bNGndXi3a6Vr4Jo5/61A==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/regjsgen@0.8.0': - resolution: {integrity: sha512-x/rqGMdzj+fWZvCOYForTghzbtqPDZ5gPwaoNGHdgDfF2QA/XZbCBp4Moo5scrkAMPhB7z26XM/AaHuIJdgauA==} - - '@babel/runtime@7.23.9': - resolution: {integrity: sha512-0CX6F+BI2s9dkUqr08KFrAIZgNFj75rdBU/DjCyYLIaV/quFjkk6T+EJ2LkZHyZTbEV4L5p97mNkUsHl2wLFAw==} + '@babel/runtime@7.25.9': + resolution: {integrity: sha512-4zpTHZ9Cm6L9L+uIqghQX8ZXg8HKFcjYO3qHoO8zTmRm6HQUJ8SSJ+KRvbMBZn0EGVlT4DRYeQ/6hjlyXBh+Kg==} engines: {node: '>=6.9.0'} - '@babel/template@7.23.9': - resolution: {integrity: sha512-+xrD2BWLpvHKNmX2QbpdpsBaWnRxahMwJjO+KZk2JOElj5nSmKezyS1B4u+QbHMTX69t4ukm6hh9lsYQ7GHCKA==} + '@babel/template@7.25.9': + resolution: {integrity: sha512-9DGttpmPvIxBb/2uwpVo3dqJ+O6RooAFOS+lB+xDqoE2PVCE8nfoHMdZLpfCQRLwvohzXISPZcgxt80xLfsuwg==} engines: {node: '>=6.9.0'} - '@babel/traverse@7.23.9': - resolution: {integrity: sha512-I/4UJ9vs90OkBtY6iiiTORVMyIhJ4kAVmsKo9KFc8UOxMeUfi2hvtIBsET5u9GizXE6/GFSuKCTNfgCswuEjRg==} + '@babel/traverse@7.25.9': + resolution: {integrity: sha512-ZCuvfwOwlz/bawvAuvcj8rrithP2/N55Tzz342AkTvq4qaWbGfmCk/tKhNaV2cthijKrPAA8SRJV5WWe7IBMJw==} engines: {node: '>=6.9.0'} - '@babel/types@7.23.9': - resolution: {integrity: sha512-dQjSq/7HaSjRM43FFGnv5keM2HsxpmyV1PfaSVm0nzzjwwTmjOe6J4bC8e3+pTEIgHaHj+1ZlLThRJ2auc/w1Q==} + '@babel/types@7.25.9': + resolution: {integrity: sha512-OwS2CM5KocvQ/k7dFJa8i5bNGJP0hXWfVCfDkqRFP1IreH1JDC7wG6eCYCi0+McbfT8OR/kNqsI0UU0xP9H6PQ==} engines: {node: '>=6.9.0'} - '@changesets/apply-release-plan@7.0.0': - resolution: {integrity: sha512-vfi69JR416qC9hWmFGSxj7N6wA5J222XNBmezSVATPWDVPIF7gkd4d8CpbEbXmRWbVrkoli3oerGS6dcL/BGsQ==} + '@changesets/apply-release-plan@7.0.5': + resolution: {integrity: sha512-1cWCk+ZshEkSVEZrm2fSj1Gz8sYvxgUL4Q78+1ZZqeqfuevPTPk033/yUZ3df8BKMohkqqHfzj0HOOrG0KtXTw==} - '@changesets/assemble-release-plan@6.0.0': - resolution: {integrity: sha512-4QG7NuisAjisbW4hkLCmGW2lRYdPrKzro+fCtZaILX+3zdUELSvYjpL4GTv0E4aM9Mef3PuIQp89VmHJ4y2bfw==} + '@changesets/assemble-release-plan@6.0.4': + resolution: {integrity: sha512-nqICnvmrwWj4w2x0fOhVj2QEGdlUuwVAwESrUo5HLzWMI1rE5SWfsr9ln+rDqWB6RQ2ZyaMZHUcU7/IRaUJS+Q==} '@changesets/changelog-git@0.2.0': resolution: {integrity: sha512-bHOx97iFI4OClIT35Lok3sJAwM31VbUM++gnMBV16fdbtBhgYu4dxsphBF/0AZZsyAHMrnM0yFcj5gZM1py6uQ==} @@ -1566,42 +1387,45 @@ packages: '@changesets/changelog-github@0.5.0': resolution: {integrity: sha512-zoeq2LJJVcPJcIotHRJEEA2qCqX0AQIeFE+L21L8sRLPVqDhSXY8ZWAt2sohtBpFZkBwu+LUwMSKRr2lMy3LJA==} - '@changesets/cli@2.27.1': - resolution: {integrity: sha512-iJ91xlvRnnrJnELTp4eJJEOPjgpF3NOh4qeQehM6Ugiz9gJPRZ2t+TsXun6E3AMN4hScZKjqVXl0TX+C7AB3ZQ==} + '@changesets/cli@2.27.9': + resolution: {integrity: sha512-q42a/ZbDnxPpCb5Wkm6tMVIxgeI9C/bexntzTeCFBrQEdpisQqk8kCHllYZMDjYtEc1ZzumbMJAG8H0Z4rdvjg==} hasBin: true - '@changesets/config@3.0.0': - resolution: {integrity: sha512-o/rwLNnAo/+j9Yvw9mkBQOZySDYyOr/q+wptRLcAVGlU6djOeP9v1nlalbL9MFsobuBVQbZCTp+dIzdq+CLQUA==} + '@changesets/config@3.0.3': + resolution: {integrity: sha512-vqgQZMyIcuIpw9nqFIpTSNyc/wgm/Lu1zKN5vECy74u95Qx/Wa9g27HdgO4NkVAaq+BGA8wUc/qvbvVNs93n6A==} '@changesets/errors@0.2.0': resolution: {integrity: sha512-6BLOQUscTpZeGljvyQXlWOItQyU71kCdGz7Pi8H8zdw6BI0g3m43iL4xKUVPWtG+qrrL9DTjpdn8eYuCQSRpow==} - '@changesets/get-dependents-graph@2.0.0': - resolution: {integrity: sha512-cafUXponivK4vBgZ3yLu944mTvam06XEn2IZGjjKc0antpenkYANXiiE6GExV/yKdsCnE8dXVZ25yGqLYZmScA==} + '@changesets/get-dependents-graph@2.1.2': + resolution: {integrity: sha512-sgcHRkiBY9i4zWYBwlVyAjEM9sAzs4wYVwJUdnbDLnVG3QwAaia1Mk5P8M7kraTOZN+vBET7n8KyB0YXCbFRLQ==} '@changesets/get-github-info@0.6.0': resolution: {integrity: sha512-v/TSnFVXI8vzX9/w3DU2Ol+UlTZcu3m0kXTjTT4KlAdwSvwutcByYwyYn9hwerPWfPkT2JfpoX0KgvCEi8Q/SA==} - '@changesets/get-release-plan@4.0.0': - resolution: {integrity: sha512-9L9xCUeD/Tb6L/oKmpm8nyzsOzhdNBBbt/ZNcjynbHC07WW4E1eX8NMGC5g5SbM5z/V+MOrYsJ4lRW41GCbg3w==} + '@changesets/get-release-plan@4.0.4': + resolution: {integrity: sha512-SicG/S67JmPTrdcc9Vpu0wSQt7IiuN0dc8iR5VScnnTVPfIaLvKmEGRvIaF0kcn8u5ZqLbormZNTO77bCEvyWw==} '@changesets/get-version-range-type@0.4.0': resolution: {integrity: sha512-hwawtob9DryoGTpixy1D3ZXbGgJu1Rhr+ySH2PvTLHvkZuQ7sRT4oQwMh0hbqZH1weAooedEjRsbrWcGLCeyVQ==} - '@changesets/git@3.0.0': - resolution: {integrity: sha512-vvhnZDHe2eiBNRFHEgMiGd2CT+164dfYyrJDhwwxTVD/OW0FUD6G7+4DIx1dNwkwjHyzisxGAU96q0sVNBns0w==} + '@changesets/git@3.0.1': + resolution: {integrity: sha512-pdgHcYBLCPcLd82aRcuO0kxCDbw/yISlOtkmwmE8Odo1L6hSiZrBOsRl84eYG7DRCab/iHnOkWqExqc4wxk2LQ==} - '@changesets/logger@0.1.0': - resolution: {integrity: sha512-pBrJm4CQm9VqFVwWnSqKEfsS2ESnwqwH+xR7jETxIErZcfd1u2zBSqrHbRHR7xjhSgep9x2PSKFKY//FAshA3g==} + '@changesets/logger@0.1.1': + resolution: {integrity: sha512-OQtR36ZlnuTxKqoW4Sv6x5YIhOmClRd5pWsjZsddYxpWs517R0HkyiefQPIytCVh4ZcC5x9XaG8KTdd5iRQUfg==} '@changesets/parse@0.4.0': resolution: {integrity: sha512-TS/9KG2CdGXS27S+QxbZXgr8uPsP4yNJYb4BC2/NeFUj80Rni3TeD2qwWmabymxmrLo7JEsytXH1FbpKTbvivw==} - '@changesets/pre@2.0.0': - resolution: {integrity: sha512-HLTNYX/A4jZxc+Sq8D1AMBsv+1qD6rmmJtjsCJa/9MSRybdxh0mjbTvE6JYZQ/ZiQ0mMlDOlGPXTm9KLTU3jyw==} + '@changesets/pre@2.0.1': + resolution: {integrity: sha512-vvBJ/If4jKM4tPz9JdY2kGOgWmCowUYOi5Ycv8dyLnEE8FgpYYUo1mgJZxcdtGGP3aG8rAQulGLyyXGSLkIMTQ==} + + '@changesets/read@0.6.1': + resolution: {integrity: sha512-jYMbyXQk3nwP25nRzQQGa1nKLY0KfoOV7VLgwucI0bUO8t8ZLCr6LZmgjXsiKuRDc+5A6doKPr9w2d+FEJ55zQ==} - '@changesets/read@0.6.0': - resolution: {integrity: sha512-ZypqX8+/im1Fm98K4YcZtmLKgjs1kDQ5zHpc2U1qdtNBmZZfo/IBiG162RoP0CUF05tvp2y4IspH11PLnPxuuw==} + '@changesets/should-skip-package@0.1.1': + resolution: {integrity: sha512-H9LjLbF6mMHLtJIc/eHR9Na+MifJ3VxtgP/Y+XLn4BF7tDTEN1HNYtH6QMcjP1uxp9sjaFYmW8xqloaCi/ckTg==} '@changesets/types@4.1.0': resolution: {integrity: sha512-LDQvVDv5Kb50ny2s25Fhm3d9QSZimsoUGBsUioj6MC3qbMUCuC8GPIvk/M6IvXx3lYhAs0lwWUQLb+VIEUCECw==} @@ -1609,159 +1433,161 @@ packages: '@changesets/types@6.0.0': resolution: {integrity: sha512-b1UkfNulgKoWfqyHtzKS5fOZYSJO+77adgL7DLRDr+/7jhChN+QcHnbjiQVOz/U+Ts3PGNySq7diAItzDgugfQ==} - '@changesets/write@0.3.0': - resolution: {integrity: sha512-slGLb21fxZVUYbyea+94uFiD6ntQW0M2hIKNznFizDhZPDgn2c/fv1UzzlW43RVzh1BEDuIqW6hzlJ1OflNmcw==} + '@changesets/write@0.3.2': + resolution: {integrity: sha512-kDxDrPNpUgsjDbWBvUo27PzKX4gqeKOlhibaOXDJA6kuBisGqNHv/HwGJrAu8U/dSf8ZEFIeHIPtvSlZI1kULw==} '@cspotcode/source-map-support@0.8.1': resolution: {integrity: sha512-IchNf6dN4tHoMFIn/7OE8LWZ19Y6q/67Bmf6vnGREv8RSbBVb9LPJxEcnwrcwX6ixSvaiGoomAUvu4YSxXrVgw==} engines: {node: '>=12'} - '@cypress/request@3.0.1': - resolution: {integrity: sha512-TWivJlJi8ZDx2wGOw1dbLuHJKUYX7bWySw377nlnGOW3hP9/MUKIsEdXT/YngWxVdgNCHRBmFlBipE+5/2ZZlQ==} - engines: {node: '>= 6'} - - '@databeat/tracker@0.9.1': - resolution: {integrity: sha512-lCwkEKRbcioDkchGgMgbGZlZXs3bMKCaxOwyP4wcR6N/nY9+P4Yhg+inUeYk7LhR6+S5jAS4V6VMLpNno+hfEA==} + '@databeat/tracker@0.9.3': + resolution: {integrity: sha512-eGsiNU/CRFujcNtUUqvBiqveCs6S6SiAhalXPDodbk74d3FzvLqHDn5k6WfOEJIhrP3CbYgfMXL0nk51s/rQsg==} '@discoveryjs/json-ext@0.5.7': resolution: {integrity: sha512-dBVuXR082gk3jsFp7Rd/JI4kytwGHecnCoTtXFb7DB6CNHp4rg5k1bhg0nWdLGLnOV71lmDzGQaLMy8iPLY0pw==} engines: {node: '>=10.0.0'} - '@esbuild/aix-ppc64@0.19.12': - resolution: {integrity: sha512-bmoCYyWdEL3wDQIVbcyzRyeKLgk2WtWLTWz1ZIAZF/EGbNOwSA6ew3PftJ1PqMiOOGu0OyFMzG53L0zqIpPeNA==} - engines: {node: '>=12'} + '@esbuild/aix-ppc64@0.23.1': + resolution: {integrity: sha512-6VhYk1diRqrhBAqpJEdjASR/+WVRtfjpqKuNw11cLiaWpAT/Uu+nokB+UJnevzy/P9C/ty6AOe0dwueMrGh/iQ==} + engines: {node: '>=18'} cpu: [ppc64] os: [aix] - '@esbuild/android-arm64@0.19.12': - resolution: {integrity: sha512-P0UVNGIienjZv3f5zq0DP3Nt2IE/3plFzuaS96vihvD0Hd6H/q4WXUGpCxD/E8YrSXfNyRPbpTq+T8ZQioSuPA==} - engines: {node: '>=12'} + '@esbuild/android-arm64@0.23.1': + resolution: {integrity: sha512-xw50ipykXcLstLeWH7WRdQuysJqejuAGPd30vd1i5zSyKK3WE+ijzHmLKxdiCMtH1pHz78rOg0BKSYOSB/2Khw==} + engines: {node: '>=18'} cpu: [arm64] os: [android] - '@esbuild/android-arm@0.19.12': - resolution: {integrity: sha512-qg/Lj1mu3CdQlDEEiWrlC4eaPZ1KztwGJ9B6J+/6G+/4ewxJg7gqj8eVYWvao1bXrqGiW2rsBZFSX3q2lcW05w==} - engines: {node: '>=12'} + '@esbuild/android-arm@0.23.1': + resolution: {integrity: sha512-uz6/tEy2IFm9RYOyvKl88zdzZfwEfKZmnX9Cj1BHjeSGNuGLuMD1kR8y5bteYmwqKm1tj8m4cb/aKEorr6fHWQ==} + engines: {node: '>=18'} cpu: [arm] os: [android] - '@esbuild/android-x64@0.19.12': - resolution: {integrity: sha512-3k7ZoUW6Q6YqhdhIaq/WZ7HwBpnFBlW905Fa4s4qWJyiNOgT1dOqDiVAQFwBH7gBRZr17gLrlFCRzF6jFh7Kew==} - engines: {node: '>=12'} + '@esbuild/android-x64@0.23.1': + resolution: {integrity: sha512-nlN9B69St9BwUoB+jkyU090bru8L0NA3yFvAd7k8dNsVH8bi9a8cUAUSEcEEgTp2z3dbEDGJGfP6VUnkQnlReg==} + engines: {node: '>=18'} cpu: [x64] os: [android] - '@esbuild/darwin-arm64@0.19.12': - resolution: {integrity: sha512-B6IeSgZgtEzGC42jsI+YYu9Z3HKRxp8ZT3cqhvliEHovq8HSX2YX8lNocDn79gCKJXOSaEot9MVYky7AKjCs8g==} - engines: {node: '>=12'} + '@esbuild/darwin-arm64@0.23.1': + resolution: {integrity: sha512-YsS2e3Wtgnw7Wq53XXBLcV6JhRsEq8hkfg91ESVadIrzr9wO6jJDMZnCQbHm1Guc5t/CdDiFSSfWP58FNuvT3Q==} + engines: {node: '>=18'} cpu: [arm64] os: [darwin] - '@esbuild/darwin-x64@0.19.12': - resolution: {integrity: sha512-hKoVkKzFiToTgn+41qGhsUJXFlIjxI/jSYeZf3ugemDYZldIXIxhvwN6erJGlX4t5h417iFuheZ7l+YVn05N3A==} - engines: {node: '>=12'} + '@esbuild/darwin-x64@0.23.1': + resolution: {integrity: sha512-aClqdgTDVPSEGgoCS8QDG37Gu8yc9lTHNAQlsztQ6ENetKEO//b8y31MMu2ZaPbn4kVsIABzVLXYLhCGekGDqw==} + engines: {node: '>=18'} cpu: [x64] os: [darwin] - '@esbuild/freebsd-arm64@0.19.12': - resolution: {integrity: sha512-4aRvFIXmwAcDBw9AueDQ2YnGmz5L6obe5kmPT8Vd+/+x/JMVKCgdcRwH6APrbpNXsPz+K653Qg8HB/oXvXVukA==} - engines: {node: '>=12'} + '@esbuild/freebsd-arm64@0.23.1': + resolution: {integrity: sha512-h1k6yS8/pN/NHlMl5+v4XPfikhJulk4G+tKGFIOwURBSFzE8bixw1ebjluLOjfwtLqY0kewfjLSrO6tN2MgIhA==} + engines: {node: '>=18'} cpu: [arm64] os: [freebsd] - '@esbuild/freebsd-x64@0.19.12': - resolution: {integrity: sha512-EYoXZ4d8xtBoVN7CEwWY2IN4ho76xjYXqSXMNccFSx2lgqOG/1TBPW0yPx1bJZk94qu3tX0fycJeeQsKovA8gg==} - engines: {node: '>=12'} + '@esbuild/freebsd-x64@0.23.1': + resolution: {integrity: sha512-lK1eJeyk1ZX8UklqFd/3A60UuZ/6UVfGT2LuGo3Wp4/z7eRTRYY+0xOu2kpClP+vMTi9wKOfXi2vjUpO1Ro76g==} + engines: {node: '>=18'} cpu: [x64] os: [freebsd] - '@esbuild/linux-arm64@0.19.12': - resolution: {integrity: sha512-EoTjyYyLuVPfdPLsGVVVC8a0p1BFFvtpQDB/YLEhaXyf/5bczaGeN15QkR+O4S5LeJ92Tqotve7i1jn35qwvdA==} - engines: {node: '>=12'} + '@esbuild/linux-arm64@0.23.1': + resolution: {integrity: sha512-/93bf2yxencYDnItMYV/v116zff6UyTjo4EtEQjUBeGiVpMmffDNUyD9UN2zV+V3LRV3/on4xdZ26NKzn6754g==} + engines: {node: '>=18'} cpu: [arm64] os: [linux] - '@esbuild/linux-arm@0.19.12': - resolution: {integrity: sha512-J5jPms//KhSNv+LO1S1TX1UWp1ucM6N6XuL6ITdKWElCu8wXP72l9MM0zDTzzeikVyqFE6U8YAV9/tFyj0ti+w==} - engines: {node: '>=12'} + '@esbuild/linux-arm@0.23.1': + resolution: {integrity: sha512-CXXkzgn+dXAPs3WBwE+Kvnrf4WECwBdfjfeYHpMeVxWE0EceB6vhWGShs6wi0IYEqMSIzdOF1XjQ/Mkm5d7ZdQ==} + engines: {node: '>=18'} cpu: [arm] os: [linux] - '@esbuild/linux-ia32@0.19.12': - resolution: {integrity: sha512-Thsa42rrP1+UIGaWz47uydHSBOgTUnwBwNq59khgIwktK6x60Hivfbux9iNR0eHCHzOLjLMLfUMLCypBkZXMHA==} - engines: {node: '>=12'} + '@esbuild/linux-ia32@0.23.1': + resolution: {integrity: sha512-VTN4EuOHwXEkXzX5nTvVY4s7E/Krz7COC8xkftbbKRYAl96vPiUssGkeMELQMOnLOJ8k3BY1+ZY52tttZnHcXQ==} + engines: {node: '>=18'} cpu: [ia32] os: [linux] - '@esbuild/linux-loong64@0.19.12': - resolution: {integrity: sha512-LiXdXA0s3IqRRjm6rV6XaWATScKAXjI4R4LoDlvO7+yQqFdlr1Bax62sRwkVvRIrwXxvtYEHHI4dm50jAXkuAA==} - engines: {node: '>=12'} + '@esbuild/linux-loong64@0.23.1': + resolution: {integrity: sha512-Vx09LzEoBa5zDnieH8LSMRToj7ir/Jeq0Gu6qJ/1GcBq9GkfoEAoXvLiW1U9J1qE/Y/Oyaq33w5p2ZWrNNHNEw==} + engines: {node: '>=18'} cpu: [loong64] os: [linux] - '@esbuild/linux-mips64el@0.19.12': - resolution: {integrity: sha512-fEnAuj5VGTanfJ07ff0gOA6IPsvrVHLVb6Lyd1g2/ed67oU1eFzL0r9WL7ZzscD+/N6i3dWumGE1Un4f7Amf+w==} - engines: {node: '>=12'} + '@esbuild/linux-mips64el@0.23.1': + resolution: {integrity: sha512-nrFzzMQ7W4WRLNUOU5dlWAqa6yVeI0P78WKGUo7lg2HShq/yx+UYkeNSE0SSfSure0SqgnsxPvmAUu/vu0E+3Q==} + engines: {node: '>=18'} cpu: [mips64el] os: [linux] - '@esbuild/linux-ppc64@0.19.12': - resolution: {integrity: sha512-nYJA2/QPimDQOh1rKWedNOe3Gfc8PabU7HT3iXWtNUbRzXS9+vgB0Fjaqr//XNbd82mCxHzik2qotuI89cfixg==} - engines: {node: '>=12'} + '@esbuild/linux-ppc64@0.23.1': + resolution: {integrity: sha512-dKN8fgVqd0vUIjxuJI6P/9SSSe/mB9rvA98CSH2sJnlZ/OCZWO1DJvxj8jvKTfYUdGfcq2dDxoKaC6bHuTlgcw==} + engines: {node: '>=18'} cpu: [ppc64] os: [linux] - '@esbuild/linux-riscv64@0.19.12': - resolution: {integrity: sha512-2MueBrlPQCw5dVJJpQdUYgeqIzDQgw3QtiAHUC4RBz9FXPrskyyU3VI1hw7C0BSKB9OduwSJ79FTCqtGMWqJHg==} - engines: {node: '>=12'} + '@esbuild/linux-riscv64@0.23.1': + resolution: {integrity: sha512-5AV4Pzp80fhHL83JM6LoA6pTQVWgB1HovMBsLQ9OZWLDqVY8MVobBXNSmAJi//Csh6tcY7e7Lny2Hg1tElMjIA==} + engines: {node: '>=18'} cpu: [riscv64] os: [linux] - '@esbuild/linux-s390x@0.19.12': - resolution: {integrity: sha512-+Pil1Nv3Umes4m3AZKqA2anfhJiVmNCYkPchwFJNEJN5QxmTs1uzyy4TvmDrCRNT2ApwSari7ZIgrPeUx4UZDg==} - engines: {node: '>=12'} + '@esbuild/linux-s390x@0.23.1': + resolution: {integrity: sha512-9ygs73tuFCe6f6m/Tb+9LtYxWR4c9yg7zjt2cYkjDbDpV/xVn+68cQxMXCjUpYwEkze2RcU/rMnfIXNRFmSoDw==} + engines: {node: '>=18'} cpu: [s390x] os: [linux] - '@esbuild/linux-x64@0.19.12': - resolution: {integrity: sha512-B71g1QpxfwBvNrfyJdVDexenDIt1CiDN1TIXLbhOw0KhJzE78KIFGX6OJ9MrtC0oOqMWf+0xop4qEU8JrJTwCg==} - engines: {node: '>=12'} + '@esbuild/linux-x64@0.23.1': + resolution: {integrity: sha512-EV6+ovTsEXCPAp58g2dD68LxoP/wK5pRvgy0J/HxPGB009omFPv3Yet0HiaqvrIrgPTBuC6wCH1LTOY91EO5hQ==} + engines: {node: '>=18'} cpu: [x64] os: [linux] - '@esbuild/netbsd-x64@0.19.12': - resolution: {integrity: sha512-3ltjQ7n1owJgFbuC61Oj++XhtzmymoCihNFgT84UAmJnxJfm4sYCiSLTXZtE00VWYpPMYc+ZQmB6xbSdVh0JWA==} - engines: {node: '>=12'} + '@esbuild/netbsd-x64@0.23.1': + resolution: {integrity: sha512-aevEkCNu7KlPRpYLjwmdcuNz6bDFiE7Z8XC4CPqExjTvrHugh28QzUXVOZtiYghciKUacNktqxdpymplil1beA==} + engines: {node: '>=18'} cpu: [x64] os: [netbsd] - '@esbuild/openbsd-x64@0.19.12': - resolution: {integrity: sha512-RbrfTB9SWsr0kWmb9srfF+L933uMDdu9BIzdA7os2t0TXhCRjrQyCeOt6wVxr79CKD4c+p+YhCj31HBkYcXebw==} - engines: {node: '>=12'} + '@esbuild/openbsd-arm64@0.23.1': + resolution: {integrity: sha512-3x37szhLexNA4bXhLrCC/LImN/YtWis6WXr1VESlfVtVeoFJBRINPJ3f0a/6LV8zpikqoUg4hyXw0sFBt5Cr+Q==} + engines: {node: '>=18'} + cpu: [arm64] + os: [openbsd] + + '@esbuild/openbsd-x64@0.23.1': + resolution: {integrity: sha512-aY2gMmKmPhxfU+0EdnN+XNtGbjfQgwZj43k8G3fyrDM/UdZww6xrWxmDkuz2eCZchqVeABjV5BpildOrUbBTqA==} + engines: {node: '>=18'} cpu: [x64] os: [openbsd] - '@esbuild/sunos-x64@0.19.12': - resolution: {integrity: sha512-HKjJwRrW8uWtCQnQOz9qcU3mUZhTUQvi56Q8DPTLLB+DawoiQdjsYq+j+D3s9I8VFtDr+F9CjgXKKC4ss89IeA==} - engines: {node: '>=12'} + '@esbuild/sunos-x64@0.23.1': + resolution: {integrity: sha512-RBRT2gqEl0IKQABT4XTj78tpk9v7ehp+mazn2HbUeZl1YMdaGAQqhapjGTCe7uw7y0frDi4gS0uHzhvpFuI1sA==} + engines: {node: '>=18'} cpu: [x64] os: [sunos] - '@esbuild/win32-arm64@0.19.12': - resolution: {integrity: sha512-URgtR1dJnmGvX864pn1B2YUYNzjmXkuJOIqG2HdU62MVS4EHpU2946OZoTMnRUHklGtJdJZ33QfzdjGACXhn1A==} - engines: {node: '>=12'} + '@esbuild/win32-arm64@0.23.1': + resolution: {integrity: sha512-4O+gPR5rEBe2FpKOVyiJ7wNDPA8nGzDuJ6gN4okSA1gEOYZ67N8JPk58tkWtdtPeLz7lBnY6I5L3jdsr3S+A6A==} + engines: {node: '>=18'} cpu: [arm64] os: [win32] - '@esbuild/win32-ia32@0.19.12': - resolution: {integrity: sha512-+ZOE6pUkMOJfmxmBZElNOx72NKpIa/HFOMGzu8fqzQJ5kgf6aTGrcJaFsNiVMH4JKpMipyK+7k0n2UXN7a8YKQ==} - engines: {node: '>=12'} + '@esbuild/win32-ia32@0.23.1': + resolution: {integrity: sha512-BcaL0Vn6QwCwre3Y717nVHZbAa4UBEigzFm6VdsVdT/MbZ38xoj1X9HPkZhbmaBGUD1W8vxAfffbDe8bA6AKnQ==} + engines: {node: '>=18'} cpu: [ia32] os: [win32] - '@esbuild/win32-x64@0.19.12': - resolution: {integrity: sha512-T1QyPSDCyMXaO3pzBkF96E8xMkiRYbUEZADd29SyPGabqxMViNoii+NcK7eWJAEoU6RZyEm5lVSIjTmcdoB9HA==} - engines: {node: '>=12'} + '@esbuild/win32-x64@0.23.1': + resolution: {integrity: sha512-BHpFFeslkWrXWyUPnbKm+xYYVYruCinGcftSBaa8zoF9hZO4BcSCFUvHVTtzpIY6YzUnYtuEhZ+C9iEXjxnasg==} + engines: {node: '>=18'} cpu: [x64] os: [win32] @@ -1771,16 +1597,16 @@ packages: peerDependencies: eslint: ^6.0.0 || ^7.0.0 || >=8.0.0 - '@eslint-community/regexpp@4.10.0': - resolution: {integrity: sha512-Cu96Sd2By9mCNTx2iyKOmq10v22jUVQv0lQnlGNy16oE9589yE+QADPbrMGCkA51cKZSg3Pu/aTJVTGfL/qjUA==} + '@eslint-community/regexpp@4.11.1': + resolution: {integrity: sha512-m4DVN9ZqskZoLU5GlWZadwDnYo3vAEydiUayB9widCl9ffWx2IvPnp6n3on5rJmziJSw9Bv+Z3ChDVdMwXCY8Q==} engines: {node: ^12.0.0 || ^14.0.0 || >=16.0.0} '@eslint/eslintrc@2.1.4': resolution: {integrity: sha512-269Z39MS6wVJtsoUl10L60WdkhJVdPG24Q4eZTH3nnF6lpvSShEK3wQjDX9JRWAUPvPh7COouPpU9IrqaZFvtQ==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} - '@eslint/js@8.57.0': - resolution: {integrity: sha512-Ys+3g2TaW7gADOJzPt83SJtCDhMjndcDMFVQ/Tj9iA1BfJzFKD9mAUXT3OenpuPHbI6P/myECxRJrofUsDx/5g==} + '@eslint/js@8.57.1': + resolution: {integrity: sha512-d9zaMRSTIKDLhctzH12MtXvJKSSUhaHcjV+2Z+GK+EEY7XKpP5yR4x+N3TAcHTcu963nIr+TMcCb4DBCYX1z6Q==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} '@ethereumjs/common@2.6.5': @@ -1807,6 +1633,9 @@ packages: '@ethersproject/abstract-signer@5.7.0': resolution: {integrity: sha512-a16V8bq1/Cz+TGCkE2OPMTOUDLS3grCpdjoJCYNnVBbdYEMSgKrU0+B90s8b6H+ByYTBZN7a3g76jdIJi7UfKQ==} + '@ethersproject/address@5.6.1': + resolution: {integrity: sha512-uOgF0kS5MJv9ZvCz7x6T2EXJSzotiybApn4XlOgoTX0xdtyVIJ7pF+6cGPxiEq/dpBiTfMiw7Yc81JcwhSYA0Q==} + '@ethersproject/address@5.7.0': resolution: {integrity: sha512-9wYhYt7aghVGo758POM5nqcOMaE168Q6aRLJZwUmiqSrAungkG74gSSeKEIR7ukixesdRZGPgVqme6vmxs1fkA==} @@ -1888,8 +1717,8 @@ packages: '@ethersproject/wordlists@5.7.0': resolution: {integrity: sha512-S2TFNJNfHWVHNE6cNDjbVlZ6MgE17MIxMbMg2zv3wn+3XSJGosL1m9ZVv3GXCf/2ymSsQ+hRI5IzoMJTG6aoVA==} - '@fastify/busboy@2.1.0': - resolution: {integrity: sha512-+KpH+QxZU7O4675t3mnkQKcZZg56u+K/Ct2K+N2AZYNVK8kyeo/bI18tI8aPm3tvNNRyTWfj6s5tnGNlcbQRsA==} + '@fastify/busboy@2.1.1': + resolution: {integrity: sha512-vBZP4NlzfOlerQTnba4aqZoMhE/a9HY7HRqoOPaETQcSQuWEIyZMHGfVu6w9wGtGK5fED5qRs2DteVCjOH60sA==} engines: {node: '>=14'} '@graphql-tools/merge@8.3.1': @@ -1918,8 +1747,8 @@ packages: '@hapi/topo@5.1.0': resolution: {integrity: sha512-foQZKJig7Ob0BMAYBfcJk8d77QtOe7Wo4ox7ff1lQYoNNAb6jwcY1ncdoy2e9wQZzvNy7ODZCYJkK8kzmcAnAg==} - '@httptoolkit/httpolyglot@2.2.1': - resolution: {integrity: sha512-HOS/0zWc3yn7NM0RQFgBeepeTE8eAKtyOkcGL/TV6if5MAfr+3bH9rwCyAhbXbjlLVR3afeBRt8JYKEerDcygA==} + '@httptoolkit/httpolyglot@2.2.2': + resolution: {integrity: sha512-Mm75bidN/jrUsuhBjHAMoQbmR52zQYi8xr/+0mQYGW+dQelg+sdJR/kGRKKZGeAoPgp/1rrZWJqdohZP0xm18g==} engines: {node: '>=12.0.0'} '@httptoolkit/subscriptions-transport-ws@0.11.2': @@ -1930,16 +1759,18 @@ packages: '@httptoolkit/websocket-stream@6.0.1': resolution: {integrity: sha512-A0NOZI+Glp3Xgcz6Na7i7o09+/+xm2m0UCU8gdtM2nIv6/cjLmhMZMqehSpTlgbx9omtLmV8LVqOskPEyWnmZQ==} - '@humanwhocodes/config-array@0.11.14': - resolution: {integrity: sha512-3T8LkOmg45BV5FICb15QQMsyUSWrQ8AygVfC7ZG32zOalnqrilm018ZVCw0eapXux8FtA33q8PSRSstjee3jSg==} + '@humanwhocodes/config-array@0.13.0': + resolution: {integrity: sha512-DZLEEqFWQFiyK6h5YIeynKx7JlvCYWL0cImfSRXZ9l4Sg2efkFGTuFf6vzXjK1cq6IYkU+Eg/JizXw+TD2vRNw==} engines: {node: '>=10.10.0'} + deprecated: Use @eslint/config-array instead '@humanwhocodes/module-importer@1.0.1': resolution: {integrity: sha512-bxveV4V8v5Yb4ncFTT3rPSgZBOpCkjfK0y4oVVVJwIuDVBRMDXrPyXRL988i5ap9m9bnyEEjWfm5WkBmtffLfA==} engines: {node: '>=12.22'} - '@humanwhocodes/object-schema@2.0.2': - resolution: {integrity: sha512-6EwiSjwWYP7pTckG6I5eyFANjPhmPjUX9JRLUSfNPC7FX7zK9gyZAfUEaECL6ALTpGX5AjnBq3C9XmVWPitNpw==} + '@humanwhocodes/object-schema@2.0.3': + resolution: {integrity: sha512-93zYdMES/c1D69yZiKDBj0V24vqNzB/koF26KPaagAfd3P/4gUlh3Dys5ogAK+Exi9QyzlD8x/08Zt7wIKcDcA==} + deprecated: Use @eslint/object-schema instead '@isaacs/cliui@8.0.2': resolution: {integrity: sha512-O8jcjabXaleOG9DQ0+ARXWZBTfnP4WNAqzuiJK7ll44AmxGKv/J2M4TPjxjY3znBCfvBXFzucm1twdyFybFqEA==} @@ -1959,26 +1790,26 @@ packages: resolution: {integrity: sha512-ZXRY4jNvVgSVQ8DL3LTcakaAtXwTVUxE81hslsyD2AtoXW/wVob10HkOJ1X/pAlcI7D+2YoZKg5do8G/w6RYgA==} engines: {node: '>=8'} - '@jridgewell/gen-mapping@0.3.4': - resolution: {integrity: sha512-Oud2QPM5dHviZNn4y/WhhYKSXksv+1xLEIsNrAbGcFzUN3ubqWRFT5gwPchNc5NuzILOU4tPBDTZ4VwhL8Y7cw==} + '@jridgewell/gen-mapping@0.3.5': + resolution: {integrity: sha512-IzL8ZoEDIBRWEzlCcRhOaCupYyN5gdIK+Q6fbFdPDg6HqX6jpkItn7DFIpW9LQzXG6Df9sA7+OKnq0qlz/GaQg==} engines: {node: '>=6.0.0'} '@jridgewell/resolve-uri@3.1.2': resolution: {integrity: sha512-bRISgCIjP20/tbWSPWMEi54QVPRZExkuD9lJL+UIxUKtwVJA8wW1Trb1jMs1RFXo1CBTNZ/5hpC9QvmKWdopKw==} engines: {node: '>=6.0.0'} - '@jridgewell/set-array@1.1.2': - resolution: {integrity: sha512-xnkseuNADM0gt2bs+BvhO0p78Mk762YnZdsuzFV018NoG1Sj1SCQvpSqa7XUaTam5vAGasABV9qXASMKnFMwMw==} + '@jridgewell/set-array@1.2.1': + resolution: {integrity: sha512-R8gLRTZeyp03ymzP/6Lil/28tGeGEzhx1q2k703KGWRAI1VdvPIXdG70VJc2pAMw3NA6JKL5hhFu1sJX0Mnn/A==} engines: {node: '>=6.0.0'} - '@jridgewell/source-map@0.3.5': - resolution: {integrity: sha512-UTYAUj/wviwdsMfzoSJspJxbkH5o1snzwX0//0ENX1u/55kkZZkcTZP6u9bwKGkv+dkk9at4m1Cpt0uY80kcpQ==} + '@jridgewell/source-map@0.3.6': + resolution: {integrity: sha512-1ZJTZebgqllO79ue2bm3rIGud/bOe0pP5BjSRCRxxYkEZS8STV7zN84UBbiYu7jy+eCKSnVIUgoWWE/tt+shMQ==} - '@jridgewell/sourcemap-codec@1.4.15': - resolution: {integrity: sha512-eF2rxCRulEKXHTRiDrDy6erMYWqNw4LPdQ8UQA4huuxaQsVeRPFl2oM8oDGxMFhJUWZf9McpLtJasDDZb/Bpeg==} + '@jridgewell/sourcemap-codec@1.5.0': + resolution: {integrity: sha512-gv3ZRaISU3fjPAgNsriBRqGWQL6quFx04YMPW/zD8XMLsU32mhCCbfbO6KZFLjvYpCZ8zyDEgqsgf+PwPaM7GQ==} - '@jridgewell/trace-mapping@0.3.23': - resolution: {integrity: sha512-9/4foRoUKp8s96tSkh8DlAAc5A0Ty8vLXld+l9gjKKY6ckwI8G15f0hskGmuLZu78ZlGa1vtsfOa+lnB4vG6Jg==} + '@jridgewell/trace-mapping@0.3.25': + resolution: {integrity: sha512-vNk6aEwybGtawWmy/PzwnGDOjCkLWSD2wqvjGGAgOAwCGWySYXfYoxt00IJkTF+8Lb57DwOb3Aa0o9CApepiYQ==} '@jridgewell/trace-mapping@0.3.9': resolution: {integrity: sha512-3Belt6tdc8bPgAtbcmdtNJlirVoTmEb5e2gC94PnkwEW9jI6CAHUeoG85tjWP5WquqfavoMtMwiG4P926ZKKuQ==} @@ -1997,27 +1828,27 @@ packages: resolution: {integrity: sha512-tghyZKLHZjcdlDqCA3gNZmLeR0XvOE9U1qoQO9ohyAZT6Pya+H9vkBPcsyXytmYLNgVoin7CKCmweo/R43V+tQ==} engines: {node: '>=12.0.0'} - '@metamask/eth-sig-util@5.1.0': - resolution: {integrity: sha512-mlgziIHYlA9pi/XZerChqg4NocdOgBPB9NmxgXWQO2U2hH8RGOJQrz6j/AIKkYxgCMIE2PY000+joOwXfzeTDQ==} - engines: {node: '>=14.0.0'} - - '@metamask/safe-event-emitter@2.0.0': - resolution: {integrity: sha512-/kSXhY692qiV1MXu6EeOZvg5nECLclxNXcKCxJ3cXQgYuRymRHpdx/t7JXfsK+JLjwA1e1c1/SBrlQYpusC29Q==} - - '@metamask/utils@3.6.0': - resolution: {integrity: sha512-9cIRrfkWvHblSiNDVXsjivqa9Ak0RYo/1H6tqTqTbAx+oBK2Sva0lWDHxGchOqA7bySGUJKAWSNJvH6gdHZ0gQ==} - engines: {node: '>=14.0.0'} + '@noble/curves@1.2.0': + resolution: {integrity: sha512-oYclrNgRaM9SsBUBVbb8M6DTV7ZHRTKugureoYEncY5c65HOmRzvSiTE3y5CYaPYJA/GVkrhXEoF0M3Ya9PMnw==} - '@noble/curves@1.3.0': - resolution: {integrity: sha512-t01iSXPuN+Eqzb4eBX0S5oubSqXbK/xXa1Ne18Hj8f9pStxztHCE2gfboSp/dZRLSqfuLpRK2nDXDK+W9puocA==} + '@noble/curves@1.4.2': + resolution: {integrity: sha512-TavHr8qycMChk8UwMld0ZDRvatedkzWfH8IiaeGCfymOP5i0hSCozz9vHOL0nkwk7HRMlFnAiKpS2jrUmSybcw==} '@noble/hashes@1.2.0': resolution: {integrity: sha512-FZfhjEDbT5GRswV3C6uvLPHMiVD6lQBmpoX5+eSiPaMTXte/IKqI5dykDxzZB/WBeK/CDuQRBWarPdi3FNY2zQ==} - '@noble/hashes@1.3.3': - resolution: {integrity: sha512-V7/fPHgl+jsVPXqqeOzT8egNj2iBIVt+ECeMMG8TdcnTikP3oaBtUVqpT/gYCR68aEBJSF+XbYUxStjbFMqIIA==} + '@noble/hashes@1.3.2': + resolution: {integrity: sha512-MVC8EAQp7MvEcm30KWENFjgR+Mkmf+D189XJTkFIlwohU5hcBbn1ZkKq7KVTi2Hme3PMGF390DaL52beVrIihQ==} engines: {node: '>= 16'} + '@noble/hashes@1.4.0': + resolution: {integrity: sha512-V1JJ1WTRUqHHrOSh597hURcMqVKVGL/ea3kv0gSnEdsEZ0/+VyPghM1lMNGc00z7CIQorSvbKpuJkxvuHbvdbg==} + engines: {node: '>= 16'} + + '@noble/hashes@1.5.0': + resolution: {integrity: sha512-1j6kQFb7QRru7eKN3ZDvRcP13rugwdxZqCjbiAVZfIJwgj2A65UmT4TgARXGlXgnRkORLTDTrO19ZErt7+QXgA==} + engines: {node: ^14.21.3 || >=16} + '@noble/secp256k1@1.7.1': resolution: {integrity: sha512-hOUk6AyBFmqVrv7k5WAw/LpszxVbj9gGN4JRkIX52fdFAj1UA61KXmZDvqVEm+pOyec3+fIeZB02LYa/pWOArw==} @@ -2033,42 +1864,46 @@ packages: resolution: {integrity: sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg==} engines: {node: '>= 8'} - '@nomicfoundation/ethereumjs-block@5.0.4': - resolution: {integrity: sha512-AcyacJ9eX/uPEvqsPiB+WO1ymE+kyH48qGGiGV+YTojdtas8itUTW5dehDSOXEEItWGbbzEJ4PRqnQZlWaPvDw==} - engines: {node: '>=18'} + '@nomicfoundation/edr-darwin-arm64@0.6.4': + resolution: {integrity: sha512-QNQErISLgssV9+qia8sIjRANqtbW8snSDvjspixT/kSQ5ZSGxxctTg7x72wPSrcu8+EBEveIe5uqENIp5GH8HQ==} + engines: {node: '>= 18'} - '@nomicfoundation/ethereumjs-blockchain@7.0.4': - resolution: {integrity: sha512-jYsd/kwzbmpnxx86tXsYV8wZ5xGvFL+7/P0c6OlzpClHsbFzeF41KrYA9scON8Rg6bZu3ZTv6JOAgj3t7USUfg==} - engines: {node: '>=18'} + '@nomicfoundation/edr-darwin-x64@0.6.4': + resolution: {integrity: sha512-cjVmREiwByyc9+oGfvAh49IAw+oVJHF9WWYRD+Tm/ZlSpnEVWxrGNBak2bd/JSYjn+mZE7gmWS4SMRi4nKaLUg==} + engines: {node: '>= 18'} - '@nomicfoundation/ethereumjs-common@4.0.4': - resolution: {integrity: sha512-9Rgb658lcWsjiicr5GzNCjI1llow/7r0k50dLL95OJ+6iZJcVbi15r3Y0xh2cIO+zgX0WIHcbzIu6FeQf9KPrg==} + '@nomicfoundation/edr-linux-arm64-gnu@0.6.4': + resolution: {integrity: sha512-96o9kRIVD6W5VkgKvUOGpWyUGInVQ5BRlME2Fa36YoNsRQMaKtmYJEU0ACosYES6ZTpYC8U5sjMulvPtVoEfOA==} + engines: {node: '>= 18'} - '@nomicfoundation/ethereumjs-ethash@3.0.4': - resolution: {integrity: sha512-xvIrwIMl9sSaiYKRem68+O7vYdj7Q2XWv5P7JXiIkn83918QzWHvqbswTRsH7+r6X1UEvdsURRnZbvZszEjAaQ==} - engines: {node: '>=18'} + '@nomicfoundation/edr-linux-arm64-musl@0.6.4': + resolution: {integrity: sha512-+JVEW9e5plHrUfQlSgkEj/UONrIU6rADTEk+Yp9pbe+mzNkJdfJYhs5JYiLQRP4OjxH4QOrXI97bKU6FcEbt5Q==} + engines: {node: '>= 18'} - '@nomicfoundation/ethereumjs-evm@2.0.4': - resolution: {integrity: sha512-lTyZZi1KpeMHzaO6cSVisR2tjiTTedjo7PcmhI/+GNFo9BmyY6QYzGeSti0sFttmjbEMioHgXxl5yrLNRg6+1w==} - engines: {node: '>=18'} + '@nomicfoundation/edr-linux-x64-gnu@0.6.4': + resolution: {integrity: sha512-nzYWW+fO3EZItOeP4CrdMgDXfaGBIBkKg0Y/7ySpUxLqzut40O4Mb0/+quqLAFkacUSWMlFp8nsmypJfOH5zoA==} + engines: {node: '>= 18'} + + '@nomicfoundation/edr-linux-x64-musl@0.6.4': + resolution: {integrity: sha512-QFRoE9qSQ2boRrVeQ1HdzU+XN7NUgwZ1SIy5DQt4d7jCP+5qTNsq8LBNcqhRBOATgO63nsweNUhxX/Suj5r1Sw==} + engines: {node: '>= 18'} + + '@nomicfoundation/edr-win32-x64-msvc@0.6.4': + resolution: {integrity: sha512-2yopjelNkkCvIjUgBGhrn153IBPLwnsDeNiq6oA0WkeM8tGmQi4td+PGi9jAriUDAkc59Yoi2q9hYA6efiY7Zw==} + engines: {node: '>= 18'} + + '@nomicfoundation/edr@0.6.4': + resolution: {integrity: sha512-YgrSuT3yo5ZQkbvBGqQ7hG+RDvz3YygSkddg4tb1Z0Y6pLXFzwrcEwWaJCFAVeeZxdxGfCgGMUYgRVneK+WXkw==} + engines: {node: '>= 18'} + + '@nomicfoundation/ethereumjs-common@4.0.4': + resolution: {integrity: sha512-9Rgb658lcWsjiicr5GzNCjI1llow/7r0k50dLL95OJ+6iZJcVbi15r3Y0xh2cIO+zgX0WIHcbzIu6FeQf9KPrg==} '@nomicfoundation/ethereumjs-rlp@5.0.4': resolution: {integrity: sha512-8H1S3s8F6QueOc/X92SdrA4RDenpiAEqMg5vJH99kcQaCy/a3Q6fgseo75mgWlbanGJXSlAPtnCeG9jvfTYXlw==} engines: {node: '>=18'} hasBin: true - '@nomicfoundation/ethereumjs-statemanager@2.0.4': - resolution: {integrity: sha512-HPDjeFrxw6llEi+BzqXkZ+KkvFnTOPczuHBtk21hRlDiuKuZz32dPzlhpRsDBGV1b5JTmRDUVqCS1lp3Gghw4Q==} - peerDependencies: - '@nomicfoundation/ethereumjs-verkle': 0.0.2 - peerDependenciesMeta: - '@nomicfoundation/ethereumjs-verkle': - optional: true - - '@nomicfoundation/ethereumjs-trie@6.0.4': - resolution: {integrity: sha512-3nSwQiFMvr2VFe/aZUyinuohYvtytUqZCUCvIWcPJ/BwJH6oQdZRB42aNFBJ/8nAh2s3OcroWpBLskzW01mFKA==} - engines: {node: '>=18'} - '@nomicfoundation/ethereumjs-tx@5.0.4': resolution: {integrity: sha512-Xjv8wAKJGMrP1f0n2PeyfFCCojHd7iS3s/Ab7qzF1S64kxZ8Z22LCMynArYsVqiFx6rzYy548HNVEyI+AYN/kw==} engines: {node: '>=18'} @@ -2087,108 +1922,119 @@ packages: c-kzg: optional: true - '@nomicfoundation/ethereumjs-verkle@0.0.2': - resolution: {integrity: sha512-bjnfZElpYGK/XuuVRmLS3yDvr+cDs85D9oonZ0YUa5A3lgFgokWMp76zXrxX2jVQ0BfHaw12y860n1+iOi6yFQ==} - engines: {node: '>=18'} - - '@nomicfoundation/ethereumjs-vm@7.0.4': - resolution: {integrity: sha512-gsA4IhmtWHI4BofKy3kio9W+dqZQs5Ji5mLjLYxHCkat+JQBUt5szjRKra2F9nGDJ2XcI/wWb0YWUFNgln4zRQ==} - engines: {node: '>=18'} + '@nomicfoundation/hardhat-chai-matchers@2.0.8': + resolution: {integrity: sha512-Z5PiCXH4xhNLASROlSUOADfhfpfhYO6D7Hn9xp8PddmHey0jq704cr6kfU8TRrQ4PUZbpfsZadPj+pCfZdjPIg==} + peerDependencies: + '@nomicfoundation/hardhat-ethers': ^3.0.0 + chai: ^4.2.0 + ethers: ^6.1.0 + hardhat: ^2.9.4 - '@nomicfoundation/solidity-analyzer-darwin-arm64@0.1.1': - resolution: {integrity: sha512-KcTodaQw8ivDZyF+D76FokN/HdpgGpfjc/gFCImdLUyqB6eSWVaZPazMbeAjmfhx3R0zm/NYVzxwAokFKgrc0w==} - engines: {node: '>= 10'} - cpu: [arm64] - os: [darwin] + '@nomicfoundation/hardhat-ethers@3.0.8': + resolution: {integrity: sha512-zhOZ4hdRORls31DTOqg+GmEZM0ujly8GGIuRY7t7szEk2zW/arY1qDug/py8AEktT00v5K+b6RvbVog+va51IA==} + peerDependencies: + ethers: 6.13.4 + hardhat: ^2.0.0 - '@nomicfoundation/solidity-analyzer-darwin-x64@0.1.1': - resolution: {integrity: sha512-XhQG4BaJE6cIbjAVtzGOGbK3sn1BO9W29uhk9J8y8fZF1DYz0Doj8QDMfpMu+A6TjPDs61lbsmeYodIDnfveSA==} - engines: {node: '>= 10'} - cpu: [x64] - os: [darwin] + '@nomicfoundation/hardhat-ignition-ethers@0.15.6': + resolution: {integrity: sha512-+jXDGWdfkuIGm0W+aFEZ9SLQz2MIj7Cf4j7ANTXUIIbK8sUkvnVOhTTAQEdqa0KgGEb45XS88BPg0w8fixwrXQ==} + peerDependencies: + '@nomicfoundation/hardhat-ethers': ^3.0.4 + '@nomicfoundation/hardhat-ignition': ^0.15.6 + '@nomicfoundation/ignition-core': ^0.15.6 + ethers: ^6.7.0 + hardhat: ^2.18.0 + + '@nomicfoundation/hardhat-ignition@0.15.6': + resolution: {integrity: sha512-PcMf4xlYvwHYej2jcuOd/rBNNMM5FO11vh9c+MF8+m7NxV4b6NOameL3uscoD7ghg0H2GNgnGXgQ67ryRqtdIQ==} + peerDependencies: + '@nomicfoundation/hardhat-verify': ^2.0.1 + hardhat: ^2.18.0 - '@nomicfoundation/solidity-analyzer-freebsd-x64@0.1.1': - resolution: {integrity: sha512-GHF1VKRdHW3G8CndkwdaeLkVBi5A9u2jwtlS7SLhBc8b5U/GcoL39Q+1CSO3hYqePNP+eV5YI7Zgm0ea6kMHoA==} - engines: {node: '>= 10'} - cpu: [x64] - os: [freebsd] + '@nomicfoundation/hardhat-network-helpers@1.0.12': + resolution: {integrity: sha512-xTNQNI/9xkHvjmCJnJOTyqDSl8uq1rKb2WOVmixQxFtRd7Oa3ecO8zM0cyC2YmOK+jHB9WPZ+F/ijkHg1CoORA==} + peerDependencies: + hardhat: ^2.9.5 - '@nomicfoundation/solidity-analyzer-linux-arm64-gnu@0.1.1': - resolution: {integrity: sha512-g4Cv2fO37ZsUENQ2vwPnZc2zRenHyAxHcyBjKcjaSmmkKrFr64yvzeNO8S3GBFCo90rfochLs99wFVGT/0owpg==} - engines: {node: '>= 10'} - cpu: [arm64] - os: [linux] + '@nomicfoundation/hardhat-toolbox@5.0.0': + resolution: {integrity: sha512-FnUtUC5PsakCbwiVNsqlXVIWG5JIb5CEZoSXbJUsEBun22Bivx2jhF1/q9iQbzuaGpJKFQyOhemPB2+XlEE6pQ==} + peerDependencies: + '@nomicfoundation/hardhat-chai-matchers': ^2.0.0 + '@nomicfoundation/hardhat-ethers': ^3.0.0 + '@nomicfoundation/hardhat-ignition-ethers': ^0.15.0 + '@nomicfoundation/hardhat-network-helpers': ^1.0.0 + '@nomicfoundation/hardhat-verify': ^2.0.0 + '@typechain/ethers-v6': ^0.5.0 + '@typechain/hardhat': ^9.0.0 + '@types/chai': ^4.2.0 + '@types/mocha': '>=9.1.0' + '@types/node': '>=18.0.0' + chai: ^4.2.0 + ethers: ^6.4.0 + hardhat: ^2.11.0 + hardhat-gas-reporter: ^1.0.8 + solidity-coverage: ^0.8.1 + ts-node: '>=8.0.0' + typechain: ^8.3.0 + typescript: '>=4.5.0' + + '@nomicfoundation/hardhat-verify@2.0.11': + resolution: {integrity: sha512-lGIo4dNjVQFdsiEgZp3KP6ntLiF7xJEJsbNHfSyIiFCyI0Yv0518ElsFtMC5uCuHEChiBBMrib9jWQvHHT+X3Q==} + peerDependencies: + hardhat: ^2.0.4 - '@nomicfoundation/solidity-analyzer-linux-arm64-musl@0.1.1': - resolution: {integrity: sha512-WJ3CE5Oek25OGE3WwzK7oaopY8xMw9Lhb0mlYuJl/maZVo+WtP36XoQTb7bW/i8aAdHW5Z+BqrHMux23pvxG3w==} - engines: {node: '>= 10'} - cpu: [arm64] - os: [linux] + '@nomicfoundation/ignition-core@0.15.6': + resolution: {integrity: sha512-9eD1NJ2G4vh7IleRNmCz/3bGVoNEPYrRVPqx0uvWzG2xD226GGQcTgtK+NovyxsQOE/AcLF1xjX3/+8kNc1sSg==} - '@nomicfoundation/solidity-analyzer-linux-x64-gnu@0.1.1': - resolution: {integrity: sha512-5WN7leSr5fkUBBjE4f3wKENUy9HQStu7HmWqbtknfXkkil+eNWiBV275IOlpXku7v3uLsXTOKpnnGHJYI2qsdA==} - engines: {node: '>= 10'} - cpu: [x64] - os: [linux] + '@nomicfoundation/ignition-ui@0.15.6': + resolution: {integrity: sha512-CW14g/BVcGZtBSF1K4eZSCjyvtz1fr9yppkFKC+Z0+sm/lXFWpwcwaVN+UiugQ/9wz9HAfSk4Y0gagdAMiSs0w==} - '@nomicfoundation/solidity-analyzer-linux-x64-musl@0.1.1': - resolution: {integrity: sha512-KdYMkJOq0SYPQMmErv/63CwGwMm5XHenEna9X9aB8mQmhDBrYrlAOSsIPgFCUSL0hjxE3xHP65/EPXR/InD2+w==} - engines: {node: '>= 10'} - cpu: [x64] - os: [linux] + '@nomicfoundation/solidity-analyzer-darwin-arm64@0.1.2': + resolution: {integrity: sha512-JaqcWPDZENCvm++lFFGjrDd8mxtf+CtLd2MiXvMNTBD33dContTZ9TWETwNFwg7JTJT5Q9HEecH7FA+HTSsIUw==} + engines: {node: '>= 12'} - '@nomicfoundation/solidity-analyzer-win32-arm64-msvc@0.1.1': - resolution: {integrity: sha512-VFZASBfl4qiBYwW5xeY20exWhmv6ww9sWu/krWSesv3q5hA0o1JuzmPHR4LPN6SUZj5vcqci0O6JOL8BPw+APg==} - engines: {node: '>= 10'} - cpu: [arm64] - os: [win32] + '@nomicfoundation/solidity-analyzer-darwin-x64@0.1.2': + resolution: {integrity: sha512-fZNmVztrSXC03e9RONBT+CiksSeYcxI1wlzqyr0L7hsQlK1fzV+f04g2JtQ1c/Fe74ZwdV6aQBdd6Uwl1052sw==} + engines: {node: '>= 12'} - '@nomicfoundation/solidity-analyzer-win32-ia32-msvc@0.1.1': - resolution: {integrity: sha512-JnFkYuyCSA70j6Si6cS1A9Gh1aHTEb8kOTBApp/c7NRTFGNMH8eaInKlyuuiIbvYFhlXW4LicqyYuWNNq9hkpQ==} - engines: {node: '>= 10'} - cpu: [ia32] - os: [win32] + '@nomicfoundation/solidity-analyzer-linux-arm64-gnu@0.1.2': + resolution: {integrity: sha512-3d54oc+9ZVBuB6nbp8wHylk4xh0N0Gc+bk+/uJae+rUgbOBwQSfuGIbAZt1wBXs5REkSmynEGcqx6DutoK0tPA==} + engines: {node: '>= 12'} - '@nomicfoundation/solidity-analyzer-win32-x64-msvc@0.1.1': - resolution: {integrity: sha512-HrVJr6+WjIXGnw3Q9u6KQcbZCtk0caVWhCdFADySvRyUxJ8PnzlaP+MhwNE8oyT8OZ6ejHBRrrgjSqDCFXGirw==} - engines: {node: '>= 10'} - cpu: [x64] - os: [win32] + '@nomicfoundation/solidity-analyzer-linux-arm64-musl@0.1.2': + resolution: {integrity: sha512-iDJfR2qf55vgsg7BtJa7iPiFAsYf2d0Tv/0B+vhtnI16+wfQeTbP7teookbGvAo0eJo7aLLm0xfS/GTkvHIucA==} + engines: {node: '>= 12'} - '@nomicfoundation/solidity-analyzer@0.1.1': - resolution: {integrity: sha512-1LMtXj1puAxyFusBgUIy5pZk3073cNXYnXUpuNKFghHbIit/xZgbk0AokpUADbNm3gyD6bFWl3LRFh3dhVdREg==} + '@nomicfoundation/solidity-analyzer-linux-x64-gnu@0.1.2': + resolution: {integrity: sha512-9dlHMAt5/2cpWyuJ9fQNOUXFB/vgSFORg1jpjX1Mh9hJ/MfZXlDdHQ+DpFCs32Zk5pxRBb07yGvSHk9/fezL+g==} engines: {node: '>= 12'} - '@nomiclabs/hardhat-ethers@2.2.3': - resolution: {integrity: sha512-YhzPdzb612X591FOe68q+qXVXGG2ANZRvDo0RRUtimev85rCrAlv/TLMEZw5c+kq9AbzocLTVX/h2jVIFPL9Xg==} - peerDependencies: - ethers: ^5.0.0 - hardhat: ^2.0.0 + '@nomicfoundation/solidity-analyzer-linux-x64-musl@0.1.2': + resolution: {integrity: sha512-GzzVeeJob3lfrSlDKQw2bRJ8rBf6mEYaWY+gW0JnTDHINA0s2gPR4km5RLIj1xeZZOYz4zRw+AEeYgLRqB2NXg==} + engines: {node: '>= 12'} - '@nomiclabs/hardhat-web3@2.0.0': - resolution: {integrity: sha512-zt4xN+D+fKl3wW2YlTX3k9APR3XZgPkxJYf36AcliJn3oujnKEVRZaHu0PhgLjO+gR+F/kiYayo9fgd2L8970Q==} - peerDependencies: - hardhat: ^2.0.0 - web3: ^1.0.0-beta.36 + '@nomicfoundation/solidity-analyzer-win32-x64-msvc@0.1.2': + resolution: {integrity: sha512-Fdjli4DCcFHb4Zgsz0uEJXZ2K7VEO+w5KVv7HmT7WO10iODdU9csC2az4jrhEsRtiR9Gfd74FlG0NYlw1BMdyA==} + engines: {node: '>= 12'} - '@pkgjs/parseargs@0.11.0': - resolution: {integrity: sha512-+1VkjdD0QBLPodGrJUeqarH8VAIvQODIbwh9XpP5Syisf7YoQgsJKPNFoqqLQlu+VQ/tVSshMR6loPMn8U+dPg==} - engines: {node: '>=14'} + '@nomicfoundation/solidity-analyzer@0.1.2': + resolution: {integrity: sha512-q4n32/FNKIhQ3zQGGw5CvPF6GTvDCpYwIf7bEY/dZTZbgfDsHyjJwURxUJf3VQuuJj+fDIFl4+KkBVbw4Ef6jA==} + engines: {node: '>= 12'} '@pkgr/core@0.1.1': resolution: {integrity: sha512-cq8o4cWH0ibXh9VGi5P20Tu9XF/0fFXl9EUinr9QfTM7a7p0oTA4iJRCQWppXR1Pg8dSM0UCItCkPwsk9qWWYA==} engines: {node: ^12.20.0 || ^14.18.0 || >=16.0.0} - '@preconstruct/cli@2.8.3': - resolution: {integrity: sha512-4PNEPcp8REUdqZIjtpXF1fqECuHt+pIS6k0PluSRcgX0KwPtfSw407Y2B/ItndgtRD3rKHXI6cKkwh/6Mc4TXg==} + '@preconstruct/cli@2.8.9': + resolution: {integrity: sha512-Psk/pgeWCFnJWddVtsarcNRZbZ+35AtNCEfOjDANrfLxyGm3Smt00rm1w8RiMiwqZryUkt9XaSHriWQBFKechQ==} hasBin: true '@preconstruct/hook@0.4.0': resolution: {integrity: sha512-a7mrlPTM3tAFJyz43qb4pPVpUx8j8TzZBFsNFqcKcE/sEakNXRlQAuCT4RGZRf9dQiiUnBahzSIWawU4rENl+Q==} - '@puppeteer/browsers@1.9.1': - resolution: {integrity: sha512-PuvK6xZzGhKPvlx3fpfdM2kYY3P/hB1URtK8wA7XUJ6prn6pp22zvJHu48th0SGcHL9SutbPHrFuQgfXTFobWA==} - engines: {node: '>=16.3.0'} + '@puppeteer/browsers@2.6.1': + resolution: {integrity: sha512-aBSREisdsGH890S2rQqK82qmQYU3uFpSH8wcZWHgHzl3LfzsxAKbLNiAG9mO8v1Y0UICBeClICxPJvyr0rcuxg==} + engines: {node: '>=18'} hasBin: true '@rollup/plugin-alias@3.1.9': @@ -2229,20 +2075,23 @@ packages: resolution: {integrity: sha512-iKnFXr7NkdZAIHiIWE+BX5ULi/ucVFYWD6TbAV+rZctiRTY2PL6tsIKhoIOaoskiWAkgu+VsbXgUVDNLHf+InQ==} engines: {node: '>= 8.0.0'} - '@scure/base@1.1.5': - resolution: {integrity: sha512-Brj9FiG2W1MRQSTB212YVPRrcbjkv48FoZi/u4l/zds/ieRrqsh7aUf6CLwkAq61oKXr/ZlTzlY66gLIj3TFTQ==} + '@rtsao/scc@1.1.0': + resolution: {integrity: sha512-zt6OdqaDoOnJ1ZYsCYGt9YmWzDXl4vQdKTyJev62gFhRGKdx7mcT54V9KIjg+d2wi9EXsPvAPKe7i7WjfVWB8g==} + + '@scure/base@1.1.9': + resolution: {integrity: sha512-8YKhl8GHiNI/pU2VMaofa2Tor7PJRAjwQLBBuilkJ9L5+13yVbC7JO/wS7piioAvPSwR3JKM1IJ/u4xQzbcXKg==} '@scure/bip32@1.1.5': resolution: {integrity: sha512-XyNh1rB0SkEqd3tXcXMi+Xe1fvg+kUIcoRIEujP1Jgv7DqW2r9lg3Ah0NkFaCs9sTkQAQA8kw7xiRXzENi9Rtw==} - '@scure/bip32@1.3.3': - resolution: {integrity: sha512-LJaN3HwRbfQK0X1xFSi0Q9amqOgzQnnDngIt+ZlsBC3Bm7/nE7K0kwshZHyaru79yIVRv/e1mQAjZyuZG6jOFQ==} + '@scure/bip32@1.4.0': + resolution: {integrity: sha512-sVUpc0Vq3tXCkDGYVWGIZTRfnvu8LoTDaev7vbwh0omSvVORONr960MQWdKqJDCReIEmTj3PAr73O3aoxz7OPg==} '@scure/bip39@1.1.1': resolution: {integrity: sha512-t+wDck2rVkh65Hmv280fYdVdY25J9YeEUIgn2LG1WM6gxFkGzcksoDiUkWVpVp3Oex9xGC68JU2dSbUfwZ2jPg==} - '@scure/bip39@1.2.2': - resolution: {integrity: sha512-HYf9TUXG80beW+hGAt3TRM8wU6pQoYur9iNypTROm42dorCGmLnFe3eWjz3gOq6G62H2WRh0FCzAR1PI+29zIA==} + '@scure/bip39@1.3.0': + resolution: {integrity: sha512-disdg7gHuTDZtY+ZdkmLpPCk7fxZSu3gBiEGuoC1XYxv9cGx3Z6cpTggCgW6odSOOIXCiDjuGejW+aJKCY/pIQ==} '@sentry/core@5.30.0': resolution: {integrity: sha512-TmfrII8w1PQZSZgPpUESqjB+jC6MvZJZdLtE/0hZ+SrnKhW3x5WlYLvTXZpcWePYBku7rl2wn1RZu6uT0qCTeg==} @@ -2289,161 +2138,179 @@ packages: resolution: {integrity: sha512-LtoMMhxAlorcGhmFYI+LhPgbPZCkgP6ra1YL604EeF6U98pLlQ3iWIGMdWSC+vWmPBWBNgmDBAhnAobLROJmwg==} engines: {node: '>=18'} - '@smithy/abort-controller@2.1.2': - resolution: {integrity: sha512-iwUxrFm/ZFCXhzhtZ6JnoJzAsqUrVfBAZUTQj8ypXGtIjwXZpKqmgYiuqrDERiydDI5gesqvsC4Rqe57GGhbVg==} - engines: {node: '>=14.0.0'} + '@smithy/abort-controller@3.1.6': + resolution: {integrity: sha512-0XuhuHQlEqbNQZp7QxxrFTdVWdwxch4vjxYgfInF91hZFkPxf9QDrdQka0KfxFMPqLNzSw0b95uGTrLliQUavQ==} + engines: {node: '>=16.0.0'} - '@smithy/config-resolver@2.1.2': - resolution: {integrity: sha512-ZDMY63xJVsJl7ei/yIMv9nx8OiEOulwNnQOUDGpIvzoBrcbvYwiMjIMe5mP5J4fUmttKkpiTKwta/7IUriAn9w==} - engines: {node: '>=14.0.0'} + '@smithy/config-resolver@3.0.10': + resolution: {integrity: sha512-Uh0Sz9gdUuz538nvkPiyv1DZRX9+D15EKDtnQP5rYVAzM/dnYk3P8cg73jcxyOitPgT3mE3OVj7ky7sibzHWkw==} + engines: {node: '>=16.0.0'} - '@smithy/core@1.3.3': - resolution: {integrity: sha512-8cT/swERvU1EUMuJF914+psSeVy4+NcNhbRe1WEKN1yIMPE5+Tq5EaPq1HWjKCodcdBIyU9ViTjd62XnebXMHA==} - engines: {node: '>=14.0.0'} + '@smithy/core@2.5.1': + resolution: {integrity: sha512-DujtuDA7BGEKExJ05W5OdxCoyekcKT3Rhg1ZGeiUWaz2BJIWXjZmsG/DIP4W48GHno7AQwRsaCb8NcBgH3QZpg==} + engines: {node: '>=16.0.0'} - '@smithy/credential-provider-imds@2.2.2': - resolution: {integrity: sha512-a2xpqWzhzcYwImGbFox5qJLf6i5HKdVeOVj7d6kVFElmbS2QW2T4HmefRc5z1huVArk9bh5Rk1NiFp9YBCXU3g==} - engines: {node: '>=14.0.0'} + '@smithy/credential-provider-imds@3.2.5': + resolution: {integrity: sha512-4FTQGAsuwqTzVMmiRVTn0RR9GrbRfkP0wfu/tXWVHd2LgNpTY0uglQpIScXK4NaEyXbB3JmZt8gfVqO50lP8wg==} + engines: {node: '>=16.0.0'} - '@smithy/eventstream-codec@2.1.2': - resolution: {integrity: sha512-2PHrVRixITHSOj3bxfZmY93apGf8/DFiyhRh9W0ukfi07cvlhlRonZ0fjgcqryJjUZ5vYHqqmfIE/Qe1HM9mlw==} + '@smithy/fetch-http-handler@3.2.9': + resolution: {integrity: sha512-hYNVQOqhFQ6vOpenifFME546f0GfJn2OiQ3M0FDmuUu8V/Uiwy2wej7ZXxFBNqdx0R5DZAqWM1l6VRhGz8oE6A==} - '@smithy/fetch-http-handler@2.4.2': - resolution: {integrity: sha512-sIGMVwa/8h6eqNjarI3F07gvML3mMXcqBe+BINNLuKsVKXMNBN6wRzeZbbx7lfiJDEHAP28qRns8flHEoBB7zw==} + '@smithy/fetch-http-handler@4.0.0': + resolution: {integrity: sha512-MLb1f5tbBO2X6K4lMEKJvxeLooyg7guq48C2zKr4qM7F2Gpkz4dc+hdSgu77pCJ76jVqFBjZczHYAs6dp15N+g==} - '@smithy/hash-node@2.1.2': - resolution: {integrity: sha512-3Sgn4s0g4xud1M/j6hQwYCkz04lVJ24wvCAx4xI26frr3Ao6v0o2VZkBpUySTeQbMUBp2DhuzJ0fV1zybzkckw==} - engines: {node: '>=14.0.0'} + '@smithy/hash-node@3.0.8': + resolution: {integrity: sha512-tlNQYbfpWXHimHqrvgo14DrMAgUBua/cNoz9fMYcDmYej7MAmUcjav/QKQbFc3NrcPxeJ7QClER4tWZmfwoPng==} + engines: {node: '>=16.0.0'} - '@smithy/invalid-dependency@2.1.2': - resolution: {integrity: sha512-qdgKhkFYxDJnKecx2ANwz3JRkXjm0qDgEnAs5BIfb2z/XqA2l7s9BTH7GTC/RR4E8h6EDCeb5rM2rnARxviqIg==} + '@smithy/invalid-dependency@3.0.8': + resolution: {integrity: sha512-7Qynk6NWtTQhnGTTZwks++nJhQ1O54Mzi7fz4PqZOiYXb4Z1Flpb2yRvdALoggTS8xjtohWUM+RygOtB30YL3Q==} - '@smithy/is-array-buffer@2.1.1': - resolution: {integrity: sha512-xozSQrcUinPpNPNPds4S7z/FakDTh1MZWtRP/2vQtYB/u3HYrX2UXuZs+VhaKBd6Vc7g2XPr2ZtwGBNDN6fNKQ==} + '@smithy/is-array-buffer@2.2.0': + resolution: {integrity: sha512-GGP3O9QFD24uGeAXYUjwSTXARoqpZykHadOmA8G5vfJPK0/DC67qa//0qvqrJzL1xc8WQWX7/yc7fwudjPHPhA==} engines: {node: '>=14.0.0'} - '@smithy/middleware-content-length@2.1.2': - resolution: {integrity: sha512-XEWtul1tHP31EtUIobEyN499paUIbnCTRtjY+ciDCEXW81lZmpjrDG3aL0FxJDPnvatVQuMV1V5eg6MCqTFaLQ==} - engines: {node: '>=14.0.0'} + '@smithy/is-array-buffer@3.0.0': + resolution: {integrity: sha512-+Fsu6Q6C4RSJiy81Y8eApjEB5gVtM+oFKTffg+jSuwtvomJJrhUJBu2zS8wjXSgH/g1MKEWrzyChTBe6clb5FQ==} + engines: {node: '>=16.0.0'} - '@smithy/middleware-endpoint@2.4.2': - resolution: {integrity: sha512-72qbmVwaWcLOd/OT52fszrrlXywPwciwpsRiIk/dIvpcwkpGE9qrYZ2bt/SYcA/ma8Rz9Ni2AbBuSXLDYISS+A==} - engines: {node: '>=14.0.0'} + '@smithy/middleware-content-length@3.0.10': + resolution: {integrity: sha512-T4dIdCs1d/+/qMpwhJ1DzOhxCZjZHbHazEPJWdB4GDi2HjIZllVzeBEcdJUN0fomV8DURsgOyrbEUzg3vzTaOg==} + engines: {node: '>=16.0.0'} - '@smithy/middleware-retry@2.1.2': - resolution: {integrity: sha512-tlvSK+v9bPHHb0dLWvEaFW2Iz0IeA57ISvSaso36I33u8F8wYqo5FCvenH7TgMVBx57jyJBXOmYCZa9n5gdJIg==} - engines: {node: '>=14.0.0'} + '@smithy/middleware-endpoint@3.2.1': + resolution: {integrity: sha512-wWO3xYmFm6WRW8VsEJ5oU6h7aosFXfszlz3Dj176pTij6o21oZnzkCLzShfmRaaCHDkBXWBdO0c4sQAvLFP6zA==} + engines: {node: '>=16.0.0'} - '@smithy/middleware-serde@2.1.2': - resolution: {integrity: sha512-XNU6aVIhlSbjuo2XsfZ7rd4HhjTXDlNWxAmhlBfViTW1TNK02CeWdeEntp5XtQKYD//pyTIbYi35EQvIidAkOw==} - engines: {node: '>=14.0.0'} + '@smithy/middleware-retry@3.0.25': + resolution: {integrity: sha512-m1F70cPaMBML4HiTgCw5I+jFNtjgz5z5UdGnUbG37vw6kh4UvizFYjqJGHvicfgKMkDL6mXwyPp5mhZg02g5sg==} + engines: {node: '>=16.0.0'} - '@smithy/middleware-stack@2.1.2': - resolution: {integrity: sha512-EPGaHGd4XmZcaRYjbhyqiqN/Q/ESxXu5e5TK24CTZUe99y8/XCxmiX8VLMM4H0DI7K3yfElR0wPAAvceoSkTgw==} - engines: {node: '>=14.0.0'} + '@smithy/middleware-serde@3.0.8': + resolution: {integrity: sha512-Xg2jK9Wc/1g/MBMP/EUn2DLspN8LNt+GMe7cgF+Ty3vl+Zvu+VeZU5nmhveU+H8pxyTsjrAkci8NqY6OuvZnjA==} + engines: {node: '>=16.0.0'} - '@smithy/node-config-provider@2.2.2': - resolution: {integrity: sha512-QXvpqHSijAm13ZsVkUo92b085UzDvYP1LblWTb3uWi9WilhDvYnVyPLXaryLhOWZ2YvdhK2170T3ZBqtg+quIQ==} - engines: {node: '>=14.0.0'} + '@smithy/middleware-stack@3.0.8': + resolution: {integrity: sha512-d7ZuwvYgp1+3682Nx0MD3D/HtkmZd49N3JUndYWQXfRZrYEnCWYc8BHcNmVsPAp9gKvlurdg/mubE6b/rPS9MA==} + engines: {node: '>=16.0.0'} - '@smithy/node-http-handler@2.4.0': - resolution: {integrity: sha512-Mf2f7MMy31W8LisJ9O+7J5cKiNwBwBBLU6biQ7/sFSFdhuOxPN7hOPoZ8vlaFjvrpfOUJw9YOpjGyNTKuvomOQ==} - engines: {node: '>=14.0.0'} + '@smithy/node-config-provider@3.1.9': + resolution: {integrity: sha512-qRHoah49QJ71eemjuS/WhUXB+mpNtwHRWQr77J/m40ewBVVwvo52kYAmb7iuaECgGTTcYxHS4Wmewfwy++ueew==} + engines: {node: '>=16.0.0'} - '@smithy/property-provider@2.1.2': - resolution: {integrity: sha512-yaXCVFKzxbSXqOoyA7AdAgXhwdjiLeui7n2P6XLjBCz/GZFdLUJgSY6KL1PevaxT4REMwUSs/bSHAe/0jdzEHw==} - engines: {node: '>=14.0.0'} + '@smithy/node-http-handler@3.2.5': + resolution: {integrity: sha512-PkOwPNeKdvX/jCpn0A8n9/TyoxjGZB8WVoJmm9YzsnAgggTj4CrjpRHlTQw7dlLZ320n1mY1y+nTRUDViKi/3w==} + engines: {node: '>=16.0.0'} - '@smithy/protocol-http@3.2.0': - resolution: {integrity: sha512-VRp0YITYIQum+rX4zeZ3cW1wl9r90IQzQN+VLS1NxdSMt6NLsJiJqR9czTxlaeWNrLHsFAETmjmdrS48Ug1liA==} - engines: {node: '>=14.0.0'} + '@smithy/property-provider@3.1.8': + resolution: {integrity: sha512-ukNUyo6rHmusG64lmkjFeXemwYuKge1BJ8CtpVKmrxQxc6rhUX0vebcptFA9MmrGsnLhwnnqeH83VTU9hwOpjA==} + engines: {node: '>=16.0.0'} - '@smithy/querystring-builder@2.1.2': - resolution: {integrity: sha512-wk6QpuvBBLJF5w8aADsZOtxaHY9cF5MZe1Ry3hSqqBxARdUrMoXi/jukUz5W0ftXGlbA398IN8dIIUj3WXqJXg==} - engines: {node: '>=14.0.0'} + '@smithy/protocol-http@4.1.5': + resolution: {integrity: sha512-hsjtwpIemmCkm3ZV5fd/T0bPIugW1gJXwZ/hpuVubt2hEUApIoUTrf6qIdh9MAWlw0vjMrA1ztJLAwtNaZogvg==} + engines: {node: '>=16.0.0'} - '@smithy/querystring-parser@2.1.2': - resolution: {integrity: sha512-z1yL5Iiagm/UxVy1tcuTFZdfOBK/QtYeK6wfClAJ7cOY7kIaYR6jn1cVXXJmhAQSh1b2ljP4xiZN4Ybj7Tbs5w==} - engines: {node: '>=14.0.0'} + '@smithy/querystring-builder@3.0.8': + resolution: {integrity: sha512-btYxGVqFUARbUrN6VhL9c3dnSviIwBYD9Rz1jHuN1hgh28Fpv2xjU1HeCeDJX68xctz7r4l1PBnFhGg1WBBPuA==} + engines: {node: '>=16.0.0'} - '@smithy/service-error-classification@2.1.2': - resolution: {integrity: sha512-R+gL1pAPuWkH6unFridk57wDH5PFY2IlVg2NUjSAjoaIaU+sxqKf/7AOWIcx9Bdn+xY0/4IRQ69urlC+F3I9gg==} - engines: {node: '>=14.0.0'} + '@smithy/querystring-parser@3.0.8': + resolution: {integrity: sha512-BtEk3FG7Ks64GAbt+JnKqwuobJNX8VmFLBsKIwWr1D60T426fGrV2L3YS5siOcUhhp6/Y6yhBw1PSPxA5p7qGg==} + engines: {node: '>=16.0.0'} - '@smithy/shared-ini-file-loader@2.3.2': - resolution: {integrity: sha512-idHGDJB+gBh+aaIjmWj6agmtNWftoyAenErky74hAtKyUaCvfocSBgEJ2pQ6o68svBluvGIj4NGFgJu0198mow==} - engines: {node: '>=14.0.0'} + '@smithy/service-error-classification@3.0.8': + resolution: {integrity: sha512-uEC/kCCFto83bz5ZzapcrgGqHOh/0r69sZ2ZuHlgoD5kYgXJEThCoTuw/y1Ub3cE7aaKdznb+jD9xRPIfIwD7g==} + engines: {node: '>=16.0.0'} - '@smithy/signature-v4@2.1.2': - resolution: {integrity: sha512-DdPWaNGIbxzyocR3ncH8xlxQgsqteRADEdCPoivgBzwv17UzKy2obtdi2vwNc5lAJ955bGEkkWef9O7kc1Eocg==} - engines: {node: '>=14.0.0'} + '@smithy/shared-ini-file-loader@3.1.9': + resolution: {integrity: sha512-/+OsJRNtoRbtsX0UpSgWVxFZLsJHo/4sTr+kBg/J78sr7iC+tHeOvOJrS5hCpVQ6sWBbhWLp1UNiuMyZhE6pmA==} + engines: {node: '>=16.0.0'} - '@smithy/smithy-client@2.4.0': - resolution: {integrity: sha512-6/jxk0om9l2s9BcgHtrBn+Hd3xcFGDzxfEJ2FvGpZxIz0S7bgvZg1gyR66O1xf1w9WZBH+W7JClhfSn2gETINw==} - engines: {node: '>=14.0.0'} + '@smithy/signature-v4@4.2.1': + resolution: {integrity: sha512-NsV1jF4EvmO5wqmaSzlnTVetemBS3FZHdyc5CExbDljcyJCEEkJr8ANu2JvtNbVg/9MvKAWV44kTrGS+Pi4INg==} + engines: {node: '>=16.0.0'} - '@smithy/types@2.10.0': - resolution: {integrity: sha512-QYXQmpIebS8/jYXgyJjCanKZbI4Rr8tBVGBAIdDhA35f025TVjJNW69FJ0TGiDqt+lIGo037YIswq2t2Y1AYZQ==} - engines: {node: '>=14.0.0'} + '@smithy/smithy-client@3.4.2': + resolution: {integrity: sha512-dxw1BDxJiY9/zI3cBqfVrInij6ShjpV4fmGHesGZZUiP9OSE/EVfdwdRz0PgvkEvrZHpsj2htRaHJfftE8giBA==} + engines: {node: '>=16.0.0'} - '@smithy/url-parser@2.1.2': - resolution: {integrity: sha512-KBPi740ciTujUaY+RfQuPABD0QFmgSBN5qNVDCGTryfsbG4jkwC0YnElSzi72m24HegMyxzZDLG4Oh4/97mw2g==} + '@smithy/types@3.6.0': + resolution: {integrity: sha512-8VXK/KzOHefoC65yRgCn5vG1cysPJjHnOVt9d0ybFQSmJgQj152vMn4EkYhGuaOmnnZvCPav/KnYyE6/KsNZ2w==} + engines: {node: '>=16.0.0'} - '@smithy/util-base64@2.1.1': - resolution: {integrity: sha512-UfHVpY7qfF/MrgndI5PexSKVTxSZIdz9InghTFa49QOvuu9I52zLPLUHXvHpNuMb1iD2vmc6R+zbv/bdMipR/g==} - engines: {node: '>=14.0.0'} + '@smithy/url-parser@3.0.8': + resolution: {integrity: sha512-4FdOhwpTW7jtSFWm7SpfLGKIBC9ZaTKG5nBF0wK24aoQKQyDIKUw3+KFWCQ9maMzrgTJIuOvOnsV2lLGW5XjTg==} - '@smithy/util-body-length-browser@2.1.1': - resolution: {integrity: sha512-ekOGBLvs1VS2d1zM2ER4JEeBWAvIOUKeaFch29UjjJsxmZ/f0L3K3x0dEETgh3Q9bkZNHgT+rkdl/J/VUqSRag==} + '@smithy/util-base64@3.0.0': + resolution: {integrity: sha512-Kxvoh5Qtt0CDsfajiZOCpJxgtPHXOKwmM+Zy4waD43UoEMA+qPxxa98aE/7ZhdnBFZFXMOiBR5xbcaMhLtznQQ==} + engines: {node: '>=16.0.0'} - '@smithy/util-body-length-node@2.2.1': - resolution: {integrity: sha512-/ggJG+ta3IDtpNVq4ktmEUtOkH1LW64RHB5B0hcr5ZaWBmo96UX2cIOVbjCqqDickTXqBWZ4ZO0APuaPrD7Abg==} - engines: {node: '>=14.0.0'} + '@smithy/util-body-length-browser@3.0.0': + resolution: {integrity: sha512-cbjJs2A1mLYmqmyVl80uoLTJhAcfzMOyPgjwAYusWKMdLeNtzmMz9YxNl3/jRLoxSS3wkqkf0jwNdtXWtyEBaQ==} - '@smithy/util-buffer-from@2.1.1': - resolution: {integrity: sha512-clhNjbyfqIv9Md2Mg6FffGVrJxw7bgK7s3Iax36xnfVj6cg0fUG7I4RH0XgXJF8bxi+saY5HR21g2UPKSxVCXg==} - engines: {node: '>=14.0.0'} + '@smithy/util-body-length-node@3.0.0': + resolution: {integrity: sha512-Tj7pZ4bUloNUP6PzwhN7K386tmSmEET9QtQg0TgdNOnxhZvCssHji+oZTUIuzxECRfG8rdm2PMw2WCFs6eIYkA==} + engines: {node: '>=16.0.0'} - '@smithy/util-config-provider@2.2.1': - resolution: {integrity: sha512-50VL/tx9oYYcjJn/qKqNy7sCtpD0+s8XEBamIFo4mFFTclKMNp+rsnymD796uybjiIquB7VCB/DeafduL0y2kw==} + '@smithy/util-buffer-from@2.2.0': + resolution: {integrity: sha512-IJdWBbTcMQ6DA0gdNhh/BwrLkDR+ADW5Kr1aZmd4k3DIF6ezMV4R2NIAmT08wQJ3yUK82thHWmC/TnK/wpMMIA==} engines: {node: '>=14.0.0'} - '@smithy/util-defaults-mode-browser@2.1.2': - resolution: {integrity: sha512-YmojdmsE7VbvFGJ/8btn/5etLm1HOQkgVX6nMWlB0yBL/Vb//s3aTebUJ66zj2+LNrBS3B9S+18+LQU72Yj0AQ==} + '@smithy/util-buffer-from@3.0.0': + resolution: {integrity: sha512-aEOHCgq5RWFbP+UDPvPot26EJHjOC+bRgse5A8V3FSShqd5E5UN4qc7zkwsvJPPAVsf73QwYcHN1/gt/rtLwQA==} + engines: {node: '>=16.0.0'} + + '@smithy/util-config-provider@3.0.0': + resolution: {integrity: sha512-pbjk4s0fwq3Di/ANL+rCvJMKM5bzAQdE5S/6RL5NXgMExFAi6UgQMPOm5yPaIWPpr+EOXKXRonJ3FoxKf4mCJQ==} + engines: {node: '>=16.0.0'} + + '@smithy/util-defaults-mode-browser@3.0.25': + resolution: {integrity: sha512-fRw7zymjIDt6XxIsLwfJfYUfbGoO9CmCJk6rjJ/X5cd20+d2Is7xjU5Kt/AiDt6hX8DAf5dztmfP5O82gR9emA==} engines: {node: '>= 10.0.0'} - '@smithy/util-defaults-mode-node@2.2.1': - resolution: {integrity: sha512-kof7M9Q2qP5yaQn8hHJL3KwozyvIfLe+ys7feifSul6gBAAeoraibo/MWqotb/I0fVLMlCMDwn7WXFsGUwnsew==} + '@smithy/util-defaults-mode-node@3.0.25': + resolution: {integrity: sha512-H3BSZdBDiVZGzt8TG51Pd2FvFO0PAx/A0mJ0EH8a13KJ6iUCdYnw/Dk/MdC1kTd0eUuUGisDFaxXVXo4HHFL1g==} engines: {node: '>= 10.0.0'} - '@smithy/util-endpoints@1.1.2': - resolution: {integrity: sha512-2/REfdcJ20y9iF+9kSBRBsaoGzjT5dZ3E6/TA45GHJuJAb/vZTj76VLTcrl2iN3fWXiDK1B8RxchaLGbr7RxxA==} - engines: {node: '>= 14.0.0'} + '@smithy/util-endpoints@2.1.4': + resolution: {integrity: sha512-kPt8j4emm7rdMWQyL0F89o92q10gvCUa6sBkBtDJ7nV2+P7wpXczzOfoDJ49CKXe5CCqb8dc1W+ZdLlrKzSAnQ==} + engines: {node: '>=16.0.0'} - '@smithy/util-hex-encoding@2.1.1': - resolution: {integrity: sha512-3UNdP2pkYUUBGEXzQI9ODTDK+Tcu1BlCyDBaRHwyxhA+8xLP8agEKQq4MGmpjqb4VQAjq9TwlCQX0kP6XDKYLg==} - engines: {node: '>=14.0.0'} + '@smithy/util-hex-encoding@3.0.0': + resolution: {integrity: sha512-eFndh1WEK5YMUYvy3lPlVmYY/fZcQE1D8oSf41Id2vCeIkKJXPcYDCZD+4+xViI6b1XSd7tE+s5AmXzz5ilabQ==} + engines: {node: '>=16.0.0'} - '@smithy/util-middleware@2.1.2': - resolution: {integrity: sha512-lvSOnwQ7iAajtWb1nAyy0CkOIn8d+jGykQOtt2NXDsPzOTfejZM/Uph+O/TmVgWoXdcGuw5peUMG2f5xEIl6UQ==} - engines: {node: '>=14.0.0'} + '@smithy/util-middleware@3.0.8': + resolution: {integrity: sha512-p7iYAPaQjoeM+AKABpYWeDdtwQNxasr4aXQEA/OmbOaug9V0odRVDy3Wx4ci8soljE/JXQo+abV0qZpW8NX0yA==} + engines: {node: '>=16.0.0'} - '@smithy/util-retry@2.1.2': - resolution: {integrity: sha512-pqifOgRqwLfRu+ks3awEKKqPeYxrHLwo4Yu2EarGzeoarTd1LVEyyf5qLE6M7IiCsxnXRhn9FoWIdZOC+oC/VQ==} - engines: {node: '>= 14.0.0'} + '@smithy/util-retry@3.0.8': + resolution: {integrity: sha512-TCEhLnY581YJ+g1x0hapPz13JFqzmh/pMWL2KEFASC51qCfw3+Y47MrTmea4bUE5vsdxQ4F6/KFbUeSz22Q1ow==} + engines: {node: '>=16.0.0'} - '@smithy/util-stream@2.1.2': - resolution: {integrity: sha512-AbGjvoSok7YeUKv9WRVRSChQfsufLR54YCAabTbaABRdIucywRQs29em0uAP6r4RLj+4aFZStWGYpFgT0P8UlQ==} - engines: {node: '>=14.0.0'} + '@smithy/util-stream@3.2.1': + resolution: {integrity: sha512-R3ufuzJRxSJbE58K9AEnL/uSZyVdHzud9wLS8tIbXclxKzoe09CRohj2xV8wpx5tj7ZbiJaKYcutMm1eYgz/0A==} + engines: {node: '>=16.0.0'} - '@smithy/util-uri-escape@2.1.1': - resolution: {integrity: sha512-saVzI1h6iRBUVSqtnlOnc9ssU09ypo7n+shdQ8hBTZno/9rZ3AuRYvoHInV57VF7Qn7B+pFJG7qTzFiHxWlWBw==} - engines: {node: '>=14.0.0'} + '@smithy/util-uri-escape@3.0.0': + resolution: {integrity: sha512-LqR7qYLgZTD7nWLBecUi4aqolw8Mhza9ArpNEQ881MJJIU2sE5iHCK6TdyqqzcDLy0OPe10IY4T8ctVdtynubg==} + engines: {node: '>=16.0.0'} - '@smithy/util-utf8@2.1.1': - resolution: {integrity: sha512-BqTpzYEcUMDwAKr7/mVRUtHDhs6ZoXDi9NypMvMfOr/+u1NW7JgqodPDECiiLboEm6bobcPcECxzjtQh865e9A==} + '@smithy/util-utf8@2.3.0': + resolution: {integrity: sha512-R8Rdn8Hy72KKcebgLiv8jQcQkXoLMOGGv5uI1/k0l+snqkOzQ1R0ChUBCxWMlBsFMekWjq0wRudIweFs7sKT5A==} engines: {node: '>=14.0.0'} + '@smithy/util-utf8@3.0.0': + resolution: {integrity: sha512-rUeT12bxFnplYDe815GXbq/oixEGHfRFFtcTF3YdDi/JaENIM6aSYYLJydG83UNzLXeRI5K8abYd/8Sp/QM0kA==} + engines: {node: '>=16.0.0'} + + '@solidity-parser/parser@0.14.5': + resolution: {integrity: sha512-6dKnHZn7fg/iQATVEzqyUOyEidbn05q7YA2mQ9hC0MMXhhV3/JrsxmFSYZAcr7j1yUP700LLhTruvJ3MiQmjJg==} + + '@solidity-parser/parser@0.18.0': + resolution: {integrity: sha512-yfORGUIPgLck41qyN7nbwJRAx17/jAIXCTanHOJZhB6PJ1iAk/84b/xlsVKFSyNyLXIj0dhppoE0+CRws7wlzA==} + '@szmarczak/http-timer@4.0.6': resolution: {integrity: sha512-4BAffykYOgO+5nzBWYwE3W90sBgLJoUPRWWcL8wlyiM8IB8ipJz3UMJ9KXQd1RKQXpKp8Tutn80HZtWsu2u76w==} engines: {node: '>=10'} @@ -2455,15 +2322,11 @@ packages: '@tootallnate/quickjs-emscripten@0.23.0': resolution: {integrity: sha512-C5Mc6rdnsaJDjO3UpGW/CQTHtCKaYlScZTly4JIu97Jxo/odCiH0ITnDXSJPTOrEKk/ycSZ0AOgTmkDtkOsvIA==} - '@trufflesuite/bigint-buffer@1.1.10': - resolution: {integrity: sha512-pYIQC5EcMmID74t26GCC67946mgTJFiLXOT/BYozgrd4UEY2JHEGLhWi9cMiQCt5BSqFEvKkCHNnoj82SRjiEw==} - engines: {node: '>= 14.0.0'} - '@trufflesuite/uws-js-unofficial@20.30.0-unofficial.0': resolution: {integrity: sha512-r5X0aOQcuT6pLwTRLD+mPnAM/nlKtvIK4Z+My++A8tTOR0qTjNRx8UB8jzRj3D+p9PMAp5LnpCUUGmz7/TppwA==} - '@tsconfig/node10@1.0.9': - resolution: {integrity: sha512-jNsYVVxU8v5g43Erja32laIDHXeoNvFEpX33OK4d6hljo3jDhCBDhx5dhCCTMWUojscpAagGiRkBKxpdl9fxqA==} + '@tsconfig/node10@1.0.11': + resolution: {integrity: sha512-DcRjDCujK/kCk/cUe8Xz8ZSpm8mS3mNNpta+jGCA6USEDfktlNvm1+IuZ9eTcDbNk41BHwpHHeW+N1lKCz4zOw==} '@tsconfig/node12@1.0.11': resolution: {integrity: sha512-cqefuRsh12pWyGsIoBKJA9luFu3mRxCA+ORZvA4ktLSzIuCUtWVxGIuXigEwO5/ywWFMZ2QEGKWvkZG1zDMTag==} @@ -2474,34 +2337,26 @@ packages: '@tsconfig/node16@1.0.4': resolution: {integrity: sha512-vxhUy4J8lyeyinH7Azl1pdd43GJhZH/tP2weN8TntQblOY+A0XbT8DJk1/oCPuOOyg/Ja757rG0CgHcWC8OfMA==} - '@typechain/ethers-v5@10.2.1': - resolution: {integrity: sha512-n3tQmCZjRE6IU4h6lqUGiQ1j866n5MTCBJreNEHHVWXa2u9GJTaeYyU1/k+1qLutkyw+sS6VAN+AbeiTqsxd/A==} + '@typechain/ethers-v6@0.5.1': + resolution: {integrity: sha512-F+GklO8jBWlsaVV+9oHaPh5NJdd6rAKN4tklGfInX1Q7h0xPgVLP39Jl3eCulPB5qexI71ZFHwbljx4ZXNfouA==} peerDependencies: - '@ethersproject/abi': ^5.0.0 - '@ethersproject/providers': ^5.0.0 - ethers: ^5.1.3 - typechain: ^8.1.1 - typescript: '>=4.3.0' + ethers: 6.x + typechain: ^8.3.2 + typescript: '>=4.7.0' - '@typechain/ethers-v5@7.2.0': - resolution: {integrity: sha512-jfcmlTvaaJjng63QsT49MT6R1HFhtO/TBMWbyzPFSzMmVIqb2tL6prnKBs4ZJrSvmgIXWy+ttSjpaxCTq8D/Tw==} + '@typechain/hardhat@9.1.0': + resolution: {integrity: sha512-mtaUlzLlkqTlfPwB3FORdejqBskSnh+Jl8AIJGjXNAQfRQ4ofHADPl1+oU7Z3pAJzmZbUXII8MhOLQltcHgKnA==} peerDependencies: - '@ethersproject/abi': ^5.0.0 - '@ethersproject/bytes': ^5.0.0 - '@ethersproject/providers': ^5.0.0 - ethers: ^5.1.3 - typechain: ^5.0.0 - typescript: '>=4.0.0' - - '@types/bignumber.js@5.0.0': - resolution: {integrity: sha512-0DH7aPGCClywOFaxxjE6UwpN2kQYe9LwuDQMv+zYA97j5GkOMo8e66LYT+a8JYU7jfmUFRZLa9KycxHDsKXJCA==} - deprecated: This is a stub types definition for bignumber.js (https://github.com/MikeMcl/bignumber.js/). bignumber.js provides its own type definitions, so you don't need @types/bignumber.js installed! + '@typechain/ethers-v6': ^0.5.1 + ethers: ^6.1.0 + hardhat: ^2.9.9 + typechain: ^8.3.2 '@types/bn.js@4.11.6': resolution: {integrity: sha512-pqr857jrp2kPuO9uRjZ3PwnJTjoQy+fcdxvBTvHm6dkmEL9q+hDD/2j/0ELOBPtPnS8LjCX0gI9nbl8lVkadpg==} - '@types/bn.js@5.1.5': - resolution: {integrity: sha512-V46N0zwKRF5Q00AZ6hWtN0T8gGmDUaUzLWQvHFo5yThtVwK/VCenFY3wXVbOvNfajEpsTfQM4IN9k/d6gUVX3A==} + '@types/bn.js@5.1.6': + resolution: {integrity: sha512-Xh8vSwUeMKeYYrj3cX4lGQgFSF/N03r+tv4AiLl1SucqV+uTQpxRcnM8AkXKHwYP9ZPXOYXRr2KPXpVlIvqh9w==} '@types/cacheable-request@6.0.3': resolution: {integrity: sha512-IQ3EbTzGxIigb1I3qPZc1rWJnH0BmSKv5QYTalEwweFvyBDLSAe24zP0le/hyi7ecGfZVlIVAg4BZqb8WBwKqw==} @@ -2509,29 +2364,23 @@ packages: '@types/chai-as-promised@7.1.8': resolution: {integrity: sha512-ThlRVIJhr69FLlh6IctTXFkmhtP3NpMZ2QGq69StYLyKZFp/HOp1VdKZj7RvfNWYYcJ1xlbLGLLWj1UvP5u/Gw==} - '@types/chai@4.3.12': - resolution: {integrity: sha512-zNKDHG/1yxm8Il6uCCVsm+dRdEsJlFoDu73X17y09bId6UwoYww+vFBsAcRzl8knM1sab3Dp1VRikFQwDOtDDw==} + '@types/chai@4.3.20': + resolution: {integrity: sha512-/pC9HAB5I/xMlc5FP77qjCnI16ChlJfW0tGa0IUcFn38VJrTV6DeZ60NU5KZBtaOZqjdpwTWohz5HU1RrhiYxQ==} + + '@types/concat-stream@1.6.1': + resolution: {integrity: sha512-eHE4cQPoj6ngxBZMvVf6Hw7Mh4jMW4U9lpGmS5GBPB9RYxlFg+CHaVN7ErNY4W9XfLIEn20b4VDYaIrbq0q4uA==} '@types/cors@2.8.17': resolution: {integrity: sha512-8CGDvrBj1zgo2qE+oS3pOCyYNqCPryMWY2bGfwA0dcfopWGgxs+78df0Rs3rc9THP4JkOhLsAa+15VdpAqkcUA==} - '@types/debug@4.1.12': - resolution: {integrity: sha512-vIChWdVG3LG1SMxEvI/AK+FWJthlrqlTu7fbrlywTkkaONwk/UAGaULXRlf8vkzFBLVm0zkMdCquhL5aOjhXPQ==} - - '@types/eslint-scope@3.7.7': - resolution: {integrity: sha512-MzMFlSLBqNF2gcHWO0G1vP/YQyfvrxZ0bF+u7mzUdZ1/xK4A4sru+nraZz5i3iEIk1l1uyicaDVTB4QbbEkAYg==} - - '@types/eslint@8.56.3': - resolution: {integrity: sha512-PvSf1wfv2wJpVIFUMSb+i4PvqNYkB9Rkp9ZDO3oaWzq4SKhsQk4mrMBr3ZH06I0hKrVGLBacmgl8JM4WVjb9dg==} - '@types/estree@0.0.39': resolution: {integrity: sha512-EYNwp3bU+98cpU4lAWYYL7Zz+2gryWH1qbdDTidVd6hkiR6weksdbMadyXKXNPEkQFhXM+hVO9ZygomHXp+AIw==} - '@types/estree@1.0.5': - resolution: {integrity: sha512-/kYRxGDLWzHOB7q+wtSUQlFrtcdUccpfy+X+9iMBpHK8QLLhx2wIPYuS5DYtR9Wa/YlZAbIovy7qVdB1Aq6Lyw==} + '@types/estree@1.0.6': + resolution: {integrity: sha512-AYnb1nQyY49te+VRAVgmzfcgjYS91mY5P0TKUDCLEM+gNnA+3T6rWITXRLYCpahpqSQbN5cE+gHpnPyXjHWxcw==} - '@types/ethereum-protocol@1.0.5': - resolution: {integrity: sha512-4wr+t2rYbwMmDrT447SGzE/43Z0EN++zyHCBoruIx32fzXQDxVa1rnQbYwPO8sLP2OugE/L8KaAIJC5kieUuBg==} + '@types/form-data@0.0.33': + resolution: {integrity: sha512-8BSvG1kGm83cyJITQMZSulnl6QV8jqAGreJsc5tPu1Jq0vTSOiY/k24Wx82JRpWwZSqrala6sd5rWi6aNXvqcw==} '@types/glob@7.2.0': resolution: {integrity: sha512-ZUxbzKl0IfJILTS6t7ip5fQQM/J3TJYubDm3nMbgubNNYS62eXeUpoLUC8/7fJNiFYHTrGPQn7hspDUzIHX3UA==} @@ -2561,23 +2410,23 @@ packages: '@types/minimatch@5.1.2': resolution: {integrity: sha512-K0VQKziLUWkVKiRVrx4a40iPaxTUefQmjtkQofBkYRcoaaL/8rhwDWww9qWbrgicNOgnpIsMxyNIUM4+n6dUIA==} - '@types/minimist@1.2.5': - resolution: {integrity: sha512-hov8bUuiLiyFPGyFPE1lwWhmzYbirOXQNNo40+y3zow8aFVTeyn3VWL0VFFfdNddA8S4Vf0Tc062rzyNr7Paag==} + '@types/mocha@10.0.9': + resolution: {integrity: sha512-sicdRoWtYevwxjOHNMPTl3vSfJM6oyW8o1wXeI7uww6b6xHg8eBznQDNSGBCDJmsE8UMxP05JgZRtsKbTqt//Q==} - '@types/mocha@10.0.6': - resolution: {integrity: sha512-dJvrYWxP/UcXm36Qn36fxhUKu8A/xMRXVT2cliFF1Z7UA9liG5Psj3ezNSZw+5puH2czDXRLcXQxf8JbJt0ejg==} - - '@types/ms@0.7.34': - resolution: {integrity: sha512-nG96G3Wp6acyAgJqGasjODb+acrI7KltPiRxzHPXnP3NgI28bpQDRv53olbqGXbfcgF5aiiHmO3xpwEpS5Ld9g==} + '@types/node@10.17.60': + resolution: {integrity: sha512-F0KIgDJfy2nA3zMLmWGKxcH2ZVEtCZXHHdOQs2gSaQ27+lNeEfGxzkIw90aXswATX7AZ33tahPbzy6KAfUreVw==} '@types/node@12.20.55': resolution: {integrity: sha512-J8xLz7q2OFulZ2cyGTLE1TbbZcjpno7FaN6zdJNrgAdrJ+DZzh/uFR6YrTb4C+nXakvud8Q4+rbhoIWlYQbUFQ==} - '@types/node@20.11.20': - resolution: {integrity: sha512-7/rR21OS+fq8IyHTgtLkDK949uzsa6n8BkziAKtPVpugIkO6D+/ooXMvzXxDnZrmtXVfjb1bKQafYpb8s89LOg==} + '@types/node@22.7.5': + resolution: {integrity: sha512-jML7s2NAzMWc//QSJ1a3prpk78cOPchGvXJsC3C6R6PSMoooztvRVQEz89gmBTBY1SPMaqo5teB4uNHPdetShQ==} + + '@types/node@22.7.9': + resolution: {integrity: sha512-jrTfRC7FM6nChvU7X2KqcrgquofrWLFDeYC1hKfwNWomVvrn7JIksqf344WN2X/y8xrgqBd2dJATZV4GbatBfg==} - '@types/normalize-package-data@2.4.4': - resolution: {integrity: sha512-37i+OaWTh9qeK4LSHPsyRC7NahnGotNuZvjLSgcPzblpHB3rrCJxAOgI5gCdKm7coonsaX1Of0ILiTcnZjbfxA==} + '@types/node@8.10.66': + resolution: {integrity: sha512-tktOkFUA4kXx2hhhrB8bIFb5TbwzS4uOhKEmwiD+NoiL0qtP2OQ9mFldbgD4dV1djrlBYP6eBuQZiWjuHUpqFw==} '@types/pbkdf2@3.1.2': resolution: {integrity: sha512-uRwJqmiXmh9++aSu1VNEn3iIxWOhd8AHXNSdlaLfdAAdSTY9jYVeGWnzejM3dvrkbqE3/hyQkQQ29IFATEGlew==} @@ -2585,8 +2434,8 @@ packages: '@types/prettier@2.7.3': resolution: {integrity: sha512-+68kP9yzs4LMp7VNh8gdzMSPZFL44MLGqiHWvttYJe+6qnuVr4Ek9wSBQoveqY/r+LwjCcU29kNVkidwim+kYA==} - '@types/readable-stream@2.3.15': - resolution: {integrity: sha512-oM5JSKQCcICF1wvGgmecmHldZ48OZamtMxcGGVICOJA8o8cahXC1zEVAif8iwoc5j8etxFaRFnf095+CDsuoFQ==} + '@types/qs@6.9.16': + resolution: {integrity: sha512-7i+zxXdPD0T4cKDuxCUXJ4wHcsJLwENa6Z3dCu8cfCK743OGy5Nu1RmAGqDPsoTDINVEcdXKRvR/zre+P2Ku1A==} '@types/resolve@1.17.1': resolution: {integrity: sha512-yy7HuzQhj0dhGpD8RLXSZWEkLsV9ibvxvi6EiJ3bkqLAO1RGo0WbkWQiwpRlSFymTJRz0d3k5LM3kkx8ArDbLw==} @@ -2600,89 +2449,82 @@ packages: '@types/seedrandom@3.0.1': resolution: {integrity: sha512-giB9gzDeiCeloIXDgzFBCgjj1k4WxcDrZtGl6h1IqmUPlxF+Nx8Ve+96QCyDZ/HseB/uvDsKbpib9hU5cU53pw==} - '@types/semver@7.5.8': - resolution: {integrity: sha512-I8EUhyrgfLrcTkzV3TSsGyl1tSuPrEDzr0yd5m90UgNxQkyDXULk3b6MlQqTCpZpNtWe1K0hzclnZkTcLBe2UQ==} - - '@types/web3-provider-engine@14.0.4': - resolution: {integrity: sha512-59wFvtceRmWXfQFoH8qtFIQZf6B7PqBwgBBmZLu4SjRK6pycnjV8K+jihbaGOFwHjTPcPFm15m+CS6I0BBm4lw==} - '@types/webextension-polyfill@0.10.7': resolution: {integrity: sha512-10ql7A0qzBmFB+F+qAke/nP1PIonS0TXZAOMVOxEUsm+lGSW6uwVcISFNa0I4Oyj0884TZVWGGMIWeXOVSNFHw==} - '@types/ws@8.5.10': - resolution: {integrity: sha512-vmQSUcfalpIq0R9q7uTo2lXs6eGIpt9wtnLdMv9LVpIjCA/+ufZRozlVoVelIYixx1ugCBKDhn89vnsEGOCx9A==} + '@types/ws@8.5.12': + resolution: {integrity: sha512-3tPRkv1EtkDpzlgyKyI8pGsGZAGPEaXeu0DOj5DI25Ja91bdAYddYHbADRYVrZMRbfW+1l5YwXVDKohDJNQxkQ==} '@types/yauzl@2.10.3': resolution: {integrity: sha512-oJoftv0LSuaDZE3Le4DbKX+KS9G36NzOeSap90UIK0yMA/NhKJhqlSGtNDORNRaIbQfzjXDrQa0ytJ6mNRGz/Q==} - '@typescript-eslint/eslint-plugin@6.21.0': - resolution: {integrity: sha512-oy9+hTPCUFpngkEZUSzbf9MxI65wbKFoQYsgPdILTfbUldp5ovUuphZVe4i30emU9M/kP+T64Di0mxl7dSw3MA==} - engines: {node: ^16.0.0 || >=18.0.0} + '@typescript-eslint/eslint-plugin@8.11.0': + resolution: {integrity: sha512-KhGn2LjW1PJT2A/GfDpiyOfS4a8xHQv2myUagTM5+zsormOmBlYsnQ6pobJ8XxJmh6hnHwa2Mbe3fPrDJoDhbA==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} peerDependencies: - '@typescript-eslint/parser': ^6.0.0 || ^6.0.0-alpha - eslint: ^7.0.0 || ^8.0.0 + '@typescript-eslint/parser': ^8.0.0 || ^8.0.0-alpha.0 + eslint: ^8.57.0 || ^9.0.0 typescript: '*' peerDependenciesMeta: typescript: optional: true - '@typescript-eslint/parser@6.21.0': - resolution: {integrity: sha512-tbsV1jPne5CkFQCgPBcDOt30ItF7aJoZL997JSF7MhGQqOeT3svWRYxiqlfA5RUdlHN6Fi+EI9bxqbdyAUZjYQ==} - engines: {node: ^16.0.0 || >=18.0.0} + '@typescript-eslint/parser@8.11.0': + resolution: {integrity: sha512-lmt73NeHdy1Q/2ul295Qy3uninSqi6wQI18XwSpm8w0ZbQXUpjCAWP1Vlv/obudoBiIjJVjlztjQ+d/Md98Yxg==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} peerDependencies: - eslint: ^7.0.0 || ^8.0.0 + eslint: ^8.57.0 || ^9.0.0 typescript: '*' peerDependenciesMeta: typescript: optional: true - '@typescript-eslint/scope-manager@6.21.0': - resolution: {integrity: sha512-OwLUIWZJry80O99zvqXVEioyniJMa+d2GrqpUTqi5/v5D5rOrppJVBPa0yKCblcigC0/aYAzxxqQ1B+DS2RYsg==} - engines: {node: ^16.0.0 || >=18.0.0} + '@typescript-eslint/scope-manager@8.11.0': + resolution: {integrity: sha512-Uholz7tWhXmA4r6epo+vaeV7yjdKy5QFCERMjs1kMVsLRKIrSdM6o21W2He9ftp5PP6aWOVpD5zvrvuHZC0bMQ==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - '@typescript-eslint/type-utils@6.21.0': - resolution: {integrity: sha512-rZQI7wHfao8qMX3Rd3xqeYSMCL3SoiSQLBATSiVKARdFGCYSRvmViieZjqc58jKgs8Y8i9YvVVhRbHSTA4VBag==} - engines: {node: ^16.0.0 || >=18.0.0} + '@typescript-eslint/type-utils@8.11.0': + resolution: {integrity: sha512-ItiMfJS6pQU0NIKAaybBKkuVzo6IdnAhPFZA/2Mba/uBjuPQPet/8+zh5GtLHwmuFRShZx+8lhIs7/QeDHflOg==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} peerDependencies: - eslint: ^7.0.0 || ^8.0.0 typescript: '*' peerDependenciesMeta: typescript: optional: true - '@typescript-eslint/types@6.21.0': - resolution: {integrity: sha512-1kFmZ1rOm5epu9NZEZm1kckCDGj5UJEf7P1kliH4LKu/RkwpsfqqGmY2OOcUs18lSlQBKLDYBOGxRVtrMN5lpg==} - engines: {node: ^16.0.0 || >=18.0.0} + '@typescript-eslint/types@8.11.0': + resolution: {integrity: sha512-tn6sNMHf6EBAYMvmPUaKaVeYvhUsrE6x+bXQTxjQRp360h1giATU0WvgeEys1spbvb5R+VpNOZ+XJmjD8wOUHw==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - '@typescript-eslint/typescript-estree@6.21.0': - resolution: {integrity: sha512-6npJTkZcO+y2/kr+z0hc4HwNfrrP4kNYh57ek7yCNlrBjWQ1Y0OS7jiZTkgumrvkX5HkEKXFZkkdFNkaW2wmUQ==} - engines: {node: ^16.0.0 || >=18.0.0} + '@typescript-eslint/typescript-estree@8.11.0': + resolution: {integrity: sha512-yHC3s1z1RCHoCz5t06gf7jH24rr3vns08XXhfEqzYpd6Hll3z/3g23JRi0jM8A47UFKNc3u/y5KIMx8Ynbjohg==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} peerDependencies: typescript: '*' peerDependenciesMeta: typescript: optional: true - '@typescript-eslint/utils@6.21.0': - resolution: {integrity: sha512-NfWVaC8HP9T8cbKQxHcsJBY5YE1O33+jpMwN45qzWWaPDZgLIbo12toGMWnmhvCpd3sIxkpDw3Wv1B3dYrbDQQ==} - engines: {node: ^16.0.0 || >=18.0.0} + '@typescript-eslint/utils@8.11.0': + resolution: {integrity: sha512-CYiX6WZcbXNJV7UNB4PLDIBtSdRmRI/nb0FMyqHPTQD1rMjA0foPLaPUV39C/MxkTd/QKSeX+Gb34PPsDVC35g==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} peerDependencies: - eslint: ^7.0.0 || ^8.0.0 + eslint: ^8.57.0 || ^9.0.0 - '@typescript-eslint/visitor-keys@6.21.0': - resolution: {integrity: sha512-JJtkDduxLi9bivAB+cYOVMtbkqdPOhZ+ZI5LC47MIRrDV4Yn2o+ZnW10Nkmr28xRpSpdJ6Sm42Hjf2+REYXm0A==} - engines: {node: ^16.0.0 || >=18.0.0} + '@typescript-eslint/visitor-keys@8.11.0': + resolution: {integrity: sha512-EaewX6lxSjRJnc+99+dqzTeoDZUfyrA52d2/HRrkI830kgovWsmIiTfmr0NZorzqic7ga+1bS60lRBUgR3n/Bw==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} '@ungap/structured-clone@1.2.0': resolution: {integrity: sha512-zuVdFrMJiuCDQUMCzQaD6KL28MjnqqN8XnAqiEq9PNm/hCPTSGfrXCOfwj1ow4LFb/tNymJPwsNbVePc1xFqrQ==} - '@vercel/nft@0.26.4': - resolution: {integrity: sha512-j4jCOOXke2t8cHZCIxu1dzKLHLcFmYzC3yqAK6MfZznOL1QIJKd0xcFsXK3zcqzU7ScsE2zWkiMMNHGMHgp+FA==} + '@vercel/nft@0.26.5': + resolution: {integrity: sha512-NHxohEqad6Ra/r4lGknO52uc/GrWILXAMs1BB4401GTqww0fw1bAqzpG1XHuDO+dprg4GvsD9ZLLSsdo78p9hQ==} engines: {node: '>=16'} hasBin: true - '@webassemblyjs/ast@1.11.6': - resolution: {integrity: sha512-IN1xI7PwOvLPgjcf180gC1bqn3q/QaOCwYUahIOhbYUu8KA/3tw2RT/T0Gidi1l7Hhj5D/INhJxiICObqpMu4Q==} + '@webassemblyjs/ast@1.12.1': + resolution: {integrity: sha512-EKfMUOPRRUTy5UII4qJDGPpqfwjOmZ5jeGFwid9mnoqIFK+e0vqoi1qH56JpmZSzEL53jKnNzScdmftJyG5xWg==} '@webassemblyjs/floating-point-hex-parser@1.11.6': resolution: {integrity: sha512-ejAj9hfRJ2XMsNHk/v6Fu2dGS+i4UaXBXGemOfQ/JfQ6mdQg/WXtwleQRLLS4OvfDhv8rYnVwH27YJLMyYsxhw==} @@ -2690,8 +2532,8 @@ packages: '@webassemblyjs/helper-api-error@1.11.6': resolution: {integrity: sha512-o0YkoP4pVu4rN8aTJgAyj9hC2Sv5UlkzCHhxqWj8butaLvnpdc2jOwh4ewE6CX0txSfLn/UYaV/pheS2Txg//Q==} - '@webassemblyjs/helper-buffer@1.11.6': - resolution: {integrity: sha512-z3nFzdcp1mb8nEOFFk8DrYLpHvhKC3grJD2ardfKOzmbmJvEf/tPIqCY+sNcwZIY8ZD7IkB2l7/pqhUhqm7hLA==} + '@webassemblyjs/helper-buffer@1.12.1': + resolution: {integrity: sha512-nzJwQw99DNDKr9BVCOZcLuJJUlqkJh+kVzVl6Fmq/tI5ZtEyWT1KZMyOXltXLZJmDtvLCDgwsyrkohEtopTXCw==} '@webassemblyjs/helper-numbers@1.11.6': resolution: {integrity: sha512-vUIhZ8LZoIWHBohiEObxVm6hwP034jwmc9kuq5GdHZH0wiLVLIPcMCdpJzG4C11cHoQ25TFIQj9kaVADVX7N3g==} @@ -2699,8 +2541,8 @@ packages: '@webassemblyjs/helper-wasm-bytecode@1.11.6': resolution: {integrity: sha512-sFFHKwcmBprO9e7Icf0+gddyWYDViL8bpPjJJl0WHxCdETktXdmtWLGVzoHbqUcY4Be1LkNfwTmXOJUFZYSJdA==} - '@webassemblyjs/helper-wasm-section@1.11.6': - resolution: {integrity: sha512-LPpZbSOwTpEC2cgn4hTydySy1Ke+XEu+ETXuoyvuyezHO3Kjdu90KK95Sh9xTbmjrCsUwvWwCOQQNta37VrS9g==} + '@webassemblyjs/helper-wasm-section@1.12.1': + resolution: {integrity: sha512-Jif4vfB6FJlUlSbgEMHUyk1j234GTNG9dBJ4XJdOySoj518Xj0oGsNi59cUQF4RRMS9ouBUxDDdyBVfPTypa5g==} '@webassemblyjs/ieee754@1.11.6': resolution: {integrity: sha512-LM4p2csPNvbij6U1f19v6WR56QZ8JcHg3QIJTlSwzFcmx6WSORicYj6I63f9yU1kEUtrpG+kjkiIAkevHpDXrg==} @@ -2711,20 +2553,20 @@ packages: '@webassemblyjs/utf8@1.11.6': resolution: {integrity: sha512-vtXf2wTQ3+up9Zsg8sa2yWiQpzSsMyXj0qViVP6xKGCUT8p8YJ6HqI7l5eCnWx1T/FYdsv07HQs2wTFbbof/RA==} - '@webassemblyjs/wasm-edit@1.11.6': - resolution: {integrity: sha512-Ybn2I6fnfIGuCR+Faaz7YcvtBKxvoLV3Lebn1tM4o/IAJzmi9AWYIPWpyBfU8cC+JxAO57bk4+zdsTjJR+VTOw==} + '@webassemblyjs/wasm-edit@1.12.1': + resolution: {integrity: sha512-1DuwbVvADvS5mGnXbE+c9NfA8QRcZ6iKquqjjmR10k6o+zzsRVesil54DKexiowcFCPdr/Q0qaMgB01+SQ1u6g==} - '@webassemblyjs/wasm-gen@1.11.6': - resolution: {integrity: sha512-3XOqkZP/y6B4F0PBAXvI1/bky7GryoogUtfwExeP/v7Nzwo1QLcq5oQmpKlftZLbT+ERUOAZVQjuNVak6UXjPA==} + '@webassemblyjs/wasm-gen@1.12.1': + resolution: {integrity: sha512-TDq4Ojh9fcohAw6OIMXqiIcTq5KUXTGRkVxbSo1hQnSy6lAM5GSdfwWeSxpAo0YzgsgF182E/U0mDNhuA0tW7w==} - '@webassemblyjs/wasm-opt@1.11.6': - resolution: {integrity: sha512-cOrKuLRE7PCe6AsOVl7WasYf3wbSo4CeOk6PkrjS7g57MFfVUF9u6ysQBBODX0LdgSvQqRiGz3CXvIDKcPNy4g==} + '@webassemblyjs/wasm-opt@1.12.1': + resolution: {integrity: sha512-Jg99j/2gG2iaz3hijw857AVYekZe2SAskcqlWIZXjji5WStnOpVoat3gQfT/Q5tb2djnCjBtMocY/Su1GfxPBg==} - '@webassemblyjs/wasm-parser@1.11.6': - resolution: {integrity: sha512-6ZwPeGzMJM3Dqp3hCsLgESxBGtT/OeCvCZ4TA1JUPYgmhAx38tTPR9JaKy0S5H3evQpO/h2uWs2j6Yc/fjkpTQ==} + '@webassemblyjs/wasm-parser@1.12.1': + resolution: {integrity: sha512-xikIi7c2FHXysxXe3COrVUPSheuBtpcfhbpFj4gmu7KRLYOzANztwUU0IbsqvMqzuNK2+glRGWCEqZo1WCLyAQ==} - '@webassemblyjs/wast-printer@1.11.6': - resolution: {integrity: sha512-JM7AhRcE+yW2GWYaKeHL5vt4xqee5N2WcezptmgyhNS+ScggqcT1OtXykhAb13Sn5Yas0j2uv9tHgrjwvzAP4A==} + '@webassemblyjs/wast-printer@1.12.1': + resolution: {integrity: sha512-+X4WAlOisVWQMikjbcvY2e0rwPsKQ9F688lksZhBcPycBBuii3O7m8FACbDMWDojpAqvjIncrG8J0XHKyQfVeA==} '@webpack-cli/configtest@1.2.0': resolution: {integrity: sha512-4FB8Tj6xyVkyqjj1OaTqCjXYULB9FMkqQ8yGrZjRDrYh0nOE+7Lhs45WioWQQMV+ceFlE368Ukhe6xdvJM9Egg==} @@ -2752,6 +2594,9 @@ packages: '@xtuc/long@4.2.2': resolution: {integrity: sha512-NuHqBY1PB/D8xU6s/thBgOAiAP7HOYDQ32+BFZILJ8ivkUkAHQnWfn6WhL79Owj1qmUnoN/YPhktdIoucipkAQ==} + abbrev@1.0.9: + resolution: {integrity: sha512-LEyx4aLEC3x6T0UguF6YILf+ntvmOaWsVfENmIW0E9H09vKlLDGelMjjSm0jkDHALj8A8quZ/HapKNigzwge+Q==} + abbrev@1.1.1: resolution: {integrity: sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==} @@ -2762,12 +2607,6 @@ packages: resolution: {integrity: sha512-t6jv+xHy+VYwc4xqZMn2Pa9DjcdzvzZmQGRjTFc8spIbRGHgBrEKbPq+rYXc7CCo0lxgYvSgKVg9qZAhpVQSjA==} engines: {node: '>=12'} - abstract-leveldown@2.6.3: - resolution: {integrity: sha512-2++wDf/DYqkPR3o5tbfdhF96EfMApo1GpPfzOsR/ZYXdkSmELlvOOEAl9iKkRsktMPHdGjO4rtkBpf2I7TiTeA==} - - abstract-leveldown@2.7.2: - resolution: {integrity: sha512-+OVvxH2rHVEhWLdbudP6p0+dNMXu8JA1CbhP19T8paTYAcX7oJ4OVjT+ZUVpv7mITxXHqDMej+GdqXBmXkw09w==} - abstract-leveldown@7.2.0: resolution: {integrity: sha512-DnhQwcFEaYsvYDnACLZhMmCWd3rkOeEvglpa4q5i/5Jlm3UIsWaxVzuXvDLFCSCWRO3yy2/+V/G7FusFgejnfQ==} engines: {node: '>=10'} @@ -2776,13 +2615,8 @@ packages: resolution: {integrity: sha512-PYAthTa2m2VKxuvSD3DPC/Gy+U+sOA1LAuT8mkmRuvw+NACSaeXEQ+NHcVF7rONl6qcaxV3Uuemwawk+7+SJLw==} engines: {node: '>= 0.6'} - acorn-import-assertions@1.9.0: - resolution: {integrity: sha512-cmMwop9x+8KFhxvKrKfPYmN6/pKTYYHBqLa0DfvVZcKMJWNyWLnaqND7dx/qn66R7ewM1UX5XMaDVP5wlVTaVA==} - peerDependencies: - acorn: ^8 - - acorn-import-attributes@1.9.2: - resolution: {integrity: sha512-O+nfJwNolEA771IYJaiLWK1UAwjNsQmZbTRqqwBYxCgVQTmpFEMvBw6LOIQV0Me339L5UMVYFyRohGnGlQDdIQ==} + acorn-import-attributes@1.9.5: + resolution: {integrity: sha512-n02Vykv5uA3eHGM/Z2dQrcD56kL8TyDb2p1+0P83PClMnC/nc+anbQRhIOWnSq4Ke/KvDPrY3C9hDtC/A3eHnQ==} peerDependencies: acorn: ^8 @@ -2791,12 +2625,12 @@ packages: peerDependencies: acorn: ^6.0.0 || ^7.0.0 || ^8.0.0 - acorn-walk@8.3.2: - resolution: {integrity: sha512-cjkyv4OtNCIeqhHrfS81QWXoCBPExR/J62oyEqepVw8WaQeSqpW2uhuLPh1m9eWhDuOo/jUXVTlifvesOWp/4A==} + acorn-walk@8.3.4: + resolution: {integrity: sha512-ueEepnujpqee2o5aIYnvHU6C0A42MNdsIDeqy5BydrkuC5R1ZuUFnm27EeFJGoEHJQgn3uleRvmTXaJgfXbt4g==} engines: {node: '>=0.4.0'} - acorn@8.11.3: - resolution: {integrity: sha512-Y9rRfJG5jcKOE0CLisYbojUjIrIEE7AGMzA/Sm4BslANhbS+cDMpgBdcPT91oJ7OuJ9hYJBx59RjbhxVnrF8Xg==} + acorn@8.13.0: + resolution: {integrity: sha512-8zSiw54Oxrdym50NlZ9sUusyO1Z1ZchgRLWRaK6c86XJFClyCgFKetdowBg5bKxyp/u+CDBJG4Mpp0m3HLZl9w==} engines: {node: '>=0.4.0'} hasBin: true @@ -2807,12 +2641,19 @@ packages: aes-js@3.0.0: resolution: {integrity: sha512-H7wUZRn8WpTq9jocdxQ2c8x2sKo9ZVmzfRE13GiNJXfp7NcKYEdvl3vspKjXox6RIG2VtaRe4JFvxG4rqp2Zuw==} + aes-js@4.0.0-beta.5: + resolution: {integrity: sha512-G965FqalsNyrPqgEGON7nIx1e/OVENSgiEIzyC63haUMuvNnwIgIjMs52hlTCKhkBny7A2ORNlfY9Zu+jmGk1Q==} + agent-base@6.0.2: resolution: {integrity: sha512-RZNwNclF7+MS/8bDg70amg32dyeZGZxiDuQmZxKLAlQjr3jGyLx+4Kkk58UO7D2QdgFIQCovuSuZESne6RG6XQ==} engines: {node: '>= 6.0.0'} - agent-base@7.1.0: - resolution: {integrity: sha512-o/zjMZRhJxny7OyEF+Op8X+efiELC7k7yOjMzgfzVqOzXqkBkWI79YoTdOtsuWd5BWhAGAuOY/Xa6xpiaWXiNg==} + agent-base@7.1.1: + resolution: {integrity: sha512-H0TSyFNDMomMNJQBn8wFV5YC/2eJ+VXECwOadZJT554xP6cODZHPX3H9QMQECxvrgiSOP1pHjy1sMWQVYJOUOA==} + engines: {node: '>= 14'} + + agent-base@7.1.3: + resolution: {integrity: sha512-jRR5wdylq8CkOe6hei19GGZnxM6rBGwFl3Bg0YItGDimvjGtAvdZk4Pu6Cl4u4Igsws4a1fd1Vq3ezrhn4KmFw==} engines: {node: '>= 14'} aggregate-error@3.1.0: @@ -2845,8 +2686,12 @@ packages: ajv@6.12.6: resolution: {integrity: sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g==} - ajv@8.12.0: - resolution: {integrity: sha512-sRu1kpcO9yLtYxBKvqfTeh9KzZEwO3STyX1HT+4CaDzC6HpTGYhIhPIzj9XuKU7KYDwnaeh5hcOwjy1QuJzBPA==} + ajv@8.17.1: + resolution: {integrity: sha512-B/gBuNg5SiMTrPkC+A2+cW0RszwxYmn6VYxB/inlBStS5nx6xHIt/ehKRhIMhqusl7a8LjQoZnjCs5vhwxOQ1g==} + + amdefine@1.0.1: + resolution: {integrity: sha512-S2Hw0TtNkMJhIabBwIojKL9YHO5T0n5eNqWJ7Lrlel/zDbftQpxpapi8tZs3X1HWa+u+QeydGmzzNU0m09+Rcg==} + engines: {node: '>=0.4.2'} ansi-align@3.0.1: resolution: {integrity: sha512-IOfwwBF5iczOjp/WeY4YxyjqAFMQoZufdQWDd19SEExbVLNXqvpzSJ/M7Za4/sCPmQ0+GRquoA7bGcINcxew6w==} @@ -2855,10 +2700,6 @@ packages: resolution: {integrity: sha512-hHUXGagefjN2iRrID63xckIvotOXOojhQKWIPUZ4mNUZ9nLZW+7FMNoE1lOkEhNWYsx/7ysGIuJYCiMAA9FnrA==} engines: {node: '>=6'} - ansi-colors@4.1.1: - resolution: {integrity: sha512-JoX0apGbHaUJBNl6yF+p6JAFYZ666/hhCGKN5t9QFjbJQKUU/g8MNbFDbvfrgKXvI1QpZplPOnwIo99lX/AAmA==} - engines: {node: '>=6'} - ansi-colors@4.1.3: resolution: {integrity: sha512-/6w/C21Pm1A7aZitlI5Ni/2J6FFQN8i1Cvz3kHABAAbw93v/NlvKdVOqz7CCWz/3iv/JplRSEEZ83XION15ovw==} engines: {node: '>=6'} @@ -2876,6 +2717,10 @@ packages: resolution: {integrity: sha512-TIGnTpdo+E3+pCyAluZvtED5p5wCqLdezCyhPZzKPcxvFplEt4i+W7OONCKgeZFT3+y5NZZfOOS/Bdcanm1MYA==} engines: {node: '>=0.10.0'} + ansi-regex@3.0.1: + resolution: {integrity: sha512-+O9Jct8wf++lXxxFc4hc8LsjaSq0HFzzL7cVsw8pRDIPdjKD2mT4ytDZlLuSBZ4cLKZFXIrMGO7DbQCtMJJMKw==} + engines: {node: '>=4'} + ansi-regex@4.1.1: resolution: {integrity: sha512-ILlv4k/3f6vfQ4OoP2AGvirOktlQ98ZEL1k9FaQjxa3L1abBgbuTDAdPOpvbGncC0BTVQrl+OM8xZGK6tWXt7g==} engines: {node: '>=6'} @@ -2884,8 +2729,8 @@ packages: resolution: {integrity: sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==} engines: {node: '>=8'} - ansi-regex@6.0.1: - resolution: {integrity: sha512-n5M855fKb2SsfMIiFFoVrABHJC8QtHwVx+mHWP3QcEqBHYienj5dHSgjbxtC0WEZXYt4wcD6zrQElDPhFuZgfA==} + ansi-regex@6.1.0: + resolution: {integrity: sha512-7HSX4QQb4CspciLpVFwyRe79O3xsIZDDLER21kERQ71oaPodF8jL725AgJMFAYbooIqolJoRLuM81SpeUkpkvA==} engines: {node: '>=12'} ansi-styles@3.2.1: @@ -2900,6 +2745,9 @@ packages: resolution: {integrity: sha512-bN798gFfQX+viw3R7yrGWRqnrN2oRkEkUjjl4JNn4E8GxxbjtG3FbrEIIY3l8/hrwUwIeCZvi4QuOTP4MErVug==} engines: {node: '>=12'} + antlr4ts@0.5.0-alpha.4: + resolution: {integrity: sha512-WPQDt1B74OfPv/IMS2ekXAKkTZIHl88uMetg6q3OTqgFxZ/dxDXI0EWLyZid/1Pe6hTftyg5N7gel5wNAGxXyQ==} + anymatch@2.0.0: resolution: {integrity: sha512-5teOsQWABXHHBFP9y3skS5P3d/WfWXpv3FUpy+LorMrNYaT9pI4oLMQX7jzQ2KklNpGpWHzdCXTDT2Y3XGlZBw==} @@ -2920,6 +2768,7 @@ packages: are-we-there-yet@2.0.0: resolution: {integrity: sha512-Ci/qENmwHnsYo9xKIcUJN5LeDKdJ6R1Z1j9V/J5wyq8nh/mYPEpIKJbBZXtZjG04HiK7zV/p6Vs9952MrMeUIw==} engines: {node: '>=10'} + deprecated: This package is no longer supported. arg@4.1.3: resolution: {integrity: sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA==} @@ -2942,14 +2791,6 @@ packages: resolution: {integrity: sha512-sKpyeERZ02v1FeCZT8lrfJq5u6goHCtpTAzPwJYe7c8SPFOboNjNg1vz2L4VTn9T4PQxEx13TbXLmYUcS6Ug7Q==} engines: {node: '>=0.10.0'} - array-back@1.0.4: - resolution: {integrity: sha512-1WxbZvrmyhkNoeYcizokbmh5oiOCIfyvGtcqbK3Ls1v1fKcquzxnQSceOx6tzq7jmai2kFLWIpGND2cLhH6TPw==} - engines: {node: '>=0.12.0'} - - array-back@2.0.0: - resolution: {integrity: sha512-eJv4pLLufP3g5kcZry0j6WXpIbzYw9GUB4mVJZno9wfwiBxbizTnHCw3VJb07cBihbFX48Y7oSrW9y+gt4glyw==} - engines: {node: '>=4'} - array-back@3.1.0: resolution: {integrity: sha512-TkuxA4UCOvxuDK6NZYXCalszEzj+TLszyASooky+i742l9TqsOdYCMJJupxRic61hwquNtppB3hgcuq9SVSH1Q==} engines: {node: '>=6'} @@ -2972,8 +2813,8 @@ packages: array-flatten@2.1.2: resolution: {integrity: sha512-hNfzcOV8W4NdualtqBFPyVO+54DSJuZGY9qT4pRroB6S9e3iiido2ISIC5h9R2sPJ8H3FHCIiEnsv1lPXO3KtQ==} - array-includes@3.1.7: - resolution: {integrity: sha512-dlcsNBIiWhPkHdOEEKnehA+RNUWDc4UqFtnIXU4uuYDPtA4LDkr7qip2p0VvFAEXNDr0yWZ9PJyIRiGjRLQzwQ==} + array-includes@3.1.8: + resolution: {integrity: sha512-itaWrbYbqpGXkGhZPGUulwnhVf5Hpy1xiCFsGqyIGglbBxmG5vSjxQen3/WGOjPpNEv1RtBLKxbmVXm8HpJStQ==} engines: {node: '>= 0.4'} array-union@1.0.2: @@ -2992,12 +2833,8 @@ packages: resolution: {integrity: sha512-SleRWjh9JUud2wH1hPs9rZBZ33H6T9HOiL0uwGnGx9FpE6wKGyfWugmbkEOIs6qWrZhg0LWeLziLrEwQJhs5mQ==} engines: {node: '>=0.10.0'} - array.prototype.filter@1.0.3: - resolution: {integrity: sha512-VizNcj/RGJiUyQBgzwxzE5oHdeuXY5hSbbmKMlphj1cy1Vl7Pn2asCGbSrru6hSQjmCzqTBPVWAF/whmEOVHbw==} - engines: {node: '>= 0.4'} - - array.prototype.findlastindex@1.2.4: - resolution: {integrity: sha512-hzvSHUshSpCflDR1QMUBLHGHP1VIEBegT4pix9H/Z92Xw3ySoy6c2qh7lJWTJnRJ8JCZ9bJNCgTyYaJGcJu6xQ==} + array.prototype.findlastindex@1.2.5: + resolution: {integrity: sha512-zfETvRFA8o7EiNn++N5f/kaCw221hrpGsDmcpndVupkPzEc1Wuf3VgC0qby1BbHs7f5DVYjgtEU2LLh5bqeGfQ==} engines: {node: '>= 0.4'} array.prototype.flat@1.3.2: @@ -3016,14 +2853,13 @@ packages: resolution: {integrity: sha512-a4eg4yhp7mmruZDQFqVMlxNRFGi/i1r87pt8SDHy0/I8PqSXoUTlWZRdAZo0VXgvEARcujbtTk8kiZRi1uDGRw==} engines: {node: '>=8.0.0'} - arrify@1.0.1: - resolution: {integrity: sha512-3CYzex9M9FGQjCGMGyi6/31c8GJbgb0qGyrx5HWxPd0aCwh4cB2YjMb2Xf9UuoogrMrlO9cTqnB5rI5GHZTcUA==} - engines: {node: '>=0.10.0'} - arrify@3.0.0: resolution: {integrity: sha512-tLkvA81vQG/XqE2mjDkGQHoOINtMHtysSnemrmoGe6PydDPMRbVugqyk4A6V/WDWEfm3l+0d8anA9r8cv/5Jaw==} engines: {node: '>=12'} + asap@2.0.6: + resolution: {integrity: sha512-BSHWgDSAiKs50o2Re8ppvp3seVHXSRM44cdSsT9FfNEUUZLOGWVCsiWaRPWM1Znn+mqZ1OfVZ3z3DWEzSp7hRA==} + asn1@0.2.6: resolution: {integrity: sha512-ix/FxPn0MDjeyJ7i/yoHGFt/EX6LyNbxSEhPPXODPL+KB0VPk86UYfL0lMdy+KCnv+fmvIzySwaK5COwqVbWTQ==} @@ -3042,6 +2878,10 @@ packages: resolution: {integrity: sha512-x1FCFnFifvYDDzTaLII71vG5uvDwgtmDTEVWAxrgeiR8VjMONcCXJx7E+USjDtHlwFmt9MysbqgF9b9Vjr6w+w==} engines: {node: '>=4'} + astral-regex@2.0.0: + resolution: {integrity: sha512-Z7tMw1ytTXt5jqMcOP+OQteU1VuNK9Y02uuJtKQ1Sv69jXQKKg5cibLwGJow8yzZP+eAc18EmLGPal0bp36rvQ==} + engines: {node: '>=8'} + async-each@1.0.6: resolution: {integrity: sha512-c646jH1avxr+aVpndVMeAfYw7wAa6idufrlN3LPA4PmKS0QEGp6PIC9nwz0WQkkvBGAMEki3pFdtxaF39J9vvg==} @@ -3051,8 +2891,8 @@ packages: async-limiter@1.0.1: resolution: {integrity: sha512-csOlWGAcRFJaI6m+F2WKdnMKr4HhdhFVBk0H/QbJFMCr+uO2kwohwXQPxw/9OCxp05r5ghVBFSyioixx3gfkNQ==} - async-mutex@0.2.6: - resolution: {integrity: sha512-Hs4R+4SPgamu6rSGW8C7cV9gaWUKEHykfzCCvIRuaVv636Ju10ZdeUbvb4TBEW0INuq2DHZqXbK4Nd3yG4RaRw==} + async-mutex@0.5.0: + resolution: {integrity: sha512-1A94B18jkJ3DYq284ohPxoXbfTA5HsQ7/Mf4DEhcyLx3Bz27Rh59iScbB6EPiP+B+joue6YCxcMXSbFC1tZKwA==} async-sema@3.1.1: resolution: {integrity: sha512-tLRNUXati5MFePdAk8dw7Qt7DpxPB60ofAgn8WRhW6a2rcimZnYBP9oxHiv0OHy+Wz7kPMG+t4LGdt31+4EmGg==} @@ -3075,9 +2915,9 @@ packages: engines: {node: '>= 4.5.0'} hasBin: true - ava@6.1.1: - resolution: {integrity: sha512-A+DG0Ag0e5zvt262Ze0pG5QH7EBmhn+DB9uK7WkUtJVAtGjZFeKTpUOKx339DMGn53+FB24pCJC5klX2WU4VOw==} - engines: {node: ^18.18 || ^20.8 || ^21} + ava@6.1.3: + resolution: {integrity: sha512-tkKbpF1pIiC+q09wNU9OfyTDYZa8yuWvU2up3+lFJ3lr1RmnYh2GBpPwzYUEB0wvTPIUysGjcZLNZr7STDviRA==} + engines: {node: ^18.18 || ^20.8 || ^21 || ^22} hasBin: true peerDependencies: '@ava/typescript': '*' @@ -3092,52 +2932,60 @@ packages: aws-sign2@0.7.0: resolution: {integrity: sha512-08kcGqnYf/YmjoRhfxyu+CLxBjUtHLXLXX/vUfx9l2LYzG3c1m61nrpyFUZI6zeS+Li/wWMMidD9KgrqtGq3mA==} - aws4@1.12.0: - resolution: {integrity: sha512-NmWvPnx0F1SfrQbYwOi7OeaNGokp9XhzNioJ/CSBs8Qa4vxug81mhJEAVZwxXuBmYB5KDRfMq/F3RR0BIU7sWg==} + aws4@1.13.2: + resolution: {integrity: sha512-lHe62zvbTB5eEABUVi/AwVh0ZKY9rMMDhmm+eeyuuUQbQ3+J+fONVQOZyj+DdrvD4BY33uYniyRJ4UJIaSKAfw==} - axios@1.6.7: - resolution: {integrity: sha512-/hDJGff6/c7u0hDkvkGxR/oy6CbCs8ziCsC7SqmhjfozqiJGc8Z11wrv9z9lYfY4K8l+H9TpjcMDX0xOZmx+RA==} + axios@1.7.7: + resolution: {integrity: sha512-S4kL7XrjgBmvdGut0sN3yJxqYzrDOnivkBiN0OFs6hLiUam3UPvswUo0kqGyhqUZGEOytHyumEdXsAkgCOUf3Q==} - b4a@1.6.6: - resolution: {integrity: sha512-5Tk1HLk6b6ctmjIkAcU/Ujv/1WqiDl0F0JdRCR80VsOcUlHcu7pWeWRlOqQLHfDEsVx9YH/aif5AG4ehoCtTmg==} + b4a@1.6.7: + resolution: {integrity: sha512-OnAYlL5b7LEkALw87fUVafQw5rVR9RjwGd4KUwNQ6DrrNmaVaUCgLipfVlzrPQ4tWOR9P0IXGNOx50jYCCdSJg==} - babel-loader@9.1.3: - resolution: {integrity: sha512-xG3ST4DglodGf8qSwv0MdeWLhrDsw/32QMdTO5T1ZIp9gQur0HkCyFs7Awskr10JKXFXwpAhiCuYX5oGXnRGbw==} + babel-loader@9.2.1: + resolution: {integrity: sha512-fqe8naHt46e0yIdkjUZYqddSXfej3AHajX+CSO5X7oy0EmPc6o5Xh+RClNoHjnieWz9AW4kZxW9yyFMhVB1QLA==} engines: {node: '>= 14.15.0'} peerDependencies: '@babel/core': ^7.12.0 webpack: '>=5' - babel-plugin-polyfill-corejs2@0.4.8: - resolution: {integrity: sha512-OtIuQfafSzpo/LhnJaykc0R/MMnuLSSVjVYy9mHArIZ9qTCSZ6TpWCuEKZYVoN//t8HqBNScHrOtCrIK5IaGLg==} + babel-plugin-polyfill-corejs2@0.4.11: + resolution: {integrity: sha512-sMEJ27L0gRHShOh5G54uAAPaiCOygY/5ratXuiyb2G46FmlSpc9eFCzYVyDiPxfNbwzA7mYahmjQc5q+CZQ09Q==} peerDependencies: '@babel/core': ^7.4.0 || ^8.0.0-0 <8.0.0 - babel-plugin-polyfill-corejs3@0.9.0: - resolution: {integrity: sha512-7nZPG1uzK2Ymhy/NbaOWTg3uibM2BmGASS4vHS4szRZAIR8R6GwA/xAujpdrXU5iyklrimWnLWU+BLF9suPTqg==} + babel-plugin-polyfill-corejs3@0.10.6: + resolution: {integrity: sha512-b37+KR2i/khY5sKmWNVQAnitvquQbNdWy6lJdsr0kmquCKEEUgMKK4SboVM3HtfnZilfjr4MMQ7vY58FVWDtIA==} peerDependencies: '@babel/core': ^7.4.0 || ^8.0.0-0 <8.0.0 - babel-plugin-polyfill-regenerator@0.5.5: - resolution: {integrity: sha512-OJGYZlhLqBh2DDHeqAxWB1XIvr49CxiJ2gIt61/PU55CQK4Z58OzMqjDe1zwQdQk+rBYsRc+1rJmdajM3gimHg==} + babel-plugin-polyfill-regenerator@0.6.2: + resolution: {integrity: sha512-2R25rQZWP63nGwaAswvDazbPXfrM3HwVoBXK6HcqeKrSrL/JqcC/rDcf95l4r7LXLyxDXc8uQDa064GubtCABg==} peerDependencies: '@babel/core': ^7.4.0 || ^8.0.0-0 <8.0.0 backo2@1.0.2: resolution: {integrity: sha512-zj6Z6M7Eq+PBZ7PQxl5NT665MvJdAkzp0f60nAJ+sLaSCBPMwVak5ZegFbgVCzFcCJTKFoMizvM5Ld7+JrRJHA==} - backoff@2.5.0: - resolution: {integrity: sha512-wC5ihrnUXmR2douXmXLCe5O3zg3GKIyvRi/hi58a/XyRxVI+3/yM0PYueQOZXPXQ9pxBislYkw+sF9b7C/RuMA==} - engines: {node: '>= 0.6'} - balanced-match@1.0.2: resolution: {integrity: sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==} - bare-events@2.2.0: - resolution: {integrity: sha512-Yyyqff4PIFfSuthCZqLlPISTWHmnQxoPuAvkmgzsJEmG3CesdIv6Xweayl0JkCZJSB2yYIdJyEz97tpxNhgjbg==} + bare-events@2.5.0: + resolution: {integrity: sha512-/E8dDe9dsbLyh2qrZ64PEPadOQ0F4gbl1sUJOrmph7xOiIxfY8vwab/4bFLh4Y88/Hk/ujKcrQKc+ps0mv873A==} + + bare-fs@2.3.5: + resolution: {integrity: sha512-SlE9eTxifPDJrT6YgemQ1WGFleevzwY+XAP1Xqgl56HtcrisC2CHCZ2tq6dBpcH2TnNxwUEUGhweo+lrQtYuiw==} + + bare-os@2.4.4: + resolution: {integrity: sha512-z3UiI2yi1mK0sXeRdc4O1Kk8aOa/e+FNWZcTiPB/dfTWyLypuE99LibgRaQki914Jq//yAWylcAt+mknKdixRQ==} - base-x@3.0.9: - resolution: {integrity: sha512-H7JU6iBHTal1gp56aKoaa//YUxEaAOUiydvrV/pILqIHXTtqxSkATOnDA2u+jZ/61sD+L/412+7kzXRtWukhpQ==} + bare-path@2.1.3: + resolution: {integrity: sha512-lh/eITfU8hrj9Ru5quUp0Io1kJWIk1bTjzo7JH1P5dWmQ2EL4hFUlfI8FonAhSlgIfhn63p84CDY/x+PisgcXA==} + + bare-stream@2.3.2: + resolution: {integrity: sha512-EFZHSIBkDgSHIwj2l2QZfP4U5OcD4xFAOwhSb/vlr9PIqyGJGvB/nfClJbcnh3EY4jtPE4zsb5ztae96bVF79A==} + + base-x@3.0.10: + resolution: {integrity: sha512-7d0s06rR9rYaIWHkpfLIFICM/tkSVdoPC9qYAQRpxn9DdKNWNsKC0uk++akckyLq16Tx2WIinnZ6WRriAt6njQ==} base64-arraybuffer-es6@0.7.0: resolution: {integrity: sha512-ESyU/U1CFZDJUdr+neHRhNozeCv72Y7Vm0m1DCbjX3KBjT6eYocvAJlSk6+8+HkVwXlT1FNxhGW6q3UKAlCvvw==} @@ -3154,8 +3002,8 @@ packages: resolution: {integrity: sha512-5T6P4xPgpp0YDFvSWwEZ4NoE3aM4QBQXDzmVbraCkFj8zHM+mba8SyqB5DbZWyR7mYHo6Y7BdQo3MoA4m0TeQg==} engines: {node: '>=0.10.0'} - basic-ftp@5.0.4: - resolution: {integrity: sha512-8PzkB0arJFV4jJWSGOYR+OEic6aeKMu/osRhBULN6RY0ykby6LKhbmuQ5ublvaas5BOwboah5D87nrHyuh8PPA==} + basic-ftp@5.0.5: + resolution: {integrity: sha512-4Bcg1P8xhUuqcii/S0Z9wiHIrQVPMermM1any+MX5GeGD7faD3/msQUDGLol9wOcz4/jbg/WJnGqoJF6LiBdtg==} engines: {node: '>=10.0.0'} batch@0.6.1: @@ -3171,13 +3019,6 @@ packages: resolution: {integrity: sha512-pbnl5XzGBdrFU/wT4jqmJVPn2B6UHPBOhzMQkY/SPUPB6QtUXtmBHBIwCbXJol93mOpGMnQyP/+BB19q04xj7g==} engines: {node: '>=4'} - bigint-crypto-utils@3.3.0: - resolution: {integrity: sha512-jOTSb+drvEDxEq6OuUybOAv/xxoh3cuYRUIPyu8sSHQNKM303UQ2R1DAo45o1AkcIXw6fzbaFI1+xGGdaXs2lg==} - engines: {node: '>=14.0.0'} - - bignumber.js@7.2.1: - resolution: {integrity: sha512-S4XzBk5sMB+Rcb/LNcpzXr57VRTxgAvaAEDAl1AwRx27j00hT84O6OkteE7u8UB3NuaaygCRrEpqox4uDOrbdQ==} - bignumber.js@9.1.2: resolution: {integrity: sha512-2/mKyZH9K85bzOEfhXDBFZTGd1CTs+5IHpeFQo9luiBG7hghdC851Pj2WAhb6E3R6b9tZj/XKhbg4fum+Kepug==} @@ -3185,8 +3026,8 @@ packages: resolution: {integrity: sha512-Un7MIEDdUC5gNpcGDV97op1Ywk748MpHcFTHoYs6qnj1Z3j7I53VG3nwZhKzoBZmbdRNnb6WRdFlwl7tSDuZGw==} engines: {node: '>=0.10.0'} - binary-extensions@2.2.0: - resolution: {integrity: sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA==} + binary-extensions@2.3.0: + resolution: {integrity: sha512-Ceh+7ox5qe7LJuLHoY0feh3pHuUDHAcRUeyL2VYghZwfpkNIy/+8Ocg0a3UuSoYzavmylwuLWQOf3hl0jjMMIw==} engines: {node: '>=8'} bindings@1.5.0: @@ -3210,12 +3051,8 @@ packages: bn.js@5.2.1: resolution: {integrity: sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==} - body-parser@1.20.1: - resolution: {integrity: sha512-jWi7abTbYwajOytWCQc37VulmWiRae5RyTpaCyDcS5/lMdtwSz5lOpDE67srw/HYe35f1z3fDQw+3txg7gNtWw==} - engines: {node: '>= 0.8', npm: 1.2.8000 || >= 1.4.16} - - body-parser@1.20.2: - resolution: {integrity: sha512-ml9pReCu3M61kGlqoTm2umSXTlRTuGTx0bfYj+uIUKKYycG5NtSbeetV3faSU6R7ajOPw0g/J1PvK4qNy7s5bA==} + body-parser@1.20.3: + resolution: {integrity: sha512-7rAxByjUMqQ3/bHJy7D6OGXvx/MMc4IqBn/X0fcM1QUcAItpZrBEYhWGem+tzXH90c+G01ypMcYJBO9Y30203g==} engines: {node: '>= 0.8', npm: 1.2.8000 || >= 1.4.16} bonjour@3.5.0: @@ -3241,18 +3078,16 @@ packages: resolution: {integrity: sha512-aNdbnj9P8PjdXU4ybaWLK2IF3jc/EoDYbC7AazW6to3TRsfXxscC9UXOB5iDiEQrkyIbWp2SLQda4+QAa7nc3w==} engines: {node: '>=0.10.0'} - braces@3.0.2: - resolution: {integrity: sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==} + braces@3.0.3: + resolution: {integrity: sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA==} engines: {node: '>=8'} - breakword@1.0.6: - resolution: {integrity: sha512-yjxDAYyK/pBvws9H4xKYpLDpYKEH6CzrBPAuXq3x18I+c/2MkVtT3qAr7Oloi6Dss9qNhPVueAAVU1CSeNDIXw==} - brorand@1.1.0: resolution: {integrity: sha512-cKV8tMCEpQs4hK/ik71d6LrPOnpkpGBR0wzxqr68g2m/LB2GxVYQroAjMJZRVM1Y4BCjCKc3vAamxSzOY2RP+w==} - brotli-wasm@1.3.1: - resolution: {integrity: sha512-Vp+v3QXddvy39Ycbmvd3/Y1kUvKhwtnprzeABcKWN4jmyg6W3W5MhGPCfXBMHeSQnizgpV59iWmkSRp7ykOnDQ==} + brotli-wasm@3.0.1: + resolution: {integrity: sha512-U3K72/JAi3jITpdhZBqzSUq+DUY697tLxOuFXB+FpAE/Ug+5C3VZrv4uA674EUZHxNAuQ9wETXNqQkxZD6oL4A==} + engines: {node: '>=v18.0.0'} browser-stdout@1.3.1: resolution: {integrity: sha512-qhAVI1+Av2X7qelOfAIYwXONood6XlZE/fXaBSmW/T5SzLAmCgzi+eiWE7fUvbHaeNBQH13UftjpXxsfLkMpgw==} @@ -3260,8 +3095,8 @@ packages: browserify-aes@1.2.0: resolution: {integrity: sha512-+7CHXqGuspUn/Sl5aO7Ea0xWGAtETPXNSAjHo48JfLdPWcMng33Xe4znFvQweqc/uzk5zSOI3H52CYnjCfb5hA==} - browserslist@4.23.0: - resolution: {integrity: sha512-QW8HiM1shhT2GuzkvklfjcKDiWFXHOeFCIA/huJPwHsslwcydgk7X+z2zXpEijP98UCY7HbubZt5J2Zgvf0CaQ==} + browserslist@4.24.2: + resolution: {integrity: sha512-ZIc+Q62revdMcqC6aChtW4jz3My3klmCO1fEmINZY/8J3EpBg5/A/D0AKmBveUh6pgoeycoMkVMko84tuYS+Gg==} engines: {node: ^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7} hasBin: true @@ -3271,11 +3106,6 @@ packages: bs58check@2.1.2: resolution: {integrity: sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==} - btoa@1.2.1: - resolution: {integrity: sha512-SB4/MIGlsiVkMcHmT+pSmIPoNDoHg+7cMzmt3Uxt628MTz2487DKSqK/fuhFBrkuqrYv5UCEnACpF4dTFNKc/g==} - engines: {node: '>= 0.4.0'} - hasBin: true - buffer-crc32@0.2.13: resolution: {integrity: sha512-VO9Ht/+p3SN7SKWqcrgEzjGbRSJYTx+Q1pTQC0wrWqHx0vpJraQ6GtHx8tvcg1rlK1byhU5gccxgOgj7B0TDkQ==} @@ -3297,14 +3127,6 @@ packages: buffer@6.0.3: resolution: {integrity: sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==} - bufferutil@4.0.5: - resolution: {integrity: sha512-HTm14iMQKK2FjFLRTM5lAVcyaUzOnqbPtesFIvREgXpJHdQm8bWS+GkQgIkfaBYRHuCnea7w8UVNfwiAQhlr9A==} - engines: {node: '>=6.14.2'} - - bufferutil@4.0.7: - resolution: {integrity: sha512-kukuqc39WOHtdxtw4UScxF/WVnMFVSQVKhtx3AjZJzhd0RGZZldcrfSEbVsWWe6KNH253574cq5F+wpv0G9pJw==} - engines: {node: '>=6.14.2'} - bufferutil@4.0.8: resolution: {integrity: sha512-4T53u4PdgsXqKaIctwF8ifXlRTTmEPJ8iEPWFdGZvcf7sbwYo6FKFEX9eNNAnzFZ7EzJAQ3CJeOtCRA4rDp7Pw==} engines: {node: '>=6.14.2'} @@ -3349,17 +3171,13 @@ packages: resolution: {integrity: sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==} engines: {node: '>=6'} - callsites@4.1.0: - resolution: {integrity: sha512-aBMbD1Xxay75ViYezwT40aQONfr+pSXTHwNKvIXhXD6+LY3F1dLIcceoC5OZKBVHbXcysz1hL9D2w0JJIMXpUw==} + callsites@4.2.0: + resolution: {integrity: sha512-kfzR4zzQtAE9PC7CzZsjl3aBNbXWuXiSeOCdLcPpBfGW8YuCqQHcRPFDbr/BPVmd3EEPVpuFzLyuT/cUhPr4OQ==} engines: {node: '>=12.20'} camel-case@4.1.2: resolution: {integrity: sha512-gxGWBrTT1JuMx6R+o5PTXMmUnhnVzLQ9SNutD4YqKtI6ap897t3tKECYla6gCWEkplXnlNybEkZg9GEGxKFCgw==} - camelcase-keys@6.2.2: - resolution: {integrity: sha512-YrwaA0vEKazPBkn0ipTiMpSajYDSe+KjQfrjhcBMxJt/znbvlHd8Pw/Vamaz5EB4Wfhs3SUR3Z9mwRu/P3s3Yg==} - engines: {node: '>=8'} - camelcase@5.3.1: resolution: {integrity: sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==} engines: {node: '>=6'} @@ -3368,8 +3186,8 @@ packages: resolution: {integrity: sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA==} engines: {node: '>=10'} - caniuse-lite@1.0.30001591: - resolution: {integrity: sha512-PCzRMei/vXjJyL5mJtzNiUCKP59dm8Apqc3PH8gJkMnMXZGox93RbE76jHsmLwmIo6/3nsYIpJtx0O7u5PqFuQ==} + caniuse-lite@1.0.30001669: + resolution: {integrity: sha512-DlWzFDJqstqtIVx1zeSpIMLjunf5SmwOw0N2Ck/QSQdS8PLS4+9HrLaYei4w8BIAL7IB/UEDu889d8vhCTPA0w==} caseless@0.12.0: resolution: {integrity: sha512-4tYFyifaFfGacoiObjJegolkwSU4xQNGbVgUiNYVUxbQ2x2lUsFvY4hVgVzGiIe6WLOPqycWXA40l+PWsxthUw==} @@ -3378,17 +3196,21 @@ packages: resolution: {integrity: sha512-K7Qy8O9p76sL3/3m7/zLKbRkyOlSZAgzEaLhyj2mXS8PsCud2Eo4hAb8aLtZqHh0QGqLcb9dlJSu6lHRVENm1w==} engines: {node: '>=6'} + cbor@8.1.0: + resolution: {integrity: sha512-DwGjNW9omn6EwP70aXsn7FQJx5kO12tX0bZkaTjzdVFM6/7nhA4t0EENocKGx6D2Bch9PE2KzCUf5SceBdeijg==} + engines: {node: '>=12.19'} + cbor@9.0.2: resolution: {integrity: sha512-JPypkxsB10s9QOWwa6zwPzqE1Md3vqpPc+cai4sAecuCsRyAtAl/pMyhPlMbT/xtPnm2dznJZYRLui57qiRhaQ==} engines: {node: '>=16'} - chai-as-promised@7.1.1: - resolution: {integrity: sha512-azL6xMoi+uxu6z4rhWQ1jbdUhOMhis2PvscD/xjLqNMkv3BPPp2JyyuTHOrf9BOosGpNQ11v6BKv/g57RXbiaA==} + chai-as-promised@7.1.2: + resolution: {integrity: sha512-aBDHZxRzYnUYuIAIPBH2s511DjlKPzXNlXSGFC8CwmroWQLfrW0LtE1nK3MAwwNhJPa9raEjNCmRoFpG0Hurdw==} peerDependencies: - chai: '>= 2.1.2 < 5' + chai: '>= 2.1.2 < 6' - chai@4.4.1: - resolution: {integrity: sha512-13sOfMv2+DWduEU+/xbun3LScLoqN17nBeTLUsmDfKdoiC1fr0n9PU4guu4AhRcOVFk/sW8LyZWHuhWtQZiF+g==} + chai@4.5.0: + resolution: {integrity: sha512-RITGBfijLkBddZvnn8jdqoTypxvqbOLYQkGGxXzeFjVHvudaPw0HNFD9x928/eUwYWd2dPCugVqspGALTZZQKw==} engines: {node: '>=4'} chalk@2.4.2: @@ -3406,24 +3228,23 @@ packages: chardet@0.7.0: resolution: {integrity: sha512-mT8iDcrh03qDGRRmoA2hmBJnxpllMR+0/0qlzjqZES6NdiWDcZkCNAk4rPFZ9Q85r27unkiNNg8ZOiwZXBHwcA==} + charenc@0.0.2: + resolution: {integrity: sha512-yrLQ/yVUFXkzg7EDQsPieE/53+0RlaWTs+wBrvW36cyilJ2SaDWfl4Yj7MtLTXleV9uEKefbAGUPv2/iWSooRA==} + check-error@1.0.3: resolution: {integrity: sha512-iKEoDYaRmd1mxM90a2OEfWhjsjPpYPuQ+lMYsoxB126+t8fw7ySEO48nmDg5COTjxDI65/Y2OWpeEHk3ZOe8zg==} - checkpoint-store@1.1.0: - resolution: {integrity: sha512-J/NdY2WvIx654cc6LWSq/IYFFCUf75fFTgwzFnmbqyORH4MwgiQCgswLLKBGzmsyTI5V7i5bp/So6sMbDWhedg==} - chokidar@2.1.8: resolution: {integrity: sha512-ZmZUazfOzf0Nve7duiCKD23PFSCs4JPoYyccjUFF3aQkQadqBhfzhjkwBH2mNOG9cTBwhamM37EIsIkZw3nRgg==} - deprecated: Chokidar 2 does not receive security updates since 2019. Upgrade to chokidar 3 with 15x fewer dependencies - - chokidar@3.5.3: - resolution: {integrity: sha512-Dr3sfKRP6oTcjf2JmUmFJfeVMvXBdegxB0iVQ5eb2V10uFJUCAS8OByZdVAyVb8xXNz3GjjTgj9kLWsZTqE6kw==} - engines: {node: '>= 8.10.0'} chokidar@3.6.0: resolution: {integrity: sha512-7VT13fmjotKpGipCW9JEQAusEPE+Ei8nl6/g4FBAmIm0GOOLMua9NDDo/DWp0ZAxCr3cPq5ZpBqmPAQgDda2Pw==} engines: {node: '>= 8.10.0'} + chokidar@4.0.1: + resolution: {integrity: sha512-n8enUVCED/KVRQlab1hr3MVpcVMvxtZjmEa956u+4YijlmQED223XMSYj2tLuKvr4jcCTzNNMpQDUer72MMmzA==} + engines: {node: '>= 14.16.0'} + chownr@1.1.4: resolution: {integrity: sha512-jJ0bqzaylmJtVnNgzTeSOs8DPavpbYgEr/b0YL8/2GO3xJEhInFmhKMUnEJQjZumK7KXGFhUy89PrsJWlakBVg==} @@ -3431,12 +3252,12 @@ packages: resolution: {integrity: sha512-bIomtDF5KGpdogkLd9VspvFzk9KfpyyGlS8YFVZl7TGPBHL5snIOnxeshwVgPteQ9b4Eydl+pVbIyE1DcvCWgQ==} engines: {node: '>=10'} - chrome-trace-event@1.0.3: - resolution: {integrity: sha512-p3KULyQg4S7NIHixdwbGX+nFHkoBiA4YQmyWtjb8XngSKV124nJmRysgAeujbUVb15vh+RvFUfCPqU7rXk+hZg==} + chrome-trace-event@1.0.4: + resolution: {integrity: sha512-rNjApaLzuwaOTjCiT8lSDdGN1APCiqkChLMJxJPWLunPAt5fy8xgU9/jNOchV84wfIxrA0lRQB7oCT8jrn/wrQ==} engines: {node: '>=6.0'} - chromium-bidi@0.5.8: - resolution: {integrity: sha512-blqh+1cEQbHBKmok3rVJkBlBxt9beKBgOsxbFgs7UJcoVbbeZ+K7+6liAsjgpc8l1Xd55cQUy14fXZdGSb4zIw==} + chromium-bidi@0.8.0: + resolution: {integrity: sha512-uJydbGdTw0DEUjhoogGveneJVWX/9YuqkWePzMmkBYwtdAqo5d3J/ovNKFr+/2hWXYmYCr6it8mSSTIj6SS6Ug==} peerDependencies: devtools-protocol: '*' @@ -3484,6 +3305,10 @@ packages: resolution: {integrity: sha512-y4coMcylgSCdVinjiDBuR8PCC2bLjyGTwEmPb9NHR/QaNU6EUOXcTY/s6VjGMD6ENSEaeQYHCY0GNGS5jfMwPw==} engines: {node: '>=6'} + cli-table3@0.5.1: + resolution: {integrity: sha512-7Qg2Jrep1S/+Q3EceiZtQcDPWxhAvBw+ERf1162v4sikJrvojMHFqXt8QIVha8UlH9rgU0BeWPytZ9/TzYqlUw==} + engines: {node: '>=6'} + cli-truncate@4.0.0: resolution: {integrity: sha512-nPdaFdQ0h/GEigbPClz11D0v/ZJEwxmeVZGeMo3Z5StPtUTkA9o1lD6QwoirYiSDzbcwn2XcjwmCp68W1IS4TA==} engines: {node: '>=18'} @@ -3508,14 +3333,6 @@ packages: clone-response@1.0.3: resolution: {integrity: sha512-ROoL94jJH2dUVML2Y/5PEDNaSHgeOdSDicUyS7izcF63G6sTc/FTjLub4b8Il9S8S0beOfYt0TaA5qvFK+w0wA==} - clone@1.0.4: - resolution: {integrity: sha512-JQHZ2QMW6l3aH/j6xCqQThY/9OH4D/9ls34cgkUBiEeocRTU04tHfKPBsUK1PqZCUQM7GiA0IIXJSuXHI64Kbg==} - engines: {node: '>=0.8'} - - clone@2.1.2: - resolution: {integrity: sha512-3Pe/CF1Nn94hyhIYpjtiLhdCoEoz0DqQ+988E9gmeEdQZlojxnOb74wctFyuwWQHzqyf9X7C7MG8juUpqBJT8w==} - engines: {node: '>=0.8'} - code-excerpt@4.0.0: resolution: {integrity: sha512-xxodCmBen3iy2i0WtAK8FlFNrRzjUqjRsMfho58xT/wvZU1YTM3fCnRjcy1gJPMepaRlgm/0e6w8SpWHpn3/cA==} engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} @@ -3544,6 +3361,10 @@ packages: colorette@2.0.20: resolution: {integrity: sha512-IfEDxwoWIjkeXL1eXcDiow4UbKjhLdq6/EuSVR9GMN7KVH3r9gQ83e73hsz1Nd1T3ijd5xv1wcWRYO+D6kCI2w==} + colors@1.4.0: + resolution: {integrity: sha512-a+UqTh4kgZg/SlGvfbzDHpgRu7AAQOmmqRHJnxhRZICKFUT91brVhNNt58CMWU9PsBbv3PDCZUHbVxuDiH2mtA==} + engines: {node: '>=0.1.90'} + combined-stream@1.0.8: resolution: {integrity: sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==} engines: {node: '>= 0.8'} @@ -3551,10 +3372,6 @@ packages: command-exists@1.2.9: resolution: {integrity: sha512-LTQ/SGc+s0Xc0Fu5WaKnR0YiygZkm9eKFvyS+fRsU7/ZWFF8ykFM6Pc9aCVf1+xasOOZpO3BAVgVrKvsqKHV7w==} - command-line-args@4.0.7: - resolution: {integrity: sha512-aUdPvQRAyBvQd2n7jXcsMDz68ckBJELXNzBybCHOibUWEg0mWTnaYCSRU8h9R+aNRSvDihJtssSRCiDRpLaezA==} - hasBin: true - command-line-args@5.2.1: resolution: {integrity: sha512-H4UfQhZyakIjC74I9d34fGYDwk3XpSr17QhEd0Q3I9Xq1CETHo4Hcuo87WyWHpAF1aSLjLRf5lD9ZGX2qStUvg==} engines: {node: '>=4.0.0'} @@ -3566,9 +3383,6 @@ packages: commander@2.20.3: resolution: {integrity: sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==} - commander@3.0.2: - resolution: {integrity: sha512-Gar0ASD4BDyKC4hl4DwHqDrmvjoxWKZigVnAbn5H1owvm4CxCPdb0HQDehwNYMJpla5+M2tPmPARzhtYuwpHow==} - commander@7.2.0: resolution: {integrity: sha512-QrWXB+ZQSVPmIWIhtEO9H+gwHaMGYiF5ChvoJ+K9ZGHG/sVsa6yiesAD1GC/x46sET00Xlwo1u49RVVVzvcSkw==} engines: {node: '>= 10'} @@ -3599,20 +3413,19 @@ packages: engines: {node: '>= 0.8.0'} concat-map@0.0.1: - resolution: {integrity: sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=} + resolution: {integrity: sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==} + + concat-stream@1.6.2: + resolution: {integrity: sha512-27HBghJxjiZtIk3Ycvn/4kbJk/1uZuJFfuPEns6LaEvpvG1f0hTea8lilrouyo9mVc2GWdcEZ8OLoGmSADlrCw==} + engines: {'0': node >= 0.8} concordance@5.0.4: resolution: {integrity: sha512-OAcsnTEYu1ARJqWVGwf4zh4JDfHZEaSNlNccFmt8YjB2l/n19/PF2viLINHc57vO4FKIAFl2FWASIGZZWZ2Kxw==} engines: {node: '>=10.18.0 <11 || >=12.14.0 <13 || >=14'} - concurrently@7.6.0: - resolution: {integrity: sha512-BKtRgvcJGeZ4XttiDiNcFiRlxoAeZOseqUvyYRUp/Vtd+9p1ULmeoSqGsDA+2ivdeDFpqrJvGvmI+StKfKl5hw==} - engines: {node: ^12.20.0 || ^14.13.0 || >=16.0.0} - hasBin: true - - concurrently@8.2.2: - resolution: {integrity: sha512-1dP4gpXFhei8IOtlXRE/T/4H88ElHgTiUzh71YUmtjTEHMSRS2Z/fgOxHSxxusGHogsRfxNq1vyAwxSC+EVyDg==} - engines: {node: ^14.13.0 || >=16.0.0} + concurrently@9.0.1: + resolution: {integrity: sha512-wYKvCd/f54sTXJMSfV6Ln/B8UrfLBKOYa+lzc6CHay3Qek+LorVSBdMVfyewFhRbH0Rbabsk4D+3PL/VjQ5gzg==} + engines: {node: '>=18'} hasBin: true connect-history-api-fallback@1.6.0: @@ -3654,16 +3467,16 @@ packages: resolution: {integrity: sha512-aSWTXFzaKWkvHO1Ny/s+ePFpvKsPnjc551iI41v3ny/ow6tBG5Vd+FuqGNhh1LxOmVzOlGUriIlOaokOvhaStA==} engines: {node: '>= 0.6'} - cookie@0.5.0: - resolution: {integrity: sha512-YZ3GUyn/o8gfKJlnlX7g7xq4gyO6OSuhGPKaaGssGB2qgDUS0gPgtTvoyZLTt9Ab6dC4hfc9dV5arkvc/OCmrw==} + cookie@0.7.1: + resolution: {integrity: sha512-6DnInpx7SJ2AK3+CTUE/ZM0vWTUboZCegxhC2xiIydHR9jNuTAASBrfEpHhiGOZw/nX51bHt6YQl8jsGo4y/0w==} engines: {node: '>= 0.6'} copy-descriptor@0.1.1: resolution: {integrity: sha512-XgZ0pFcakEUlbwQEVNg3+QAis1FyTL3Qel9FYy8pSkQqoG3PNoT0bOCQtOXcOkur21r2Eq2kI+IE+gsmAEVlYw==} engines: {node: '>=0.10.0'} - core-js-compat@3.36.0: - resolution: {integrity: sha512-iV9Pd/PsgjNWBXeq8XRtWVSgz2tKAfhfvBs7qxYty+RlRd+OCksaWmOnc4JKrTc1cToXL1N0s3l/vwlxPtdElw==} + core-js-compat@3.38.1: + resolution: {integrity: sha512-JRH6gfXxGmrzF3tZ57lFx97YARxCXPaMzPo6jELZhv88pBH5VXpQ+y0znKGlFnzuaihqhLbefxSJxWJMPtfDzw==} core-util-is@1.0.2: resolution: {integrity: sha512-3lqz5YjWTYnW6dlDa5TLaTCcShfar1e40rmcJVwCBJC6mWlFuj0eCHIElmG1g5kyuJ/GD+8Wn4FFCcz4gJPfaQ==} @@ -3718,6 +3531,9 @@ packages: resolution: {integrity: sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==} engines: {node: '>= 8'} + crypt@0.0.2: + resolution: {integrity: sha512-mCxBlsHFYh9C+HVpiEacem8FEBnMXgU9gy4zmNC+SXAZNB/1idgp/aulFJ4FgCi7GPEVbfyng092GqL2k2rmow==} + css-select@4.3.0: resolution: {integrity: sha512-wPpOYtnsVontu2mODhA19JrqWxNsfdatRKd64kmpRbQgh1KtItko5sTnEpPdpSaJszTOhEMlF/RPz28qj4HqhQ==} @@ -3725,25 +3541,13 @@ packages: resolution: {integrity: sha512-HTUrgRJ7r4dsZKU6GjmpfRK1O76h97Z8MfS1G0FozR+oF2kG6Vfe8JE6zwrkbxigziPHinCJ+gCPjA9EaBDtRw==} engines: {node: '>= 6'} - csv-generate@3.4.3: - resolution: {integrity: sha512-w/T+rqR0vwvHqWs/1ZyMDWtHHSJaN06klRqJXBEpDJaM/+dZkso0OKh1VcuuYvK3XM53KysVNq8Ko/epCK8wOw==} - - csv-parse@4.16.3: - resolution: {integrity: sha512-cO1I/zmz4w2dcKHVvpCr7JVRu8/FymG5OEpmvsZYlccYolPBLoVGKUHgNoc4ZGkFeFlWGEDmMyBM+TTqRdW/wg==} - - csv-stringify@5.6.5: - resolution: {integrity: sha512-PjiQ659aQ+fUTQqSrd1XEDnOr52jh30RBurfzkscaE2tPaFsDH5wOAHJiw8XAHphRknCwMUE9KRayc4K/NbO8A==} - - csv@5.5.3: - resolution: {integrity: sha512-QTaY0XjjhTQOdguARF0lGKm5/mEq9PD9/VhZZegHDIBq2tQwgNpHc3dneD4mGo2iJs+fTKv5Bp0fZ+BRuY3Z0g==} - engines: {node: '>= 0.1.90'} - currently-unhandled@0.4.1: resolution: {integrity: sha512-/fITjgjGU50vjQ4FH6eUoYu+iUoUKIXws2hL15JJpIR+BbTxaXQsMuuyjtNh2WqsSBS5nsaZHFsFecyw5CCAng==} engines: {node: '>=0.10.0'} - d@1.0.1: - resolution: {integrity: sha512-m62ShEObQ39CfralilEQRjH6oAMtNCV1xJyEx5LpRYUVN+EviphDgUc/F3hnYbADmkiNs67Y+3ylmlG7Lnu+FA==} + d@1.0.2: + resolution: {integrity: sha512-MOqHvMWF9/9MX6nza0KgvFH4HpMU0EF5uUDXqX/BtxtU8NfB0QzRtJ8Oe/6SuS4kbhyzVJwjd97EA4PKrzJ8bw==} + engines: {node: '>=0.12'} dashdash@1.14.1: resolution: {integrity: sha512-jRFi8UDGo6j+odZiEpjazZaWqEal3w/basFjQHQEwVtZJGDpxbH1MeYluwCS8Xq5wmLJooDlMgvVarmWfGM44g==} @@ -3753,20 +3557,31 @@ packages: resolution: {integrity: sha512-7hvf7/GW8e86rW0ptuwS3OcBGDjIi6SZva7hCyWC0yYry2cOPmLIjXAUHI6DK2HsnwJd9ifmt57i8eV2n4YNpw==} engines: {node: '>= 14'} + data-view-buffer@1.0.1: + resolution: {integrity: sha512-0lht7OugA5x3iJLOWFhWK/5ehONdprk0ISXqVFn/NFrDu+cuc8iADFrGQz5BnRK7LLU3JmkbXSxaqX+/mXYtUA==} + engines: {node: '>= 0.4'} + + data-view-byte-length@1.0.1: + resolution: {integrity: sha512-4J7wRJD3ABAzr8wP+OcIcqq2dlUKp4DVflx++hs5h5ZKydWMI6/D/fAot+yh6g2tHh8fLFTvNOaVN357NvSrOQ==} + engines: {node: '>= 0.4'} + + data-view-byte-offset@1.0.0: + resolution: {integrity: sha512-t/Ygsytq+R995EJ5PZlD4Cu56sWa8InXySaViRzw9apusqsOO2bQP+SbYzAhR0pFKoB+43lYy8rWban9JSuXnA==} + engines: {node: '>= 0.4'} + dataloader@1.4.0: resolution: {integrity: sha512-68s5jYdlvasItOJnCuI2Q9s4q98g0pCyL3HrcKJu8KNugUl8ahgmZYg38ysLTgQjjXX3H8CJLkAvWrclWfcalw==} dataloader@2.2.2: resolution: {integrity: sha512-8YnDaaf7N3k/q5HnTJVuzSyLETjoZjVmHc4AeKAzOvKHEFQKcn64OKBfzHYtE9zGjctNM7V9I0MfnUVLpi7M5g==} - date-fns@2.30.0: - resolution: {integrity: sha512-fnULvOpxnC5/Vg3NCiWelDsLiUc9bRwAPs/+LfTLNvetFCtCTN+yQz15C/fs4AwX1R9K5GLtLfn8QW+dWisaAw==} - engines: {node: '>=0.11'} - date-time@3.1.0: resolution: {integrity: sha512-uqCUKXE5q1PNBXjPqvwhwJf9SwMoAHBgWJ6DcrnS5o+W2JOiIILl0JEdVD8SGujrNS02GGxgwAg2PN2zONgtjg==} engines: {node: '>=6'} + death@1.1.0: + resolution: {integrity: sha512-vsV6S4KVHvTGxbEcij7hkWRv0It+sGGWVOM67dQde/o5Xjnr+KmLjxWJii2uEObIrt1CcM9w0Yaovx+iOlIL+w==} + debug@2.6.9: resolution: {integrity: sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==} peerDependencies: @@ -3783,8 +3598,8 @@ packages: supports-color: optional: true - debug@4.3.4: - resolution: {integrity: sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==} + debug@4.3.7: + resolution: {integrity: sha512-Er2nc/H7RrMXZBFCEim6TCmMk02Z8vLC2Rbi1KEBggpo0fS6l0S1nnapwmIi3yW/+GOJap1Krg4w0Hg80oCqgQ==} engines: {node: '>=6.0'} peerDependencies: supports-color: '*' @@ -3792,9 +3607,14 @@ packages: supports-color: optional: true - decamelize-keys@1.1.1: - resolution: {integrity: sha512-WiPxgEirIV0/eIOMcnFBA3/IJZAZqKnwAwWyvvdi4lsr1WCN22nhdf/3db3DoZcUjTV2SqfzIwNyp6y2xs3nmg==} - engines: {node: '>=0.10.0'} + debug@4.4.0: + resolution: {integrity: sha512-6WTZ/IxCY/T6BALoZHaE4ctp9xm+Z5kY/pzYaCHRFeyVhojxlrm+46y68HA6hr0TcwEssoxNiDEUJQjfPZ/RYA==} + engines: {node: '>=6.0'} + peerDependencies: + supports-color: '*' + peerDependenciesMeta: + supports-color: + optional: true decamelize@1.2.0: resolution: {integrity: sha512-z2S+W9X73hAUUki+N+9Za2lBlun89zigOyGrsax+KUQ6wKW4ZoWpEYBkGhQjwAjjDCkWxhY0VKEhk8wzY7F5cA==} @@ -3816,8 +3636,8 @@ packages: resolution: {integrity: sha512-aW35yZM6Bb/4oJlZncMH2LCoZtJXTRxES17vE3hoRiowU2kWHaJKFkSBDnDR+cm9J+9QhXmREyIfv0pji9ejCQ==} engines: {node: '>=10'} - deep-eql@4.1.3: - resolution: {integrity: sha512-WaEtAOpRA1MQ0eohqZjpGD8zdI0Ovsm8mmFhaDN8dvDZzyoUMcYDnf5Y6iu7HTXxf8JDS23qWa4a+hKCDyOPzw==} + deep-eql@4.1.4: + resolution: {integrity: sha512-SUwdGfqdKOwxCPeVYjwSyRpJ7Z+fhpwIAtmCUdZIWZ/YP5R9WAsyuSgpLVDi9bjWoN2LXHNss/dk3urXtdQxGg==} engines: {node: '>=6'} deep-equal@1.1.2: @@ -3843,16 +3663,10 @@ packages: resolution: {integrity: sha512-eXTJmRbm2TIt9MgWTsOH1wEuhew6XGZcMeGKCtLedIg/NCsg1iBePXkceTdK4Fii7pzmN9tGsZhKzZ4h7O/fxw==} engines: {node: '>=8'} - defaults@1.0.4: - resolution: {integrity: sha512-eFuaLoy/Rxalv2kr+lqMlUnrDWV+3j4pljOIJgLIhI058IQfWJ7vXhyEIHu+HtC738klGALYxOKDO0bQP3tg8A==} - defer-to-connect@2.0.1: resolution: {integrity: sha512-4tvttepXG1VaYGrRibk5EwJd1t4udunSOVMdLSAL6mId1ix438oPwPZMALY41FCijukO1L0twNcGsdzS7dHgDg==} engines: {node: '>=10'} - deferred-leveldown@1.2.2: - resolution: {integrity: sha512-uukrWD2bguRtXilKt6cAWKyoXrTSMo5m7crUdLfWQmu8kIm88w3QZoUL+6nhpfKVmhHANER6Re3sKoNoZ3IKMA==} - define-data-property@1.1.4: resolution: {integrity: sha512-rBMvIzlpA8v6E+SJZoo++HAYqsLrkg7MSfIinMPFhmkorw7X+dOXVJQs+QT69zGkzMyfDnIMN2Wid1+NbL3T+A==} engines: {node: '>= 0.4'} @@ -3900,32 +3714,35 @@ packages: resolution: {integrity: sha512-2sJGJTaXIIaR1w4iJSNoN0hnMY7Gpc/n8D4qSCJw8QqFWXf7cuAgnEHxBpweaVcPevC2l3KpjYCx3NypQQgaJg==} engines: {node: '>= 0.8', npm: 1.2.8000 || >= 1.4.16} - destroyable-server@1.0.1: - resolution: {integrity: sha512-i3ZQbobNLw6EhSqgs0vFYqajDDWs0dm8JORWpQK+uRXBDxAAtGdmzTyqBkQNyr4hT6jMck3J7F2Qq6H50aJMyg==} + destroyable-server@1.0.2: + resolution: {integrity: sha512-Ln7ZKRq+7kr/3e4FCI8+jAjRbqbdaET8/ZBoUVvn+sDSAD7zDZA5mykkPRcrjBcaGy+LOM4ntMlIp1NMj1kMxw==} engines: {node: '>=12.0.0'} detect-indent@6.1.0: resolution: {integrity: sha512-reYkTUJAZb9gUuZ2RvVCNhVHdg62RHnJ7WJl8ftMi4diZ6NWlciOzQN88pUhSELEwflJht4oQDv0F0BMlwaYtA==} engines: {node: '>=8'} - detect-libc@2.0.2: - resolution: {integrity: sha512-UX6sGumvvqSaXgdKGUsgZWqcUyIXZ/vZTrlRT/iobiKhGL0zL4d3osHj3uqllWJK+i+sixDS/3COVEOFbupFyw==} + detect-libc@2.0.3: + resolution: {integrity: sha512-bwy0MGW55bG41VqxxypOsdSdGqLwXPI/focwgTYCFMbdUiBAxLg9CFzG08sz2aqzknwiX7Hkl0bQENjg8iLByw==} engines: {node: '>=8'} detect-node@2.1.0: resolution: {integrity: sha512-T0NIuQpnTvFDATNuHN5roPwSBG83rFsuO+MXXH9/3N1eFbn4wcPjttvjMLEPWJ0RGUYgQE7cGgS3tNxbqCGM7g==} - devtools-protocol@0.0.1232444: - resolution: {integrity: sha512-pM27vqEfxSxRkTMnF+XCmxSEb6duO5R+t8A9DEEJgy4Wz2RVanje2mmj99B6A3zv2r/qGfYlOvYznUhuokizmg==} + devtools-protocol@0.0.1367902: + resolution: {integrity: sha512-XxtPuC3PGakY6PD7dG66/o8KwJ/LkH2/EKe19Dcw58w53dv4/vSQEkn/SzuyhHE2q4zPgCkxQBxus3VV4ql+Pg==} diff@4.0.2: resolution: {integrity: sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==} engines: {node: '>=0.3.1'} - diff@5.0.0: - resolution: {integrity: sha512-/VTCrvm5Z0JGty/BWHljh+BAiw3IK+2j87NGMu8Nwc/f48WoDAC395uomO9ZD117ZOBaHmkX1oyLvkVM/aIT3w==} + diff@5.2.0: + resolution: {integrity: sha512-uIFDxqpRZGZ6ThOk84hEfqWoHx2devRFvpTZcTHur85vImfaxUbTW9Ryh4CpCuDnToOP1CEtXKIgytHBPVff5A==} engines: {node: '>=0.3.1'} + difflib@0.2.4: + resolution: {integrity: sha512-9YVwmMb0wQHQNr5J9m6BSj6fk4pfGITGQOOs+D9Fl+INODWFOfvhIU1hNv6GgR1RBoC/9NJcwu77zShxV0kT7w==} + dir-glob@3.0.1: resolution: {integrity: sha512-WkrWp9GR4KXfKGYzOLmTuGVi1UWFfws377n9cc55/tb6DuqyF6pcQ5AbiHEshaDpY9v6oaSr2XCDidGmMwdzIA==} engines: {node: '>=8'} @@ -3993,12 +3810,15 @@ packages: ee-first@1.1.1: resolution: {integrity: sha512-WMwm9LhRUo+WUaRN+vRuETqG89IgZphVSNkdFgeb6sS/E4OrDIN7t48CAewSHXc6C8lefD8KKfr5vY61brQlow==} - electron-to-chromium@1.4.682: - resolution: {integrity: sha512-oCglfs8yYKs9RQjJFOHonSnhikPK3y+0SvSYc/YpYJV//6rqc0/hbwd0c7vgK4vrl6y2gJAwjkhkSGWK+z4KRA==} + electron-to-chromium@1.5.45: + resolution: {integrity: sha512-vOzZS6uZwhhbkZbcRyiy99Wg+pYFV5hk+5YaECvx0+Z31NR3Tt5zS6dze2OepT6PCTzVzT0dIJItti+uAW5zmw==} elliptic@6.5.4: resolution: {integrity: sha512-iLhC6ULemrljPZb+QutR5TQGB+pdW6KGD5RSegS+8sorOZT+rdQFbsQFJgvN3eRqNALqJer4oQ16YvJHlU8hzQ==} + elliptic@6.5.7: + resolution: {integrity: sha512-ESVCtTwiA+XhY3wyh24QqRGBoP3rEdDUl3EDUUo9tft074fi19IrdpH7hLCMMP3CIj7jb3W96rn8lt/BqIlt5Q==} + emittery@0.10.0: resolution: {integrity: sha512-AGvFfs+d0JKCJQ4o01ASQLGPmSCxgfU9RFXvzPvZdjKK8oscynksuJhWrSTSw7j7Ep/sZct5b5ZhYCi8S/t0HQ==} engines: {node: '>=12'} @@ -4007,8 +3827,8 @@ packages: resolution: {integrity: sha512-tJdCJitoy2lrC2ldJcqN4vkqJ00lT+tOWNT1hBJjO/3FDMJa5TTIiYGCKGkn/WfCyOzUMObeohbVTj00fhiLiA==} engines: {node: '>=14.16'} - emoji-regex@10.3.0: - resolution: {integrity: sha512-QpLs9D9v9kArv4lfDEgg1X/gN5XLnf/A6l9cs8SPZLRZR3ZkY9+kwIQTxm+fsSej5UMYGE8fdoaZVIBlqG0XTw==} + emoji-regex@10.4.0: + resolution: {integrity: sha512-EC+0oUMY1Rqm4O6LLrgjtYDvcVYTy7chDnM4Q7030tP4Kwj3u/pR6gP9ygnp2CJMK5Gq+9Q2oqmrFJAz01DXjw==} emoji-regex@7.0.3: resolution: {integrity: sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA==} @@ -4023,11 +3843,15 @@ packages: resolution: {integrity: sha512-TPJXq8JqFaVYm2CWmPvnP2Iyo4ZSM7/QKcSmuMLDObfpH5fi7RUGmd/rTDf+rut/saiDiQEeVTNgAmJEdAOx0w==} engines: {node: '>= 0.8'} + encodeurl@2.0.0: + resolution: {integrity: sha512-Q0n9HRi4m6JuGIV1eFlmvJB7ZEVxu93IrMyiMsGC0lrMJMWzRgx6WGquyfQgZVb31vhGgXnfmPNNXmxnOkRBrg==} + engines: {node: '>= 0.8'} + end-of-stream@1.4.4: resolution: {integrity: sha512-+uw1inIHVPQoaVuHzRyXd21icM+cnt4CzD5rW+NC1wjOUSTOs+Te7FOv7AhN7vS9x/oIyhLP5PR1H+phQAHu5Q==} - enhanced-resolve@5.15.0: - resolution: {integrity: sha512-LXYT42KJ7lpIKECr2mAXIaMldcNCh/7E0KBKOu4KSfkHmP+mZmSs+8V5gBAqisWBy0OO4W5Oyys0GO1Y8KtdKg==} + enhanced-resolve@5.17.1: + resolution: {integrity: sha512-LMHl3dXhTcfv8gM4kEzIUeTQ+7fpdA0l2tUf34BddXPkz2A5xJ5L/Pchd5BL6rdccM9QGvu0sWZzK1Z1t4wwyg==} engines: {node: '>=10.13.0'} enquirer@2.4.1: @@ -4041,8 +3865,8 @@ packages: resolution: {integrity: sha512-+h1lkLKhZMTYjog1VEpJNG7NZJWcuc2DDk/qsqSTRRCOXiLjeQ1d1/udrUGhqMxUgAlwKNZ0cf2uqan5GLuS2A==} engines: {node: '>=6'} - envinfo@7.11.1: - resolution: {integrity: sha512-8PiZgZNIB4q/Lw4AhOvAfB/ityHAd2bli3lESSWmWSzSsl5dKpy5N1d1Rfkd2teq/g9xN90lc6o98DOjMeYHpg==} + envinfo@7.14.0: + resolution: {integrity: sha512-CO40UI41xDQzhLB1hWyqUKgFhs250pNcGbyGKe1l/e4FSaI/+YE4IMG76GDt0In67WLPACIITC+sOi08x4wIvg==} engines: {node: '>=4'} hasBin: true @@ -4053,13 +3877,10 @@ packages: error-ex@1.3.2: resolution: {integrity: sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g==} - es-abstract@1.22.4: - resolution: {integrity: sha512-vZYJlk2u6qHYxBOTjAeg7qUxHdNfih64Uu2J8QqWgXZ2cri0ZpJAkzDUK/q593+mvKwlxyaxr6F1Q+3LKoQRgg==} + es-abstract@1.23.3: + resolution: {integrity: sha512-e+HfNH61Bj1X9/jLc5v1owaLYuHdeHHSQlkhCBiTK8rBvKaULl/beGMxwrMXjpYrv4pz22BlY570vVePA2ho4A==} engines: {node: '>= 0.4'} - es-array-method-boxes-properly@1.0.0: - resolution: {integrity: sha512-wd6JXUmyHmt8T5a2xreUwKcGPq6f1f+WwIJkijUqiGcJz1qqnZgP6XIK+QyIWU5lT7imeNxUll48bziG+TSYcA==} - es-define-property@1.0.0: resolution: {integrity: sha512-jxayLKShrEqqzJ0eumQbVhTYQM27CfT1T35+gCgDFoL82JLsXqTJ76zv6A0YLOgEnLUMvLzsDsGIrl8NFpT2gQ==} engines: {node: '>= 0.4'} @@ -4068,8 +3889,12 @@ packages: resolution: {integrity: sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw==} engines: {node: '>= 0.4'} - es-module-lexer@1.4.1: - resolution: {integrity: sha512-cXLGjP0c4T3flZJKQSuziYoq7MlT+rnvfZjfp7h+I7K9BNX54kP9nyWvdbwjQ4u1iWbOL4u96fgeZLToQlZC7w==} + es-module-lexer@1.5.4: + resolution: {integrity: sha512-MVNK56NiMrOwitFB7cqDwq0CQutbw+0BvLshJSse0MUNU+y1FC3bUS/AQg7oUng+/wKrrki7JfmwtVHkVfPLlw==} + + es-object-atoms@1.0.0: + resolution: {integrity: sha512-MZ4iQ6JwHOBQjahnjwaC1ZtIBH+2ohjamzAO3oaHcXYup7qxjF2fixyH+Q71voWHeOkI2q/TnJao/KfXYIZWbw==} + engines: {node: '>= 0.4'} es-set-tostringtag@2.0.3: resolution: {integrity: sha512-3T8uNMC3OQTHkFUsFq8r/BwAXLHvU/9O9mE0fBc/MY5iq/8H7ncvO947LmYA6ldWw9Uh8Yhf25zu6n7nML5QWQ==} @@ -4082,8 +3907,8 @@ packages: resolution: {integrity: sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA==} engines: {node: '>= 0.4'} - es5-ext@0.10.63: - resolution: {integrity: sha512-hUCZd2Byj/mNKjfP9jXrdVZ62B8KuA/VoK7X8nUh5qT+AxDmcbvZz041oDVZdbIN1qW6XY9VDNwzkvKnZvK2TQ==} + es5-ext@0.10.64: + resolution: {integrity: sha512-p2snDhiLaXe6dahss1LddxqEm+SkuDvV8dnIQG0MWjyHpcMNfXKPE+/Cc0y+PhxJX3A4xGNeFCj5oc0BUh6deg==} engines: {node: '>=0.10'} es6-error@4.1.1: @@ -4095,16 +3920,17 @@ packages: es6-promise@4.2.8: resolution: {integrity: sha512-HJDGx5daxeIvxdBxvG2cb9g4tEvwIk3i8+nhX0yGrYmZUzbkdg8QbDevheDB8gd0//uPj4c1EQua8Q+MViT0/w==} - es6-symbol@3.1.3: - resolution: {integrity: sha512-NJ6Yn3FuDinBaBRWl/q5X/s4koRHBrgKAu+yGI6JCBeiu3qrcbJhwT2GeR/EXVfylRk8dpQVJoLEFhK+Mu31NA==} + es6-symbol@3.1.4: + resolution: {integrity: sha512-U9bFFjX8tFiATgtkJ1zg25+KviIXpgRvRHS8sau3GfhVzThRQrOeksPeT0BWW2MNZs1OEWJ1DPXOQMn0KKRkvg==} + engines: {node: '>=0.12'} - esbuild@0.19.12: - resolution: {integrity: sha512-aARqgq8roFBj054KvQr5f1sFu0D65G+miZRCuJyJ0G13Zwx7vRar5Zhn2tkQNzIXcBrNVsv/8stehpj+GAjgbg==} - engines: {node: '>=12'} + esbuild@0.23.1: + resolution: {integrity: sha512-VVNz/9Sa0bs5SELtn3f7qhJCDPCF5oMEl5cO9/SSinpE9hbPVvxbd572HH5AKiP7WD8INO53GgfDDhRjkylHEg==} + engines: {node: '>=18'} hasBin: true - escalade@3.1.2: - resolution: {integrity: sha512-ErCHMCae19vR8vQGe50xIsVomy19rg6gFu3+r3jkEO46suLMWBksvVyoGgQV+jOfl84ZSOSlmv6Gxa89PmTGmA==} + escalade@3.2.0: + resolution: {integrity: sha512-WUj2qlxaQtO4g6Pq5c29GTcWGDyd8itL8zTlipgECz3JesAiiOKotd8JU6otB3PACgG6xkJUyVhboMS+bje/jA==} engines: {node: '>=6'} escape-html@1.0.3: @@ -4126,6 +3952,11 @@ packages: resolution: {integrity: sha512-/veY75JbMK4j1yjvuUxuVsiS/hr/4iHs9FTT6cgTexxdE0Ly/glccBAkloH/DofkjRbZU3bnoj38mOmhkZ0lHw==} engines: {node: '>=12'} + escodegen@1.8.1: + resolution: {integrity: sha512-yhi5S+mNTOuRvyW4gWlg5W1byMaQGWWSYHXsuFZ7GBo7tpyOwi2EdzMP/QWxh9hwkD2m+wDVHJsxhRIj+v/b/A==} + engines: {node: '>=0.12.0'} + hasBin: true + escodegen@2.1.0: resolution: {integrity: sha512-2NlIDTwUWJN0mRPQOdtQBzbUHvdGY2P1VXSyU83Q3xKxM7WHX2Ql8dKq782Q9TgQUNOLEzEYu9bzLNj1q88I5w==} engines: {node: '>=6.0'} @@ -4140,8 +3971,8 @@ packages: eslint-import-resolver-node@0.3.9: resolution: {integrity: sha512-WFj2isz22JahUv+B788TlO3N6zL3nNJGU8CcZbPZvVEkBPaJdCV4vy5wyghty5ROFbCRnm132v8BScu5/1BQ8g==} - eslint-module-utils@2.8.1: - resolution: {integrity: sha512-rXDXR3h7cs7dy9RNpUlQf80nX31XWJEyGq1tRMo+6GsO5VmTe4UTwtmonAD4ZkAsrfMVDA2wlGJ3790Ys+D49Q==} + eslint-module-utils@2.12.0: + resolution: {integrity: sha512-wALZ0HFoytlyh/1+4wuZ9FJCD/leWHQzzrxJ8+rebyReSLk7LApMyd3WJaLVoN+D5+WIdJyDK1c6JnE65V4Zyg==} engines: {node: '>=4'} peerDependencies: '@typescript-eslint/parser': '*' @@ -4161,18 +3992,18 @@ packages: eslint-import-resolver-webpack: optional: true - eslint-plugin-import@2.29.1: - resolution: {integrity: sha512-BbPC0cuExzhiMo4Ff1BTVwHpjjv28C5R+btTOGaCRC7UEz801up0JadwkeSk5Ued6TG34uaczuVuH6qyy5YUxw==} + eslint-plugin-import@2.31.0: + resolution: {integrity: sha512-ixmkI62Rbc2/w8Vfxyh1jQRTdRTF52VxwRVHl/ykPAmqG+Nb7/kNn+byLP0LxPgI7zWA16Jt82SybJInmMia3A==} engines: {node: '>=4'} peerDependencies: '@typescript-eslint/parser': '*' - eslint: ^2 || ^3 || ^4 || ^5 || ^6 || ^7.2.0 || ^8 + eslint: ^2 || ^3 || ^4 || ^5 || ^6 || ^7.2.0 || ^8 || ^9 peerDependenciesMeta: '@typescript-eslint/parser': optional: true - eslint-plugin-prettier@5.1.3: - resolution: {integrity: sha512-C9GCVAs4Eq7ZC/XFQHITLiHJxQngdtraXaM+LoUFoFp/lHNl2Zn8f3WQbe9HvTBBQ9YnKFB0/2Ajdqwo5D1EAw==} + eslint-plugin-prettier@5.2.1: + resolution: {integrity: sha512-gH3iR3g4JfF+yYPaJYkN7jEl9QbweL/YfkoRlNnuIEHEz1vHVlCmWOS+eGGiRuzHQXdJFCOTxRgvju9b8VUmrw==} engines: {node: ^14.18.0 || >=16.0.0} peerDependencies: '@types/eslint': '>=8.0.0' @@ -4197,9 +4028,10 @@ packages: resolution: {integrity: sha512-wpc+LXeiyiisxPlEkUzU6svyS1frIO3Mgxj1fdy7Pm8Ygzguax2N3Fa/D/ag1WqbOprdI+uY6wMUl8/a2G+iag==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} - eslint@8.57.0: - resolution: {integrity: sha512-dZ6+mexnaTIbSBZWgou51U6OmzIhYM2VcNdtiTtI7qPNZm35Akpr0f6vtw3w1Kmn5PYo+tZVfh13WrhpS6oLqQ==} + eslint@8.57.1: + resolution: {integrity: sha512-ypowyDxpVSYpkXr9WPv2PAZCtNip1Mv5KTW0SCurXv/9iOpcrH9PaqUElksqEB6pChqHGDRCFTyrZlGhnLNGiA==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + deprecated: This version is no longer supported. Please see https://eslint.org/version-support for other options. hasBin: true esniff@2.0.1: @@ -4210,19 +4042,28 @@ packages: resolution: {integrity: sha512-oruZaFkjorTpF32kDSI5/75ViwGeZginGGy2NoOSg3Q9bnwlnmDm4HLnkl0RE3n+njDXR037aY1+x58Z/zFdwQ==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + esprima@2.7.3: + resolution: {integrity: sha512-OarPfz0lFCiW4/AV2Oy1Rp9qu0iusTKqykwTspGCZtPxmF81JR4MmIebvF1F9+UOKth2ZubLQ4XGGaU+hSn99A==} + engines: {node: '>=0.10.0'} + hasBin: true + esprima@4.0.1: resolution: {integrity: sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==} engines: {node: '>=4'} hasBin: true - esquery@1.5.0: - resolution: {integrity: sha512-YQLXUplAwJgCydQ78IMJywZCceoqk1oH01OERdSAJc/7U2AylwjhSCLDEtqwg811idIS/9fIU5GjG73IgjKMVg==} + esquery@1.6.0: + resolution: {integrity: sha512-ca9pw9fomFcKPvFLXhBKUK90ZvGibiGOvRJNbjljY7s7uq/5YO4BOzcYtJqExdx99rF6aAcnRxHmcUHcz6sQsg==} engines: {node: '>=0.10'} esrecurse@4.3.0: resolution: {integrity: sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag==} engines: {node: '>=4.0'} + estraverse@1.9.3: + resolution: {integrity: sha512-25w1fMXQrGdoquWnScXZGckOv+Wes+JDnuN/+7ex3SauFRS72r2lFDec0EKPt2YD1wUJ/IrfEex+9yp4hfSOJA==} + engines: {node: '>=0.10.0'} + estraverse@4.3.0: resolution: {integrity: sha512-39nnKffWz8xN1BU/2c79n9nB9HDzo0niYUqx6xyqUnyoAnQyyWpOTdZEeiCch8BBu515t4wp9ZmgVfVhn9EBpw==} engines: {node: '>=4.0'} @@ -4245,25 +4086,16 @@ packages: resolution: {integrity: sha512-aIL5Fx7mawVa300al2BnEE4iNvo1qETxLrPI/o05L7z6go7fCw1J6EQmbK4FmJ2AS7kgVF/KEZWufBfdClMcPg==} engines: {node: '>= 0.6'} - eth-block-tracker@5.0.1: - resolution: {integrity: sha512-NVs+JDSux0FdmOrl3A2YDcQFkkYf9/qW9irvPmtC7bhMoPAe6oBlaqqe/m9Ixh5rkKqAox4mEyWGpsFmf/IsNw==} - eth-ens-namehash@2.0.8: resolution: {integrity: sha512-VWEI1+KJfz4Km//dadyvBBoBeSQ0MHTXPvr8UIXiLW6IanxvAV+DmlZAijZwAyggqGUfwQBeHf7tc9wzc1piSw==} - eth-json-rpc-filters@4.2.2: - resolution: {integrity: sha512-DGtqpLU7bBg63wPMWg1sCpkKCf57dJ+hj/k3zF26anXMzkmtSBDExL8IhUu7LUd34f0Zsce3PYNO2vV2GaTzaw==} - - eth-json-rpc-infura@5.1.0: - resolution: {integrity: sha512-THzLye3PHUSGn1EXMhg6WTLW9uim7LQZKeKaeYsS9+wOBcamRiCQVGHa6D2/4P0oS0vSaxsBnU/J6qvn0MPdow==} - deprecated: Package no longer supported. Contact Support at https://www.npmjs.com/support for more info. - - eth-json-rpc-middleware@6.0.0: - resolution: {integrity: sha512-qqBfLU2Uq1Ou15Wox1s+NX05S9OcAEL4JZ04VZox2NS0U+RtCMjSxzXhLFWekdShUPZ+P8ax3zCO2xcPrp6XJQ==} - - eth-json-rpc-middleware@9.0.1: - resolution: {integrity: sha512-5yLNjkedXA4LTIBzzU2f7aHFJqANPsc5qCdOZy6T2p7mlDLW+0q0YBQg6Lx4sHdamOWUnJwvm70qzPAqst5zSg==} - engines: {node: '>=14.0.0'} + eth-gas-reporter@0.2.27: + resolution: {integrity: sha512-femhvoAM7wL0GcI8ozTdxfuBtBFJ9qsyIAsmKVjlWAHUbdnnXHt+lKzz/kmldM5lA9jLuNHGwuIxorNpLbR1Zw==} + peerDependencies: + '@codechecks/client': ^0.1.0 + peerDependenciesMeta: + '@codechecks/client': + optional: true eth-lib@0.1.29: resolution: {integrity: sha512-bfttrr3/7gG4E02HoWTDUcDDslN003OlOoBxk9virpAZQ1ja/jDgwkWB8QfJF7ojuEowrqy+lzp9VcJG7/k5bQ==} @@ -4271,27 +4103,8 @@ packages: eth-lib@0.2.8: resolution: {integrity: sha512-ArJ7x1WcWOlSpzdoTBX8vkwlkSQ85CjjifSZtV4co64vWxSV8geWfPI9x4SVYu3DSxnX4yWFVTtGL+j9DUFLNw==} - eth-query@2.1.2: - resolution: {integrity: sha512-srES0ZcvwkR/wd5OQBRA1bIJMww1skfGS0s8wlwK3/oNP4+wnds60krvu5R1QbpRQjMmpG5OMIWro5s7gvDPsA==} - - eth-rpc-errors@3.0.0: - resolution: {integrity: sha512-iPPNHPrLwUlR9xCSYm7HHQjWBasor3+KZfRvwEWxMz3ca0yqnlBeJrnyphkGIXZ4J7AMAaOLmwy4AWhnxOiLxg==} - - eth-rpc-errors@4.0.3: - resolution: {integrity: sha512-Z3ymjopaoft7JDoxZcEb3pwdGh7yiYMhOwm2doUt6ASXlMavpNlK6Cre0+IMl2VSGyEU9rkiperQhp5iRxn5Pg==} - - eth-sig-util@1.4.2: - resolution: {integrity: sha512-iNZ576iTOGcfllftB73cPB5AN+XUQAT/T8xzsILsghXC1o8gJUqe3RHlcDqagu+biFpYQ61KQrZZJza8eRSYqw==} - deprecated: Deprecated in favor of '@metamask/eth-sig-util' - - ethereum-bloom-filters@1.0.10: - resolution: {integrity: sha512-rxJ5OFN3RwjQxDcFP2Z5+Q9ho4eIdEmSc2ht0fCu8Se9nbXjZ7/031uXoUYJ87KHCOdVeiUuwSnoS7hmYAGVHA==} - - ethereum-common@0.0.18: - resolution: {integrity: sha512-EoltVQTRNg2Uy4o84qpa2aXymXDJhxm7eos/ACOg0DG4baAbMjhbdAEsx9GeE8sC3XCxnYvrrzZDH8D8MtA2iQ==} - - ethereum-common@0.2.0: - resolution: {integrity: sha512-XOnAR/3rntJgbCdGhqdaLIxDLWKLmsZOGhHdBKadEr6gEnJLH52k93Ou+TUdFaPN3hJc3isBZBal3U/XZ15abA==} + ethereum-bloom-filters@1.2.0: + resolution: {integrity: sha512-28hyiE7HVsWubqhpVLVmZXFd4ITeHi+BUu05o9isf0GUpMtzBUi+8/gFrGaGYzvGAJQmJ3JKj77Mk9G98T84rA==} ethereum-cryptography@0.1.3: resolution: {integrity: sha512-w8/4x1SGGzc+tO97TASLja6SLd3fRIK2tLVcV2Gx4IB21hE19atll5Cq9o3d0ZmAYC/8aw0ipieTSiekAea4SQ==} @@ -4299,43 +4112,12 @@ packages: ethereum-cryptography@1.2.0: resolution: {integrity: sha512-6yFQC9b5ug6/17CQpCyE3k9eKBMdhyVjzUy1WkiuY/E4vj/SXDBbCw8QEIaXqf0Mf2SnY6RmpDcwlUmBSS0EJw==} - ethereum-cryptography@2.1.3: - resolution: {integrity: sha512-BlwbIL7/P45W8FGW2r7LGuvoEZ+7PWsniMvQ4p5s2xCyw9tmaDlpfsN9HjAucbF+t/qpVHwZUisgfK24TCW8aA==} + ethereum-cryptography@2.2.1: + resolution: {integrity: sha512-r/W8lkHSiTLxUxW8Rf3u4HGB0xQweG2RyETjywylKZSzLWoWAijRz8WCuOtJ6wah+avllXBqZuk29HCCvhEIRg==} ethereumjs-abi@0.6.8: resolution: {integrity: sha512-Tx0r/iXI6r+lRsdvkFDlut0N08jWMnKRZ6Gkq+Nmw75lZe4e6o3EkSnkaBP5NF6+m5PTGAr9JP43N3LyeoglsA==} - ethereumjs-abi@https://codeload.github.com/ethereumjs/ethereumjs-abi/tar.gz/ee3994657fa7a427238e6ba92a84d0b529bbcde0: - resolution: {tarball: https://codeload.github.com/ethereumjs/ethereumjs-abi/tar.gz/ee3994657fa7a427238e6ba92a84d0b529bbcde0} - name: ethereumjs-abi - version: 0.6.8 - - ethereumjs-account@2.0.5: - resolution: {integrity: sha512-bgDojnXGjhMwo6eXQC0bY6UK2liSFUSMwwylOmQvZbSl/D7NXQ3+vrGO46ZeOgjGfxXmgIeVNDIiHw7fNZM4VA==} - - ethereumjs-block@1.7.1: - resolution: {integrity: sha512-B+sSdtqm78fmKkBq78/QLKJbu/4Ts4P2KFISdgcuZUPDm9x+N7qgBPIIFUGbaakQh8bzuquiRVbdmvPKqbILRg==} - deprecated: 'New package name format for new versions: @ethereumjs/block. Please update.' - - ethereumjs-block@2.2.2: - resolution: {integrity: sha512-2p49ifhek3h2zeg/+da6XpdFR3GlqY3BIEiqxGF8j9aSRIgkb7M1Ky+yULBKJOu8PAZxfhsYA+HxUk2aCQp3vg==} - deprecated: 'New package name format for new versions: @ethereumjs/block. Please update.' - - ethereumjs-common@1.5.2: - resolution: {integrity: sha512-hTfZjwGX52GS2jcVO6E2sx4YuFnf0Fhp5ylo4pEPhEffNln7vS59Hr5sLnp3/QCazFLluuBZ+FZ6J5HTp0EqCA==} - deprecated: 'New package name format for new versions: @ethereumjs/common. Please update.' - - ethereumjs-tx@1.3.7: - resolution: {integrity: sha512-wvLMxzt1RPhAQ9Yi3/HKZTn0FZYpnsmQdbKYfUUpi4j1SEIcbkd9tndVjcPrufY3V7j2IebOpC00Zp2P/Ay2kA==} - deprecated: 'New package name format for new versions: @ethereumjs/tx. Please update.' - - ethereumjs-tx@2.1.2: - resolution: {integrity: sha512-zZEK1onCeiORb0wyCXUvg94Ve5It/K6GD1K+26KfFKodiBiS6d9lfCXlUKGBBdQ+bv7Day+JK0tj1K+BeNFRAw==} - deprecated: 'New package name format for new versions: @ethereumjs/tx. Please update.' - - ethereumjs-util@5.2.1: - resolution: {integrity: sha512-v3kT+7zdyCm1HIqWlLNrHGqHGLpGYIhjeHxQjnDXjLT2FyGJDsd3LWMYUo7pAFRrk86CR3nUJfhC81CCoJNNGQ==} - ethereumjs-util@6.2.1: resolution: {integrity: sha512-W2Ktez4L01Vexijrm5EB6w7dg4n/TgpoYU4avuT5T3Vmnw/eCRtiBrJfQYS/DCSvDIOLn2k57GcHdeBcgVxAqw==} @@ -4343,13 +4125,13 @@ packages: resolution: {integrity: sha512-SDl5kKrQAudFBUe5OJM9Ac6WmMyYmXX/6sTmLZ3ffG2eY6ZIGBes3pEDxNN6V72WyOw4CPD5RomKdsa8DAAwLg==} engines: {node: '>=10.0.0'} - ethereumjs-vm@2.6.0: - resolution: {integrity: sha512-r/XIUik/ynGbxS3y+mvGnbOKnuLo40V5Mj1J25+HEO63aWYREIqvWeRO/hnROlMBE5WoniQmPmhiaN0ctiHaXw==} - deprecated: 'New package name format for new versions: @ethereumjs/vm. Please update.' - ethers@5.7.2: resolution: {integrity: sha512-wswUsmWo1aOK8rR7DIKiWSw9DbLWe6x98Jrn8wcTflTVvaXhAMaB5zGAXy0GYQEQp9iO1iSHWVyARQm11zUtyg==} + ethers@6.13.4: + resolution: {integrity: sha512-21YtnZVg4/zKkCQPjrDj38B1r4nQvTZLopUGMLQ1ePU2zV/joCfDC3t3iKQjWRzjjjbzR+mdAIoikeBRNkdllA==} + engines: {node: '>=14.0.0'} + ethjs-unit@0.1.6: resolution: {integrity: sha512-/Sn9Y0oKl0uqQuvgFk/zQgR7aw1g36qX/jzSQ5lSwlO0GigPymk4eGQfeNTD03w1dPOqfz8V77Cy43jH56pagw==} engines: {node: '>=6.5.0', npm: '>=3'} @@ -4392,8 +4174,8 @@ packages: resolution: {integrity: sha512-w/ozOKR9Obk3qoWeY/WDi6MFta9AoMR+zud60mdnbniMcBxRuFJyDt2LdX/14A1UABeqk+Uk+LDfUpvoGKppZA==} engines: {node: '>=0.10.0'} - express@4.18.2: - resolution: {integrity: sha512-5/PsL6iGPdfQ/lKM1UuielYgv3BUoJfz1aUwU9vHZ+J7gyvwdQXFEBIEIaxeGf0GIcreATNyBExtalisDbuMqQ==} + express@4.21.1: + resolution: {integrity: sha512-YSFlK1Ee0/GC8QaO91tHcDxJiE/X4FbpAyQWkxAvG6AXCuR65YzK8ua6D9hvi/TzUfZMpc+BwuM1IPw8fmQBiQ==} engines: {node: '>= 0.10.0'} ext@1.7.0: @@ -4433,9 +4215,6 @@ packages: fake-indexeddb@4.0.2: resolution: {integrity: sha512-SdTwEhnakbgazc7W3WUXOJfGmhH0YfG4d+dRPOFoYDRTL6U5t8tvrmkf2W/C3W1jk2ylV7Wrnj44RASqpX/lEw==} - fake-merkle-patricia-tree@1.0.1: - resolution: {integrity: sha512-Tgq37lkc9pUIgIKw5uitNUKcgcYL3R6JvXtKQbOf/ZSavXbidsksgp/pAY6p//uhw0I4yoMsvTSovvVIsk/qxA==} - fast-deep-equal@2.0.1: resolution: {integrity: sha512-bCK/2Z4zLidyB4ReuIsvALH6w31YfAQDmXMqMx6FyfHqvBxtjC0eRumeSu4Bs3XtXwpyIywtSTrVT99BxY1f9w==} @@ -4452,17 +4231,20 @@ packages: resolution: {integrity: sha512-oX2ruAFQwf/Orj8m737Y5adxDQO0LAB7/S5MnxCdTNDd4p6BsyIVsv9JQsATbTSq8KHRpLwIHbVlUNatxd+1Ow==} engines: {node: '>=8.6.0'} + fast-json-patch@3.1.1: + resolution: {integrity: sha512-vf6IHUX2SBcA+5/+4883dsIjpBTqmfBjmYiWK1savxQmFk4JfBMLa7ynTYOs1Rolp/T1betJxHiGD3g1Mn8lUQ==} + fast-json-stable-stringify@2.1.0: resolution: {integrity: sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw==} fast-levenshtein@2.0.6: resolution: {integrity: sha512-DCXu6Ifhqcks7TZKY3Hxp3y6qphY5SJZmrWMDrKcERSOXWQdMhU9Ig/PYrzyw/ul9jOIyh0N4M0tbC5hodg8dw==} - fast-safe-stringify@2.1.1: - resolution: {integrity: sha512-W+KJc2dmILlPplD/H4K9l9LcAHAfPtP6BY84uVLXQ6Evcz9Lcg33Y2z1IVblT6xdY54PXYVHEv+0Wpq8Io6zkA==} + fast-uri@3.0.3: + resolution: {integrity: sha512-aLrHthzCjH5He4Z2H9YZ+v6Ujb9ocRuW6ZzkJQOrTxleEijANq4v1TsaPaVG1PZcuurEzrLcWRyYBYXD5cEiaw==} - fast-xml-parser@4.2.5: - resolution: {integrity: sha512-B9/wizE4WngqQftFPmdaMYlXoJlJOYxGQOanC77fq9k8+Z0v5dDSVh+3glErdIROP//s/jgb7ZuxKfB8nVyo0g==} + fast-xml-parser@4.4.1: + resolution: {integrity: sha512-xkjOecfnKGkSsOwtZ5Pz7Us/T6mrbPQrq0nh+aCO5V9nk5NLWmasAHumTKjiPJPWANe+kAZ84Jc8ooJkzZ88Sw==} hasBin: true fastest-levenshtein@1.0.16: @@ -4479,8 +4261,8 @@ packages: fd-slicer@1.1.0: resolution: {integrity: sha512-cE1qsB/VwyQozZ+q1dGxR8LBYNZeofhEdUNGSMbQD3Gw2lAzX9Zb3uIU6Ebc/Fmyjo9AWWfnn0AUCHqtevs/8g==} - figures@6.0.1: - resolution: {integrity: sha512-0oY/olScYD4IhQ8u//gCPA4F3mlTn2dacYmiDm/mbDQvpmLjV4uH+zhsQ5IyXRyvqkvtUkXkNdGvg5OFJTCsuQ==} + figures@6.1.0: + resolution: {integrity: sha512-d+l3qxjSesT4V7v2fh+QnmFnUWv9lSpjarhShNTgBOfA0ttejbQUAlHLitbjkoRiDulW0OPoQPYIGhIC8ohejg==} engines: {node: '>=18'} file-entry-cache@6.0.1: @@ -4494,16 +4276,16 @@ packages: resolution: {integrity: sha512-VcpLTWqWDiTerugjj8e3+esbg+skS3M9e54UuR3iCeIDMXCLTsAH8hTSzDQU/X6/6t3eYkOKoZSef2PlU6U1XQ==} engines: {node: '>=0.10.0'} - fill-range@7.0.1: - resolution: {integrity: sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==} + fill-range@7.1.1: + resolution: {integrity: sha512-YsGpe3WHLK8ZYi4tWDg2Jy3ebRz2rXowDxnld4bkQB00cc/1Zw9AWnC0i9ztDJitivtQvaI9KaLyKrc+hBW0yg==} engines: {node: '>=8'} finalhandler@1.1.2: resolution: {integrity: sha512-aAWcW57uxVNrQZqFXjITpW3sIUQmHGG3qSb9mUah9MgMC4NeWhNOlNjXEYq3HjRAvL6arUviZGGJsBg6z0zsWA==} engines: {node: '>= 0.8'} - finalhandler@1.2.0: - resolution: {integrity: sha512-5uXcUVftlQMFnWC9qu/svkWv3GTd2PfUhK/3PLkYNAe7FbqJMt3515HaxE6eRL74GdsriiwujiawdaB1BpEISg==} + finalhandler@1.3.1: + resolution: {integrity: sha512-6BN9trH7bp3qvnrRyzsBz+g3lZxTNZTbVO2EV1CS0WIcDbawYVdYvGflME/9QP0h0pYlCDBCTjYa9nZzMDpyxQ==} engines: {node: '>= 0.8'} find-cache-dir@3.3.2: @@ -4514,10 +4296,6 @@ packages: resolution: {integrity: sha512-9ZonPT4ZAK4a+1pUPVPZJapbi7O5qbbJPdYw/NOQWZZbVLdDTYM3A4R9z/DpAM08IDaFGsvPgiGZ82WEwUDWjg==} engines: {node: '>=14.16'} - find-replace@1.0.3: - resolution: {integrity: sha512-KrUnjzDCD9426YnCP56zGYy/eieTnhtK6Vn++j+JJzmlsWWwEkDnsyVF575spT6HJ6Ow9tlbT3TQTDsa+O4UWA==} - engines: {node: '>=4.0.0'} - find-replace@3.0.0: resolution: {integrity: sha512-6Tb2myMioCAgv5kfvP5/PkZZ/ntTpVK39fHY7WkWBgvbeE+VHd/tZuZ4mrC+bxh4cfOZeYKVPaJIZtZXV7GNCQ==} engines: {node: '>=4.0.0'} @@ -4546,9 +4324,6 @@ packages: resolution: {integrity: sha512-v2ZsoEuVHYy8ZIlYqwPe/39Cy+cFDzp4dXPaxNvkEuouymu+2Jbz0PxpKarJHYJTmv2HWT3O382qY8l4jMWthw==} engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} - find-yarn-workspace-root2@1.2.16: - resolution: {integrity: sha512-hr6hb1w8ePMpPVUK39S4RlwJzi+xPLuVuG8XlwXU3KD5Yn3qgBWVfy3AzNlDhWvE1EORCE65/Qm26rFQt3VLVA==} - flat-cache@3.2.0: resolution: {integrity: sha512-CYcENa+FtcUKLmhhqyctpclsq7QF38pKjZHsGNiSQF5r4FtoKDWabFDl3hzaEQMvT1LHEysw5twgLvpYYb4vbw==} engines: {node: ^10.12.0 || >=12.0.0} @@ -4560,8 +4335,8 @@ packages: flatted@3.3.1: resolution: {integrity: sha512-X8cqMLLie7KsNUDSdzeN8FYK9rEt4Dt67OsG/DNGnYTSDBG4uFAJFBnUeiV+zCVAvwFy56IjM9sH51jVaEhNxw==} - follow-redirects@1.15.5: - resolution: {integrity: sha512-vSFWUON1B+yAw1VN4xMfxgn5fTUiaOzAJCKBwIIgT/+7CuGy9+r+5gITvP62j3RmaD5Ph65UaERdOSRGUzZtgw==} + follow-redirects@1.15.9: + resolution: {integrity: sha512-gew4GsXizNgdoRyqmyfMHyAmXsZDk6mHkSxZFCzW9gwlbtOW44CDtYavM+y+72qD/Vq2l550kMF52DT8fOLJqQ==} engines: {node: '>=4.0'} peerDependencies: debug: '*' @@ -4580,8 +4355,8 @@ packages: resolution: {integrity: sha512-dCIq9FpEcyQyXKCkyzmlPTFNgrCzPudOe+mhvJU5zAtlBnGVy2yKxtfsxK2tQBThwq225jcvBjpw1Gr40uzZCA==} engines: {node: '>=8.0.0'} - foreground-child@3.1.1: - resolution: {integrity: sha512-TMKDUnIte6bfb5nWv7V/caI169OHgvwjb7V4WkeUvbQQdjr5rWKqHFiKWb/fcOwB+CzBT+qbWjvj+DVwRskpIg==} + foreground-child@3.3.0: + resolution: {integrity: sha512-Ld2g8rrAyMYFXBhEqMz8ZAHBi4J4uS1i/CxGMDnjyFWddMXLVcDp051DZfu+t7+ab7Wv6SMqpWmyFIj5UbfFvg==} engines: {node: '>=14'} forever-agent@0.6.1: @@ -4594,8 +4369,12 @@ packages: resolution: {integrity: sha512-1lLKB2Mu3aGP1Q/2eCOx0fNbRMe7XdwktwOruhfqqd0rIJWwN4Dh+E3hrPSlDCXnSR7UtZ1N38rVXm+6+MEhJQ==} engines: {node: '>= 0.12'} - form-data@4.0.0: - resolution: {integrity: sha512-ETEklSGi5t0QMZuiXoA/Q6vcnxcLQP5vdugSpuAyi6SVGi2clPPp+xgEhuMaHC+zGgn31Kd235W35f7Hykkaww==} + form-data@2.5.2: + resolution: {integrity: sha512-GgwY0PS7DbXqajuGf4OYlsrIu3zgxD6Vvql43IBhm6MahqA5SK/7mwhtNj2AdH2z35YR34ujJ7BN+3fFC3jP5Q==} + engines: {node: '>= 0.12'} + + form-data@4.0.1: + resolution: {integrity: sha512-tzN8e4TX8+kkxGPK8D5u0FNmjPUjw3lwC9lSLxxoB/+GtsJG91CO8bSWy73APlgAZzZbXEYZJuxjkHH2w+Ezhw==} engines: {node: '>= 6'} forwarded@0.2.0: @@ -4616,8 +4395,9 @@ packages: fromentries@1.3.2: resolution: {integrity: sha512-cHEpEQHUg0f8XdtZCc2ZAhrHzKzT0MrFUTcvx+hfxYu7rGMDc5SKoXFh+n4YigxsHXRzc6OrCshdR1bWH6HHyg==} - fs-extra@0.30.0: - resolution: {integrity: sha512-UvSPKyhMn6LEd/WpUaV9C9t3zATuqoqfWc3QdPhPLb58prN9tqYPlPWi8Krxi44loBoUzlobqZ3+8tGpxxSzwA==} + fs-extra@10.1.0: + resolution: {integrity: sha512-oRXApq54ETRj4eMiFzGnHWGy+zo5raudjuxN0b8H7s/RU2oW0Wvsx9O0ACRN/kRq9E8Vu/ReskGB5o3ji+FzHQ==} + engines: {node: '>=12'} fs-extra@11.2.0: resolution: {integrity: sha512-PmDi3uwK5nFuXh7XDTlVnS17xJS7vW36is2+w3xcv8SVxiB4NyATf4ctkVY5bkSjX0Y4nbvZCq1/EjtEyr9ktw==} @@ -4645,6 +4425,9 @@ packages: resolution: {integrity: sha512-V/JgOLFCS+R6Vcq0slCuaeWEdNC3ouDlJMNIsacH2VtALiu9mV4LPrHc5cDl8k5aw6J8jwgWWpiTo5RYhmIzvg==} engines: {node: '>= 8'} + fs-readdir-recursive@1.1.0: + resolution: {integrity: sha512-GNanXlVr2pf02+sPN40XN8HG+ePaNcvM0q5mZBd668Obwb0yD5GiUbZOFgwn8kGMY6I3mdyDJzieUy3PTYyTRA==} + fs.realpath@1.0.0: resolution: {integrity: sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==} @@ -4652,7 +4435,7 @@ packages: resolution: {integrity: sha512-oWb1Z6mkHIskLzEJ/XWX0srkpkTQ7vaopMQkyaEIoq0fmtFVxOthb8cCxeT+p3ynTdkk/RZwbgG4brR5BeWECw==} engines: {node: '>= 4.0'} os: [darwin] - deprecated: The v1 package contains DANGEROUS / INSECURE binaries. Upgrade to safe fsevents v2 + deprecated: Upgrade to fsevents v2 to mitigate potential security issues fsevents@2.3.3: resolution: {integrity: sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==} @@ -4666,9 +4449,6 @@ packages: resolution: {integrity: sha512-Z5kx79swU5P27WEayXM1tBi5Ze/lbIyiNgU3qyXUOf9b2rgXYyF9Dy9Cx+IQv/Lc8WCG6L82zwUPpSS9hGehIg==} engines: {node: '>= 0.4'} - functional-red-black-tree@1.0.1: - resolution: {integrity: sha512-dsKNQNdj6xA3T+QlADDA7mOSlX0qiMINjn0cgr+eGHGsbSHzTabcIogz2+p/iqP1Xs6EP/sS2SbqH+brGTbq0g==} - functions-have-names@1.2.3: resolution: {integrity: sha512-xckBUXyTIqT97tq2x2AMb+g163b5JFysYk0x4qxNFwbfQkmNZoiRHb6sPzI9/QV33WeuvVYBUIiD4NzNIyqaRQ==} @@ -4684,6 +4464,7 @@ packages: gauge@3.0.2: resolution: {integrity: sha512-+5J6MS/5XksCuXq++uFRsnUd7Ovu1XenbeuIuNRJxYWjgQbPuFhT14lAvsWfqfAmnwluf1OwMjz39HjfLPci0Q==} engines: {node: '>=10'} + deprecated: This package is no longer supported. gensync@1.0.0-beta.2: resolution: {integrity: sha512-3hN7NaskYvMDLQY55gnW3NQ+mesEAepTqlg+VEbj7zzqEMBVNhzcGYYeqFo/TlYz6eQiFcp1HcsCZO+nGgS8zg==} @@ -4693,8 +4474,8 @@ packages: resolution: {integrity: sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==} engines: {node: 6.* || 8.* || >= 10.*} - get-east-asian-width@1.2.0: - resolution: {integrity: sha512-2nk+7SIVb14QrgXFHcm84tD4bKQz0RxPuMT8Ag5KPOq7J5fEmAg0UbXdTOSHqNuHSU28k55qnceesxXRZGzKWA==} + get-east-asian-width@1.3.0: + resolution: {integrity: sha512-vpeMIQKxczTD/0s2CdEWHcb0eeJe6TFjxb+J5xgX7hScxqrGuyjmv4c1D4A/gelKfyox0gJJwIHF+fLjeaM8kQ==} engines: {node: '>=18'} get-func-name@2.0.2: @@ -4708,6 +4489,10 @@ packages: resolution: {integrity: sha512-pjzuKtY64GYfWizNAJ0fr9VqttZkNiK2iS430LtIHzjBEr6bX8Am2zm4sW4Ro5wjWW5cAlRL1qAMTcXbjNAO2Q==} engines: {node: '>=8.0.0'} + get-port@3.2.0: + resolution: {integrity: sha512-x5UJKlgeUiNT8nyo/AcnwLnZuZNcSjSw0kogRB+Whd1fjjFq4B1hySFxSFWWSn4mIBzg3sRNUDFYc4g5gjPoLg==} + engines: {node: '>=4'} + get-stream@4.1.0: resolution: {integrity: sha512-GMat4EJ5161kIy2HevLlr4luNjBgvmj413KaQA7jt4V8B4RDsfpHk7WQ9GVqfYyyx8OS/L66Kox+rJRNklLK7w==} engines: {node: '>=6'} @@ -4724,8 +4509,8 @@ packages: resolution: {integrity: sha512-g0QYk1dZBxGwk+Ngc+ltRH2IBp2f7zBkBMBJZCDerh6EhlhSR6+9irMCuT/09zD6qkarHUSn529sK/yL4S27mg==} engines: {node: '>= 0.4'} - get-tsconfig@4.7.2: - resolution: {integrity: sha512-wuMsz4leaj5hbGgg4IvDU0bqJagpftG5l5cXIAvo8uZrqn0NJqwtfupTN00VnkQJPcIRrxYrm1Ue24btpCha2A==} + get-tsconfig@4.8.1: + resolution: {integrity: sha512-k9PN+cFBmaLWtVz29SkUoqU5O0slLuHJXt/2P+tMVFT+phsSGXGkp9t3rQIqdz0e+06EHNGs3oM6ZX1s2zHxRg==} get-uri@6.0.3: resolution: {integrity: sha512-BzUrJBS9EcUb4cFol8r4W3v1cPsSyajLSthNkz5BxbpDcHN5tIrM10E2eNvfnvBn3DaT3DUgx0OpsBKkaOpanw==} @@ -4738,6 +4523,10 @@ packages: getpass@0.1.7: resolution: {integrity: sha512-0fzj9JxOLfJ+XGLhR8ze3unN0KZCgZwiSSDz168VERjK8Wl8kVSdcu2kspd4s4wtAa1y/qrVRiAA0WclVsu0ng==} + ghost-testrpc@0.0.2: + resolution: {integrity: sha512-i08dAEgJ2g8z5buJIrCTduwPIhih3DP+hOCTyyryikfV8T0bNvHnGXO67i0DD1H4GBDETTclPy9njZbfluQYrQ==} + hasBin: true + glob-base@0.3.0: resolution: {integrity: sha512-ab1S1g1EbO7YzauaJLkgLp7DZVAqj9M/dvKlTt8DkXA2tiOIcSMrlVI2J1RZyB5iJVccEscjGn+kpOG9788MHA==} engines: {node: '>=0.10.0'} @@ -4753,23 +4542,39 @@ packages: glob-to-regexp@0.4.1: resolution: {integrity: sha512-lkX1HJXwyMcprw/5YUZc2s7DrpAiHB21/V+E1rHUrVNokkvB6bqMzT0VfV6/86ZNabt1k14YOIaT7nDvOX3Iiw==} - glob@10.3.10: - resolution: {integrity: sha512-fa46+tv1Ak0UPK1TOy/pZrIybNNt4HCv7SDzwyfiOZkvZLEbjsZkJBPtDHVshZjbecAoAGSC20MjLDG/qr679g==} - engines: {node: '>=16 || 14 >=14.17'} + glob@11.0.0: + resolution: {integrity: sha512-9UiX/Bl6J2yaBbxKoEBRm4Cipxgok8kQYcOPEhScPwebu2I0HoQOuYdIO6S3hLuWoZgpDpwQZMzTFxgpkyT76g==} + engines: {node: 20 || >=22} hasBin: true + glob@5.0.15: + resolution: {integrity: sha512-c9IPMazfRITpmAAKi22dK1VKxGDX9ehhqfABDriL/lzO92xcUKEJPQHrVA/2YHSNFB4iFlykVmWvwo48nr3OxA==} + deprecated: Glob versions prior to v9 are no longer supported + glob@7.1.7: resolution: {integrity: sha512-OvD9ENzPLbegENnYP5UUfJIirTg4+XwMWGaQfQTY0JenxNvvIKP3U3/tAQSPIu/lHxXYSZmpXlUHeqAIdKzBLQ==} + deprecated: Glob versions prior to v9 are no longer supported glob@7.2.0: resolution: {integrity: sha512-lmLf6gtyrPq8tTjSmrO94wBeQbFR3HbLHbuyD69wuyQkImp2hWqMGB47OX65FBkPffO641IP9jWa1z4ivqG26Q==} + deprecated: Glob versions prior to v9 are no longer supported glob@7.2.3: resolution: {integrity: sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==} + deprecated: Glob versions prior to v9 are no longer supported glob@8.1.0: resolution: {integrity: sha512-r8hpEjiQEYlF2QU0df3dS+nxxSIreXQS1qRhMJM0Q5NDdR386C7jb7Hwwod8Fgiuex+k0GFjgft18yvxm5XoCQ==} engines: {node: '>=12'} + deprecated: Glob versions prior to v9 are no longer supported + + global-modules@2.0.0: + resolution: {integrity: sha512-NGbfmJBp9x8IxyJSd1P+otYK8vonoJactOogrVfFRIAEY1ukil8RSKDz2Yo7wh1oihl51l/r6W4epkeKJHqL8A==} + engines: {node: '>=6'} + + global-prefix@3.0.0: + resolution: {integrity: sha512-awConJSVCHVGND6x3tmMaKcQvwXLhjdkmomy2W+Goaui8YPgYgXJZewhg3fWC+DlfqqQuWg8AwqjGTD2nAPVWg==} + engines: {node: '>=6'} global@4.4.0: resolution: {integrity: sha512-wv/LAoHdRE3BeTGz53FAamhGlPLhlssK45usmGFThIi4XqnBmjKQ16u+RNbP7WvigRZDxUsM0J3gcQ5yicaL0w==} @@ -4782,16 +4587,20 @@ packages: resolution: {integrity: sha512-AhO5QUcj8llrbG09iWhPU2B204J1xnPeL8kQmVorSsy+Sjj1sk8gIyh6cUocGmH4L0UuhAJy+hJMRA4mgA4mFQ==} engines: {node: '>=8'} - globalthis@1.0.3: - resolution: {integrity: sha512-sFdI5LyBiNTHjRd7cGPWapiHWMOXKyuBNX/cWJ3NfzrZQVa8GI/8cofCl74AOVqq9W5kNmguTIzJ/1s2gyI9wA==} + globalthis@1.0.4: + resolution: {integrity: sha512-DpLKbNU4WylpxJykQujfCcwYWiV/Jhm50Goo0wrVILAv5jOr9d+H+UR3PhSCD2rCCEIg0uc+G+muBTwD54JhDQ==} engines: {node: '>= 0.4'} + globby@10.0.2: + resolution: {integrity: sha512-7dUi7RvCoT/xast/o/dLN53oqND4yk0nsHkhRgn9w65C4PofCLOoJ39iSOg+qVDdWQPIEj+eszMHQ+aLVwwQSg==} + engines: {node: '>=8'} + globby@11.1.0: resolution: {integrity: sha512-jhIXaOzy1sb8IyocaruWSn1TjmnBVs8Ayhcy83rmxNJ8q2uWKCAj3CnJY+KpGSXCueAPc0i05kVvVKtP1t9S3g==} engines: {node: '>=10'} - globby@14.0.1: - resolution: {integrity: sha512-jOMLD2Z7MAhyG8aJpNOpmziMOP4rPLcc95oQPKXBazW82z+CEgPFBQvEpRUa1KeIMUJo4Wsm+q6uzO/Q/4BksQ==} + globby@14.0.2: + resolution: {integrity: sha512-s3Fq41ZVh7vbbe2PN3nrW7yC7U7MFVc5c98/iTl9c2GawNMKx/J648KQRW6WKkuU8GIbbh2IXfIRQjOZnXcTnw==} engines: {node: '>=18'} globby@6.1.0: @@ -4812,14 +4621,11 @@ packages: graceful-fs@4.2.11: resolution: {integrity: sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==} - grapheme-splitter@1.0.4: - resolution: {integrity: sha512-bzh50DW9kTPM00T8y4o8vQg89Di9oLJVLW/KaOGIXJWP/iqCN6WKYkbNOF04vFLJhwcpYUh9ydh/+5vpOqV4YQ==} - graphemer@1.4.0: resolution: {integrity: sha512-EtKwoO6kxCL9WO5xipiHTZlSzBm7WLT627TqC/uVRd0HKmq8NXyebnNYxDoBi7wt8eTWrUrKXCOVaFq9x1kgag==} - graphql-http@1.22.0: - resolution: {integrity: sha512-9RBUlGJWBFqz9LwfpmAbjJL/8j/HCNkZwPBU5+Bfmwez+1Ay43DocMNQYpIWsWqH0Ftv6PTNAh2aRnnMCBJgLw==} + graphql-http@1.22.1: + resolution: {integrity: sha512-4Jor+LRbA7SfSaw7dfDUs2UBzvWg3cKrykfHRgKsOIvQaLuf+QOcG2t3Mx5N9GzSNJcuqMqJWz0ta5+BryEmXg==} engines: {node: '>=12'} peerDependencies: graphql: '>=0.11 <=16' @@ -4835,13 +4641,18 @@ packages: peerDependencies: graphql: ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 - graphql@15.8.0: - resolution: {integrity: sha512-5gghUc24tP9HRznNpV2+FIoq3xKkj5dTQqf4v0CpdPbFVwFkWoxOM+o+2OC9ZSvjEMTjfmG9QT+gcvggTwW1zw==} + graphql@15.9.0: + resolution: {integrity: sha512-GCOQdvm7XxV1S4U4CGrsdlEN37245eC8P9zaYCMr6K1BG0IPGy5lUwmJsEOGyl1GD6HXjOtl2keCP9asRBwNvA==} engines: {node: '>= 10.x'} handle-thing@2.0.1: resolution: {integrity: sha512-9Qn4yBxelxoh2Ow62nP+Ka/kMnOXRi8BXnRaUwezLNhqelnN49xKz4F/dPP8OYLxLxq6JDtZb2i9XznUQbNPTg==} + handlebars@4.7.8: + resolution: {integrity: sha512-vafaFqs8MZkRrSX7sFVUdo3ap/eNiLnb4IakshzvP56X5Nr1iGKAIqdX6tMlm6HcNRIkr6AxO5jFEoJzzpT8aQ==} + engines: {node: '>=0.4.7'} + hasBin: true + har-schema@2.0.0: resolution: {integrity: sha512-Oqluz6zhGX8cyRaTQlFMPw80bSJVG2x/cFb8ZPhUILGgHka9SsokCCOQgpveePerqidZOrT14ipqfJb7ILcW5Q==} engines: {node: '>=4'} @@ -4851,12 +4662,13 @@ packages: engines: {node: '>=6'} deprecated: this library is no longer supported - hard-rejection@2.1.0: - resolution: {integrity: sha512-VIZB+ibDhx7ObhAe7OVtoEbuP4h/MuOTHJ+J8h/eBXotJYl0fBgR72xDFCKgIh22OJZIOVNxBMWuhAr10r8HdA==} - engines: {node: '>=6'} + hardhat-gas-reporter@1.0.10: + resolution: {integrity: sha512-02N4+So/fZrzJ88ci54GqwVA3Zrf0C9duuTyGt0CFRIh/CdNwbnTgkXkRfojOMLBQ+6t+lBIkgbsOtqMvNwikA==} + peerDependencies: + hardhat: ^2.0.2 - hardhat@2.20.1: - resolution: {integrity: sha512-q75xDQiQtCZcTMBwjTovrXEU5ECr49baxr4/OBkIu/ULTPzlB20yk1dRWNmD2IFbAeAeXggaWvQAdpiScaHtPw==} + hardhat@2.22.14: + resolution: {integrity: sha512-sD8vHtS9l5QQVHzyPPe3auwZDJyZ0fG3Z9YENVa4oOqVEefCuHcPzdU736rei3zUKTqkX0zPIHkSMHpu02Fq1A==} hasBin: true peerDependencies: ts-node: '*' @@ -4870,6 +4682,10 @@ packages: has-bigints@1.0.2: resolution: {integrity: sha512-tSvCKtBr9lkF0Ex0aQiP9N+OpV4zi2r/Nee5VkRDbaqv35RLYMzbwQfFSZZH0kR+Rd6302UJZ2p/bJCEoR3VoQ==} + has-flag@1.0.0: + resolution: {integrity: sha512-DyYHfIYwAJmjAjSSPKANxI8bFY9YtFrgkAfinBojQ8YJTOuOuav64tMUJv584SES4xl74PmuaevIyaLESHdTAA==} + engines: {node: '>=0.10.0'} + has-flag@3.0.0: resolution: {integrity: sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw==} engines: {node: '>=4'} @@ -4923,20 +4739,20 @@ packages: resolution: {integrity: sha512-Hrp5vIK/xr5SkeN2onO32H0MgNZ0f17HRNH39WfL0SYUNOTZ5Lz1TJ8Pajo/87dYGEFlLMm7mIc/k/s6Bvz9HQ==} engines: {node: '>=8'} - hasown@2.0.1: - resolution: {integrity: sha512-1/th4MHjnwncwXsIW6QMzlvYL9kG5e/CpVvLRZe4XPa8TOUNbCELqmvhDmnkNsAjwaG4+I8gJJL0JBvTTLO9qA==} + hasown@2.0.2: + resolution: {integrity: sha512-0hJU9SCPvmMzIBdZFqNPXWa6dqh7WdH0cII9y+CyS8rG3nL48Bclra9HmKhVVUHyPWNH5Y7xDwAB7bfgSjkUMQ==} engines: {node: '>= 0.4'} he@1.2.0: resolution: {integrity: sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw==} hasBin: true + heap@0.2.7: + resolution: {integrity: sha512-2bsegYkkHO+h/9MGbn6KWcE45cHZgPANo5LXF7EvWdT0yT2EguSVO1nDgU5c8+ZOPwp2vMNa7YFsJhVcDR9Sdg==} + hmac-drbg@1.0.1: resolution: {integrity: sha512-Tti3gMqLdZfhOQY1Mzf/AanLiqh1WTiJgEj26ZuYQ9fbkLomzGchCws4FyrSd4VkpBfiNhaE1On+lOz894jvXg==} - hosted-git-info@2.8.9: - resolution: {integrity: sha512-mxIDAb9Lsm6DoOJ7xH+5+X4y1LU/4Hi50L9C5sIswK3JzULS4bwk1FvjdBgvYR4bzT4tuUQiC15FE2f5HbLvYw==} - hpack.js@2.1.6: resolution: {integrity: sha512-zJxVehUdMGIKsRaNt7apO2Gqp0BdqW5yaiGHXXmbpvxgBYVZnAql+BJb4RO5ad2MgpbZKn5G6nMnegrH1FcNYQ==} @@ -4951,8 +4767,8 @@ packages: engines: {node: '>=12'} hasBin: true - html-webpack-plugin@5.6.0: - resolution: {integrity: sha512-iwaY4wzbe48AfKLZ/Cc8k0L+FKG6oSNRaZ8x5A/T/IVDGyXcbHncM9TdDa93wn0FsSm82FhTKW7f3vS61thXAw==} + html-webpack-plugin@5.6.3: + resolution: {integrity: sha512-QSf1yjtSAsmf7rYBV7XX86uua4W/vkhIt0xNXKbsi2foEeW7vjJQz4bhnpL3xH+l1ryl1680uNv968Z+X6jSYg==} engines: {node: '>=10.13.0'} peerDependencies: '@rspack/core': 0.x || 1.x @@ -4966,14 +4782,19 @@ packages: htmlparser2@6.1.0: resolution: {integrity: sha512-gyyPk6rgonLFEDGoeRgQNaEUvdJ4ktTmmUh/h2t7s+M8oPpIPxgNACWa+6ESR57kXstwqPiCut0V8NRpcwgU7A==} + http-basic@8.1.3: + resolution: {integrity: sha512-/EcDMwJZh3mABI2NhGfHOGOeOZITqfkEO4p/xK+l3NpyncIHUQBoMvCSF/b5GqvKtySC2srL/GGG3+EtlqlmCw==} + engines: {node: '>=6.0.0'} + http-cache-semantics@4.1.1: resolution: {integrity: sha512-er295DKPVsV82j5kw1Gjt+ADA/XYHsajl82cGNQG2eyoPkvgUhX+nDIyelzhIWbbsXP39EHcI6l5tYs2FYqYXQ==} http-deceiver@1.2.7: resolution: {integrity: sha512-LmpOGxTfbpgtGVxJrj5k7asXHCgNZp5nLfp+hWc8QQRqtb7fUy6kRY3BO1h9ddF6yIPYUARgxGOwB42DnxIaNw==} - http-encoding@1.5.1: - resolution: {integrity: sha512-2m4JnG1Z5RX5pRMdccyp6rX1jVo4LO+ussQzWdwR4AmrWhtX0KP1NyslVAFAspQwMxt2P00CCWXIBKj7ILZLpQ==} + http-encoding@2.0.1: + resolution: {integrity: sha512-vqe8NzlqqvDgcrwI2JTPAiB/6Zs1zTEVZNnTZBJeBhaejLGSpXQtNf87ifumq/P4X82G9E4WWfJMNmwb6vsuGw==} + engines: {node: '>=v18.0.0'} http-errors@1.6.3: resolution: {integrity: sha512-lks+lVC8dgGyh97jxvxeYTWQFvh4uw4yC12gVl63Cg30sjPX4wuGcdkICVXDAESr6OJGjqGA8Iz5mkeN6zlD7A==} @@ -5001,14 +4822,13 @@ packages: resolution: {integrity: sha512-7mz/721AbnJwIVbnaSv1Cz3Am0ZLT/UBwkC92VlxhXv/k/BBQfM2fXElQNC27BVGr0uwUpplYPQM9LnaBMR5NQ==} engines: {node: '>=8.0.0'} + http-response-object@3.0.2: + resolution: {integrity: sha512-bqX0XTF6fnXSQcEJ2Iuyr75yVakyjIDCqroJQ/aHfSdlM743Cwqoi2nDYMzLGWUcuTWGWy8AAvOKXTfiv6q9RA==} + http-signature@1.2.0: resolution: {integrity: sha512-CAbnr6Rz4CYQkLYUtSNXxQPUH2gK8f3iWexVlsnMeD+GjlsQ0Xsy1cOX+mN3dtxYomRy21CiOzU8Uhw6OwncEQ==} engines: {node: '>=0.8', npm: '>=1.3.7'} - http-signature@1.3.6: - resolution: {integrity: sha512-3adrsD6zqo4GsTqtO7FyrejHNv+NgiIfAfv68+jVlFmSr9OGy7zrxONceFRLKvnnZA5jbxQBX1u9PpB6Wi32Gw==} - engines: {node: '>=0.10'} - http2-wrapper@1.0.3: resolution: {integrity: sha512-V+23sDMr12Wnz7iTcDeJr3O6AIxlnvT/bmaAAAP/Xda35C90p9599p0F1eHR/N1KILWSoWVAiOMFjBBXaXSMxg==} engines: {node: '>=10.19.0'} @@ -5021,8 +4841,12 @@ packages: resolution: {integrity: sha512-dFcAjpTQFgoLMzC2VwU+C/CbS7uRL0lWmxDITmqm7C+7F0Odmj6s9l6alZc6AELXhrnggM2CeWSXHGOdX2YtwA==} engines: {node: '>= 6'} - https-proxy-agent@7.0.4: - resolution: {integrity: sha512-wlwpilI7YdjSkWaQ/7omYBMTliDcmCN8OLihO6I9B86g06lMyAoqgoDpV0XqoaPOKj+0DIdAvnsWfyAAhmimcg==} + https-proxy-agent@7.0.5: + resolution: {integrity: sha512-1e4Wqeblerz+tMKPIq2EMGiiWW1dIjZOksyHWSUm1rmuvw/how9hBHZ38lAGj5ID4Ik6EdkOw7NmWPy6LAwalw==} + engines: {node: '>= 14'} + + https-proxy-agent@7.0.6: + resolution: {integrity: sha512-vK9P5/iUfdl95AI+JVyUuIcVtd4ofvtrOr3HNtM2yxC9bnMbEdp3x01OhQNnjb8IJYi38VlTE3mBXwcfvywuSw==} engines: {node: '>= 14'} human-id@1.0.2: @@ -5054,15 +4878,15 @@ packages: ignore-walk@3.0.4: resolution: {integrity: sha512-PY6Ii8o1jMRA1z4F2hRkH/xN59ox43DavKvD3oDpfurRlOJyAHpifIwpbdv1n4jt4ov0jSpw3kQ4GhJnpBL6WQ==} - ignore@5.3.1: - resolution: {integrity: sha512-5Fytz/IraMjqpwfd34ke28PTVMjZjJG2MPn5t7OE4eUCUNf8BAa7b5WUS9/Qvr6mwOQS7Mk6vdsMno5he+T8Xw==} + ignore@5.3.2: + resolution: {integrity: sha512-hsBTNUqQTDwkWtcdYI2i06Y/nUBEsNEDJKjWdigLvegy8kDuJAS8uRlpkkcQpyEXL0Z/pjDy5HBmMjRCJ2gq+g==} engines: {node: '>= 4'} - immediate@3.3.0: - resolution: {integrity: sha512-HR7EVodfFUdQCTIeySw+WDRFJlPcLOJbXfwwZ7Oom6tjsvZ3bOkCDJHehQC3nxJrv7+f9XecwazynjU8e4Vw3Q==} + immer@10.0.2: + resolution: {integrity: sha512-Rx3CqeqQ19sxUtYV9CU911Vhy8/721wRFnJv3REVGWUmoAcIwzifTsdmJte/MV+0/XpM35LZdQMBGkRIoLPwQA==} - immutable@4.3.5: - resolution: {integrity: sha512-8eabxkth9gZatlwl5TBuJnCsoTADlL6ftEr7A4qgdaTsPyreilDSnUk57SO+jfKcNtxPa22U5KK6DSeAYhpBJw==} + immutable@4.3.7: + resolution: {integrity: sha512-1hqclzwYwjRDFLjcFxOM5AYkkG0rpFPpr1RLPMEuGczoS7YA8gLhy8SWXYRAA/XwfEHpfo3cw5JGioS32fnMRw==} import-fresh@3.3.0: resolution: {integrity: sha512-veYYhQa+D1QBKznvhUHxb8faxlrwUnxseDAbAp457E0wLNio2bOSKnjYDhMj+YiAq61xrMGhQk9iXVk5FzgQMw==} @@ -5073,8 +4897,8 @@ packages: engines: {node: '>=6'} hasBin: true - import-local@3.1.0: - resolution: {integrity: sha512-ASB07uLtnDs1o6EHjKpX34BKYDSqnFerfTOJL2HvMqF70LnxpjkzDB8J44oT9pu4AMPkQwf8jl6szgvNd2tRIg==} + import-local@3.2.0: + resolution: {integrity: sha512-2SPlun1JUPWoM6t3F0dw0FkCF/jWY8kttcY4f599GLTSjh2OCuuhdTkJQsEcZzBqbXZGKMK2OqW1oZsjtf/gQA==} engines: {node: '>=8'} hasBin: true @@ -5092,6 +4916,7 @@ packages: inflight@1.0.6: resolution: {integrity: sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA==} + deprecated: This module is not supported, and leaks memory. Do not use it. Check out lru-cache if you want a good and tested way to coalesce async requests by a key value, which is much more comprehensive and powerful. inherits@2.0.3: resolution: {integrity: sha512-x00IRNXNy63jwGkJmzPigoySHbaqpNuzKbBOmzK+g2OdZpQ9w+sxCN+VSB3ja7IAge2OP2qpfxTjeNcyjmW1uw==} @@ -5099,6 +4924,9 @@ packages: inherits@2.0.4: resolution: {integrity: sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==} + ini@1.3.8: + resolution: {integrity: sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew==} + internal-ip@4.3.0: resolution: {integrity: sha512-S1zBo1D6zcsyuC6PMmY5+55YMILQ9av8lotMx447Bq6SAgo/sDK6y6uUKmuYhW7eacnIhFfsPmCNYdDzsnnDCg==} engines: {node: '>=6'} @@ -5107,6 +4935,10 @@ packages: resolution: {integrity: sha512-NGnrKwXzSms2qUUih/ILZ5JBqNTSa1+ZmP6flaIp6KmSElgE9qdndzS3cqjrDovwFdmwsGsLdeFgB6suw+1e9g==} engines: {node: '>= 0.4'} + interpret@1.4.0: + resolution: {integrity: sha512-agE4QfB2Lkp9uICn7BAqoscw4SZP9kTE2hxiFI3jBPmXJfdqiahTbUuKGsMoN2GtqL9AxhYioAcVvgsb1HvRbA==} + engines: {node: '>= 0.10'} + interpret@2.2.0: resolution: {integrity: sha512-Ju0Bz/cEia55xDwUWEa8+olFpCiQoypjnQySseKtmjNrnps3P+xfpUmGr90T7yjlVJmOtybRvPXhKMbHr+fWnw==} engines: {node: '>= 0.10'} @@ -5178,13 +5010,18 @@ packages: resolution: {integrity: sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA==} engines: {node: '>= 0.4'} - is-core-module@2.13.1: - resolution: {integrity: sha512-hHrIjvZsftOsvKSn2TRYl63zvxsgE0K+0mYMoH6gD4omR5IWB2KynivBQczo3+wF1cCkjzvptnI9Q0sPU66ilw==} + is-core-module@2.15.1: + resolution: {integrity: sha512-z0vtXSwucUJtANQWldhbtbt7BnL0vxiFjIdDLAatwhDYty2bad6s+rijD6Ri4YuYJubLzIJLUidCh09e1djEVQ==} + engines: {node: '>= 0.4'} is-data-descriptor@1.0.1: resolution: {integrity: sha512-bc4NlCDiCr28U4aEsQ3Qs2491gVq4V8G7MQyws968ImqjKuYtTJXrl7Vq7jsN7Ly/C3xj5KWFrY7sHNeDkAzXw==} engines: {node: '>= 0.4'} + is-data-view@1.0.1: + resolution: {integrity: sha512-AHkaJrsUVW6wq6JS8y3JnM/GJF/9cf+k20+iDzlSaJrinEo5+7vRiteOSwBhHRiAyQATN1AmY4hwzxJKPmYf+w==} + engines: {node: '>= 0.4'} + is-date-object@1.0.5: resolution: {integrity: sha512-9YQaSxsAiSwcvS33MBk3wTCVnWK+HhF8VZR2jRxehM16QcVOdHqPn4VPHmRK4lSr38n9JriurInLcP90xsYNfQ==} engines: {node: '>= 0.4'} @@ -5217,10 +5054,6 @@ packages: resolution: {integrity: sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==} engines: {node: '>=0.10.0'} - is-fn@1.0.0: - resolution: {integrity: sha512-XoFPJQmsAShb3jEQRfzf2rqXavq7fIqF/jOekp308JlThqrODnMpweVSGilKTCXELfLhltGP2AGgbQGVP8F1dg==} - engines: {node: '>=0.10.0'} - is-fullwidth-code-point@2.0.0: resolution: {integrity: sha512-VHskAKYM8RfSFXwee5t5cbN5PZeq1Wrh6qd5bkyiXIf6UQcN6w/A0eXM9r6t8d+GYOh+o6ZhiEnb88LN/Y8m2w==} engines: {node: '>=4'} @@ -5249,7 +5082,7 @@ packages: engines: {node: '>=0.10.0'} is-hex-prefixed@1.0.0: - resolution: {integrity: sha1-fY035q135dEnFIkTxXPggtd39VQ=} + resolution: {integrity: sha512-WvtOiug1VFrE9v1Cydwm+FnXd3+w9GaeVUss5W4v/SLy3UW00vP+6iNF2SdnfiBoLy4bTqVdkftNGTUeOFVsbA==} engines: {node: '>=6.5.0', npm: '>=3'} is-module@1.0.0: @@ -5287,10 +5120,6 @@ packages: resolution: {integrity: sha512-Fd4gABb+ycGAmKou8eMftCupSir5lRxqf4aD/vd0cD2qc4HL07OjCeuHMr8Ro4CoMaeCKDB0/ECBOVWjTwUvPQ==} engines: {node: '>=8'} - is-plain-obj@1.1.0: - resolution: {integrity: sha512-yvkRyxmFKEOQ4pNXCmJG5AEQNlXJS5LaONXo5/cLdTZdWvsZ1ioJEonLGAosKlMWE8lwUy/bJzMjcw8az73+Fg==} - engines: {node: '>=0.10.0'} - is-plain-obj@2.1.0: resolution: {integrity: sha512-YWnfyRwxL/+SsrWYfOpUtz5b3YD+nyfkHvjbcanzk8zgyO4ASD67uVMRt8k5bM4lLMDnXfriRhOpemw+NfT1eA==} engines: {node: '>=8'} @@ -5348,8 +5177,8 @@ packages: resolution: {integrity: sha512-knxG2q4UC3u8stRGyAVJCOdxFmv5DZiRcdlIaAQXAbSfJya+OhopNotLQrstBhququ4ZpuKbDc/8S6mgXgPFPw==} engines: {node: '>=10'} - is-unicode-supported@2.0.0: - resolution: {integrity: sha512-FRdAyx5lusK1iHG0TWpVtk9+1i+GjrzRffhDg4ovQ7mcidMQ6mj+MhKPmvh7Xwyv5gIS06ns49CA7Sqg7lC22Q==} + is-unicode-supported@2.1.0: + resolution: {integrity: sha512-mE00Gnza5EEB3Ds0HfMyllZzbBrmLOX3vfWoj9A9PEnTfratQ/BcaJOuMhnkhjXvb2+FkY3VuHqtAGpTPmglFQ==} engines: {node: '>=18'} is-weakref@1.0.2: @@ -5363,9 +5192,6 @@ packages: resolution: {integrity: sha512-gfygJYZ2gLTDlmbWMI0CE2MwnFzSN/2SZfkMlItC4K/JBlsWVDB0bO6XhqcY13YXE7iMcAJnzTCJjPiTeJJ0Mw==} engines: {node: '>=4'} - isarray@0.0.1: - resolution: {integrity: sha512-D2S+3GLxWH+uhrNEcoh/fnmYeP8E8/zHl644d/jdA0g2uyXvy3sb0qxotE+ne0LtccHknQzWwZEzhak7oJ0COQ==} - isarray@1.0.0: resolution: {integrity: sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ==} @@ -5403,6 +5229,10 @@ packages: resolution: {integrity: sha512-BXgQl9kf4WTCPCCpmFGoJkz/+uhvm7h7PFKUYxh7qarQd3ER33vHG//qaE8eN25l07YqZPpHXU9I09l/RD5aGQ==} engines: {node: '>=8'} + istanbul-lib-instrument@6.0.3: + resolution: {integrity: sha512-Vtgk7L/R2JHyyGW07spoFlB8/lpjiOLTjMdms6AFMraYt3BaJauod/NGrfnVG/y4Ix1JEuMRPDPEj2ua+zz1/Q==} + engines: {node: '>=10'} + istanbul-lib-processinfo@2.0.3: resolution: {integrity: sha512-NkwHbo3E00oybX6NGJi6ar0B29vxyvNwoC7eJ4G4Yq28UfY758Hgn/heV8VRFhevPED4LXfFz0DQ8z/0kw9zMg==} engines: {node: '>=8'} @@ -5422,9 +5252,9 @@ packages: iterall@1.3.0: resolution: {integrity: sha512-QZ9qOMdF+QLHxy1QIpUHUU1D5pS2CG2P69LF6L6CPjPYA/XMOmKV3PZpawHoAjHNyB0swdVTRxdYT4tbBbxqwg==} - jackspeak@2.3.6: - resolution: {integrity: sha512-N3yCS/NegsOBokc8GAdM8UcmfsKiSS8cipheD/nivzr700H+nsMOxJjQnvwOcRYVuFkdH0wGUvW2WbXGmrZGbQ==} - engines: {node: '>=14'} + jackspeak@4.0.2: + resolution: {integrity: sha512-bZsjR/iRjl1Nk1UkjGpAzLNfQtzuijhn2g+pbZb98HQ1Gk8vM9hfbxeMBP+M2/UUdwj0RqGG3mlvk2MsAqwvEw==} + engines: {node: 20 || >=22} jest-worker@26.6.2: resolution: {integrity: sha512-KWYVV1c4i+jbMpaBC+U++4Va0cp8OisU185o73T1vo99hqi7w8tSJfUXYswwqqrjzwxa6KpRK54WhPvwf5w6PQ==} @@ -5434,15 +5264,12 @@ packages: resolution: {integrity: sha512-7vuh85V5cdDofPyxn58nrPjBktZo0u9x1g8WtjQol+jZDaE+fhN+cIvTj11GndBnMnyfrUOG1sZQxCdjKh+DKg==} engines: {node: '>= 10.13.0'} - joi@17.12.2: - resolution: {integrity: sha512-RonXAIzCiHLc8ss3Ibuz45u28GOsWE1UpfDXLbN/9NKbL4tCJf8TWYVKsoYuuh+sAUt7fsSNpA+r2+TBA6Wjmw==} + joi@17.13.3: + resolution: {integrity: sha512-otDA4ldcIx+ZXsKHWmp0YizCweVRZG96J10b0FevjfuncLO1oX59THoAmHkNubYJ+9gWsYsp5k8v4ib6oDv1fA==} js-base64@3.7.7: resolution: {integrity: sha512-7rCnleh0z2CkXhH67J8K1Ytz0b2Y+yxTPL+/KOJoa20hfnVQ/3/T6W/KflYI4bRHRagNeXeU2bkNGI3v1oS/lw==} - js-sdsl@4.4.2: - resolution: {integrity: sha512-dwXFwByc/ajSV6m5bcKAPwe4yDDF6D614pxmIi5odytzxRlwqF6nwoiCek80Ixc7Cvma5awClxrzFtxCQvcM8w==} - js-sha3@0.5.7: resolution: {integrity: sha512-GII20kjaPX0zJ8wzkTbNDYMY7msuZcTWk8S5UOh6806Jq/wz1J8/bnr8uGU0DAUmYDjj2Mr4X1cW8v/GLYnR+g==} @@ -5470,13 +5297,9 @@ packages: jsbn@1.1.0: resolution: {integrity: sha512-4bYVV3aAMtDTTu4+xsDYa6sy9GyJ69/amsu9sYF2zqjiEoZA5xJi3BrfX3uY+/IekIu7MwdObdbDWpoZdBv3/A==} - jsesc@0.5.0: - resolution: {integrity: sha512-uZz5UnB7u4T9LvwmFqXii7pZSouaRPorGs5who1Ip7VO0wxanFvBL7GkM6dTHlgX+jhBApRetaWpnDabOeTcnA==} - hasBin: true - - jsesc@2.5.2: - resolution: {integrity: sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA==} - engines: {node: '>=4'} + jsesc@3.0.2: + resolution: {integrity: sha512-xKqzzWXDttJuOcawBt4KnKHHIf5oQ/Cxax+0PWFG+DFDgHNAdi+TXECADI+RYiFUMmx8792xsMbbgXj4CwnP4g==} + engines: {node: '>=6'} hasBin: true json-buffer@3.0.1: @@ -5488,16 +5311,6 @@ packages: json-parse-even-better-errors@2.3.1: resolution: {integrity: sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w==} - json-rpc-engine@5.4.0: - resolution: {integrity: sha512-rAffKbPoNDjuRnXkecTjnsE3xLLrb00rEkdgalINhaYVYIxDwWtvYBr9UFbhTvPB1B2qUOLoFd/cV6f4Q7mh7g==} - - json-rpc-engine@6.1.0: - resolution: {integrity: sha512-NEdLrtrq1jUZyfjkr9OCz9EzCNhnRyWtt1PAnvnhwy6e8XETS0Dtc+ZNCO2gvuAoKsIn2+vCSowXTYE4CkgnAQ==} - engines: {node: '>=10.0.0'} - - json-rpc-random-id@1.0.1: - resolution: {integrity: sha512-RJ9YYNCkhVDBuP4zN5BBtYAzEl03yq/jIIsyif0JY9qyJuQQZNeDK7anAPKKlyEtLSj2s8h6hNh2F8zO5q7ScA==} - json-schema-traverse@0.4.1: resolution: {integrity: sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==} @@ -5510,9 +5323,9 @@ packages: json-stable-stringify-without-jsonify@1.0.1: resolution: {integrity: sha512-Bdboy+l7tA3OGW6FjyFHWkP5LuByj1Tk33Ljyq0axyzdk9//JSi2u3fP1QSmd1KNwq6VOKYGlAu87CisVir6Pw==} - json-stable-stringify@1.1.1: - resolution: {integrity: sha512-SU/971Kt5qVQfJpyDveVhQ/vya+5hvrjClFOcr8c0Fq5aODJjMwutrOfCU+eCnVD5gpx1Q3fEqkyom77zH1iIg==} - engines: {node: '>= 0.4'} + json-stream-stringify@3.1.6: + resolution: {integrity: sha512-x7fpwxOkbhFCaJDJ8vb1fBY3DdSa4AlITaz+HHILQJzdPMnHEFjxPwVUi1ALIbcIxDE0PNe/0i7frnY8QnBQog==} + engines: {node: '>=7.10.1'} json-stringify-safe@5.0.1: resolution: {integrity: sha512-ZClg6AaYvamvYEE82d3Iyd3vSSIjQ+odgjaTzRuO3s7toCdFKczob2i0zCh7JE8kWn17yvAWhUVxvqGwUalsRA==} @@ -5526,26 +5339,19 @@ packages: engines: {node: '>=6'} hasBin: true - jsonfile@2.4.0: - resolution: {integrity: sha512-PKllAqbgLgxHaj8TElYymKCAgrASebJrWpTnEkOaTowt23VKXXN0sUeriJ+eh7y6ufb/CC5ap11pz71/cM0hUw==} - jsonfile@4.0.0: resolution: {integrity: sha512-m6F1R3z8jjlf2imQHS2Qez5sjKWQzbuuhuJ/FKYFRZvPE3PuHcSMVZzfsLhGVOkfd20obL5SWEBew5ShlquNxg==} jsonfile@6.1.0: resolution: {integrity: sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ==} - jsonify@0.0.1: - resolution: {integrity: sha512-2/Ki0GcmuqSrgFyelQq9M05y7PS0mEwuIzrf3f1fPqkVDVRvZrPZtVSMHxdgo8Aq0sxAOb/cr2aqqA3LeWHVPg==} + jsonschema@1.4.1: + resolution: {integrity: sha512-S6cATIPVv1z0IlxdN+zUk5EPjkGCdnhN4wVSBlvoUO1tOLJootbo9CquNJmbIh4yikWHiUedhRYrNPn1arpEmQ==} jsprim@1.4.2: resolution: {integrity: sha512-P2bSOMAc/ciLz6DzgjVlGJP9+BrJWu5UDGK70C2iweC5QBIeFf0ZXRvGjEj2uYgrY2MkAAhsSWHDWlFtEroZWw==} engines: {node: '>=0.6.0'} - jsprim@2.0.2: - resolution: {integrity: sha512-gqXddjPqQ6G40VdnI6T6yObEC+pDNvyP95wdQhkWkg7crHH3km5qP1FsOXEkzEQwnz6gz5qGTn1c2Y52wP3OyQ==} - engines: {'0': node >=0.6.0} - jwt-decode@4.0.0: resolution: {integrity: sha512-+KJGIyHgkGuIq3IEBNftfhW/LfWhXUIY6OmyVWjliu5KH1y0fw7VQ8YndE2O4qZdMSd9SqbnC8GOcZEy0Om7sA==} engines: {node: '>=18'} @@ -5553,10 +5359,6 @@ packages: keccak256@1.0.6: resolution: {integrity: sha512-8GLiM01PkdJVGUhR1e6M/AvWnSqYS0HaERI+K/QtStGDGlSTx2B1zTqZk4Zlqu5TxHJNTxWAdP9Y+WI50OApUw==} - keccak@3.0.2: - resolution: {integrity: sha512-PyKKjkH53wDMLGrvmRGSNWgmSxZOUqbnXwKL9tmgbFYA1iAYqW21kfR7mZXV0MlESiefxQQE9X9fTa3X+2MPDQ==} - engines: {node: '>=10.0.0'} - keccak@3.0.4: resolution: {integrity: sha512-3vKuW0jV8J3XNTzvfyicFR5qvxrSAGl7KIhvgOu5cmWwM7tZRj3fMbj/pfIf4be7aznbc+prBWGjywox/g2Y6Q==} engines: {node: '>=10.0.0'} @@ -5579,26 +5381,14 @@ packages: resolution: {integrity: sha512-dcS1ul+9tmeD95T+x28/ehLgd9mENa3LsvDTtzm3vyBEO7RPptvAD+t44WVXaUjTBRcrpFeFlC8WCruUR456hw==} engines: {node: '>=0.10.0'} - klaw@1.3.1: - resolution: {integrity: sha512-TED5xi9gGQjGpNnvRWknrwAB1eL5GciPfVFOt3Vk1OJCVDQbzuSfrF3hkUQKlsgKrG1F+0t5W0m+Fje1jIt8rw==} - - kleur@4.1.5: - resolution: {integrity: sha512-o+NO+8WrRiQEE4/7nwRJhN1HWpVmJm511pBHUxPLtp0BUISzlBplORYSmTclCnJvQq2tKu/sgl3xVpkc7ZWuQQ==} + kleur@3.0.3: + resolution: {integrity: sha512-eTIzlVOSUR+JxdDFepEYcBMtZ9Qqdef+rnzWdRZuMbOywu5tO2w2N7rqjoANZ5k9vywhL6Br1VRjUIgTQx4E8w==} engines: {node: '>=6'} - level-codec@7.0.1: - resolution: {integrity: sha512-Ua/R9B9r3RasXdRmOtd+t9TCOEIIlts+TN/7XTT2unhDaL6sJn83S3rUyljbr6lVtw49N3/yA0HHjpV6Kzb2aQ==} - level-concat-iterator@3.1.0: resolution: {integrity: sha512-BWRCMHBxbIqPxJ8vHOvKUsaO0v1sLYZtjN3K2iZJsRBYtp+ONsY6Jfi6hy9K3+zolgQRryhIn2NRZjZnWJ9NmQ==} engines: {node: '>=10'} - level-errors@1.0.5: - resolution: {integrity: sha512-/cLUpQduF6bNrWuAC4pwtUKA5t669pCsCi2XbmojG2tFeOr9j6ShtdDCtFFQO1DRt+EVZhx9gPzP9G2bUaG4ig==} - - level-iterator-stream@1.3.1: - resolution: {integrity: sha512-1qua0RHNtr4nrZBgYlpV0qHHeHpcRRWTxEZJ8xsemoHAXNL5tbooh4tPEEqIqsbWCAJBmUmkwYK/sW5OrFjWWw==} - level-supports@2.1.0: resolution: {integrity: sha512-E486g1NCjW5cF78KGPrMDRBYzPuueMZ6VBXHT6gC7A8UYWGiM14fGgp+s/L1oFfDWSPV/+SFkYCmZ0SiESkRKA==} engines: {node: '>=10'} @@ -5611,15 +5401,9 @@ packages: resolution: {integrity: sha512-t7bFwFtsQeD8cl8NIoQ2iwxA0CL/9IFw7/9gAjOonH0PWTTiRfY7Hq+Ejbsxh86tXobDQ6IOiddjNYIfOBs06w==} engines: {node: '>=12'} - level-ws@0.0.0: - resolution: {integrity: sha512-XUTaO/+Db51Uiyp/t7fCMGVFOTdtLS/NIACxE/GHsij15mKzxksZifKVjlXDF41JMUP/oM1Oc4YNGdKnc3dVLw==} - - leveldown@6.1.0: - resolution: {integrity: sha512-8C7oJDT44JXxh04aSSsfcMI8YiaGRhOFI9/pMEL7nWJLVsWajDPTRxsSHTM2WcTVY5nXM+SuRHzPPi0GbnDX+w==} - engines: {node: '>=10.12.0'} - - levelup@1.3.9: - resolution: {integrity: sha512-VVGHfKIlmw8w1XqpGOAGwq6sZm2WwWLmlDcULkKWQXEA5EopA8OBNJ2Ck2v6bdk8HeEZSbCSEgzXadyQFm76sQ==} + levn@0.3.0: + resolution: {integrity: sha512-0OO4y2iOHix2W6ujICbKIaEQXvFQHue65vUG3pb5EUomzPI90z9hsA1VsO/dbIIpC53J8gxM9Q4Oho0jrCM/yA==} + engines: {node: '>= 0.8.0'} levn@0.4.1: resolution: {integrity: sha512-+bT2uH4E5LGE7h/n3evcS/sQlJXCpIp6ym8OWJ5eV6+67Dsql/LaaT7qJBAt2rzfoa/5QBGBhxDix1dMt2kQKQ==} @@ -5632,10 +5416,6 @@ packages: resolution: {integrity: sha512-Gnxj3ev3mB5TkVBGad0JM6dmLiQL+o0t23JPBZ9sd+yvSLk05mFoqKBw5N8gbbkU4TNXyqCgIrl/VM17OgUIgQ==} engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} - load-yaml-file@0.2.0: - resolution: {integrity: sha512-OfCBkGEw4nN6JLtgRidPX6QxjBQGQf72q3si2uvqyFEMbycSFFHwAZeXx6cJgFM9wmLrf9zBwCP3Ivqa+LLZPw==} - engines: {node: '>=6'} - loader-runner@4.3.0: resolution: {integrity: sha512-3R/1M+yS3j5ou80Me59j7F9IMs4PXs3VqRrm0TU3AbKPxlmpoY1TNscJV/oGJXo8qCatFGTfDbY6W6ipGOYXfg==} engines: {node: '>=6.11.5'} @@ -5663,18 +5443,27 @@ packages: lodash.camelcase@4.3.0: resolution: {integrity: sha512-TwuEnCnxbc3rAvhf/LbG7tJUDzhqXyFnv3dtzLOPgCG/hODL7WFnsbwktkD7yUV0RrreP/l1PALq/YSg6VvjlA==} + lodash.clonedeep@4.5.0: + resolution: {integrity: sha512-H5ZhCF25riFd9uB5UCkVKo61m3S/xZk1x4wA6yp/L3RFP6Z/eHH1ymQcGLo7J3GMPfm0V/7m1tryHuGVxpqEBQ==} + lodash.debounce@4.0.8: resolution: {integrity: sha512-FT1yDzDYEoYWhnSGnpE/4Kj1fLZkDFyqRb7fNt6FdYOSxlUWAtp42Eh6Wb0rGIv/m9Bgo7x4GhQbm5Ys4SG5ow==} lodash.flattendeep@4.4.0: resolution: {integrity: sha512-uHaJFihxmJcEX3kT4I23ABqKKalJ/zDrDg0lsFtc1h+3uw49SIJ5beyhx5ExVRti3AvKoOJngIj7xz3oylPdWQ==} + lodash.isequal@4.5.0: + resolution: {integrity: sha512-pDo3lu8Jhfjqls6GkMgpahsF9kCyayhgykjyLMNFTKWrpVdAQtYyB4muAMWozBB4ig/dtWAmsMxLEI8wuz+DYQ==} + lodash.merge@4.6.2: resolution: {integrity: sha512-0KpjqXRVvrYyCsX1swR/XTK0va6VQkQM6MNo7PqW77ByjAhoARA8EfrP1N4+KlKj8YS0ZUCtRT/YUuhyYDujIQ==} lodash.startcase@4.4.0: resolution: {integrity: sha512-+WKqsK294HMSc2jEbNgpHpd0JfIBhp7rEV4aqXWqFr6AlXov+SlcgB1Fv01y2kGe3Gc8nMW7VA0SrGuSkRfIEg==} + lodash.truncate@4.4.2: + resolution: {integrity: sha512-jttmRe7bRse52OsWIMDLaXxWqRAmtIUccAQ3garviCqJjafXOfNMO0yMfNpdD6zbGaTU0P5Nz7e7gAT6cKmJRw==} + lodash@4.17.21: resolution: {integrity: sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==} @@ -5682,8 +5471,8 @@ packages: resolution: {integrity: sha512-8XPvpAA8uyhfteu8pIvQxpJZ7SYYdpUivZpGy6sFsBuKRY/7rQGavedeB8aK+Zkyq6upMFVL/9AW6vOYzfRyLg==} engines: {node: '>=10'} - loglevel@1.9.1: - resolution: {integrity: sha512-hP3I3kCrDIMuRwAwHltphhDM1r8i55H33GgqjXbrisuJhF4kRhW1dNuxsRklp4bXl8DSdLaNLuiL4A/LWRfxvg==} + loglevel@1.9.2: + resolution: {integrity: sha512-HgMmCqIJSAKqo68l0rS2AanEWfkxaZ5wNiEFb5ggm08lDs9Xl2KxBlX3PTcaD2chBM1gXAYf491/M2Rv8Jwayg==} engines: {node: '>= 0.6.0'} loupe@2.3.7: @@ -5700,9 +5489,9 @@ packages: resolution: {integrity: sha512-ozCC6gdQ+glXOQsveKD0YsDy8DSQFjDTz4zyzEHNV5+JP5D62LmfDZ6o1cycFx9ouG940M5dE8C8CTewdj2YWQ==} engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} - lru-cache@10.2.0: - resolution: {integrity: sha512-2bIM8x+VAf6JT4bKAljS1qUWgMsqZRPGJS6FSahIMPVvctcNhyVp7AJu7quxOW9jwkryBReKZY5tY5JYv2n/7Q==} - engines: {node: 14 || >=16.14} + lru-cache@11.0.1: + resolution: {integrity: sha512-CgeuL5uom6j/ZVrg7G/+1IXqRY8JXX4Hghfy5YE0EhoYQWvndP1kufu58cmZLNIDKnRhZrXfdS9urVWx98AipQ==} + engines: {node: 20 || >=22} lru-cache@4.1.5: resolution: {integrity: sha512-sWZlbEP2OsHNkXrMl5GYk/jKk70MBng6UU4YI/qGDYbgf6YbP4EvmqISbXCoJiRKs+1bSpFHVgQxvJ17F2li5g==} @@ -5710,10 +5499,6 @@ packages: lru-cache@5.1.1: resolution: {integrity: sha512-KpNARQA3Iwv+jTA0utUVVbrh+Jlrr1Fv0e56GGzAFOXN7dk/FviaDW8LHmK52DlcH4WP2n6gI8vN1aesBFgo9w==} - lru-cache@6.0.0: - resolution: {integrity: sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==} - engines: {node: '>=10'} - lru-cache@7.18.3: resolution: {integrity: sha512-jumlc0BIUrS3qJGgIkWZsyfAM7NCWiBcCDhnd+3NNM5KbBmLTgHVfWBcg6W+rLUsIpzpERPsvwUP7CckAQSOoA==} engines: {node: '>=12'} @@ -5721,15 +5506,11 @@ packages: lru_map@0.3.3: resolution: {integrity: sha512-Pn9cox5CsMYngeDbmChANltQl+5pi6XmTrraMSzhPmMBbmgcxmqWry0U3PGapCU1yB4/LqCcom7qhHZiF/jGfQ==} - ltgt@2.2.1: - resolution: {integrity: sha512-AI2r85+4MquTw9ZYqabu4nMwy9Oftlfa/e/52t9IjtfG+mGBbTNdAoZ3RQKLHR6r0wQnwZnPIEh/Ya6XTWAKNA==} - magic-string@0.25.9: resolution: {integrity: sha512-RmF0AsMzgt25qzqqLc1+MbHmhdx0ojF2Fvs4XnOqz2ZOBXzzkEwc/dJQZCYHAn7v1jbVOjAZfK8msRn4BxO4VQ==} - magic-string@0.30.7: - resolution: {integrity: sha512-8vBuFF/I/+OSLRmdf2wwFCJCz+nSn0m6DPvGH1fS/KiQoSaR+sETbov0eIk9KhEKy8CYqIkIAnbohxT/4H0kuA==} - engines: {node: '>=12'} + magic-string@0.30.12: + resolution: {integrity: sha512-Ea8I3sQMVXr8JhN4z+H/d8zwo+tYDgHE9+5G4Wnrwhs0gaK9fXTKx0Tw5Xwsd/bCPTTZNRAdpyzvoeORe9LYpw==} make-dir@3.1.0: resolution: {integrity: sha512-g3FeP20LNwhALb/6Cz6Dd4F2ngze0jz7tbzrD2wAV+o9FeNHe4rL+yK2md0J/fiSf1sa1ADhXqi5+oVwOM/eGw==} @@ -5746,18 +5527,13 @@ packages: resolution: {integrity: sha512-8y/eV9QQZCiyn1SprXSrCmqJN0yNRATe+PO8ztwqrvrbdRLA3eYJF0yaR0YayLWkMbsQSKWS9N2gPcGEc4UsZg==} engines: {node: '>=0.10.0'} - map-obj@1.0.1: - resolution: {integrity: sha512-7N/q3lyZ+LVCp7PzuxrJr4KMbBE2hW7BT7YNia330OFxIf4d3r5zVpicP2650l7CPN6RM9zOJRl3NGpqSiw3Eg==} - engines: {node: '>=0.10.0'} - - map-obj@4.3.0: - resolution: {integrity: sha512-hdN1wVrZbb29eBGiGjJbeP8JbKjq1urkHJ/LIP/NY48MZ1QVXUsQBV1G1zvYFHn1XE06cwjBsOI2K3Ulnj1YXQ==} - engines: {node: '>=8'} - map-visit@1.0.0: resolution: {integrity: sha512-4y7uGv8bd2WdM9vpQsiQNo41Ln1NvhvDRuVt0k2JZQ+ezN2uaQes7lZeZ+QQUHOLQAtDaBJ+7wCbi+ab/KFs+w==} engines: {node: '>=0.10.0'} + markdown-table@1.1.3: + resolution: {integrity: sha512-1RUZVgQlpJSPWYbFSpmudq5nHY1doEIv89gBtF0s4gW1GF2XorxcA/70M5vq7rLv0a6mhOUccRsqkwhwLCIQ2Q==} + matcher@5.0.0: resolution: {integrity: sha512-s2EMBOWtXFc8dgqvoAzKJXxNHibcdJMV0gwqKUaw9E2JBJuGUK7DrNKrA6g/i+v72TT16+6sVm5mS3thaMLQUw==} engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} @@ -5773,9 +5549,6 @@ packages: resolution: {integrity: sha512-dq+qelQ9akHpcOl/gUVRTxVIOkAJ1wR3QAvb4RsVjS8oVoFjDGTc679wJYmUmknUF5HwMLOgb5O+a3KxfWapPQ==} engines: {node: '>= 0.6'} - memdown@1.4.1: - resolution: {integrity: sha512-iVrGHZB8i4OQfM155xx8akvG9FIj+ht14DX5CQkCTG4EHzZ3d3sgckIf/Lm9ivZalEsFuEVnWv2B2WZvbrro2w==} - memoize@10.0.0: resolution: {integrity: sha512-H6cBLgsi6vMWOcCpvVCdFFnl3kerEXbrYh9q+lY6VXvQSmM6CkmV08VOwT+WE2tzIEqRPFfAq3fm4v/UIW6mSA==} engines: {node: '>=18'} @@ -5787,16 +5560,8 @@ packages: resolution: {integrity: sha512-S3UwM3yj5mtUSEfP41UZmt/0SCoVYUcU1rkXv+BQ5Ig8ndL4sPoJNBUJERafdPb5jjHJGuMgytgKvKIf58XNBw==} engines: {node: '>= 0.10.0'} - meow@6.1.1: - resolution: {integrity: sha512-3YffViIt2QWgTy6Pale5QpopX/IvU3LPL03jOTqp6pGj3VjesdO/U8CuHMKpnQr4shCNCM5fd5XFFvIIl6JBHg==} - engines: {node: '>=8'} - - meow@7.1.1: - resolution: {integrity: sha512-GWHvA5QOcS412WCo8vwKDlTelGLsCGBVevQB5Kva961rmNfun0PCbv5+xta2kUMFJyR8/oWnn7ddeKdosbAPbA==} - engines: {node: '>=10'} - - merge-descriptors@1.0.1: - resolution: {integrity: sha512-cCi6g3/Zr1iqQi6ySbseM1Xvooa98N0w31jzUYrXPX2xqObmFGHJ0tQ5u74H3mVh7wLouTseZyYIq39g8cNp1w==} + merge-descriptors@1.0.3: + resolution: {integrity: sha512-gaNvAS7TZ897/rVaZ0nMtAyxNyi/pdbjbAwUpFQpN70GqnVfOiXpeUUMKRBmzXaSQ8DdTX4/0ms62r2K+hE6mQ==} merge-stream@2.0.0: resolution: {integrity: sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==} @@ -5805,9 +5570,6 @@ packages: resolution: {integrity: sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg==} engines: {node: '>= 8'} - merkle-patricia-tree@2.3.2: - resolution: {integrity: sha512-81PW5m8oz/pz3GvsAwbauj7Y00rqm81Tzad77tHBwU7pIAtN+TJnMSOJhxBKflSVYhptMMb9RskhqHqrSm1V+g==} - methods@1.1.2: resolution: {integrity: sha512-iclAHeNqNm68zFtnZ0e+1L2yUIdvzNoauKU4WBA3VvH/vPFieF7qfRlwUZU+DA9P9bPXIS90ulxoUoCH23sV2w==} engines: {node: '>= 0.6'} @@ -5819,14 +5581,18 @@ packages: resolution: {integrity: sha512-MWikgl9n9M3w+bpsY3He8L+w9eF9338xRl8IAO5viDizwSzziFEyUzo2xrrloB64ADbTf8uA8vRqqttDTOmccg==} engines: {node: '>=0.10.0'} - micromatch@4.0.5: - resolution: {integrity: sha512-DMy+ERcEW2q8Z2Po+WNXuw3c5YaUSFjAO5GsJqfEl7UjvtIuFKO6ZrKvcItdy98dwFI2N1tg3zNIdKaQT+aNdA==} + micromatch@4.0.8: + resolution: {integrity: sha512-PXwfBhYu0hBCPw8Dn0E+WDYb7af3dSLVWKi3HGv84IdF4TyFoC0ysxFd0Goxw7nSv4T/PzEJQxsYsEiFCKo2BA==} engines: {node: '>=8.6'} mime-db@1.52.0: resolution: {integrity: sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==} engines: {node: '>= 0.6'} + mime-db@1.53.0: + resolution: {integrity: sha512-oHlN/w+3MQ3rba9rqFr6V/ypF10LSkdwUysQL7GkXoTgIWeV+tcXGA852TBxH+gsh8UWoyhR1hKcoMJTuWflpg==} + engines: {node: '>= 0.6'} + mime-types@2.1.35: resolution: {integrity: sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==} engines: {node: '>= 0.6'} @@ -5841,8 +5607,8 @@ packages: engines: {node: '>=4.0.0'} hasBin: true - mimic-function@5.0.0: - resolution: {integrity: sha512-RBfQ+9X9DpXdEoK7Bu+KeEU6vFhumEIiXKWECPzRBmDserEq4uR2b/VCm0LwpMSosoq2k+Zuxj/GzOr0Fn6h/g==} + mimic-function@5.0.1: + resolution: {integrity: sha512-VP79XUPxV2CigYP3jWwAUFSku2aKqBH7uTAapFWCBqutsbmDo96KY5o8uh6U+/YSIn5OxJnXp73beVkpqMIGhA==} engines: {node: '>=18'} mimic-response@1.0.1: @@ -5856,31 +5622,27 @@ packages: min-document@2.19.0: resolution: {integrity: sha512-9Wy1B3m3f66bPPmU5hdA4DR4PB2OfDU/+GS3yAB7IQozE3tqXaVv2zOjgla7MEGSRv95+ILmOuvhLkOK6wJtCQ==} - min-indent@1.0.1: - resolution: {integrity: sha512-I9jwMn07Sy/IwOj3zVkVik2JTvgpaykDZEigL6Rx6N9LbMywwUSMtxET+7lVoDLLd3O3IXwJwvuuns8UB/HeAg==} - engines: {node: '>=4'} - minimalistic-assert@1.0.1: resolution: {integrity: sha512-UtJcAD4yEaGtjPezWuO9wC4nwUnVH/8/Im3yEHQP4b67cXlD/Qr9hdITCU1xDbSEXg2XKNaP8jsReV7vQd00/A==} minimalistic-crypto-utils@1.0.1: resolution: {integrity: sha512-JIYlbt6g8i5jKfJ3xz7rF0LXmv2TkDxBLUkiBeZ7bAx4GnnNMr8xFpGnOxn6GhTEHx3SjRrZEoU+j04prX1ktg==} + minimatch@10.0.1: + resolution: {integrity: sha512-ethXTt3SGGR+95gudmqJ1eNhRO7eGEGIgYA9vnPatK4/etz2MEVDno5GMCibdMTuBMyElzIlgxMna3K94XDIDQ==} + engines: {node: 20 || >=22} + minimatch@3.1.2: resolution: {integrity: sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==} - minimatch@5.0.1: - resolution: {integrity: sha512-nLDxIFRyhDblz3qMuq+SoRZED4+miJ/G+tdDrjkkkRnjAsBexeGpgjLEQ0blJy7rHhR2b93rhQY4SvyWu9v03g==} + minimatch@5.1.6: + resolution: {integrity: sha512-lKwV/1brpG6mBUFHtb7NUmtABCb2WZZmm2wNiOA5hAb8VdCS4B3dtMWyvcoViccwAW/COERjXLt0zP1zXUN26g==} engines: {node: '>=10'} - minimatch@9.0.3: - resolution: {integrity: sha512-RHiac9mvaRw0x3AYRgDC1CxAP7HTcNrrECeA8YYJeWnpo+2Q5CegtZjaotWTWxDG3UeGA1coE05iH1mPjT/2mg==} + minimatch@9.0.5: + resolution: {integrity: sha512-G6T0ZX48xgozx7587koeX9Ys2NYy6Gmv//P89sEte9V9whIapMNF4idKxnW2QtCcLiTWlb/wfCabAtAFWhhBow==} engines: {node: '>=16 || 14 >=14.17'} - minimist-options@4.1.0: - resolution: {integrity: sha512-Q4r8ghd80yhO/0j1O3B2BjweX3fiHg9cdOwjJd2J76Q135c+NDxGCqdYKQ1SKBuFfgWbAUzBfvYjPUEeNgqN1A==} - engines: {node: '>= 6'} - minimist@1.2.8: resolution: {integrity: sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==} @@ -5895,8 +5657,8 @@ packages: resolution: {integrity: sha512-3FnjYuehv9k6ovOEbyOswadCDPX1piCfhV8ncmYtHOjuPwylVWsghTLo7rabjC3Rx5xD4HDx8Wm1xnMF7S5qFQ==} engines: {node: '>=8'} - minipass@7.0.4: - resolution: {integrity: sha512-jYofLM5Dam9279rdkWzqHozUo4ybjdZmCsDHePy5V/PbBcVMiSZR97gmAy45aqi8CK1lG2ECd356FU86avfwUQ==} + minipass@7.1.2: + resolution: {integrity: sha512-qOOzS1cBTWYF4BH8fVePDBOO9iptMnGUEZwNc/cMWnTV2nVLZ7VoNWEPHkYczZA0pdoA7dl6e7FL659nX9S2aw==} engines: {node: '>=16 || 14 >=14.17'} minizlib@1.3.3: @@ -5913,13 +5675,6 @@ packages: resolution: {integrity: sha512-WRoDn//mXBiJ1H40rqa3vH0toePwSsGb45iInWlTySa+Uu4k3tYUSxa2v1KqAiLtvlrSzaExqS1gtk96A9zvEA==} engines: {node: '>=0.10.0'} - mixme@0.5.10: - resolution: {integrity: sha512-5H76ANWinB1H3twpJ6JY8uvAtpmFvHNArpilJAjXRKXSDDLPIMoZArw5SH0q9z+lLs8IrMw7Q2VWpWimFKFT1Q==} - engines: {node: '>= 8.0.0'} - - mkdirp-classic@0.5.3: - resolution: {integrity: sha512-gKLcREMhtuZRwRAfqP3RFW+TK4JqApVBtOIftVgjuABpAtpxhPGaDcfvbhNvD0B8iD1oUr/txX35NjcaY6Ns/A==} - mkdirp-promise@5.0.1: resolution: {integrity: sha512-Hepn5kb1lJPtVW84RFT40YG1OddBNTOVUZR2bzQUHc+Z03en8/3uX0+060JDhcEzyO08HmipsN9DcnFMxhIL9w==} engines: {node: '>=4'} @@ -5942,16 +5697,16 @@ packages: mnemonist@0.38.5: resolution: {integrity: sha512-bZTFT5rrPKtPJxj8KSV0WkPyNxl72vQepqqVUAW2ARUpUSF2qXMB6jZj7hW5/k7C1rtpzqbD/IIbJwLXUjCHeg==} - mocha@10.3.0: - resolution: {integrity: sha512-uF2XJs+7xSLsrmIvn37i/wnc91nw7XjOQB8ccyx5aEgdnohr7n+rEiZP23WkCYHjilR6+EboEnbq/ZQDz4LSbg==} + mocha@10.7.3: + resolution: {integrity: sha512-uQWxAu44wwiACGqjbPYmjo7Lg8sFrS3dQe7PP2FQI+woptP4vZXSMcfMyFL/e1yFEeEpV4RtyTpZROOKmxis+A==} engines: {node: '>= 14.0.0'} hasBin: true mock-fs@4.14.0: resolution: {integrity: sha512-qYvlv/exQ4+svI3UOvPUpLDF0OMX5euvUH0Ny4N5QyRyhNdgAgUrVH3iUINSzEPLvx0kbo/Bp28GJKIqvE7URw==} - mockttp@3.10.1: - resolution: {integrity: sha512-D+8uEDJr/DDEzQ6Weg2w1hw+vA/+FzfltOUpqpjCxbaqRrDvQrfOkkYgtx4jlp7b3tfxJBMTO4MwuBhhfY93WQ==} + mockttp@3.15.3: + resolution: {integrity: sha512-UW8IkPttmGZuJf8A5ahMqB8c8MngSgtCAxEbWaCqvZqnINfoZackkSWO/sU25iyvH+UBZRBRTdkm4ItJriVBmw==} engines: {node: '>=14.14.0'} hasBin: true @@ -5959,12 +5714,13 @@ packages: resolution: {integrity: sha512-0yuvsqSCv8LbaOKhnsQ/T5JhyFlCYLPXK3U2sgV10zoKQwzs/MyfuQUOZQ1V/6OCOJsK/TRgNVrPuPDqtdMFtA==} engines: {node: '>=10'} + mri@1.2.0: + resolution: {integrity: sha512-tzzskb3bG8LvYGFF/mDTpq3jpI6Q9wc3LEmBaghu+DdCssd1FakN7Bc0hVNmEyGq1bq3RgfkCb3cmQLpNPOroA==} + engines: {node: '>=4'} + ms@2.0.0: resolution: {integrity: sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==} - ms@2.1.2: - resolution: {integrity: sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==} - ms@2.1.3: resolution: {integrity: sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==} @@ -5994,8 +5750,8 @@ packages: multihashes@0.4.21: resolution: {integrity: sha512-uVSvmeCWf36pU2nB4/1kzYZjsXD9vofZKpgudqkceYY5g2aZZXJ5r9lxuzoRLl1OAp28XljXsEJ/X/85ZsKmKw==} - nan@2.18.0: - resolution: {integrity: sha512-W7tfG7vMOGtD30sHoZSSc/JVYiyDPEyQVso/Zz+/uQd0B0L46gtC+pHha5FFMRpil6fm/AoEcRWyOVi4+E/f8w==} + nan@2.22.0: + resolution: {integrity: sha512-nbajikzWTMwsW+eSsNm3QwlOs7het9gGJU5dDZzRTQGk03vyBOauxgI4VakDzE0PtsGTmXPsXTbbjVhRwR5mpw==} nano-json-stream-parser@0.1.2: resolution: {integrity: sha512-9MqxMH/BSJC7dnLsEMPyfN5Dvoo49IsPFYMcHw3Bcfc2kN0lpHRBSzlMSVx4HGyJ7s9B31CyBTVehWJoQ8Ctew==} @@ -6004,15 +5760,17 @@ packages: resolution: {integrity: sha512-fpoe2T0RbHwBTBUOftAfBPaDEi06ufaUai0mE6Yn1kacc3SnTErfb/h+X94VXzI64rKFHYImXSvdwGGCmwOqCA==} engines: {node: '>=0.10.0'} - napi-macros@2.0.0: - resolution: {integrity: sha512-A0xLykHtARfueITVDernsAWdtIMbOJgKgcluwENp3AlsKN/PloyO10HtmoqnFAQAcxPkgZN7wdfPfEd0zNGxbg==} - native-duplexpair@1.0.0: resolution: {integrity: sha512-E7QQoM+3jvNtlmyfqRZ0/U75VFgCls+fSkbml2MpgWkWyz3ox8Y58gNhfuziuQYGNNQAbFZJQck55LHCnCK6CA==} natural-compare@1.4.0: resolution: {integrity: sha512-OWND8ei3VtNC9h7V60qff3SVobHr996CTwgxubgyQYEpg290h9J0buyECNNJexkFm5sOajh5G116RYA1c8ZMSw==} + ndjson@2.0.0: + resolution: {integrity: sha512-nGl7LRGrzugTtaFcJMhLbpzJM6XdivmbkdlaGcrk/LXg2KL/YBC6z1g70xh0/al+oFuVFP8N8kiWRucmeEH/qQ==} + engines: {node: '>=10'} + hasBin: true + negotiator@0.6.3: resolution: {integrity: sha512-+EUsqGPLsM+j/zdChZjsnX51g4XrHFOIXwfnCVPGlQk/k5giakcKsuxCObBRu6DSm9opw/O6slWbJdghQM4bBg==} engines: {node: '>= 0.6'} @@ -6036,6 +5794,12 @@ packages: node-addon-api@2.0.2: resolution: {integrity: sha512-Ntyt4AIXyaLIuMHF6IOoTakB3K+RWxwtsHNRxllEoA6vPwP9o4866g6YWDLUdnucilZhmkxiHwHr11gAENw+QA==} + node-addon-api@5.1.0: + resolution: {integrity: sha512-eh0GgfEkpnoWDq+VY8OyvYhFEzBk6jIYbRKdIlyTiAXIVJ8PyBaKb0rp7oDtoddbdoHWhq8wwr+XZ81F1rpNdA==} + + node-emoji@1.11.0: + resolution: {integrity: sha512-wo2DpQkQp7Sjm2A0cq+sN7EHKO6Sl0ctXeBdFZrL9T9+UywORbufTcTZxom8YqpLQt/FqNMUkOpkZrJVYSKD3A==} + node-fetch@2.7.0: resolution: {integrity: sha512-c4FRfUm/dbcWZ7U+1Wq0AwCyFL+3nt2bEw05wfxSz+DWpWsitgmSgYmy2dQdWyKC1694ELPqMs/YzUSNozLt8A==} engines: {node: 4.x || >=6.0.0} @@ -6049,33 +5813,30 @@ packages: resolution: {integrity: sha512-dPEtOeMvF9VMcYV/1Wb8CPoVAXtp6MKMlcbAt4ddqmGqUJ6fQZFXkNZNkNlfevtNkGtaSoXf/vNNNSvgrdXwtA==} engines: {node: '>= 6.13.0'} - node-gyp-build@4.4.0: - resolution: {integrity: sha512-amJnQCcgtRVw9SvoebO3BKGESClrfXGCUTX9hSn1OuGQTQBOZmVd0Z0OlecpuRksKvbsUqALE8jls/ErClAPuQ==} - hasBin: true - - node-gyp-build@4.8.0: - resolution: {integrity: sha512-u6fs2AEUljNho3EYTJNBfImO5QTo/J/1Etd+NVdCj7qWKUSN/bSLkZwhDv7I+w/MSC6qJ4cknepkAYykDdK8og==} + node-gyp-build@4.8.2: + resolution: {integrity: sha512-IRUxE4BVsHWXkV/SFOut4qTlagw2aM8T5/vnTsmrHJvVoKueJHRc/JaFND7QDDc61kLYUJ6qlZM3sqTSyx2dTw==} hasBin: true node-preload@0.2.1: resolution: {integrity: sha512-RM5oyBy45cLEoHqCeh+MNuFAxO0vTFBLskvQbOKnEE7YTTSN4tbN8QWDIPQ6L+WvKsB/qLEGpYe2ZZ9d4W9OIQ==} engines: {node: '>=8'} - node-releases@2.0.14: - resolution: {integrity: sha512-y10wOWt8yZpqXmOgRo77WaHEmhYQYGNA6y421PKsKYWEK8aW+cqAphborZDhqfyKrbZEN92CN1X2KbafY2s7Yw==} + node-releases@2.0.18: + resolution: {integrity: sha512-d9VeXT4SJ7ZeOqGX6R5EM022wpL+eWPooLI+5UpWn2jCT1aosUQEhQP214x33Wkwx3JQMvIm+tIoVOdodFS40g==} nofilter@3.1.0: resolution: {integrity: sha512-l2NNj07e9afPnhAhvgVrCD/oy2Ai1yfLpuo3EpiO1jFTsB4sFz6oIfAfSZyQzVpkZQ9xS8ZS5g1jCBgq4Hwo0g==} engines: {node: '>=12.19'} + nopt@3.0.6: + resolution: {integrity: sha512-4GUt3kSEYmk4ITxzB/b9vaIDfUVWN/Ml1Fwl11IlnIG2iaJ9O6WXZ9SrYM9NLI8OCBieN2Y8SWC2oJV0RQ7qYg==} + hasBin: true + nopt@5.0.0: resolution: {integrity: sha512-Tbj67rffqceeLpcRXrT7vKAN8CwfPeIBgM7E6iBkmKLV7bEMwpGgYLGv0jACUsECaa/vuxP0IjEont6umdMgtQ==} engines: {node: '>=6'} hasBin: true - normalize-package-data@2.5.0: - resolution: {integrity: sha512-/5CMN3T0R4XTj4DcGaexo+roZSdSFW/0AOOTROrjxzCG1wrWXEsGbRKevjlIL+ZDE4sZlJr5ED4YW0yqmkK+eA==} - normalize-path@2.1.1: resolution: {integrity: sha512-3pKJwH184Xo/lnH6oyP1q2pMd7HcypqqmRs91/6/i2CGtWwIKGCkOOMTm/zXbgTEWHw1uNpNi/igc3ePOYHb6w==} engines: {node: '>=0.10.0'} @@ -6105,6 +5866,7 @@ packages: npmlog@5.0.1: resolution: {integrity: sha512-AqZtDUWOMKs1G/8lwylVjrdYgqA4d9nu8hc+0gzRxlDb1I10+FHBGMXs6aiQHFdCUUlqH99MUMuLfzWDNDtfxw==} + deprecated: This package is no longer supported. nth-check@2.1.1: resolution: {integrity: sha512-lqjrjmaOoAnWfMmBPL+XNnynZh2+swxiX3WUE0s4yEHI6m+AwrK2UZOimIRl3X/4QctVqS8AiZjFqyOGrMXb/w==} @@ -6118,6 +5880,11 @@ packages: engines: {node: '>=8.9'} hasBin: true + nyc@17.1.0: + resolution: {integrity: sha512-U42vQ4czpKa0QdI1hu950XuNhYqgoM+ZF1HT+VuUHL9hPfDPVvNQyltmMqdE9bUHMVa+8yNbc3QKTj8zQhlVxQ==} + engines: {node: '>=18'} + hasBin: true + oauth-sign@0.9.0: resolution: {integrity: sha512-fexhUFFPTGV8ybAtSIGbV6gOkSv8UtRbDBnAyLQw4QPKkgNlsH2ByPGtMUqdWkos6YCRmAqViwgZrJc/mRDzZQ==} @@ -6129,15 +5896,13 @@ packages: resolution: {integrity: sha512-79LYn6VAb63zgtmAteVOWo9Vdj71ZVBy3Pbse+VqxDpEP83XuujMrGqHIwAXJ5I/aM0zU7dIyIAhifVTPrNItQ==} engines: {node: '>=0.10.0'} - object-inspect@1.13.1: - resolution: {integrity: sha512-5qoj1RUiKOMsCCNLV1CBiPYE10sziTsnmNxkAI/rZhiD63CF7IqdFGC/XzjWjpSgLf0LxXX3bDFIh0E18f6UhQ==} - - object-is@1.1.5: - resolution: {integrity: sha512-3cyDsyHgtmi7I7DfSSI2LDp6SK2lwvtbg0p0R1e0RvTqF5ceGx+K2dfSjm1bKDMVCFEDAQvy+o8c6a7VujOddw==} + object-inspect@1.13.2: + resolution: {integrity: sha512-IRZSRuzJiynemAXPYtPe5BoI/RESNYR7TYm50MC5Mqbd3Jmw5y790sErYw3V6SryFJD64b74qQQs9wn5Bg/k3g==} engines: {node: '>= 0.4'} - object-keys@0.4.0: - resolution: {integrity: sha512-ncrLw+X55z7bkl5PnUvHwFK9FcGuFYo9gtjws2XtSzL+aZ8tm830P60WJ0dSmFVaSalWieW5MD7kEdnXda9yJw==} + object-is@1.1.6: + resolution: {integrity: sha512-F8cZ+KfGlSGi09lJT7/Nd6KJZ9ygtvYC0/UYYLI9nmQKLMnydpB9yvbv9K1uSkEu7FU9vYPmVwLg328tX+ot3Q==} + engines: {node: '>= 0.4'} object-keys@1.1.1: resolution: {integrity: sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==} @@ -6151,19 +5916,20 @@ packages: resolution: {integrity: sha512-byy+U7gp+FVwmyzKPYhW2h5l3crpmGsxl7X2s8y43IgxvG4g3QZ6CffDtsNQy1WsmZpQbO+ybo0AlW7TY6DcBQ==} engines: {node: '>= 0.4'} - object.fromentries@2.0.7: - resolution: {integrity: sha512-UPbPHML6sL8PI/mOqPwsH4G6iyXcCGzLin8KvEPenOZN5lpCNBZZQ+V62vdjB1mQHrmqGQt5/OJzemUA+KJmEA==} + object.fromentries@2.0.8: + resolution: {integrity: sha512-k6E21FzySsSK5a21KRADBd/NGneRegFO5pLHfdQLpRDETUNJueLXs3WCzyQ3tFRDYgbq3KHGXfTbi2bs8WQ6rQ==} engines: {node: '>= 0.4'} - object.groupby@1.0.2: - resolution: {integrity: sha512-bzBq58S+x+uo0VjurFT0UktpKHOZmv4/xePiOA1nbB9pMqpGK7rUPNgf+1YC+7mE+0HzhTMqNUuCqvKhj6FnBw==} + object.groupby@1.0.3: + resolution: {integrity: sha512-+Lhy3TQTuzXI5hevh8sBGqbmurHbbIjAi0Z4S63nthVLmLxfbj4T54a4CfZrXIrt9iP4mVAPYMo/v99taj3wjQ==} + engines: {node: '>= 0.4'} object.pick@1.3.0: resolution: {integrity: sha512-tqa/UMy/CCoYmj+H5qc07qvSL9dqcs/WZENZ1JbtWBlATP+iVOe778gE6MSijnyCnORzDuX6hU+LA4SZ09YjFQ==} engines: {node: '>=0.10.0'} - object.values@1.1.7: - resolution: {integrity: sha512-aU6xnDFYT3x17e/f0IiiwlGPTy2jzMySGfUB4fq6z7CV8l85CWHDk5ErhyhpfDHhrOMwGFhSQkhMGHaIotA6Ng==} + object.values@1.2.0: + resolution: {integrity: sha512-yBYjY9QX2hnRmZHAjG/f13MzmBzxzYgQhFrke06TTyKY5zSTEqkOeukBzIdVA3j3ulu8Qa3MbVFShV7T2RmGtQ==} engines: {node: '>= 0.4'} obliterator@2.0.4: @@ -6194,10 +5960,17 @@ packages: resolution: {integrity: sha512-PqHpggC9bLV0VeWcdKhkpxY+3JTzetLSqTCWL/z/tFIbI6G8JCjondXklT1JinczLz2Xib62sSp0T/gKT4KksA==} engines: {node: '>=4'} - optionator@0.9.3: - resolution: {integrity: sha512-JjCoypp+jKn1ttEFExxhetCKeJt9zhAgAve5FXHixTvFDW/5aEktX9bufBKLRRMdU7bNtpLfcGu94B3cdEJgjg==} + optionator@0.8.3: + resolution: {integrity: sha512-+IW9pACdk3XWmmTXG8m3upGUJst5XRGzxMRjXzAuJ1XnIFNvfhjjIuYkDvysnPQ7qzqVzLt78BCruntqRhWQbA==} engines: {node: '>= 0.8.0'} + optionator@0.9.4: + resolution: {integrity: sha512-6IpQ7mKUxRcZNLIObR0hz7lxsapSSIYNZJwXPGeF0mTVqGKFIXj1DQcMoT22S3ROcLyY/rz0PWaWZ9ayWmad9g==} + engines: {node: '>= 0.8.0'} + + ordinal@1.0.3: + resolution: {integrity: sha512-cMddMgb2QElm8G7vdaa02jhUNbTSrhsgAGUz1OokD83uJTwSUn+nKoNoKVVaRa08yF6sgfO7Maou1+bgLd9rdQ==} + os-tmpdir@1.0.2: resolution: {integrity: sha512-D2FR03Vir7FIu45XBY20mTb+/ZSWB00sjU9jdQXt83gDrI4Ztz5Fs7/yy74g2N5SVQY4xY1qDr4rNddwYRVX0g==} engines: {node: '>=0.10.0'} @@ -6269,8 +6042,8 @@ packages: resolution: {integrity: sha512-/bjOqmgETBYB5BoEeGVea8dmvHb2m9GLy1E9W43yeyfP6QQCZGFNa+XRceJEuDB6zqr+gKpIAmlLebMpykw/MQ==} engines: {node: '>=10'} - p-map@7.0.1: - resolution: {integrity: sha512-2wnaR0XL/FDOj+TgpDuRb2KTjLnu3Fma6b1ZUwGY7LcqenMcvP/YFpjpbPKY6WVGsbuJZRuoUz8iPrt8ORnAFw==} + p-map@7.0.2: + resolution: {integrity: sha512-z4cYYMMdKHzw4O5UkWJImbZynVIo0lSGTXc7bzB1e/rrDqkgGUNysK/o4bTr+0+xKvvLoTyGqYC4Fgljy9qe1Q==} engines: {node: '>=18'} p-retry@3.0.1: @@ -6285,8 +6058,12 @@ packages: resolution: {integrity: sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==} engines: {node: '>=6'} - pac-proxy-agent@7.0.1: - resolution: {integrity: sha512-ASV8yU4LLKBAjqIPMbrgtaKIvxQri/yh2OpI+S6hVa9JRkUI3Y3NPFbfngDtY7oFtSMD3w31Xns89mDa3Feo5A==} + pac-proxy-agent@7.0.2: + resolution: {integrity: sha512-BFi3vZnO9X5Qt6NRz7ZOaPja3ic0PhlsmCRYLOpN11+mWBCR6XJDqW5RF3j8jm4WGGQZtBA+bTfxYzeKW73eHg==} + engines: {node: '>= 14'} + + pac-proxy-agent@7.1.0: + resolution: {integrity: sha512-Z5FnLVVZSnX7WjBg0mhDtydeRZ1xMcATZThjySQUHqr+0ksP8kqaw23fNKkaaN/Z8gwLUs/W7xdl0I75eP2Xyw==} engines: {node: '>= 14'} pac-resolver@7.0.1: @@ -6301,6 +6078,12 @@ packages: resolution: {integrity: sha512-whdkPIooSu/bASggZ96BWVvZTRMOFxnyUG5PnTSGKoJE2gd5mbVNmR2Nj20QFzxYYgAXpoqC+AiXzl+UMRh7zQ==} engines: {node: '>=8'} + package-json-from-dist@1.0.1: + resolution: {integrity: sha512-UEZIS3/by4OC8vL3P2dTXRETpebLI2NiI5vIrjaD/5UtrkFX/tNbwjTSRAGC/+7CAo2pIcBaRgWmcBBHcsaCIw==} + + package-manager-detector@0.2.2: + resolution: {integrity: sha512-VgXbyrSNsml4eHWIvxxG/nTL4wgybMTXCV2Un/+yEc3aDKKU6nQBZjbeP3Pl3qm9Qg92X/1ng4ffvCeD/zwHgg==} + param-case@3.0.4: resolution: {integrity: sha512-RXlj7zCYokReqWpOPH9oYivUzLYZ5vAPIfEmCTNViosC78F8F0H9y7T7gG2M39ymgutxF5gcFEsyZQSph9Bp3A==} @@ -6308,6 +6091,9 @@ packages: resolution: {integrity: sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g==} engines: {node: '>=6'} + parse-cache-control@1.0.1: + resolution: {integrity: sha512-60zvsJReQPX5/QP0Kzfd/VrpjScIQ7SHBW6bFCYfEP+fp0Eppr1SHhIO5nd1PjZtvclzSzES9D/p5nFJurwfWg==} + parse-glob@3.0.4: resolution: {integrity: sha512-FC5TeK0AwXzq3tUBFtH74naWkPQCEWs4K+xMxWZBlKDWu0bVHXGZa+KKqxKidd7xwhdZ19ZNuF2uO1M/r196HA==} engines: {node: '>=0.10.0'} @@ -6367,12 +6153,12 @@ packages: path-parse@1.0.7: resolution: {integrity: sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==} - path-scurry@1.10.1: - resolution: {integrity: sha512-MkhCqzzBEpPvxxQ71Md0b1Kk51W01lrYvlMzSUaIzNsODdd7mqhiimSZlr+VegAz5Z6Vzt9Xg2ttE//XBhH3EQ==} - engines: {node: '>=16 || 14 >=14.17'} + path-scurry@2.0.0: + resolution: {integrity: sha512-ypGJsmGtdXUOeM5u93TyeIEfEhM6s+ljAhrk5vAvSx8uyY/02OvrZnA0YNGUrPXfpJMgI1ODd3nwz8Npx4O4cg==} + engines: {node: 20 || >=22} - path-to-regexp@0.1.7: - resolution: {integrity: sha512-5DFkuoqlv1uYQKxy8omFBeJPQcdoE07Kv2sferDCrAq1ohOU+MSDswDIbnx3YAM60qIOnYa53wBhXW0EbMonrQ==} + path-to-regexp@0.1.10: + resolution: {integrity: sha512-7lf7qcQidTku0Gu3YDPc8DJ1q7OOucfa/BSsIwjuh56VU7katFvuM8hULfkwB3Fns/rsVF7PwPKVw1sl5KQS9w==} path-type@4.0.0: resolution: {integrity: sha512-gDKb8aZMDeD/tZWs9P6+q0J9Mwkdl6xMV8TjnGP3qJVJ06bdMgkbBlLU8IdfOsIsFz2BW1rNVT3XuNEl8zPAvw==} @@ -6395,8 +6181,8 @@ packages: performance-now@2.1.0: resolution: {integrity: sha512-7EAHlyLHI56VEIdK57uwHdHKIaAGbnXPiw0yWbarQZOKaKpvUIgW0jWRVLiatnM+XXlSwsanIBH/hzGMJulMow==} - picocolors@1.0.0: - resolution: {integrity: sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ==} + picocolors@1.1.1: + resolution: {integrity: sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==} picomatch@2.3.1: resolution: {integrity: sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==} @@ -6410,10 +6196,6 @@ packages: resolution: {integrity: sha512-udgsAY+fTnvv7kI7aaxbqwWNb0AHiB0qBO89PZKPkoTmGOgdbrHDKD+0B2X4uTfJ/FT1R09r9gTsjUjNJotuog==} engines: {node: '>=0.10.0'} - pify@3.0.0: - resolution: {integrity: sha512-C3FsVNH1udSEX48gGX1xfvwTWfsYWj5U+8/uK15BGzIGrKoUpghX8hWZwa/OFnakBiiVNmBvemTJR5mcy7iPcg==} - engines: {node: '>=4'} - pify@4.0.1: resolution: {integrity: sha512-uB80kBFb/tfd68bVleG9T5GGsGPjJrLAUpR5PZIrhBnIaRTQRjqdJSsIKkOP6OAIFbj7GOrcudc5pNjZ+geV2g==} engines: {node: '>=6'} @@ -6450,10 +6232,6 @@ packages: resolution: {integrity: sha512-VP/72JeXqak2KiOzjgKtQen5y3IZHn+9GOuLDafPv0eXa47xq0At93XahYBs26MsifCQ4enGKwbjBTKgb9QJXg==} engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} - portfinder@1.0.28: - resolution: {integrity: sha512-Se+2isanIcEqf2XMHjyUKskczxbPH7dQnlMjXX6+dybayyHvAf/TCgyMRlzf/B6QDhAEFOGes0pzRo3by4AbMA==} - engines: {node: '>= 0.12.0'} - portfinder@1.0.32: resolution: {integrity: sha512-on2ZJVVDXRADWE6jnQaX0ioEylzgBpQk8r55NE4wjXW1ZxO+BgDlY6DXwj20i0V8eB4SenDQ00WEaxfiIQPcxg==} engines: {node: '>= 0.12.0'} @@ -6466,13 +6244,9 @@ packages: resolution: {integrity: sha512-d7Uw+eZoloe0EHDIYoe+bQ5WXnGMOpmiZFTuMWCwpjzzkL2nTjcKiAk4hh8TjnGye2TwWOk3UXucZ+3rbmBa8Q==} engines: {node: '>= 0.4'} - precond@0.2.3: - resolution: {integrity: sha512-QCYG84SgGyGzqJ/vlMsxeXd/pgL/I94ixdNFyh1PusWmTCyVfPJjZ1K1jvHtsbfnXQs2TSkEP2fR7QiMZAnKFQ==} - engines: {node: '>= 0.6'} - - preferred-pm@3.1.3: - resolution: {integrity: sha512-MkXsENfftWSRpzCzImcp4FRsCc3y1opwB73CfCNWyzMqArju2CrlMHlqB7VexKiPEOjGMbttv1r9fSCn5S610w==} - engines: {node: '>=10'} + prelude-ls@1.1.2: + resolution: {integrity: sha512-ESF23V4SKG6lVSGZgYNpbsiaAkdab6ZgOxe52p7+Kid3W3u3bxR4Vfd/o21dmN7jSt0IwgZ4v5MUd26FEtXE9w==} + engines: {node: '>= 0.8.0'} prelude-ls@1.2.1: resolution: {integrity: sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g==} @@ -6487,16 +6261,16 @@ packages: engines: {node: '>=10.13.0'} hasBin: true - prettier@3.2.5: - resolution: {integrity: sha512-3/GWa9aOC0YeD7LUfvOG2NiDyhOWRvt1k+rcKhOuYnMY24iiCphgneUfJDyFXd6rZCAnuLBv6UeAULtrhT/F4A==} + prettier@3.3.3: + resolution: {integrity: sha512-i2tDNA0O5IrMO757lfrdQZCc2jPNDVntV0m/+4whiDfWaTKfMNgR7Qz0NAeGz/nRqF4m5/6CLzbP4/liHt12Ew==} engines: {node: '>=14'} hasBin: true pretty-error@4.0.0: resolution: {integrity: sha512-AoJ5YMAcXKYxKhuJGdcvse+Voc6v1RgnsR3nWcYU7q4t6z0Q6T86sv5Zq8VIRbOWWFpvdGE83LtdSMNd+6Y0xw==} - pretty-ms@9.0.0: - resolution: {integrity: sha512-E9e9HJ9R9NasGOgPaPE8VMeiPKAyWR5jcFpNnwIejslIhWqdqOrb2wShBsncMPUb+BcCd2OPYfh7p2W6oemTng==} + pretty-ms@9.1.0: + resolution: {integrity: sha512-o1piW0n3tgKIKCwk2vpM/vOV13zjJzvP37Ioze54YlTHE06m4tjEbzg9WsKkvTuyYln2DHjo5pY4qrZGI0otpw==} engines: {node: '>=18'} process-nextick-args@2.0.1: @@ -6514,16 +6288,19 @@ packages: resolution: {integrity: sha512-7PiHtLll5LdnKIMw100I+8xJXR5gW2QwWYkT6iJva0bXitZKa/XMrSbdmg3r2Xnaidz9Qumd0VPaMrZlF9V9sA==} engines: {node: '>=0.4.0'} - promise-to-callback@1.0.0: - resolution: {integrity: sha512-uhMIZmKM5ZteDMfLgJnoSq9GCwsNKrYau73Awf1jIy6/eUcuuZ3P+CD9zUv0kJsIUbU+x6uLNIhXhLHDs1pNPA==} - engines: {node: '>=0.10.0'} + promise@8.3.0: + resolution: {integrity: sha512-rZPNPKTOYVNEEKFaq1HqTgOwZD+4/YHS5ukLzQCypkj+OkYx7iv0mA91lJlpPPZ8vMau3IIGj5Qlwrx+8iiSmg==} + + prompts@2.4.2: + resolution: {integrity: sha512-NxNv/kLguCA7p3jE8oL2aEBsrJWgAakBpgmgK6lpPWV+WuOmY6r2/zbAVnP+T8bQlA0nzHXSJSJW0Hq7ylaD2Q==} + engines: {node: '>= 6'} proxy-addr@2.0.7: resolution: {integrity: sha512-llQsMLSUDUPT44jdrU/O37qlnifitDP+ZwrmmZcoSKyLKvtZxpyV0n2/bD/N4tBAAZ/gJEdZU7KMraoK1+XYAg==} engines: {node: '>= 0.10'} - proxy-agent@6.3.1: - resolution: {integrity: sha512-Rb5RVBy1iyqOtNl15Cw/llpeLH8bsb37gM1FUfKQ+Wck6xHlbAhWGUFiTRHtkjqGTA5pSHz6+0hrPW/oECihPQ==} + proxy-agent@6.5.0: + resolution: {integrity: sha512-TmatMXdr2KlRiA2CyDu8GqR8EjahTG3aY3nXjdzFyoZbmB8hrBsTyMezhULIXKnC0jpfjlmiZ3+EaCzoInSu/A==} engines: {node: '>= 14'} proxy-from-env@1.1.0: @@ -6538,8 +6315,8 @@ packages: psl@1.9.0: resolution: {integrity: sha512-E/ZsdU4HLs/68gYzgGTkMicWTLPdAftJLfJFlLUAAKZGkStNU72sZjT66SnMDVOfOWY/YAoiD7Jxa9iHvngcag==} - pump@3.0.0: - resolution: {integrity: sha512-LwZy+p3SFs1Pytd/jYct4wpv49HiYCqd9Rlc5ZVdk0V+8Yzv6jR5Blk3TRmPL1ft69TxP0IMZGJ+WPFU2BFhww==} + pump@3.0.2: + resolution: {integrity: sha512-tUPXtzlGM8FE3P0ZL6DVs/3P58k9nk8/jZeQCurTJylQA8qFYzHFfhBJkuqyE0FifOsQ0uKWekiZ5g8wtr28cw==} punycode@1.4.1: resolution: {integrity: sha512-jmYNElW7yvO7TV33CjSmvSiE2yco3bV2czu/OzDKdMNVZQWfxCblURLhf+47syQRBntjfLdd/H0egrzIG+oaFQ==} @@ -6552,25 +6329,17 @@ packages: resolution: {integrity: sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg==} engines: {node: '>=6'} - puppeteer-core@21.11.0: - resolution: {integrity: sha512-ArbnyA3U5SGHokEvkfWjW+O8hOxV1RSJxOgriX/3A4xZRqixt9ZFHD0yPgZQF05Qj0oAqi8H/7stDorjoHY90Q==} - engines: {node: '>=16.13.2'} + puppeteer-core@23.10.3: + resolution: {integrity: sha512-7JG8klL2qHLyH8t2pOmM9zgykhaulUf7cxnmmqupjdwGfNMiGaYehQka20iUB9R/fwVyG8mFMZcsmw1FHrgKVw==} + engines: {node: '>=18'} - puppeteer@21.11.0: - resolution: {integrity: sha512-9jTHuYe22TD3sNxy0nEIzC7ZrlRnDgeX3xPkbS7PnbdwYjl2o/z/YuCrRBwezdKpbTDTJ4VqIggzNyeRcKq3cg==} - engines: {node: '>=16.13.2'} + puppeteer@23.10.3: + resolution: {integrity: sha512-ODG+L9vCSPkQ1j+yDtNDdkSsWt2NXNrQO5C8MlwkYgE2hYnXdqVRbBpsHnoP7+EULJJKbWyR2Q4BdfohjQor3A==} + engines: {node: '>=18'} hasBin: true - qs@6.10.4: - resolution: {integrity: sha512-OQiU+C+Ds5qiH91qh/mg0w+8nwQuLjM4F4M/PbmhDOoYehPh+Fb0bDjtR1sOvy7YKxvj28Y/M0PhP5uVX0kB+g==} - engines: {node: '>=0.6'} - - qs@6.11.0: - resolution: {integrity: sha512-MvjoMCJwEarSbUYk5O+nmoSzSutSsTwF85zcHPQ9OrlFoZOYIjaqBAJIqIXjptyD5vThxGq52Xu/MaJzRkIk4Q==} - engines: {node: '>=0.6'} - - qs@6.11.2: - resolution: {integrity: sha512-tDNIz22aBzCDxLtVH++VnTfzxlfeK5CbqohpSqpJgj1Wg/cQbStNAz3NuqCs5vV+pjBsK4x4pN9HlVh7rcYRiA==} + qs@6.13.0: + resolution: {integrity: sha512-+38qI9SOr8tfZ4QmJNplMUxqjbe7LKvvZgWdExBOmd+egZTtjLB67Gu0HRX3u/XOq7UU2Nx6nsjvS16Z9uwfpg==} engines: {node: '>=0.6'} qs@6.5.3: @@ -6590,10 +6359,6 @@ packages: queue-tick@1.0.1: resolution: {integrity: sha512-kJt5qhMxoszgU/62PLP1CJytzd2NKetjSRnyuj31fDd3Rlcz3fzlFdFLD1SItunPwyqEOkca6GbV612BWfaBag==} - quick-lru@4.0.1: - resolution: {integrity: sha512-ARhCpm70fzdcvNQfPoy49IaanKkTlRWF2JMzqhcJbhSFRZv7nPTvZJdcY7301IPmvW+/p0RgIWnQDLJxifsQ7g==} - engines: {node: '>=8'} - quick-lru@5.1.1: resolution: {integrity: sha512-WuyALRjWPDGtt/wzJiadO5AXY+8hZ80hVpe6MyivgraREW751X3SbhRvG3eLKOYN+8VEvqLcf3wdnt44Z4S4SA==} engines: {node: '>=10'} @@ -6605,10 +6370,6 @@ packages: resolution: {integrity: sha512-Hrgsx+orqoygnmhFbKaHE6c296J+HTAQXoxEF6gNupROmmGJRoyzfG3ccAveqCBrwr/2yxQ5BVd/GTl5agOwSg==} engines: {node: '>= 0.6'} - raw-body@2.5.1: - resolution: {integrity: sha512-qqJBtEyVgS0ZmPGdCFPWJ3FreoqvG4MVQln/kCgF7Olq95IbOp0/BWyMwbdtn4VTvkM8Y7khCQ2Xgk/tcrCXig==} - engines: {node: '>= 0.8'} - raw-body@2.5.2: resolution: {integrity: sha512-8zGqypfENjCIqGhgXToC8aB2r7YrBX+AQAfIPs/Mlk+BtPTztOvTS01NRW/3Eh60J+a48lt8qsCzirQ6loCVfA==} engines: {node: '>= 0.8'} @@ -6616,14 +6377,6 @@ packages: react-native-keychain@8.2.0: resolution: {integrity: sha512-SkRtd9McIl1Ss2XSWNLorG+KMEbgeVqX+gV+t3u1EAAqT8q2/OpRmRbxpneT2vnb/dMhiU7g6K/pf3nxLUXRvA==} - read-pkg-up@7.0.1: - resolution: {integrity: sha512-zK0TB7Xd6JpCLmlLmufqykGE+/TlOePD6qKClNW7hHDKFh/J7/7gCWGR7joEQEW1bKq3a3yUZSObOoWLFQ4ohg==} - engines: {node: '>=8'} - - read-pkg@5.2.0: - resolution: {integrity: sha512-Ug69mNOpfvKDAc2Q8DRpMjjzdtrnv9HcSMX+4VsZxD1aZ6ZzrIE7rlzXBtWTyhULSMKg076AW6WR5iZpD0JiOg==} - engines: {node: '>=8'} - read-tls-client-hello@1.0.1: resolution: {integrity: sha512-OvSzfVv6Y656ekUxB7aDhWkLW7y1ck16ChfLFNJhKNADFNweH2fvyiEZkGmmdtXbOtlNuH2zVXZoFCW349M+GA==} engines: {node: '>=12.0.0'} @@ -6632,12 +6385,6 @@ packages: resolution: {integrity: sha512-VIMnQi/Z4HT2Fxuwg5KrY174U1VdUIASQVWXXyqtNRtxSr9IYkn1rsI6Tb6HsrHCmB7gVpNwX6JxPTHcH6IoTA==} engines: {node: '>=6'} - readable-stream@1.0.34: - resolution: {integrity: sha512-ok1qVCJuRkNmvebYikljxJA/UEsKwLl2nI1OmaqAu4/UE+h0wKCHok4XkL/gvi39OacXvw59RJUOFUkDib2rHg==} - - readable-stream@1.1.14: - resolution: {integrity: sha512-+MeVjFf4L44XUkhM1eYbD8fyEsxcV81pqMSR5gblfcLCHfZvbrqy4/qYHE+/R5HoBUT11WV5O08Cr1n3YXkWVQ==} - readable-stream@2.3.8: resolution: {integrity: sha512-8p0AUk4XODgIewSi0l8Epjs+EVnWiK7NoDIEGU0HhE7+ZyY8D1IMY7odu5lRrFXGg71L15KG8QrPmum45RTtdA==} @@ -6653,23 +6400,31 @@ packages: resolution: {integrity: sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA==} engines: {node: '>=8.10.0'} + readdirp@4.0.2: + resolution: {integrity: sha512-yDMz9g+VaZkqBYS/ozoBJwaBhTbZo3UNYQHNRw1D3UFQB8oHB4uS/tAODO+ZLjGWmUbKnIlOWO+aaIiAxrUWHA==} + engines: {node: '>= 14.16.0'} + realistic-structured-clone@3.0.0: resolution: {integrity: sha512-rOjh4nuWkAqf9PWu6JVpOWD4ndI+JHfgiZeMmujYcPi+fvILUu7g6l26TC1K5aBIp34nV+jE1cDO75EKOfHC5Q==} + rechoir@0.6.2: + resolution: {integrity: sha512-HFM8rkZ+i3zrV+4LQjwQ0W+ez98pApMGM3HUrN04j3CqzPOzl9nmP15Y8YXNm8QHGv/eacOVEjqhmWpkRV0NAw==} + engines: {node: '>= 0.10'} + rechoir@0.7.1: resolution: {integrity: sha512-/njmZ8s1wVeR6pjTZ+0nCnv8SpZNRMT2D1RLOJQESlYFDBvwpTA4KWJpZ+sBJ4+vhjILRcK7JIFdGCdxEAAitg==} engines: {node: '>= 0.10'} - redent@3.0.0: - resolution: {integrity: sha512-6tDA8g98We0zd0GvVeMT9arEOnTw9qM03L9cJXaCjrip1OO764RDBLBfrB4cwzNGDj5OA5ioymC9GkizgWJDUg==} - engines: {node: '>=8'} + recursive-readdir@2.2.3: + resolution: {integrity: sha512-8HrF5ZsXk5FAH9dgsx3BlUer73nIhuj+9OrQwEbLTPOBzGkL1lsFCR01am+v+0m2Cmbs1nP12hLDl5FA7EszKA==} + engines: {node: '>=6.0.0'} reduce-flatten@2.0.0: resolution: {integrity: sha512-EJ4UNY/U1t2P/2k6oqotuX2Cc3T6nxJwsM0N0asT7dhrtH1ltUxDn4NalSYmPE2rCkVpcf/X6R0wDwcFpzhd4w==} engines: {node: '>=6'} - regenerate-unicode-properties@10.1.1: - resolution: {integrity: sha512-X007RyZLsCJVVrjgEFVpLUTZwyOZk3oiL75ZcuYjlIWd6rNJtOjkBwQc5AsRrpbKVkxN6sklw/k/9m2jJYOf8Q==} + regenerate-unicode-properties@10.2.0: + resolution: {integrity: sha512-DqHn3DwbmmPVzeKj9woBadqmXxLvQoQIwu7nopMc72ztvxVmVk2SBhSnx67zuye5TP+lJsb/TBQsjLKhnDf3MA==} engines: {node: '>=4'} regenerate@1.4.2: @@ -6685,16 +6440,19 @@ packages: resolution: {integrity: sha512-J6SDjUgDxQj5NusnOtdFxDwN/+HWykR8GELwctJ7mdqhcyy1xEc4SRFHUXvxTp661YaVKAjfRLZ9cCqS6tn32A==} engines: {node: '>=0.10.0'} - regexp.prototype.flags@1.5.2: - resolution: {integrity: sha512-NcDiDkTLuPR+++OCKB0nWafEmhg/Da8aUPLPMQbK+bxKKCm1/S5he+AqYa4PlMCVBalb4/yxIRub6qkEx5yJbw==} + regexp.prototype.flags@1.5.3: + resolution: {integrity: sha512-vqlC04+RQoFalODCbCumG2xIOvapzVMHwsyIGM/SIE8fRhFFsXeH8/QQ+s0T0kDAhKc4k30s73/0ydkHQz6HlQ==} engines: {node: '>= 0.4'} - regexpu-core@5.3.2: - resolution: {integrity: sha512-RAM5FlZz+Lhmo7db9L298p2vHP5ZywrVXmVXpmAD9GuL5MPH6t9ROw1iA/wfHkQ76Qe7AaPF0nGuim96/IrQMQ==} + regexpu-core@6.1.1: + resolution: {integrity: sha512-k67Nb9jvwJcJmVpw0jPttR1/zVfnKf8Km0IPatrU/zJ5XeG3+Slx0xLXs9HByJSzXzrlz5EDvN6yLNMDc2qdnw==} engines: {node: '>=4'} - regjsparser@0.9.1: - resolution: {integrity: sha512-dQUtn90WanSNl+7mQKcXAgZxvUe7Z0SqXlgzv0za4LwiUhyzBC58yQO3liFoUgu8GiJVInAhJjkj1N0EtQ5nkQ==} + regjsgen@0.8.0: + resolution: {integrity: sha512-RvwtGe3d7LvWiDQXeQw8p5asZUmfU1G/l6WbUXeHta7Y2PEIvBTwH6E2EfmYUK8pxcxEdEmaomqyp0vZZ7C+3Q==} + + regjsparser@0.11.1: + resolution: {integrity: sha512-1DHODs4B8p/mQHU9kr+jv8+wIC9mtG4eBHxWxIq5mhjE3D5oORhCc6deRKzTjs9DcfRFmj9BHSDguZklqCGFWQ==} hasBin: true relateurl@0.2.7: @@ -6719,6 +6477,14 @@ packages: resolution: {integrity: sha512-PV0dzCYDNfRi1jCDbJzpW7jNNDRuCOG/jI5ctQcGKt/clZD+YcPS3yIlWuTJMmESC8aevCFmWJy5wjAFgNqN6w==} engines: {node: '>=0.10'} + req-cwd@2.0.0: + resolution: {integrity: sha512-ueoIoLo1OfB6b05COxAA9UpeoscNpYyM+BqYlA7H6LVF4hKGPXQQSSaD2YmvDVJMkk4UDpAHIeU1zG53IqjvlQ==} + engines: {node: '>=4'} + + req-from@2.0.0: + resolution: {integrity: sha512-LzTfEVDVQHBRfjOUMgNBA+V6DWsSnoeKzf42J7l0xa/B4jyPOuuF5MlNSmomLNGemWTnV2TIdjSSLnEn95fOQA==} + engines: {node: '>=4'} + request@2.88.2: resolution: {integrity: sha512-MsvtOrfG9ZcrOwAW+Qi+F6HbD0CWXEh9ou77uOb7FM2WPhwT7smM833PzanhJLsgXjN89Ir6V2PczXNnMpwKhw==} engines: {node: '>= 6'} @@ -6768,6 +6534,9 @@ packages: resolution: {integrity: sha512-ZuF55hVUQaaczgOIwqWzkEcEidmlD/xl44x1UZnhOXcYuFN2S6+rcxpG+C1N3So0wvNI3DmJICUFfu2SxhBmvg==} deprecated: https://github.com/lydell/resolve-url#deprecated + resolve@1.1.7: + resolution: {integrity: sha512-9znBF0vBcaSN3W2j7wKvdERPwqTxSpCq+if5C0WoTCyV9n24rua28jeuQ2pL/HOf+yUe/Mef+H/5p60K0Id3bg==} + resolve@1.17.0: resolution: {integrity: sha512-ic+7JYiV8Vi2yzQGFWOkiZD5Z9z7O2Zhm9XMaTxdJExKasieFCr+yXZ/WmXsckHiKl12ar0y6XiXDx3m4RHn1w==} @@ -6792,15 +6561,17 @@ packages: rimraf@2.7.1: resolution: {integrity: sha512-uWjbaKIK3T1OSVptzX7Nl6PvQ3qAGtKEtVRjRuazjfL3Bx5eI409VZSqgND+4UNnmzLVdPj9FqFJNPqBZFve4w==} + deprecated: Rimraf versions prior to v4 are no longer supported hasBin: true rimraf@3.0.2: resolution: {integrity: sha512-JZkJMZkAGFFPP2YqXZXPbMlMBgsxzE8ILs4lMIX/2o0L9UBw9O/Y3o6wFw/i9YLapcUJWwqbi3kdxIPdC62TIA==} + deprecated: Rimraf versions prior to v4 are no longer supported hasBin: true - rimraf@5.0.5: - resolution: {integrity: sha512-CqDakW+hMe/Bz202FPEymy68P+G50RfMQK+Qo5YUqc9SPipvbGjCGKd0RSKEelbsfQuw3g5NZDSrlZZAJurH1A==} - engines: {node: '>=14'} + rimraf@6.0.1: + resolution: {integrity: sha512-9dkvaxAsk/xNXSJzMgFqqMCuFgt2+KsOFek3TMLfo8NCPfWpBmqwyNn5Y+NX56QUYfCtsyhF3ayiboEoUmJk/A==} + engines: {node: 20 || >=22} hasBin: true ripemd160@2.0.2: @@ -6810,28 +6581,19 @@ packages: resolution: {integrity: sha512-d5gdPmgQ0Z+AklL2NVXr/IoSjNZFfTVvQWzL/AM2AOcSzYP2xjlb0AC8YyCLc41MSNf6P6QVtjgPdmVtzb+4lQ==} hasBin: true - rollup@2.79.1: - resolution: {integrity: sha512-uKxbd0IhMZOhjAiD5oAFp7BqvkA4Dv47qpOCtaNvng4HBwdbWtdOh8f5nZNuk2rp51PMGk3bzfWu5oayNEuYnw==} + rollup@2.79.2: + resolution: {integrity: sha512-fS6iqSPZDs3dr/y7Od6y5nha8dW1YnbgtsyotCVvoFGKbERG++CVRFv1meyGDE1SNItQA8BrnCw7ScdAhRJ3XQ==} engines: {node: '>=10.0.0'} hasBin: true run-parallel@1.2.0: resolution: {integrity: sha512-5l4VyZR86LZ/lDxZTR6jqL8AFE2S0IFLMP26AbjsLVADxHdhB/c0GUsH+y39UfCi3dzz8OlQuPmnaJOMoDHQBA==} - rust-verkle-wasm@0.0.1: - resolution: {integrity: sha512-BN6fiTsxcd2dCECz/cHtGTt9cdLJR925nh7iAuRcj8ymKw7OOaPmCneQZ7JePOJ/ia27TjEL91VdOi88Yf+mcA==} - - rustbn-wasm@0.2.0: - resolution: {integrity: sha512-FThvYFNTqrEKGqXuseeg0zR7yROh/6U1617mCHF68OVqrN1tNKRN7Tdwy4WayPVsCmmK+eMxtIZX1qL6JxTkMg==} - - rustbn.js@0.2.0: - resolution: {integrity: sha512-4VlvkRUuCJvr2J6Y0ImW7NvTCriMi7ErOAqWk1y69vAdoNIzCF3yPmgeNzx+RQTLEDFq5sHfscn1MwHxP9hNfA==} - rxjs@7.8.1: resolution: {integrity: sha512-AA3TVj+0A2iuIoQkWEK/tqFjBq2j+6PO6Y0zJcvzLAFhEFIO3HL0vls9hWLncZbAAbK0mar7oZ4V079I/qPMxg==} - safe-array-concat@1.1.0: - resolution: {integrity: sha512-ZdQ0Jeb9Ofti4hbt5lX3T2JcAamT9hfzYU1MNB+z/jaEbB6wfFfPIR/zEORmZqobkCCJhSjodobH6WHNmJ97dg==} + safe-array-concat@1.1.2: + resolution: {integrity: sha512-vj6RsCsWBCf19jIeHEfkRMw8DPiBb+DMXklQ/1SGDHOMlHdPUkZXFQ2YdplS23zESTijAcurb1aSgJA3AgMu1Q==} engines: {node: '>=0.4'} safe-buffer@5.1.2: @@ -6840,10 +6602,6 @@ packages: safe-buffer@5.2.1: resolution: {integrity: sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==} - safe-event-emitter@1.0.1: - resolution: {integrity: sha512-e1wFe99A91XYYxoQbcq2ZJUWurxEyP8vfz7A7vuUe1s95q8r5ebraVaA1BukYJcpM6V16ugWoD9vngi8Ccu5fg==} - deprecated: Renamed to @metamask/safe-event-emitter - safe-regex-test@1.0.3: resolution: {integrity: sha512-CdASjNJPvRa7roO6Ra/gLYBTzYzzPyyBXxIMdGW3USQLyjWEls2RgW5UBTXaQVp+OrpeCK3bLem8smtmheoRuw==} engines: {node: '>= 0.4'} @@ -6854,6 +6612,10 @@ packages: safer-buffer@2.1.2: resolution: {integrity: sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==} + sc-istanbul@0.4.6: + resolution: {integrity: sha512-qJFF/8tW/zJsbyfh/iT/ZM5QNHE3CXxtLJbZsL+CzdJLBsPD7SedJZoUA4d8iAcN2IoMp/Dx80shOOd2x96X/g==} + hasBin: true + schema-utils@1.0.0: resolution: {integrity: sha512-i27Mic4KovM/lnGsy8whRCHhc7VicJajAjTrYg11K9zfZXnYIt4k5F+kZkwjnrhKzLic/HLU4j11mjsz2G/75g==} engines: {node: '>= 4'} @@ -6869,9 +6631,9 @@ packages: scrypt-js@3.0.1: resolution: {integrity: sha512-cdwTTnqPu0Hyvf5in5asVdZocVDTNRmR7XEcJuIzMjJeSHybHl7vpB66AzwTaIg6CLSbtjcxc8fqcySfnTkccA==} - secp256k1@4.0.3: - resolution: {integrity: sha512-NLZVf+ROMxwtEj3Xa562qgv2BK5e2WNmXPiOdVIPLgs6lyTzMvBq0aWTYMI5XCP9jZMVKOcqZLw/Wc4vDkuxhA==} - engines: {node: '>=10.0.0'} + secp256k1@4.0.4: + resolution: {integrity: sha512-6JfvwvjUOn8F/jUoBY2Q1v5WY5XS+rj8qSe0v8Y4ezH4InLgTEeOOPQsRll9OV429Pvo6BCHGavIyJfr3TAhsw==} + engines: {node: '>=18.0.0'} select-hose@2.0.0: resolution: {integrity: sha512-mEugaLK+YfkijB4fx0e6kImuJdCIt2LxCRcbEYPqRGCs4F2ogyfZU5IAZRdjCP8JPq2AtdNoC/Dux63d9Kiryg==} @@ -6879,14 +6641,6 @@ packages: selfsigned@1.10.14: resolution: {integrity: sha512-lkjaiAye+wBZDCBsu5BGi0XiLRxeUlsGod5ZP924CRSEoGuZAw/f7y9RKu28rwTfiHVhdavhB0qH0INV6P1lEA==} - semaphore@1.1.0: - resolution: {integrity: sha512-O4OZEaNtkMd/K0i6js9SL+gqy0ZCBMgUvlSqHKi4IBdjhe7wB8pwztUk1BbZ1fmrvpwFrPbHzqd2w5pTcJH6LA==} - engines: {node: '>=0.8.0'} - - semver@5.4.1: - resolution: {integrity: sha512-WfG/X9+oATh81XtllIo/I8gOiY9EXRdv1cQdyykeXK17YcUW3EXUAi2To4pcH6nZtJPr7ZOpM5OMyWJZm+8Rsg==} - hasBin: true - semver@5.7.2: resolution: {integrity: sha512-cBznnQ9KjJqU67B52RMC65CMarK2600WFnbkcaiwWq3xy/5haFJlshgnpjovMVJ+Hff49d8GEn0b87C5pDQ10g==} hasBin: true @@ -6895,22 +6649,19 @@ packages: resolution: {integrity: sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==} hasBin: true - semver@7.6.0: - resolution: {integrity: sha512-EnwXhrlwXMk9gKu5/flx5sv/an57AkRplG3hTK68W7FRDN+k+OWBj65M7719OkA82XLBxrcX0KSHj+X5COhOVg==} + semver@7.6.3: + resolution: {integrity: sha512-oVekP1cKtI+CTDvHWYFUcMtsK/00wmAEfyqKfNdARm8u1wNVhSgaX7A8d4UuIlUI5e84iEwOhs7ZPYRmzU9U6A==} engines: {node: '>=10'} hasBin: true - send@0.18.0: - resolution: {integrity: sha512-qqWzuOjSFOuqPjFe4NOsMLafToQQwBSOEpS+FwEt3A2V3vKubTquT3vmLTQpFgMXp8AlFWFuP1qKaJZOtPpVXg==} + send@0.19.0: + resolution: {integrity: sha512-dW41u5VfLXu8SJh5bwRmyYUbAoSB3c9uQh6L8h/KtsFREPWpbX1lrljJo186Jc4nmci/sGUZ9a0a0J2zgfq2hw==} engines: {node: '>= 0.8.0'} serialize-error@7.0.1: resolution: {integrity: sha512-8I8TjW5KMOKsZQTvoxjuSIa7foAwPWGOts+6o7sgjz41/qMD9VQHEDxi6PBvK2l0MXUmqZyNpUK+T2tQaaElvw==} engines: {node: '>=10'} - serialize-javascript@6.0.0: - resolution: {integrity: sha512-Qr3TosvguFt8ePWqsvRfrKyQXIiW+nGbYpy8XK24NQHE83caxWt+mIymTT19DGFbNWNLfEwsrkSmN64lVWB9ag==} - serialize-javascript@6.0.2: resolution: {integrity: sha512-Saa1xPByTTq2gdeFZYLLo+RFE35NHZkAbqZeWNd3BpzppeVisAqpDjcp8dyf6uIvEqJRd46jemmyA4iFIeVk8g==} @@ -6918,8 +6669,8 @@ packages: resolution: {integrity: sha512-pXHfKNP4qujrtteMrSBb0rc8HJ9Ms/GrXwcUtUtD5s4ewDJI8bT3Cz2zTVRMKtri49pLx2e0Ya8ziP5Ya2pZZw==} engines: {node: '>= 0.8.0'} - serve-static@1.15.0: - resolution: {integrity: sha512-XGuRDNjXUijsUL0vl6nSD7cwURuzEgglbOaFuZM9g3kwDXOWVTck0jLzjPzGD+TazWbboZYu52/9/XPdUgne9g==} + serve-static@1.16.2: + resolution: {integrity: sha512-VqpjJZKadQB/PEbEwvFdO43Ax5dFBZ2UECszz8bQ7pi7wt//PWe1P6MN7eCnjsatYtBT6EuiClbjSWP2WrIoTw==} engines: {node: '>= 0.8.0'} servify@0.1.12: @@ -6929,18 +6680,14 @@ packages: set-blocking@2.0.0: resolution: {integrity: sha512-KiKBS8AnWGEyLzofFfmvKwpdPzqiy16LvQfK3yv/fVH7Bj13/wl3JSR1J+rfgRE9q7xUJK4qvgS8raSOeLUehw==} - set-function-length@1.2.1: - resolution: {integrity: sha512-j4t6ccc+VsKwYHso+kElc5neZpjtq9EnRICFZtWyBsLojhmeF/ZBd/elqm22WJh/BziDe/SBiOeAt0m2mfLD0g==} + set-function-length@1.2.2: + resolution: {integrity: sha512-pgRc4hJ4/sNjWCSS9AmnS40x3bNMDTknHgL5UaMBTMyJnU90EgWh1Rz+MC9eFu4BuN/UwZjKQuY/1v3rM7HMfg==} engines: {node: '>= 0.4'} set-function-name@2.0.2: resolution: {integrity: sha512-7PGFlmtwsEADb0WYyvCMa1t+yke6daIG4Wirafur5kcf+MhUnPms1UeR0CKQdTZD81yESwMHbtn+TR+dMviakQ==} engines: {node: '>= 0.4'} - set-immediate-shim@1.0.1: - resolution: {integrity: sha512-Li5AOqrZWCVA2n5kryzEmqai6bKSIvpz5oUJHPVj6+dsbD3X1ixtsY5tEnsaNpH3pFAHmG8eIHUrtEtohrg+UQ==} - engines: {node: '>=0.10.0'} - set-value@2.0.1: resolution: {integrity: sha512-JxHc1weCN68wRY0fhCoXpyK55m/XPHafOmK4UWD7m2CI14GMcFypt4w/0+NV5f/ZMby2F6S2wwA7fgynh9gWSw==} engines: {node: '>=0.10.0'} @@ -6958,6 +6705,9 @@ packages: resolution: {integrity: sha512-QMEp5B7cftE7APOjk5Y6xgrbWu+WkLVQwk8JNjZ8nKRciZaByEW6MubieAiToS7+dwvrjGhH8jRXz3MVd0AYqQ==} hasBin: true + sha1@1.1.1: + resolution: {integrity: sha512-dZBS6OrMjtgVkopB1Gmo4RQCDKiZsqcpAQpkV/aaj+FCrCg8r4I4qMkDPQjBgLIxlmu9k4nUbWq6ohXahOneYA==} + shallow-clone@3.0.1: resolution: {integrity: sha512-/6KqX+GVUdqPuPPd2LxDDxzX6CAbjJehAAOKlNpqqUpAqPM6HeL8f+o3a+JsyGjn2lv0WY8UsTgUJjU9Ok55NA==} engines: {node: '>=8'} @@ -6981,8 +6731,13 @@ packages: shell-quote@1.8.1: resolution: {integrity: sha512-6j1W9l1iAs/4xYBI1SYOVZyFcCis9b4KCLQ8fgAGG07QvzaRLVVRQvAy85yNmmZSjYjg4MWh4gNvlPujU/5LpA==} - side-channel@1.0.5: - resolution: {integrity: sha512-QcgiIWV4WV7qWExbN5llt6frQB/lBven9pqliLXfGPB+K9ZYXxDozp0wLkHS24kWCm+6YXH/f0HhnObZnZOBnQ==} + shelljs@0.8.5: + resolution: {integrity: sha512-TiwcRcrkhHvbrZbnRcFYMLl30Dfov3HKqzp5tO5b4pt6G/SezKcYhmDg15zXVBswHmctSAQKznqNW2LO5tTDow==} + engines: {node: '>=4'} + hasBin: true + + side-channel@1.0.6: + resolution: {integrity: sha512-fDW/EZ6Q9RiO8eFG8Hj+7u/oW+XrPTIChwCOM2+th2A6OblDtYYIpve9m+KvI9Z4C9qSEXlaGR6bTEYHReuglA==} engines: {node: '>= 0.4'} signal-exit@3.0.7: @@ -6998,6 +6753,9 @@ packages: simple-get@2.8.2: resolution: {integrity: sha512-Ijd/rV5o+mSBBs4F/x9oDPtTx9Zb6X9brmnXvMW4J7IR15ngi9q5xxqWBKU744jTZiaXtxaPL7uHG6vtN8kUkw==} + sisteransi@1.0.5: + resolution: {integrity: sha512-bLGGlR1QxBcynn2d5YmDX4MGjlZvy2MRBDRNHLJ8VI6l6+9FUiyTFNJ0IveOSP0bcXgVDPRcfGqA0pjaqUpfVg==} + slash@3.0.0: resolution: {integrity: sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q==} engines: {node: '>=8'} @@ -7006,6 +6764,10 @@ packages: resolution: {integrity: sha512-ZA6oR3T/pEyuqwMgAKT0/hAv8oAXckzbkmR0UkUosQ+Mc4RxGoJkRmwHgHufaenlyAgE1Mxgpdcrf75y6XcnDg==} engines: {node: '>=14.16'} + slice-ansi@4.0.0: + resolution: {integrity: sha512-qMCMfhY040cVHT43K9BFygqYbUPFZKHOg7K73mtTWJRb8pyP3fzf4Ixd5SzdEJQ6MRUg/WBnOLxghZtKKurENQ==} + engines: {node: '>=10'} + slice-ansi@5.0.0: resolution: {integrity: sha512-FC+lgizVPfie0kkhqUScwRu1O/lF6NOgJmlCgK+/LYxDCTk8sGelYaHDhFcDN+Sn3Cv+3VSa4Byeo+IMCzpMgQ==} engines: {node: '>=12'} @@ -7014,11 +6776,6 @@ packages: resolution: {integrity: sha512-94hK0Hh8rPqQl2xXc3HsaBoOXKV20MToPkcXvwbISWLEs+64sBq5kFgn2kJDHb1Pry9yrP0dxrCI9RRci7RXKg==} engines: {node: '>= 6.0.0', npm: '>= 3.0.0'} - smartwrap@2.0.2: - resolution: {integrity: sha512-vCsKNQxb7PnCNd2wY1WClWifAc2lwqsG8OaswpJkVJsvMGcnEntdTCDajZCkk93Ay1U3t/9puJmb525Rg5MZBA==} - engines: {node: '>=6'} - hasBin: true - snapdragon-node@2.1.1: resolution: {integrity: sha512-O27l4xaMYt/RSQ5TR3vpWCAB5Kb/czIcqUFOM/C4fYcLnbZUc1PkjTAMjof2pBWaSTwOUd6qUHcFGVGj7aIwnw==} engines: {node: '>=0.10.0'} @@ -7042,18 +6799,28 @@ packages: resolution: {integrity: sha512-Fgl0YPZ902wEsAyiQ+idGd1A7rSFx/ayC1CQVMw5P+EQx2V0SgpGtf6OKFhVjPflPUl9YMmEOnmfjCdMUsygww==} engines: {node: '>= 10'} - socks-proxy-agent@8.0.2: - resolution: {integrity: sha512-8zuqoLv1aP/66PHF5TqwJ7Czm3Yv32urJQHrVyhD7mmA6d61Zv8cIXQYPTWwmg6qlupnPvs/QKDmfa4P/qct2g==} + socks-proxy-agent@8.0.4: + resolution: {integrity: sha512-GNAq/eg8Udq2x0eNiFkr9gRg5bA7PXEWagQdeRX4cPSG+X/8V38v637gim9bjFptMk1QWsCTr0ttrJEiXbNnRw==} + engines: {node: '>= 14'} + + socks-proxy-agent@8.0.5: + resolution: {integrity: sha512-HehCEsotFqbPW9sJ8WVYB6UbmIMv7kUUORIF2Nncq4VQvBfNBLibW9YZR5dlYCSUhwcD628pRllm7n+E+YTzJw==} engines: {node: '>= 14'} - socks@2.8.1: - resolution: {integrity: sha512-B6w7tkwNid7ToxjZ08rQMT8M9BJAf8DKx8Ft4NivzH0zBUfd6jldGcisJn/RLgxcX3FPNDdNQCUEMMT79b+oCQ==} + socks@2.8.3: + resolution: {integrity: sha512-l5x7VUUWbjVFbafGLxPWkYsHIhEvmF85tbIeFZWc8ZPtoMyybuEhL7Jye/ooC4/d48FgOjSJXgsF/AJPYCW8Zw==} engines: {node: '>= 10.0.0', npm: '>= 3.0.0'} - solc@0.7.3: - resolution: {integrity: sha512-GAsWNAjGzIDg7VxzP6mPjdurby3IkGCjQcM8GFYZT6RyaoUZKmMU6Y7YwG+tFGhv7dwZ8rmR4iwFDrrD99JwqA==} - engines: {node: '>=8.0.0'} + solc@0.8.26: + resolution: {integrity: sha512-yiPQNVf5rBFHwN6SIf3TUUvVAFKcQqmSUFeq+fb6pNRCo0ZCgpYOZDi3BVoezCPIAcKrVYd/qXlBLUP9wVrZ9g==} + engines: {node: '>=10.0.0'} + hasBin: true + + solidity-coverage@0.8.13: + resolution: {integrity: sha512-RiBoI+kF94V3Rv0+iwOj3HQVSqNzA9qm/qDP1ZDXK5IX0Cvho1qiz8hAXTsAo6KOIUeP73jfscq0KlLqVxzGWA==} hasBin: true + peerDependencies: + hardhat: ^2.11.0 source-map-resolve@0.5.3: resolution: {integrity: sha512-Htz+RnsXWk5+P2slx5Jh3Q66vhQj1Cllm0zvnaY98+NFx+Dv2CF/f5O/t8x+KaNdrdIAsruNzoh/KpialbqAnw==} @@ -7066,6 +6833,10 @@ packages: resolution: {integrity: sha512-cPiFOTLUKvJFIg4SKVScy4ilPPW6rFgMgfuZJPNoDuMs3nC1HbMUycBoJw77xFIp6z1UJQJOfx6C9GMH80DiTw==} deprecated: See https://github.com/lydell/source-map-url#deprecated + source-map@0.2.0: + resolution: {integrity: sha512-CBdZ2oa/BHhS4xj5DlhjWNHcan57/5YuvfdLf17iVmIpd9KRm+DFLmC6nBNj+6Ua7Kt3TmOjDpQT1aTYOQtoUA==} + engines: {node: '>=0.8.0'} + source-map@0.5.7: resolution: {integrity: sha512-LbrmJOMUSdEVxIKvdcJzQC+nQhe8FUZQTXQy6+I75skNgn3OoQ0DZA8YnFa7gp8tqtL3KPf1kmo0R5DoApeSGQ==} engines: {node: '>=0.10.0'} @@ -7078,12 +6849,6 @@ packages: resolution: {integrity: sha512-9NykojV5Uih4lgo5So5dtw+f0JgJX30KCNI8gwhz2J9A15wD0Ml6tjHKwf6fTSa6fAdVBdZeNOs9eJ71qCk8vA==} deprecated: Please use @jridgewell/sourcemap-codec instead - spawn-command@0.0.2: - resolution: {integrity: sha512-zC8zGoGkmc8J9ndvml8Xksr1Amk9qBujgbF0JAIWO7kXr43w0h/0GJNM/Vustixu+YE8N/MTrQ7N31FvHUACxQ==} - - spawn-command@0.0.2-1: - resolution: {integrity: sha512-n98l9E2RMSJ9ON1AKisHzz7V42VDiBQGY6PB1BwRglz99wpVsSuGzQ+jOi6lFXBGVTCrRpltvjm+/XA+tpeJrg==} - spawn-wrap@2.0.0: resolution: {integrity: sha512-EeajNjfN9zMnULLwhZZQU3GWBoFNkbngTUPfaawT4RkMiviTxcX0qfhVbGey39mfctfDHkWtuecgQ8NJcyQWHg==} engines: {node: '>=8'} @@ -7091,18 +6856,6 @@ packages: spawndamnit@2.0.0: resolution: {integrity: sha512-j4JKEcncSjFlqIwU5L/rp2N5SIPsdxaRsIv678+TZxZ0SRDJTm8JrxJMjE/XuiEZNEir3S8l0Fa3Ke339WI4qA==} - spdx-correct@3.2.0: - resolution: {integrity: sha512-kN9dJbvnySHULIluDHy32WHRUu3Og7B9sbY7tsFLctQkIqnMh3hErYgdMjTYuqmcXX+lK5T1lnUt3G7zNswmZA==} - - spdx-exceptions@2.5.0: - resolution: {integrity: sha512-PiU42r+xO4UbUS1buo3LPJkjlO7430Xn5SVAhdpzzsPHsjbYVflnnFdATgabnLude+Cqu25p6N+g2lw/PFsa4w==} - - spdx-expression-parse@3.0.1: - resolution: {integrity: sha512-cbqHunsQWnJNE6KhVSMsMeH5H/L9EpymbzqTQ3uLwNCLZ1Q481oWaofqH7nO6V07xlXwY6PhQdQ2IedWx/ZK4Q==} - - spdx-license-ids@3.0.17: - resolution: {integrity: sha512-sh8PWc/ftMqAAdFiBu6Fy6JUOYjqDJBJvIhpfDMyHrr0Rbp5liZqd4TjtQ/RgfLjKFZb+LMx5hpml5qOWy0qvg==} - spdy-transport@3.0.0: resolution: {integrity: sha512-hsLVFE5SjA6TCisWeJXFKniGGOpBgMLmerfO2aCyCU5s7nJ/rpAepqmFifv/GCbSbueEeAJJnmSQ2rKC/g8Fcw==} @@ -7114,6 +6867,9 @@ packages: resolution: {integrity: sha512-NzNVhJDYpwceVVii8/Hu6DKfD2G+NrQHlS/V/qgv763EYudVwEcMQNxd2lh+0VrUByXN/oJkl5grOhYWvQUYiw==} engines: {node: '>=0.10.0'} + split2@3.2.2: + resolution: {integrity: sha512-9NThjpgZnifTkJpzTZ7Eue85S49QwpNhZTq6GRJwObb6jnLFNGB7Qm73V5HewTROPyxD0C29xqmaI68bQtV+hg==} + sprintf-js@1.0.3: resolution: {integrity: sha512-D9cPgkvLlV3t3IzL0D0YLvGA9Ahk4PcvVwUbN0dSGr1aP0Nrt4AEnTUbuGvquEC0mA64Gqt1fzirlRs5ibXx8g==} @@ -7148,11 +6904,8 @@ packages: stream-shift@1.0.3: resolution: {integrity: sha512-76ORR0DO1o1hlKwTbi/DM3EXWGf3ZJYO8cXX5RJwnul2DEg2oyoZyjLNoQM8WsvZiFKCRfC1O0J7iCvie3RZmQ==} - stream-transform@2.1.3: - resolution: {integrity: sha512-9GHUiM5hMiCi6Y03jD2ARC1ettBXkQBoQAe7nJsPknnI0ow10aXjTnew8QtYQmLjzn974BnmWEAJgCY6ZP1DeQ==} - - streamx@2.16.1: - resolution: {integrity: sha512-m9QYj6WygWyWa3H1YY69amr4nVgy61xfjys7xO7kviL5rfIEc2naf+ewFiOA+aEJD7y0JO3h2GoiUv4TDwEGzQ==} + streamx@2.20.1: + resolution: {integrity: sha512-uTa0mU6WUC65iUvzKH4X9hEdvSW7rbPxPtwfWiLMSj3qTdQbAiUboZTxauKfpFuGIGa1C2BYijZ7wgdUXICJhA==} strict-uri-encode@1.1.0: resolution: {integrity: sha512-R3f198pcvnB+5IpnBlRkphuE9n46WyVl8I39W/ZUTZLz4nqSP/oLYUrcnJrw462Ds8he4YKMov2efsTIw1BDGQ==} @@ -7161,6 +6914,10 @@ packages: string-format@2.0.0: resolution: {integrity: sha512-bbEs3scLeYNXLecRRuk6uJxdXUSj6le/8rNPHChIJTn2V79aXVTR1EH2OH5zLKKoz0V02fOUKZZcw01pLUShZA==} + string-width@2.1.1: + resolution: {integrity: sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==} + engines: {node: '>=4'} + string-width@3.1.0: resolution: {integrity: sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==} engines: {node: '>=6'} @@ -7173,22 +6930,20 @@ packages: resolution: {integrity: sha512-HnLOCR3vjcY8beoNLtcjZ5/nxn2afmME6lhrDrebokqMap+XbeW8n9TXpPDOqdGK5qcI3oT0GKTW6wC7EMiVqA==} engines: {node: '>=12'} - string-width@7.1.0: - resolution: {integrity: sha512-SEIJCWiX7Kg4c129n48aDRwLbFb2LJmXXFrWBG4NGaRtMQ3myKPKbwrD1BKqQn74oCoNMBVrfDEr5M9YxCsrkw==} + string-width@7.2.0: + resolution: {integrity: sha512-tsaTIkKW9b4N+AEj+SVA+WhJzV7/zMhcSu78mLKWSk7cXMOSHsBKFWUs0fWwq8QyK3MgJBQRX6Gbi4kYbdvGkQ==} engines: {node: '>=18'} - string.prototype.trim@1.2.8: - resolution: {integrity: sha512-lfjY4HcixfQXOfaqCvcBuOIapyaroTXhbkfJN3gcB1OtyupngWK4sEET9Knd0cXd28kTUqu/kHoV4HKSJdnjiQ==} + string.prototype.trim@1.2.9: + resolution: {integrity: sha512-klHuCNxiMZ8MlsOihJhJEBJAiMVqU3Z2nEXWfWnIqjN0gEFS9J9+IxKozWWtQGcgoa1WUZzLjKPTr4ZHNFTFxw==} engines: {node: '>= 0.4'} - string.prototype.trimend@1.0.7: - resolution: {integrity: sha512-Ni79DqeB72ZFq1uH/L6zJ+DKZTkOtPIHovb3YZHQViE+HDouuU4mBrLOLDn5Dde3RF8qw5qVETEjhu9locMLvA==} + string.prototype.trimend@1.0.8: + resolution: {integrity: sha512-p73uL5VCHCO2BZZ6krwwQE3kCzM7NKmis8S//xEC6fQonchbum4eP6kR4DLEjQFO3Wnj3Fuo8NM0kOSjVdHjZQ==} - string.prototype.trimstart@1.0.7: - resolution: {integrity: sha512-NGhtDFu3jCEm7B4Fy0DpLewdJQOZcQ0rGbwQ/+stjnrp2i+rlKeCvos9hOIeCmqwratM47OBxY7uFZzjxHXmrg==} - - string_decoder@0.10.31: - resolution: {integrity: sha512-ev2QzSzWPYmy9GuqfIVildA4OdcGLeFZQrq5ys6RtiuF+RQQiZWr8TZNyAcuVXyQRYfEO+MsoB/1BuQVhOJuoQ==} + string.prototype.trimstart@1.0.8: + resolution: {integrity: sha512-UXSH262CSZY1tfu3G3Secr6uGLCFVPMhIqHjlgCUtCCcgihYc/xKs9djMTMUOb2j1mVSeU8EU6NWc/iQKU6Gfg==} + engines: {node: '>= 0.4'} string_decoder@1.1.1: resolution: {integrity: sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==} @@ -7200,6 +6955,10 @@ packages: resolution: {integrity: sha512-VhumSSbBqDTP8p2ZLKj40UjBCV4+v8bUSEpUb4KjRgWk9pbqGF4REFj6KEagidb2f/M6AzC0EmFyDNGaw9OCzg==} engines: {node: '>=0.10.0'} + strip-ansi@4.0.0: + resolution: {integrity: sha512-4XaJ2zQdCzROZDivEVIDPkcQn8LMFSa8kj8Gxb/Lnwzv9A8VctNZ+lfivC/sV3ivW8ElJTERXZoPBRrZKkNKow==} + engines: {node: '>=4'} + strip-ansi@5.2.0: resolution: {integrity: sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==} engines: {node: '>=6'} @@ -7225,13 +6984,9 @@ packages: engines: {node: '>=0.10.0'} strip-hex-prefix@1.0.0: - resolution: {integrity: sha1-DF8VX+8RUTczd96du1iNoFUA428=} + resolution: {integrity: sha512-q8d4ue7JGEiVcypji1bALTos+0pWtyGlivAWyPuTkHzuTCJqrK9sWxYQZUq6Nq3cuyv3bm734IhHvHtGGURU6A==} engines: {node: '>=6.5.0', npm: '>=3'} - strip-indent@3.0.0: - resolution: {integrity: sha512-laJTa3Jb+VQpaC6DseHhF7dXVqHTfJPCRDaEbid/drOhgitgYku/letMUqOXFoWV0zIIUbjpdH2t+tYj4bQMRQ==} - engines: {node: '>=8'} - strip-json-comments@3.1.1: resolution: {integrity: sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==} engines: {node: '>=8'} @@ -7239,14 +6994,14 @@ packages: strnum@1.0.5: resolution: {integrity: sha512-J8bbNyKKXl5qYcR36TIO8W3mVGVHrmmxsd5PAItGkmyzwJvybiw2IVq5nqd0i4LSNSkB/sx9VHllbfFdr9k1JA==} - superstruct@1.0.3: - resolution: {integrity: sha512-8iTn3oSS8nRGn+C2pgXSKPI3jmpm6FExNazNpjvqS6ZUJQCej3PUXEKM8NjHBOs54ExM+LPW/FBRhymrdcCiSg==} - engines: {node: '>=14.0.0'} - supertap@3.0.1: resolution: {integrity: sha512-u1ZpIBCawJnO+0QePsEiOknOfCRq0yERxiAchT0i4li0WHNUJbf0evXXSXOcCAR4M8iMDoajXYmstm/qO81Isw==} engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} + supports-color@3.2.3: + resolution: {integrity: sha512-Jds2VIYDrlp5ui7t8abHN2bjAu4LV/q4N2KivFPpGH0lrka0BMq/33AmECUXlKPcHigkNaqfXRENFju+rlcy+A==} + engines: {node: '>=0.8.0'} + supports-color@5.5.0: resolution: {integrity: sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==} engines: {node: '>=4'} @@ -7274,20 +7029,31 @@ packages: resolution: {integrity: sha512-e900nM8RRtGhlV36KGEU9k65K3mPb1WV70OdjfxlG2EAuM1noi/E/BaW/uMhL7bPEssK8QV57vN3esixjUvcXQ==} engines: {node: '>=0.10.0'} - synckit@0.8.8: - resolution: {integrity: sha512-HwOKAP7Wc5aRGYdKH+dw0PRRpbO841v2DENBtjnR5HFWoiNByAl7vrx3p0G/rCyYXQsrxqtX48TImFtPcIHSpQ==} + sync-request@6.1.0: + resolution: {integrity: sha512-8fjNkrNlNCrVc/av+Jn+xxqfCjYaBoHqCsDz6mt030UMxJGr+GSfCV1dQt2gRtlL63+VPidwDVLr7V2OcTSdRw==} + engines: {node: '>=8.0.0'} + + sync-rpc@1.3.6: + resolution: {integrity: sha512-J8jTXuZzRlvU7HemDgHi3pGnh/rkoqR/OZSjhTyyZrEkkYQbk7Z33AXp37mkPfPpfdOuj7Ex3H/TJM1z48uPQw==} + + synckit@0.9.2: + resolution: {integrity: sha512-vrozgXDQwYO72vHjUb/HnFbQx1exDjoKzqx23aXEg2a9VIg2TSFZ8FmeZpTjUCFMYw7mpX4BE2SFu8wI7asYsw==} engines: {node: ^14.18.0 || >=16.0.0} table-layout@1.0.2: resolution: {integrity: sha512-qd/R7n5rQTRFi+Zf2sk5XVVd9UQl6ZkduPFC3S7WEGJAmetDTjY3qPN50eSKzwuzEyQKy5TN2TiZdkIjos2L6A==} engines: {node: '>=8.0.0'} + table@6.8.2: + resolution: {integrity: sha512-w2sfv80nrAh2VCbqR5AK27wswXhqcck2AhfnNW76beQXskGZ1V12GwS//yYVa3d3fcvAip2OUnbDAjW2k3v9fA==} + engines: {node: '>=10.0.0'} + tapable@2.2.1: resolution: {integrity: sha512-GNzQvQTOIP6RyTfE2Qxb8ZVlNmw0n88vp1szwWRimP02mnTsx3Wtn5qRdqY9w2XduFNUgvOwhNnQsjwCp+kqaQ==} engines: {node: '>=6'} - tar-fs@3.0.4: - resolution: {integrity: sha512-5AFQU8b9qLfZCX9zp2duONhPmZv0hGYiBPJsyUdqMjzq/mqVpy/rEUSeHk1+YitmxugaptgBh5oDGU3VsAJq4w==} + tar-fs@3.0.6: + resolution: {integrity: sha512-iokBDQQkUyeXhgPYaZxmczGPhnhXZ0CmrqI+MOb/WFGS9DW5wnfrLgtjUJBvz50vQ3qfRwJ62QVoCFu8mPVu5w==} tar-stream@3.1.7: resolution: {integrity: sha512-qJj60CXt7IU1Ffyc3NJMjh6EkuCFej46zUqJ4J7pqYlThyd9bO0XBTmcOIhSzZJVWfsLks0+nle/j538YAW9RQ==} @@ -7296,8 +7062,8 @@ packages: resolution: {integrity: sha512-a20gEsvHnWe0ygBY8JbxoM4w3SJdhc7ZAuxkLqh+nvNQN2IOt0B5lLgM490X5Hl8FF0dl0tOf2ewFYAlIFgzVA==} engines: {node: '>=4.5'} - tar@6.2.0: - resolution: {integrity: sha512-/Wo7DcT0u5HUV486xg675HtjNd3BXZ6xDbzsCUZPt5iw8bTQ63bP0Raut3mvro9u+CUyq7YQd8Cx55fsZXxqLQ==} + tar@6.2.1: + resolution: {integrity: sha512-DZ4yORTwrbTj/7MZYq2w+/ZFdI6OZ/f9SFHR+71gIVUZhOQPHzVCLpvRnPgyaMpfWxxk/4ONva3GQSyNIKRv6A==} engines: {node: '>=10'} temp-dir@3.0.0: @@ -7324,8 +7090,8 @@ packages: uglify-js: optional: true - terser@5.28.1: - resolution: {integrity: sha512-wM+bZp54v/E9eRRGXb5ZFDvinrJIOaTapx3WUokyVGZu5ucVCK55zEgGd5Dl2fSr3jUo5sDiERErUWLY6QPFyA==} + terser@5.36.0: + resolution: {integrity: sha512-IYV9eNMuFAV4THUspIRXkLakHnV6XO7FEdtKjf/mDyrnqUg9LnlOn6/RwRvM9SZjR4GUq8Nk8zj67FzVARr74w==} engines: {node: '>=10'} hasBin: true @@ -7333,13 +7099,19 @@ packages: resolution: {integrity: sha512-cAGWPIyOHU6zlmg88jwm7VRyXnMN7iV68OGAbYDk/Mh/xC/pzVPlQtY6ngoIH/5/tciuhGfvESU8GrHrcxD56w==} engines: {node: '>=8'} - test-value@2.1.0: - resolution: {integrity: sha512-+1epbAxtKeXttkGFMTX9H42oqzOTufR1ceCF+GYA5aOmvaPq9wd4PUS8329fn2RRLGNeUkgRLnVpycjx8DsO2w==} - engines: {node: '>=0.10.0'} + text-decoder@1.2.1: + resolution: {integrity: sha512-x9v3H/lTKIJKQQe7RPQkLfKAnc9lUTkWDypIQgTzPJAq+5/GCDHonmshfvlsNSj58yyshbIJJDLmU15qNERrXQ==} text-table@0.2.0: resolution: {integrity: sha512-N+8UisAXDGk8PFXP4HAzVR9nbfmVJ3zYLAWiTIoqC5v5isinhr+r5uaO8+7r3BMfuNIufIsA7RdpVgacC2cSpw==} + then-request@6.0.2: + resolution: {integrity: sha512-3ZBiG7JvP3wbDzA9iNY5zJQcHL4jn/0BWtXIkagfz7QgOL/LqjCEOBQuJNZfu0XYnv5JhKh+cDxCPM4ILrqruA==} + engines: {node: '>=6.0.0'} + + through2@4.0.2: + resolution: {integrity: sha512-iOqSav00cVxEEICeD7TjLB1sueEL+81Wpzp2bY17uZjZN0pWZPuo4suZ/61VujxmqSGFfgOcNuTZ85QJwNZQpw==} + through@2.3.8: resolution: {integrity: sha512-w89qg7PI8wAdvX60bMDP+bFoD5Dvhm9oLheFp5O4a2QF0cSBGsBX4qZmadPMvVqlLJBBci+WqGGOAPvcDeNSVg==} @@ -7358,10 +7130,6 @@ packages: resolution: {integrity: sha512-jRCJlojKnZ3addtTOjdIqoRuPEKBvNXcGYqzO6zWZX8KfKEpnGY5jfggJQ3EjKuu8D4bJRr0y+cYJFmYbImXGw==} engines: {node: '>=0.6.0'} - to-fast-properties@2.0.0: - resolution: {integrity: sha512-/OaKK0xYrs3DmxRYqL/yDc+FxFUVYhDlXMhRmv3z915w2HF1tnN1omB354j8VUGO/hbRzyD6Y3sA7v7GS/ceog==} - engines: {node: '>=4'} - to-object-path@0.3.0: resolution: {integrity: sha512-9mWHdnGRuh3onocaHzukyvCZhzvr6tiflAy/JRFXcJX0TjgfWA9pk9t8CMbzmBE4Jfw58pXbkngtBtqYxzNEyg==} engines: {node: '>=0.10.0'} @@ -7386,10 +7154,6 @@ packages: resolution: {integrity: sha512-nlLsUzgm1kfLXSXfRZMc1KLAugd4hqJHDTvc2hDIwS3mZAfMEuMbc03SujMF+GEcpaX/qboeycw6iO8JwVv2+g==} engines: {node: '>=0.8'} - tough-cookie@4.1.3: - resolution: {integrity: sha512-aX/y5pVRkfRnfmuX+OdbSdXvPe6ieKX/G2s7e98f4poJHnqH3281gDPm/metm6E/WRamfx7WC4HUqkWHfQHprw==} - engines: {node: '>=6'} - tr46@0.0.3: resolution: {integrity: sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw==} @@ -7401,12 +7165,8 @@ packages: resolution: {integrity: sha512-L0Orpi8qGpRG//Nd+H90vFB+3iHnue1zSSGmNOOCh1GLJ7rUKVwV2HvijphGQS2UmhUZewS9VgvxYIdgr+fG1A==} hasBin: true - trim-newlines@3.0.1: - resolution: {integrity: sha512-c1PTsA3tYrIsLGkJkzHF+w9F2EyxfXGo4UyJc4pFL++FMjnq0HJS69T3M7d//gKrFKwy429bouPescbjecU+Zw==} - engines: {node: '>=8'} - - ts-api-utils@1.2.1: - resolution: {integrity: sha512-RIYA36cJn2WiH9Hy77hdF9r7oEwxAtB/TS9/S4Qd90Ap4z5FSiin5zEiTL44OII1Y3IIlEvxwxFUVgrHSZ/UpA==} + ts-api-utils@1.3.0: + resolution: {integrity: sha512-UQMIo7pb8WRomKR1/+MFVLTroIvDVtMX3K6OUir8ynLyzB8Jeriont2bTAtmNPa1ekAgN7YPDyf6V+ygrdU+eQ==} engines: {node: '>=16'} peerDependencies: typescript: '>=4.2.0' @@ -7440,22 +7200,20 @@ packages: tslib@1.14.1: resolution: {integrity: sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg==} - tslib@2.6.2: - resolution: {integrity: sha512-AEYxH93jGFPn/a2iVAwW87VuUIkR1FVUKB77NwMF7nBTDkDrrT/Hpt/IrCJ0QXhW27jTBDcf5ZY7w6RiqTMw2Q==} + tslib@2.7.0: + resolution: {integrity: sha512-gLXCKdN1/j47AiHiOkJN69hJmcbGTHI0ImLmbYLHykhgeN0jVGola9yVjFgzCUklsZQMW55o+dW7IXv3RCXDzA==} + + tslib@2.8.0: + resolution: {integrity: sha512-jWVzBLplnCmoaTr13V9dYbiQ99wvZRd0vNWaDRg+aVYRcjDF3nDksxFDE/+fkXnKhpnUUkmx5pK/v8mCtLVqZA==} tsort@0.0.1: - resolution: {integrity: sha1-4igPXoF/i/QnVlf9D5rr1E9aJ4Y=} + resolution: {integrity: sha512-Tyrf5mxF8Ofs1tNoxA13lFeZ2Zrbd6cKbuH3V+MQ5sb6DtBj5FjrXVsRWT8YvNAQTqNoz66dz1WsbigI22aEnw==} - tsx@4.7.1: - resolution: {integrity: sha512-8d6VuibXHtlN5E3zFkgY8u4DX7Y3Z27zvvPKVmLon/D4AjuKzarkUBTLDBgj9iTQ0hg5xM7c/mYiRVM+HETf0g==} + tsx@4.19.1: + resolution: {integrity: sha512-0flMz1lh74BR4wOvBjuh9olbnwqCPc35OOlfyzHba0Dc+QNUeWX/Gq2YTbnwcWPO3BMd8fkzRVrHcsR+a7z7rA==} engines: {node: '>=18.0.0'} hasBin: true - tty-table@4.2.3: - resolution: {integrity: sha512-Fs15mu0vGzCrj8fmJNP7Ynxt5J7praPXqFN0leZeZBXJwkMxv9cb2D454k1ltrtUSJbZ4yH4e0CynsHLxmUfFA==} - engines: {node: '>=8.0.0'} - hasBin: true - tunnel-agent@0.6.0: resolution: {integrity: sha512-McnNiV1l8RYeY8tBgEpuodCC1mLUdbSN+CYBL7kJsJNInOP8UjDDEwdk6Mw60vdLLrr5NHKZhMAOSrR2NZuQ+w==} @@ -7468,12 +7226,16 @@ packages: tweetnacl@1.0.3: resolution: {integrity: sha512-6rt+RN7aOi1nGMyC4Xa5DdYiukl2UWCbcJft7YhxReBGQD7OAM8Pbxw6YMo4r2diNEA8FEmu32YOn9rhaiE5yw==} + type-check@0.3.2: + resolution: {integrity: sha512-ZCmOJdvOWDBYJlzAoFkC+Q0+bUyEOS1ltgp1MGU03fqHG+dbi9tBFU2Rd9QKiDZFAYrhPh2JUf7rZRIuHRKtOg==} + engines: {node: '>= 0.8.0'} + type-check@0.4.0: resolution: {integrity: sha512-XleUoc9uwGXqjWwXaUTZAmzMcFZ5858QA2vvx1Ur5xIcixXIP+8LnFDgRplU30us6teqdlskFfu+ae4K79Ooew==} engines: {node: '>= 0.8.0'} - type-detect@4.0.8: - resolution: {integrity: sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g==} + type-detect@4.1.0: + resolution: {integrity: sha512-Acylog8/luQ8L7il+geoSxhEkazvkslg7PSNKOX59mbB9cOveP5aq9h74Y7YU8yDpJwetzQQrfIwtf4Wp4LKcw==} engines: {node: '>=4'} type-fest@0.13.1: @@ -7488,10 +7250,6 @@ packages: resolution: {integrity: sha512-t0rzBq87m3fVcduHDUFhKmyyX+9eo6WQjZvf51Ea/M0Q7+T374Jp1aUiyUl0GKxp8M/OETVHSDvmkyPgvX+X2w==} engines: {node: '>=10'} - type-fest@0.6.0: - resolution: {integrity: sha512-q+MB8nYR1KDLrgr4G5yemftpMC7/QLqVndBmEEdqzmNj5dcFOO4Oo8qlwZE3ULT3+Zim1F8Kq4cBnikNhlCMlg==} - engines: {node: '>=8'} - type-fest@0.7.1: resolution: {integrity: sha512-Ne2YiiGN8bmrmJJEuTWTLJR32nh/JdL1+PSicowtNb0WFpn59GK8/lfD61bVtzguz7b3PBt74nxpv/Pw5po5Rg==} engines: {node: '>=8'} @@ -7504,17 +7262,8 @@ packages: resolution: {integrity: sha512-TkRKr9sUTxEH8MdfuCSP7VizJyzRNMjj2J2do2Jr3Kym598JVdEksuzPQCnlFPW4ky9Q+iA+ma9BGm06XQBy8g==} engines: {node: '>= 0.6'} - type@1.2.0: - resolution: {integrity: sha512-+5nt5AAniqsCnu2cEQQdpzCAh33kVx8n0VoFidKpB1dVVLAN/F+bgVOqOJqOnEnrhp222clB5p3vUlD+1QAnfg==} - - type@2.7.2: - resolution: {integrity: sha512-dzlvlNlt6AXU7EBSfpAscydQ7gXB+pPGsPnfJnZpiNJBDj7IaJzQlBZYGdEi4R9HmPdBv2XmWJ6YUtoTa7lmCw==} - - typechain@5.2.0: - resolution: {integrity: sha512-0INirvQ+P+MwJOeMct+WLkUE4zov06QxC96D+i3uGFEHoiSkZN70MKDQsaj8zkL86wQwByJReI2e7fOUwECFuw==} - hasBin: true - peerDependencies: - typescript: '>=4.1.0' + type@2.7.3: + resolution: {integrity: sha512-8j+1QmAbPvLZow5Qpi6NCaN8FB60p/6x8/vfNqOk/hC+HuvFZhL4+WfekuhQLiqFZXOgQdrs3B+XxEmCc6b3FQ==} typechain@8.3.2: resolution: {integrity: sha512-x/sQYr5w9K7yv3es7jo4KTX05CLxOf7TRWwoHlrjRh8H82G64g+k7VuWPJlgMo6qrjfCulOdfBjiaDtmhFYD/Q==} @@ -7534,19 +7283,25 @@ packages: resolution: {integrity: sha512-Ous0vodHa56FviZucS2E63zkgtgrACj7omjwd/8lTEMEPFFyjfixMZ1ZXenpgCFBBt4EC1J2XsyVS2gkG0eTFA==} engines: {node: '>= 0.4'} - typed-array-length@1.0.5: - resolution: {integrity: sha512-yMi0PlwuznKHxKmcpoOdeLwxBoVPkqZxd7q2FgMkmD3bNwvF5VW0+UlUQ1k1vmktTu4Yu13Q0RIxEP8+B+wloA==} + typed-array-length@1.0.6: + resolution: {integrity: sha512-/OxDN6OtAk5KBpGb28T+HZc2M+ADtvRxXrKKbUwtsLgdoxgX13hyy7ek6bFRl5+aBs2yZzB0c4CnQfAtVypW/g==} engines: {node: '>= 0.4'} typed-error@3.2.2: resolution: {integrity: sha512-Z48LU67/qJ+vyA7lh3ozELqpTp3pvQoY5RtLi5wQ/UGSrEidBhlVSqhjr8B3iqbGpjqAoJYrtSYXWMDtidWGkA==} engines: {node: '>=6.0.0', npm: '>=3.0.0'} + typed-query-selector@2.12.0: + resolution: {integrity: sha512-SbklCd1F0EiZOyPiW192rrHZzZ5sBijB6xM+cpmrwDqObvdtunOHHIk9fCGsoK5JVIYXoyEp4iEdE3upFH3PAg==} + typedarray-to-buffer@3.1.5: resolution: {integrity: sha512-zdu8XMNEDepKKR+XYOXAVPtWui0ly0NtohUscw+UmaHiAWT8hrV1rr//H6V+0DvJ3OQ19S979M0laLfX8rm82Q==} - typescript@5.3.3: - resolution: {integrity: sha512-pXWcraxM0uxAS+tN0AG/BF2TyqmHO014Z070UsJ+pFvYuRSq8KH8DmWpnbXe0pEPDHXZV3FcAbJkijJ5oNEnWw==} + typedarray@0.0.6: + resolution: {integrity: sha512-/aCDEGatGvZ2BIk+HmLf4ifCJFwvKFNb9/JeZPMulfgFracn9QFcAf5GO8B/mweUjSoblS5In0cWhqpfs/5PQA==} + + typescript@5.6.3: + resolution: {integrity: sha512-hjcS1mhfuyi4WW8IWtjP7brDrG2cuDZukyrYrSauoXGNgx0S7zceP07adYkJycEr56BOUTNPzbInooiN3fn1qw==} engines: {node: '>=14.17'} hasBin: true @@ -7558,9 +7313,6 @@ packages: resolution: {integrity: sha512-6FTtyGr8ldU0pfbvW/eOZrEtEkczHRUtduBnA90Jh9kMPCiFNnXIon3vF41N0S4tV1HHQt4Hk1j4srpESziCaA==} engines: {node: '>=0.1.14'} - typical@2.6.1: - resolution: {integrity: sha512-ofhi8kjIje6npGozTip9Fr8iecmYfEbS06i0JnIg+rh51KakryWF4+jX8lLKZVhy6N+ID45WYSFCxPOdTWCzNg==} - typical@4.0.0: resolution: {integrity: sha512-VAH4IvQ7BDFYglMd7BPRDfLgxZZX4O4TFcRDA6EN5X7erNJJq+McIEp8np9aVtxrCJ6qx4GTYVfOWNjcqwZgRw==} engines: {node: '>=8'} @@ -7569,6 +7321,11 @@ packages: resolution: {integrity: sha512-dvdQgNDNJo+8B2uBQoqdb11eUCE1JQXhvjC/CZtgvZseVd5TYMXnq0+vuUemXbd/Se29cTaUuPX3YIc2xgbvIg==} engines: {node: '>=8'} + uglify-js@3.19.3: + resolution: {integrity: sha512-v3Xu+yuwBXisp6QYTcH4UbH+xYJXqnq2m/LtQVWKWzYc1iehYnLixoQDN9FH6/j9/oybfd6W9Ghwkl8+UMKTKQ==} + engines: {node: '>=0.8.0'} + hasBin: true + ultron@1.1.1: resolution: {integrity: sha512-UIEXBNeYmKptWH6z8ZnqTeS8fV74zG0/eRU9VGkpzz+LIJNs8W/zM/L+7ctCkRrgbNnnR0xxw4bKOr0cW0N0Og==} @@ -7578,23 +7335,23 @@ packages: unbzip2-stream@1.4.3: resolution: {integrity: sha512-mlExGW4w71ebDJviH16lQLtZS32VKqsSfk80GCfUlwT/4/hNRFsoscrF/c++9xinkMzECL1uL9DDwXqFWkruPg==} - undici-types@5.26.5: - resolution: {integrity: sha512-JlCMO+ehdEIKqlFxk6IfVoAUVmgz7cU7zD/h9XZ0qzeosSHmUJVOzSQvvYSYWXkFXC+IfLKSIffhv0sVZup6pA==} + undici-types@6.19.8: + resolution: {integrity: sha512-ve2KP6f/JnbPBFyobGHuerC9g1FYGn/F8n1LWTwNxCEzd6IfqTwUQcNXgEtmmQ6DlRrC1hrSrBnCZPokRrDHjw==} - undici@5.28.3: - resolution: {integrity: sha512-3ItfzbrhDlINjaP0duwnNsKpDQk3acHI3gVJ1z4fmwMK31k5G9OVIAMLSIaP6w4FaGkaAkN6zaQO9LUvZ1t7VA==} + undici@5.28.4: + resolution: {integrity: sha512-72RFADWFqKmUb2hmmvNODKL3p9hcB6Gt2DOQMis1SEBaV6a4MH8soBvzg+95CYhCKPFedut2JY9bMfrDl9D23g==} engines: {node: '>=14.0'} - unicode-canonical-property-names-ecmascript@2.0.0: - resolution: {integrity: sha512-yY5PpDlfVIU5+y/BSCxAJRBIS1Zc2dDG3Ujq+sR0U+JjUevW2JhocOF+soROYDSaAezOzOKuyyixhD6mBknSmQ==} + unicode-canonical-property-names-ecmascript@2.0.1: + resolution: {integrity: sha512-dA8WbNeb2a6oQzAQ55YlT5vQAWGV9WXOsi3SskE3bcCdM0P4SDd+24zS/OCacdRq5BkdsRj9q3Pg6YyQoxIGqg==} engines: {node: '>=4'} unicode-match-property-ecmascript@2.0.0: resolution: {integrity: sha512-5kaZCrbp5mmbz5ulBkDkbY0SsPOjKqVS35VpL9ulMPfSl0J0Xsm+9Evphv9CoIZFwre7aJoa94AY6seMKGVN5Q==} engines: {node: '>=4'} - unicode-match-property-value-ecmascript@2.1.0: - resolution: {integrity: sha512-qxkjQt6qjg/mYscYMC0XKRn3Rh0wFPlfxB0xkt9CfyTvpX1Ra0+rAmdX2QyAobptSEvuy4RtpPRui6XkV+8wjA==} + unicode-match-property-value-ecmascript@2.2.0: + resolution: {integrity: sha512-4IehN3V/+kkr5YeSSDDQG8QLqO26XpL2XP3GQtqwlT/QYSECAwFztxVHjlbh0+gjJ3XmNLS0zDsbgs9jWKExLg==} engines: {node: '>=4'} unicode-property-aliases-ecmascript@2.1.0: @@ -7613,10 +7370,6 @@ packages: resolution: {integrity: sha512-rBJeI5CXAlmy1pV+617WB9J63U6XcazHHF2f2dbJix4XzpUF0RS3Zbj0FGIOCAva5P/d/GBOYaACQ1w+0azUkg==} engines: {node: '>= 4.0.0'} - universalify@0.2.0: - resolution: {integrity: sha512-CJ1QgKmNg3CwvAv/kOFmtnEN05f0D/cn9QntgNOQlQF9dgvVTHj3t+8JPdjqawCHk7V/KA+fbUqzZ9XWhcqPUg==} - engines: {node: '>= 4.0.0'} - universalify@2.0.1: resolution: {integrity: sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw==} engines: {node: '>= 10.0.0'} @@ -7633,8 +7386,8 @@ packages: resolution: {integrity: sha512-aZwGpamFO61g3OlfT7OQCHqhGnW43ieH9WZeP7QxN/G/jS4jfqUkZxoryvJgVPEcrl5NL/ggHsSmLMHuH64Lhg==} engines: {node: '>=4'} - update-browserslist-db@1.0.13: - resolution: {integrity: sha512-xebP81SNcPuNpPP3uzeW1NYXxI3rxyJzF3pD6sH4jE7o/IX+WtSpwnVU+qIsDPyk0d3hmFQ7mjqc6AtV604hbg==} + update-browserslist-db@1.1.1: + resolution: {integrity: sha512-R8UzCaa9Az+38REPiJ1tXlImTJXlVfgHZsglwBD/k6nj76ctsH1E3q4doGrukiLQd3sGQYu56r5+lo5r94l29A==} hasBin: true peerDependencies: browserslist: '>= 4.21.0' @@ -7652,12 +7405,16 @@ packages: url-set-query@1.0.0: resolution: {integrity: sha512-3AChu4NiXquPfeckE5R5cGdiHCMWJx1dwCWOmWIL4KHAziJNOFIYJlpGFeKDvwLPHovZRCxK3cYlwzqI9Vp+Gg==} - url@0.11.3: - resolution: {integrity: sha512-6hxOLGfZASQK/cijlZnZJTq8OXAkt/3YGfQX45vvMYXpZoo8NdWZcY73K108Jf759lS1Bv/8wXnHDTSz17dSRw==} + url@0.11.4: + resolution: {integrity: sha512-oCwdVC7mTuWiPyjLUz/COz5TLk6wgp0RCsN+wHZ2Ekneac9w8uuV0njcbbie2ME+Vs+d6duwmYuR3HgQXs1fOg==} + engines: {node: '>= 0.4'} urlpattern-polyfill@10.0.0: resolution: {integrity: sha512-H/A06tKD7sS1O1X2SshBVeA5FLycRpjqiBeqGKmBwBDBy28EnRjORxTNe269KSSr5un5qyWi1iL61wLxpd+ZOg==} + urlpattern-polyfill@8.0.2: + resolution: {integrity: sha512-Qp95D4TPJl1kC9SKigDcqgyM2VDVO4RiJc2d4qe5GrYm+zbIQCWWKAFaJNQ4BhdFeDGwBmAxqJBwWSJDb9T3BQ==} + use@3.1.1: resolution: {integrity: sha512-cwESVXlO3url9YWlFW/TA9cshCEhtu7IKJ/p5soJ/gGpj7vbvFrAY/eIioQ6Dw23KjZhYgiIo8HOs1nQ2vr/oQ==} engines: {node: '>=0.10.0'} @@ -7709,9 +7466,6 @@ packages: v8-compile-cache@2.4.0: resolution: {integrity: sha512-ocyWc3bAHBB/guyqJQVI5o4BZkPhznPYUG2ea80Gond/BgNWpap8TOmLSeeQG7bnh2KMISxskdADG59j7zruhw==} - validate-npm-package-license@3.0.4: - resolution: {integrity: sha512-DpKm2Ui/xN7/HQKCtpZxoRWBhZ9Z0kqtygG8XCgNQ8ZlDnxuQmWhj566j8fN4Cu3/JmbhsDo7fcAJq4s9h27Ew==} - value-or-promise@1.0.11: resolution: {integrity: sha512-41BrgH+dIbCFXClcSapVs5M6GkENd3gQOJpEfPDNa71LsUGMXDL0jMWpI/Rh7WhX+Aalfz2TTS3Zt5pUsbnhLg==} engines: {node: '>=12'} @@ -7727,21 +7481,18 @@ packages: resolution: {integrity: sha512-ZZKSmDAEFOijERBLkmYfJ+vmk3w+7hOLYDNkRCuRuMJGEmqYNCNLyBBFwWKVMhfwaEF3WOd0Zlw86U/WC/+nYw==} engines: {'0': node >=0.6.0} - wait-on@7.2.0: - resolution: {integrity: sha512-wCQcHkRazgjG5XoAq9jbTMLpNIjoSlZslrJ2+N9MxDsGEv1HnFoVjOCexL0ESva7Y9cu350j+DWADdk54s4AFQ==} + wait-on@8.0.1: + resolution: {integrity: sha512-1wWQOyR2LVVtaqrcIL2+OM+x7bkpmzVROa0Nf6FryXkS+er5Sa1kzFGjzZRqLnHa3n1rACFLeTwUqE1ETL9Mig==} engines: {node: '>=12.0.0'} hasBin: true - watchpack@2.4.0: - resolution: {integrity: sha512-Lcvm7MGST/4fup+ifyKi2hjyIAwcdI4HRgtvTpIUxBRhB+RFtUh8XtDOxUfctVCnhVi+QQj49i91OyvzkJl6cg==} + watchpack@2.4.2: + resolution: {integrity: sha512-TnbFSbcOCcDgjZ4piURLCbJ3nJhznVh9kw6F6iokjiFPl8ONxe9A6nMDVXDiNbrSfLILs6vB07F7wLBrwPYzJw==} engines: {node: '>=10.13.0'} wbuf@1.7.3: resolution: {integrity: sha512-O84QOnr0icsbFGLS0O3bI5FswxzRr8/gHwWkDlQFskhSPryQXvrTMxjxGP4+iWYoauLoBvfDpkrOauZ+0iZpDA==} - wcwidth@1.0.1: - resolution: {integrity: sha512-XHPEwS0q6TaxcvG85+8EYkbiCux2XtWG2mkc47Ng2A77BQu9+DqIOJldST4HgPkuea7dvKSj5VgX3P1d4rW8Tg==} - web3-bzz@1.10.4: resolution: {integrity: sha512-ZZ/X4sJ0Uh2teU9lAGNS8EjveEppoHNQiKlOXAjedsrdWuaMErBPdLQjXfcrYvN6WM6Su9PMsAxf3FXXZ+HwQw==} engines: {node: '>=8.0.0'} @@ -7802,10 +7553,6 @@ packages: resolution: {integrity: sha512-mKINnhOOnZ4koA+yV2OT5s5ztVjIx7IY9a03w6s+yao/BUn+Luuty0/keNemZxTr1E8Ehvtn28vbOtW7Ids+Ow==} engines: {node: '>=8.0.0'} - web3-provider-engine@16.0.7: - resolution: {integrity: sha512-I/3809UDA0LpGlBGGulalrKO4zFWPQIgOMwgt717sXlKVXW4cRPZZgO8gPbnOq9PotOuV89dYDse0ClLqw+kcA==} - engines: {node: '>=12.0.0'} - web3-providers-http@1.10.4: resolution: {integrity: sha512-m2P5Idc8hdiO0l60O6DSCPw0kw64Zgi0pMjbEFRmxKIck2Py57RQMu4bxvkxJwkF06SlGaEQF8rFZBmuX7aagQ==} engines: {node: '>=8.0.0'} @@ -7892,8 +7639,8 @@ packages: resolution: {integrity: sha512-/DyMEOrDgLKKIG0fmvtz+4dUX/3Ghozwgm6iPp8KRhvn+eQf9+Q7GWxVNMk3+uCPWfdXYC4ExGBckIXdFEfH1w==} engines: {node: '>=10.13.0'} - webpack@5.90.3: - resolution: {integrity: sha512-h6uDYlWCctQRuXBs1oYpVe6sFcWedl0dpcVaTf/YF67J9bKvwJajFulMVSYKHrksMB3I/pIagRzDxwxkebuzKA==} + webpack@5.95.0: + resolution: {integrity: sha512-2t3XstrKULz41MNMBF+cJ97TyHdyQ8HCt//pqErqDvNjU9YQBnZxIHa11VXsi7F3mb5/aO2tuDxdeTPdU7xu9Q==} engines: {node: '>=10.13.0'} hasBin: true peerDependencies: @@ -7910,8 +7657,8 @@ packages: resolution: {integrity: sha512-OqedPIGOfsDlo31UNwYbCFMSaO9m9G/0faIHj5/dZFDMFqPTcx6UwqyOy3COEaEOg/9VsGIpdqn62W5KhoKSpg==} engines: {node: '>=0.8.0'} - websocket@1.0.34: - resolution: {integrity: sha512-PRDso2sGwF6kM75QykIesBijKSVceR6jL2G8NGYyq2XrItNC2P5/qL5XeR056GhA+Ly7JMFvJb9I312mJfmqnQ==} + websocket@1.0.35: + resolution: {integrity: sha512-/REy6amwPZl44DDzvRCkaI1q1bIiQB0mEFQLUrhz3z2EK91cp3n72rAjUlrTP0zV22HJIUOVHQGPxhFRjxjt+Q==} engines: {node: '>=4.0.0'} well-known-symbols@2.0.0: @@ -7931,12 +7678,8 @@ packages: which-module@2.0.1: resolution: {integrity: sha512-iBdZ57RDvnOR9AGBhML2vFZf7h8vmBjhoaZqODJBFWHVtKkDmKuHai3cx5PgVMrX5YDNp27AofYbAwctSS+vhQ==} - which-pm@2.0.0: - resolution: {integrity: sha512-Lhs9Pmyph0p5n5Z3mVnN0yWcbQYUAD7rbQUiMsQxOJ3T57k7RFe35SUwWMf7dsbDZks1uOmw4AecB/JMDj3v/w==} - engines: {node: '>=8.15'} - - which-typed-array@1.1.14: - resolution: {integrity: sha512-VnXFiIW8yNn9kIHN88xvZ4yOWchftKDsRJ8fEPacX/wl1lOvBrhsJ/OeJCXq7B0AaijRuqgzSKalJoPk+D8MPg==} + which-typed-array@1.1.15: + resolution: {integrity: sha512-oV0jmFtUky6CXfkqehVvBP/LSWJ2sy4vWMioiENyJLePrBO/yKyV9OyJySfAKosh+RYkIl5zJCNZ8/4JncrpdA==} engines: {node: '>= 0.4'} which@1.3.1: @@ -7958,12 +7701,19 @@ packages: wildcard@2.0.1: resolution: {integrity: sha512-CC1bOL87PIWSBhDcTrdeLo6eGT7mCFtrg0uIJtqJUFyK+eJnzl8A1niH56uu7KMa5XFrtiV+AQuHO3n7DsHnLQ==} + word-wrap@1.2.5: + resolution: {integrity: sha512-BN22B5eaMMI9UMtjrGd5g5eCYPpCPDUy0FJXbYsaT5zYxjFOckS53SQDE3pWkVoWpHXVb3BrYcEN4Twa55B5cA==} + engines: {node: '>=0.10.0'} + + wordwrap@1.0.0: + resolution: {integrity: sha512-gvVzJFlPycKc5dZN4yPkP8w7Dc37BtP1yczEneOb4uq34pXZcvrtRTmWV8W+Ume+XCxKgbjM+nevkyFPMybd4Q==} + wordwrapjs@4.0.1: resolution: {integrity: sha512-kKlNACbvHrkpIw6oPeYDSmdCTu2hdMHoyXLTcUKala++lx5Y+wjJ/e474Jqv5abnVmwxw08DiTuHmw69lJGksA==} engines: {node: '>=8.0.0'} - workerpool@6.2.1: - resolution: {integrity: sha512-ILEIE97kDZvF9Wb9f6h5aXK4swSlKGUcOEGiIYb2OOu/IrDU9iwj0fD//SsA6E5ibwJxpEvhullJY4Sl4GcpAw==} + workerpool@6.5.1: + resolution: {integrity: sha512-Fs4dNYcsdpYSAfVxhnl1L5zTksjvOJxtC5hzMNl+1t9B8hTJTdKDyZ5ju7ztgPy+ft9tBFXoOlDNiOT9WUXZlA==} wrap-ansi@5.1.0: resolution: {integrity: sha512-QC1/iN/2/RPVJ5jYK8BGttj5z83LmSKmvbvrXPNCLZSEb32KKVDJDl/MOt2N01qU2H/FkzEa9PKto1BqDjtd7Q==} @@ -7994,7 +7744,7 @@ packages: ws@3.3.3: resolution: {integrity: sha512-nnWLa/NwZSt4KQJu51MYlCcSQ5g7INpOrOMt4XV8j4dqTXdmlUmSHQ8/oLC069ckre0fRsgfvsKwbTdtKLCDkA==} peerDependencies: - bufferutil: ^4.0.1 + bufferutil: ^4.0.8 utf-8-validate: ^5.0.2 peerDependenciesMeta: bufferutil: @@ -8002,10 +7752,10 @@ packages: utf-8-validate: optional: true - ws@6.2.2: - resolution: {integrity: sha512-zmhltoSR8u1cnDsD43TX59mzoMZsLKqUweyYBAIvTngR3shc0W6aOZylZmq/7hqyVxPdi+5Ud2QInblgyE72fw==} + ws@6.2.3: + resolution: {integrity: sha512-jmTjYU0j60B+vHey6TfR3Z7RD61z/hmxBS3VMSGIrroOWXQEneK1zNuotOUrGyBHQj0yrpsLHPWtigEFd13ndA==} peerDependencies: - bufferutil: ^4.0.1 + bufferutil: ^4.0.8 utf-8-validate: ^5.0.2 peerDependenciesMeta: bufferutil: @@ -8017,7 +7767,7 @@ packages: resolution: {integrity: sha512-YmhHDO4MzaDLB+M9ym/mDA5z0naX8j7SIlT8f8z+I0VtzsRbekxEutHSme7NPS2qE8StCYQNUnfWdXta/Yu85A==} engines: {node: '>=8.3.0'} peerDependencies: - bufferutil: ^4.0.1 + bufferutil: ^4.0.8 utf-8-validate: ^5.0.2 peerDependenciesMeta: bufferutil: @@ -8025,11 +7775,11 @@ packages: utf-8-validate: optional: true - ws@7.5.9: - resolution: {integrity: sha512-F+P9Jil7UiSKSkppIiD94dN07AwvFixvLIj1Og1Rl9GGMuNipJnV9JzjD6XuqmAeiswGvUmNLjr5cFuXwNS77Q==} + ws@7.5.10: + resolution: {integrity: sha512-+dbF1tHwZpXcbOJdVOkzLDxZP1ailvSxM6ZweXTegylPny803bFhA+vqBYw4s31NSAk4S2Qz+AKXK9a4wkdjcQ==} engines: {node: '>=8.3.0'} peerDependencies: - bufferutil: ^4.0.1 + bufferutil: ^4.0.8 utf-8-validate: ^5.0.2 peerDependenciesMeta: bufferutil: @@ -8041,7 +7791,19 @@ packages: resolution: {integrity: sha512-x9vcZYTrFPC7aSIbj7sRCYo7L/Xb8Iy+pW0ng0wt2vCJv7M9HOMy0UoN3rr+IFC7hb7vXoqS+P9ktyLLLhO+LA==} engines: {node: '>=10.0.0'} peerDependencies: - bufferutil: ^4.0.1 + bufferutil: ^4.0.8 + utf-8-validate: '>=5.0.2' + peerDependenciesMeta: + bufferutil: + optional: true + utf-8-validate: + optional: true + + ws@8.17.1: + resolution: {integrity: sha512-6XQFvXTkbfUOZOKKILFG1PDK2NDQs4azKQl26T0YS5CxqWLgXajbPZ+h4gZekJyRqFU8pvnbAbbs/3TgRPy+GQ==} + engines: {node: '>=10.0.0'} + peerDependencies: + bufferutil: ^4.0.8 utf-8-validate: '>=5.0.2' peerDependenciesMeta: bufferutil: @@ -8049,11 +7811,11 @@ packages: utf-8-validate: optional: true - ws@8.16.0: - resolution: {integrity: sha512-HS0c//TP7Ina87TfiPUz1rQzMhHrl/SG2guqRcTOIUYD2q8uhUdNHZYJUaQ8aTGPzCh+c6oawMKW35nFl1dxyQ==} + ws@8.18.0: + resolution: {integrity: sha512-8VbfWfHLbbwu3+N6OKsOMpBdT4kXPDDB9cJk2bJ6mh9ucxdlnNvH1e+roYkKmN9Nxw2yjz7VzeO9oOz2zJ04Pw==} engines: {node: '>=10.0.0'} peerDependencies: - bufferutil: ^4.0.1 + bufferutil: ^4.0.8 utf-8-validate: '>=5.0.2' peerDependenciesMeta: bufferutil: @@ -8070,10 +7832,6 @@ packages: xhr@2.6.0: resolution: {integrity: sha512-/eCGLb5rxjx5e3mF1A7s+pLlR6CGyqWN91fv1JgER5mVWg1MZmlhBvy9kjcsOdRk8RrIujotWyJamfyrp+WIcA==} - xtend@2.1.2: - resolution: {integrity: sha512-vMNKzr2rHP9Dp/e1NQFnLQlwlhp9L/LfvnsVdHxN1f+uggyVI3i08uD14GPvCToPkdsRfyPqIyYGmIk58V98ZQ==} - engines: {node: '>=0.4'} - xtend@4.0.2: resolution: {integrity: sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ==} engines: {node: '>=0.4'} @@ -8105,8 +7863,8 @@ packages: resolution: {integrity: sha512-o50j0JeToy/4K6OZcaQmW6lyXXKhq7csREXcDwk2omFPJEwUNOVtJKvmDr9EI1fAJZUyZcRF7kxGBWmRXudrCQ==} engines: {node: '>=6'} - yargs-parser@20.2.4: - resolution: {integrity: sha512-WOkpgNhPTlE73h4VFAFsOnomJVaovO8VqLDzy5saChRBFQFBoMYirowyW+Q9HB4HFF4Z7VZTiG3iSzJJA29yRA==} + yargs-parser@20.2.9: + resolution: {integrity: sha512-y11nGElTIV+CT3Zv9t7VKl+Q3hTQoT9a1Qzezhhl6Rp21gJ/IVTW7Z3y9EWXhuUBC2Shnf+DX0antecpAwSP8w==} engines: {node: '>=10'} yargs-parser@21.1.1: @@ -8143,1192 +7901,1147 @@ packages: resolution: {integrity: sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==} engines: {node: '>=10'} - yocto-queue@1.0.0: - resolution: {integrity: sha512-9bnSc/HEW2uRy67wc+T8UwauLuPJVn28jb+GtJY16iiKWyvmYJRXVT4UamsAEGQfPohgr2q4Tq0sQbQlxTfi1g==} + yocto-queue@1.1.1: + resolution: {integrity: sha512-b4JR1PFR10y1mKjhHY9LaGo6tmrgjit7hxVIeAmyMw3jegXR4dhYqLaQF5zMXZxY7tLpMyJeLjr1C4rLmkVe8g==} engines: {node: '>=12.20'} - zod@3.22.4: - resolution: {integrity: sha512-iC+8Io04lddc+mVqQ9AZ7OQ2MrUKGN+oIQyq1vemgt46jwCwLfhq7/pwnBnNXXXZb8VTVLKwp9EDkx+ryxIWmg==} + zod@3.23.8: + resolution: {integrity: sha512-XBx9AXhXktjUqnepgTiE5flcKIYWi/rme0Eaj+5Y0lftuGBq+jyRu/md4WnuxqgP1ubdpNCsYEYPxrzVHD8d6g==} - zstd-codec@0.1.4: - resolution: {integrity: sha512-KYnWoFWgGtWyQEKNnUcb3u8ZtKO8dn5d8u+oGpxPlopqsPyv60U8suDyfk7Z7UtAO6Sk5i1aVcAs9RbaB1n36A==} + zstd-codec@0.1.5: + resolution: {integrity: sha512-v3fyjpK8S/dpY/X5WxqTK3IoCnp/ZOLxn144GZVlNUjtwAchzrVo03h+oMATFhCIiJ5KTr4V3vDQQYz4RU684g==} snapshots: - '@0xsequence/ethauth@0.8.1(ethers@5.7.2)': + '@0xsequence/ethauth@1.0.0(ethers@6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10))': dependencies: - ethers: 5.7.2 + ethers: 6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10) js-base64: 3.7.7 - '@0xsequence/wallet-contracts@1.10.0': - optionalDependencies: - '@ethersproject/abi': 5.7.0 - '@ethersproject/providers': 5.7.2 - ethers: 5.7.2 + '@0xsequence/wallet-contracts@3.0.1(bufferutil@4.0.8)(typechain@8.3.2(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10)': + dependencies: + '@typechain/ethers-v6': 0.5.1(ethers@6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10))(typechain@8.3.2(typescript@5.6.3))(typescript@5.6.3) + ethers: 6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10) + keccak256: 1.0.6 transitivePeerDependencies: - bufferutil + - typechain + - typescript - utf-8-validate - '@0xsequence/wallet-contracts@2.0.0(@ethersproject/abi@5.7.0)(@ethersproject/bytes@5.7.0)(@ethersproject/providers@5.7.2)(typechain@5.2.0)(typescript@5.3.3)': + '@0xsequence/wallet-contracts@3.0.1(bufferutil@4.0.8)(typechain@8.3.2(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@6.0.3)': dependencies: - '@typechain/ethers-v5': 7.2.0(@ethersproject/abi@5.7.0)(@ethersproject/bytes@5.7.0)(@ethersproject/providers@5.7.2)(ethers@5.7.2)(typechain@5.2.0)(typescript@5.3.3) - ethers: 5.7.2 + '@typechain/ethers-v6': 0.5.1(ethers@6.13.4(bufferutil@4.0.8)(utf-8-validate@6.0.3))(typechain@8.3.2(typescript@5.6.3))(typescript@5.6.3) + ethers: 6.13.4(bufferutil@4.0.8)(utf-8-validate@6.0.3) keccak256: 1.0.6 transitivePeerDependencies: - - '@ethersproject/abi' - - '@ethersproject/bytes' - - '@ethersproject/providers' - bufferutil - typechain - typescript - utf-8-validate - '@aashutoshrathi/word-wrap@1.2.6': {} - - '@ampproject/remapping@2.2.1': - dependencies: - '@jridgewell/gen-mapping': 0.3.4 - '@jridgewell/trace-mapping': 0.3.23 - - '@aws-crypto/crc32@3.0.0': - dependencies: - '@aws-crypto/util': 3.0.0 - '@aws-sdk/types': 3.521.0 - tslib: 1.14.1 - - '@aws-crypto/ie11-detection@3.0.0': - dependencies: - tslib: 1.14.1 - - '@aws-crypto/sha256-browser@3.0.0': - dependencies: - '@aws-crypto/ie11-detection': 3.0.0 - '@aws-crypto/sha256-js': 3.0.0 - '@aws-crypto/supports-web-crypto': 3.0.0 - '@aws-crypto/util': 3.0.0 - '@aws-sdk/types': 3.521.0 - '@aws-sdk/util-locate-window': 3.495.0 - '@aws-sdk/util-utf8-browser': 3.259.0 - tslib: 1.14.1 - - '@aws-crypto/sha256-js@3.0.0': - dependencies: - '@aws-crypto/util': 3.0.0 - '@aws-sdk/types': 3.521.0 - tslib: 1.14.1 - - '@aws-crypto/supports-web-crypto@3.0.0': - dependencies: - tslib: 1.14.1 - - '@aws-crypto/util@3.0.0': - dependencies: - '@aws-sdk/types': 3.521.0 - '@aws-sdk/util-utf8-browser': 3.259.0 - tslib: 1.14.1 - - '@aws-sdk/client-cognito-identity-provider@3.521.0': - dependencies: - '@aws-crypto/sha256-browser': 3.0.0 - '@aws-crypto/sha256-js': 3.0.0 - '@aws-sdk/client-sts': 3.521.0(@aws-sdk/credential-provider-node@3.521.0) - '@aws-sdk/core': 3.521.0 - '@aws-sdk/credential-provider-node': 3.521.0 - '@aws-sdk/middleware-host-header': 3.521.0 - '@aws-sdk/middleware-logger': 3.521.0 - '@aws-sdk/middleware-recursion-detection': 3.521.0 - '@aws-sdk/middleware-user-agent': 3.521.0 - '@aws-sdk/region-config-resolver': 3.521.0 - '@aws-sdk/types': 3.521.0 - '@aws-sdk/util-endpoints': 3.521.0 - '@aws-sdk/util-user-agent-browser': 3.521.0 - '@aws-sdk/util-user-agent-node': 3.521.0 - '@smithy/config-resolver': 2.1.2 - '@smithy/core': 1.3.3 - '@smithy/fetch-http-handler': 2.4.2 - '@smithy/hash-node': 2.1.2 - '@smithy/invalid-dependency': 2.1.2 - '@smithy/middleware-content-length': 2.1.2 - '@smithy/middleware-endpoint': 2.4.2 - '@smithy/middleware-retry': 2.1.2 - '@smithy/middleware-serde': 2.1.2 - '@smithy/middleware-stack': 2.1.2 - '@smithy/node-config-provider': 2.2.2 - '@smithy/node-http-handler': 2.4.0 - '@smithy/protocol-http': 3.2.0 - '@smithy/smithy-client': 2.4.0 - '@smithy/types': 2.10.0 - '@smithy/url-parser': 2.1.2 - '@smithy/util-base64': 2.1.1 - '@smithy/util-body-length-browser': 2.1.1 - '@smithy/util-body-length-node': 2.2.1 - '@smithy/util-defaults-mode-browser': 2.1.2 - '@smithy/util-defaults-mode-node': 2.2.1 - '@smithy/util-endpoints': 1.1.2 - '@smithy/util-middleware': 2.1.2 - '@smithy/util-retry': 2.1.2 - '@smithy/util-utf8': 2.1.1 - tslib: 2.6.2 + '@adraffy/ens-normalize@1.10.1': {} + + '@ampproject/remapping@2.3.0': + dependencies: + '@jridgewell/gen-mapping': 0.3.5 + '@jridgewell/trace-mapping': 0.3.25 + + '@aws-crypto/sha256-browser@5.2.0': + dependencies: + '@aws-crypto/sha256-js': 5.2.0 + '@aws-crypto/supports-web-crypto': 5.2.0 + '@aws-crypto/util': 5.2.0 + '@aws-sdk/types': 3.667.0 + '@aws-sdk/util-locate-window': 3.568.0 + '@smithy/util-utf8': 2.3.0 + tslib: 2.8.0 + + '@aws-crypto/sha256-js@5.2.0': + dependencies: + '@aws-crypto/util': 5.2.0 + '@aws-sdk/types': 3.667.0 + tslib: 2.8.0 + + '@aws-crypto/supports-web-crypto@5.2.0': + dependencies: + tslib: 2.8.0 + + '@aws-crypto/util@5.2.0': + dependencies: + '@aws-sdk/types': 3.667.0 + '@smithy/util-utf8': 2.3.0 + tslib: 2.8.0 + + '@aws-sdk/client-cognito-identity-provider@3.678.0': + dependencies: + '@aws-crypto/sha256-browser': 5.2.0 + '@aws-crypto/sha256-js': 5.2.0 + '@aws-sdk/client-sso-oidc': 3.678.0(@aws-sdk/client-sts@3.678.0) + '@aws-sdk/client-sts': 3.678.0 + '@aws-sdk/core': 3.678.0 + '@aws-sdk/credential-provider-node': 3.678.0(@aws-sdk/client-sso-oidc@3.678.0(@aws-sdk/client-sts@3.678.0))(@aws-sdk/client-sts@3.678.0) + '@aws-sdk/middleware-host-header': 3.667.0 + '@aws-sdk/middleware-logger': 3.667.0 + '@aws-sdk/middleware-recursion-detection': 3.667.0 + '@aws-sdk/middleware-user-agent': 3.678.0 + '@aws-sdk/region-config-resolver': 3.667.0 + '@aws-sdk/types': 3.667.0 + '@aws-sdk/util-endpoints': 3.667.0 + '@aws-sdk/util-user-agent-browser': 3.675.0 + '@aws-sdk/util-user-agent-node': 3.678.0 + '@smithy/config-resolver': 3.0.10 + '@smithy/core': 2.5.1 + '@smithy/fetch-http-handler': 3.2.9 + '@smithy/hash-node': 3.0.8 + '@smithy/invalid-dependency': 3.0.8 + '@smithy/middleware-content-length': 3.0.10 + '@smithy/middleware-endpoint': 3.2.1 + '@smithy/middleware-retry': 3.0.25 + '@smithy/middleware-serde': 3.0.8 + '@smithy/middleware-stack': 3.0.8 + '@smithy/node-config-provider': 3.1.9 + '@smithy/node-http-handler': 3.2.5 + '@smithy/protocol-http': 4.1.5 + '@smithy/smithy-client': 3.4.2 + '@smithy/types': 3.6.0 + '@smithy/url-parser': 3.0.8 + '@smithy/util-base64': 3.0.0 + '@smithy/util-body-length-browser': 3.0.0 + '@smithy/util-body-length-node': 3.0.0 + '@smithy/util-defaults-mode-browser': 3.0.25 + '@smithy/util-defaults-mode-node': 3.0.25 + '@smithy/util-endpoints': 2.1.4 + '@smithy/util-middleware': 3.0.8 + '@smithy/util-retry': 3.0.8 + '@smithy/util-utf8': 3.0.0 + tslib: 2.8.0 transitivePeerDependencies: - aws-crt - '@aws-sdk/client-sso-oidc@3.521.0(@aws-sdk/credential-provider-node@3.521.0)': - dependencies: - '@aws-crypto/sha256-browser': 3.0.0 - '@aws-crypto/sha256-js': 3.0.0 - '@aws-sdk/client-sts': 3.521.0(@aws-sdk/credential-provider-node@3.521.0) - '@aws-sdk/core': 3.521.0 - '@aws-sdk/credential-provider-node': 3.521.0 - '@aws-sdk/middleware-host-header': 3.521.0 - '@aws-sdk/middleware-logger': 3.521.0 - '@aws-sdk/middleware-recursion-detection': 3.521.0 - '@aws-sdk/middleware-user-agent': 3.521.0 - '@aws-sdk/region-config-resolver': 3.521.0 - '@aws-sdk/types': 3.521.0 - '@aws-sdk/util-endpoints': 3.521.0 - '@aws-sdk/util-user-agent-browser': 3.521.0 - '@aws-sdk/util-user-agent-node': 3.521.0 - '@smithy/config-resolver': 2.1.2 - '@smithy/core': 1.3.3 - '@smithy/fetch-http-handler': 2.4.2 - '@smithy/hash-node': 2.1.2 - '@smithy/invalid-dependency': 2.1.2 - '@smithy/middleware-content-length': 2.1.2 - '@smithy/middleware-endpoint': 2.4.2 - '@smithy/middleware-retry': 2.1.2 - '@smithy/middleware-serde': 2.1.2 - '@smithy/middleware-stack': 2.1.2 - '@smithy/node-config-provider': 2.2.2 - '@smithy/node-http-handler': 2.4.0 - '@smithy/protocol-http': 3.2.0 - '@smithy/smithy-client': 2.4.0 - '@smithy/types': 2.10.0 - '@smithy/url-parser': 2.1.2 - '@smithy/util-base64': 2.1.1 - '@smithy/util-body-length-browser': 2.1.1 - '@smithy/util-body-length-node': 2.2.1 - '@smithy/util-defaults-mode-browser': 2.1.2 - '@smithy/util-defaults-mode-node': 2.2.1 - '@smithy/util-endpoints': 1.1.2 - '@smithy/util-middleware': 2.1.2 - '@smithy/util-retry': 2.1.2 - '@smithy/util-utf8': 2.1.1 - tslib: 2.6.2 + '@aws-sdk/client-sso-oidc@3.678.0(@aws-sdk/client-sts@3.678.0)': + dependencies: + '@aws-crypto/sha256-browser': 5.2.0 + '@aws-crypto/sha256-js': 5.2.0 + '@aws-sdk/client-sts': 3.678.0 + '@aws-sdk/core': 3.678.0 + '@aws-sdk/credential-provider-node': 3.678.0(@aws-sdk/client-sso-oidc@3.678.0(@aws-sdk/client-sts@3.678.0))(@aws-sdk/client-sts@3.678.0) + '@aws-sdk/middleware-host-header': 3.667.0 + '@aws-sdk/middleware-logger': 3.667.0 + '@aws-sdk/middleware-recursion-detection': 3.667.0 + '@aws-sdk/middleware-user-agent': 3.678.0 + '@aws-sdk/region-config-resolver': 3.667.0 + '@aws-sdk/types': 3.667.0 + '@aws-sdk/util-endpoints': 3.667.0 + '@aws-sdk/util-user-agent-browser': 3.675.0 + '@aws-sdk/util-user-agent-node': 3.678.0 + '@smithy/config-resolver': 3.0.10 + '@smithy/core': 2.5.1 + '@smithy/fetch-http-handler': 3.2.9 + '@smithy/hash-node': 3.0.8 + '@smithy/invalid-dependency': 3.0.8 + '@smithy/middleware-content-length': 3.0.10 + '@smithy/middleware-endpoint': 3.2.1 + '@smithy/middleware-retry': 3.0.25 + '@smithy/middleware-serde': 3.0.8 + '@smithy/middleware-stack': 3.0.8 + '@smithy/node-config-provider': 3.1.9 + '@smithy/node-http-handler': 3.2.5 + '@smithy/protocol-http': 4.1.5 + '@smithy/smithy-client': 3.4.2 + '@smithy/types': 3.6.0 + '@smithy/url-parser': 3.0.8 + '@smithy/util-base64': 3.0.0 + '@smithy/util-body-length-browser': 3.0.0 + '@smithy/util-body-length-node': 3.0.0 + '@smithy/util-defaults-mode-browser': 3.0.25 + '@smithy/util-defaults-mode-node': 3.0.25 + '@smithy/util-endpoints': 2.1.4 + '@smithy/util-middleware': 3.0.8 + '@smithy/util-retry': 3.0.8 + '@smithy/util-utf8': 3.0.0 + tslib: 2.8.0 transitivePeerDependencies: - aws-crt - '@aws-sdk/client-sso@3.521.0': - dependencies: - '@aws-crypto/sha256-browser': 3.0.0 - '@aws-crypto/sha256-js': 3.0.0 - '@aws-sdk/core': 3.521.0 - '@aws-sdk/middleware-host-header': 3.521.0 - '@aws-sdk/middleware-logger': 3.521.0 - '@aws-sdk/middleware-recursion-detection': 3.521.0 - '@aws-sdk/middleware-user-agent': 3.521.0 - '@aws-sdk/region-config-resolver': 3.521.0 - '@aws-sdk/types': 3.521.0 - '@aws-sdk/util-endpoints': 3.521.0 - '@aws-sdk/util-user-agent-browser': 3.521.0 - '@aws-sdk/util-user-agent-node': 3.521.0 - '@smithy/config-resolver': 2.1.2 - '@smithy/core': 1.3.3 - '@smithy/fetch-http-handler': 2.4.2 - '@smithy/hash-node': 2.1.2 - '@smithy/invalid-dependency': 2.1.2 - '@smithy/middleware-content-length': 2.1.2 - '@smithy/middleware-endpoint': 2.4.2 - '@smithy/middleware-retry': 2.1.2 - '@smithy/middleware-serde': 2.1.2 - '@smithy/middleware-stack': 2.1.2 - '@smithy/node-config-provider': 2.2.2 - '@smithy/node-http-handler': 2.4.0 - '@smithy/protocol-http': 3.2.0 - '@smithy/smithy-client': 2.4.0 - '@smithy/types': 2.10.0 - '@smithy/url-parser': 2.1.2 - '@smithy/util-base64': 2.1.1 - '@smithy/util-body-length-browser': 2.1.1 - '@smithy/util-body-length-node': 2.2.1 - '@smithy/util-defaults-mode-browser': 2.1.2 - '@smithy/util-defaults-mode-node': 2.2.1 - '@smithy/util-endpoints': 1.1.2 - '@smithy/util-middleware': 2.1.2 - '@smithy/util-retry': 2.1.2 - '@smithy/util-utf8': 2.1.1 - tslib: 2.6.2 + '@aws-sdk/client-sso@3.678.0': + dependencies: + '@aws-crypto/sha256-browser': 5.2.0 + '@aws-crypto/sha256-js': 5.2.0 + '@aws-sdk/core': 3.678.0 + '@aws-sdk/middleware-host-header': 3.667.0 + '@aws-sdk/middleware-logger': 3.667.0 + '@aws-sdk/middleware-recursion-detection': 3.667.0 + '@aws-sdk/middleware-user-agent': 3.678.0 + '@aws-sdk/region-config-resolver': 3.667.0 + '@aws-sdk/types': 3.667.0 + '@aws-sdk/util-endpoints': 3.667.0 + '@aws-sdk/util-user-agent-browser': 3.675.0 + '@aws-sdk/util-user-agent-node': 3.678.0 + '@smithy/config-resolver': 3.0.10 + '@smithy/core': 2.5.1 + '@smithy/fetch-http-handler': 3.2.9 + '@smithy/hash-node': 3.0.8 + '@smithy/invalid-dependency': 3.0.8 + '@smithy/middleware-content-length': 3.0.10 + '@smithy/middleware-endpoint': 3.2.1 + '@smithy/middleware-retry': 3.0.25 + '@smithy/middleware-serde': 3.0.8 + '@smithy/middleware-stack': 3.0.8 + '@smithy/node-config-provider': 3.1.9 + '@smithy/node-http-handler': 3.2.5 + '@smithy/protocol-http': 4.1.5 + '@smithy/smithy-client': 3.4.2 + '@smithy/types': 3.6.0 + '@smithy/url-parser': 3.0.8 + '@smithy/util-base64': 3.0.0 + '@smithy/util-body-length-browser': 3.0.0 + '@smithy/util-body-length-node': 3.0.0 + '@smithy/util-defaults-mode-browser': 3.0.25 + '@smithy/util-defaults-mode-node': 3.0.25 + '@smithy/util-endpoints': 2.1.4 + '@smithy/util-middleware': 3.0.8 + '@smithy/util-retry': 3.0.8 + '@smithy/util-utf8': 3.0.0 + tslib: 2.8.0 transitivePeerDependencies: - aws-crt - '@aws-sdk/client-sts@3.521.0(@aws-sdk/credential-provider-node@3.521.0)': - dependencies: - '@aws-crypto/sha256-browser': 3.0.0 - '@aws-crypto/sha256-js': 3.0.0 - '@aws-sdk/core': 3.521.0 - '@aws-sdk/credential-provider-node': 3.521.0 - '@aws-sdk/middleware-host-header': 3.521.0 - '@aws-sdk/middleware-logger': 3.521.0 - '@aws-sdk/middleware-recursion-detection': 3.521.0 - '@aws-sdk/middleware-user-agent': 3.521.0 - '@aws-sdk/region-config-resolver': 3.521.0 - '@aws-sdk/types': 3.521.0 - '@aws-sdk/util-endpoints': 3.521.0 - '@aws-sdk/util-user-agent-browser': 3.521.0 - '@aws-sdk/util-user-agent-node': 3.521.0 - '@smithy/config-resolver': 2.1.2 - '@smithy/core': 1.3.3 - '@smithy/fetch-http-handler': 2.4.2 - '@smithy/hash-node': 2.1.2 - '@smithy/invalid-dependency': 2.1.2 - '@smithy/middleware-content-length': 2.1.2 - '@smithy/middleware-endpoint': 2.4.2 - '@smithy/middleware-retry': 2.1.2 - '@smithy/middleware-serde': 2.1.2 - '@smithy/middleware-stack': 2.1.2 - '@smithy/node-config-provider': 2.2.2 - '@smithy/node-http-handler': 2.4.0 - '@smithy/protocol-http': 3.2.0 - '@smithy/smithy-client': 2.4.0 - '@smithy/types': 2.10.0 - '@smithy/url-parser': 2.1.2 - '@smithy/util-base64': 2.1.1 - '@smithy/util-body-length-browser': 2.1.1 - '@smithy/util-body-length-node': 2.2.1 - '@smithy/util-defaults-mode-browser': 2.1.2 - '@smithy/util-defaults-mode-node': 2.2.1 - '@smithy/util-endpoints': 1.1.2 - '@smithy/util-middleware': 2.1.2 - '@smithy/util-retry': 2.1.2 - '@smithy/util-utf8': 2.1.1 - fast-xml-parser: 4.2.5 - tslib: 2.6.2 + '@aws-sdk/client-sts@3.678.0': + dependencies: + '@aws-crypto/sha256-browser': 5.2.0 + '@aws-crypto/sha256-js': 5.2.0 + '@aws-sdk/client-sso-oidc': 3.678.0(@aws-sdk/client-sts@3.678.0) + '@aws-sdk/core': 3.678.0 + '@aws-sdk/credential-provider-node': 3.678.0(@aws-sdk/client-sso-oidc@3.678.0(@aws-sdk/client-sts@3.678.0))(@aws-sdk/client-sts@3.678.0) + '@aws-sdk/middleware-host-header': 3.667.0 + '@aws-sdk/middleware-logger': 3.667.0 + '@aws-sdk/middleware-recursion-detection': 3.667.0 + '@aws-sdk/middleware-user-agent': 3.678.0 + '@aws-sdk/region-config-resolver': 3.667.0 + '@aws-sdk/types': 3.667.0 + '@aws-sdk/util-endpoints': 3.667.0 + '@aws-sdk/util-user-agent-browser': 3.675.0 + '@aws-sdk/util-user-agent-node': 3.678.0 + '@smithy/config-resolver': 3.0.10 + '@smithy/core': 2.5.1 + '@smithy/fetch-http-handler': 3.2.9 + '@smithy/hash-node': 3.0.8 + '@smithy/invalid-dependency': 3.0.8 + '@smithy/middleware-content-length': 3.0.10 + '@smithy/middleware-endpoint': 3.2.1 + '@smithy/middleware-retry': 3.0.25 + '@smithy/middleware-serde': 3.0.8 + '@smithy/middleware-stack': 3.0.8 + '@smithy/node-config-provider': 3.1.9 + '@smithy/node-http-handler': 3.2.5 + '@smithy/protocol-http': 4.1.5 + '@smithy/smithy-client': 3.4.2 + '@smithy/types': 3.6.0 + '@smithy/url-parser': 3.0.8 + '@smithy/util-base64': 3.0.0 + '@smithy/util-body-length-browser': 3.0.0 + '@smithy/util-body-length-node': 3.0.0 + '@smithy/util-defaults-mode-browser': 3.0.25 + '@smithy/util-defaults-mode-node': 3.0.25 + '@smithy/util-endpoints': 2.1.4 + '@smithy/util-middleware': 3.0.8 + '@smithy/util-retry': 3.0.8 + '@smithy/util-utf8': 3.0.0 + tslib: 2.8.0 transitivePeerDependencies: - aws-crt - '@aws-sdk/core@3.521.0': - dependencies: - '@smithy/core': 1.3.3 - '@smithy/protocol-http': 3.2.0 - '@smithy/signature-v4': 2.1.2 - '@smithy/smithy-client': 2.4.0 - '@smithy/types': 2.10.0 - tslib: 2.6.2 - - '@aws-sdk/credential-provider-env@3.521.0': - dependencies: - '@aws-sdk/types': 3.521.0 - '@smithy/property-provider': 2.1.2 - '@smithy/types': 2.10.0 - tslib: 2.6.2 - - '@aws-sdk/credential-provider-http@3.521.0': - dependencies: - '@aws-sdk/types': 3.521.0 - '@smithy/fetch-http-handler': 2.4.2 - '@smithy/node-http-handler': 2.4.0 - '@smithy/property-provider': 2.1.2 - '@smithy/protocol-http': 3.2.0 - '@smithy/smithy-client': 2.4.0 - '@smithy/types': 2.10.0 - '@smithy/util-stream': 2.1.2 - tslib: 2.6.2 - - '@aws-sdk/credential-provider-ini@3.521.0(@aws-sdk/credential-provider-node@3.521.0)': - dependencies: - '@aws-sdk/client-sts': 3.521.0(@aws-sdk/credential-provider-node@3.521.0) - '@aws-sdk/credential-provider-env': 3.521.0 - '@aws-sdk/credential-provider-process': 3.521.0 - '@aws-sdk/credential-provider-sso': 3.521.0(@aws-sdk/credential-provider-node@3.521.0) - '@aws-sdk/credential-provider-web-identity': 3.521.0(@aws-sdk/credential-provider-node@3.521.0) - '@aws-sdk/types': 3.521.0 - '@smithy/credential-provider-imds': 2.2.2 - '@smithy/property-provider': 2.1.2 - '@smithy/shared-ini-file-loader': 2.3.2 - '@smithy/types': 2.10.0 - tslib: 2.6.2 + '@aws-sdk/core@3.678.0': + dependencies: + '@aws-sdk/types': 3.667.0 + '@smithy/core': 2.5.1 + '@smithy/node-config-provider': 3.1.9 + '@smithy/property-provider': 3.1.8 + '@smithy/protocol-http': 4.1.5 + '@smithy/signature-v4': 4.2.1 + '@smithy/smithy-client': 3.4.2 + '@smithy/types': 3.6.0 + '@smithy/util-middleware': 3.0.8 + fast-xml-parser: 4.4.1 + tslib: 2.8.0 + + '@aws-sdk/credential-provider-env@3.678.0': + dependencies: + '@aws-sdk/core': 3.678.0 + '@aws-sdk/types': 3.667.0 + '@smithy/property-provider': 3.1.8 + '@smithy/types': 3.6.0 + tslib: 2.8.0 + + '@aws-sdk/credential-provider-http@3.678.0': + dependencies: + '@aws-sdk/core': 3.678.0 + '@aws-sdk/types': 3.667.0 + '@smithy/fetch-http-handler': 3.2.9 + '@smithy/node-http-handler': 3.2.5 + '@smithy/property-provider': 3.1.8 + '@smithy/protocol-http': 4.1.5 + '@smithy/smithy-client': 3.4.2 + '@smithy/types': 3.6.0 + '@smithy/util-stream': 3.2.1 + tslib: 2.8.0 + + '@aws-sdk/credential-provider-ini@3.678.0(@aws-sdk/client-sso-oidc@3.678.0(@aws-sdk/client-sts@3.678.0))(@aws-sdk/client-sts@3.678.0)': + dependencies: + '@aws-sdk/client-sts': 3.678.0 + '@aws-sdk/core': 3.678.0 + '@aws-sdk/credential-provider-env': 3.678.0 + '@aws-sdk/credential-provider-http': 3.678.0 + '@aws-sdk/credential-provider-process': 3.678.0 + '@aws-sdk/credential-provider-sso': 3.678.0(@aws-sdk/client-sso-oidc@3.678.0(@aws-sdk/client-sts@3.678.0)) + '@aws-sdk/credential-provider-web-identity': 3.678.0(@aws-sdk/client-sts@3.678.0) + '@aws-sdk/types': 3.667.0 + '@smithy/credential-provider-imds': 3.2.5 + '@smithy/property-provider': 3.1.8 + '@smithy/shared-ini-file-loader': 3.1.9 + '@smithy/types': 3.6.0 + tslib: 2.8.0 transitivePeerDependencies: - - '@aws-sdk/credential-provider-node' + - '@aws-sdk/client-sso-oidc' - aws-crt - '@aws-sdk/credential-provider-node@3.521.0': - dependencies: - '@aws-sdk/credential-provider-env': 3.521.0 - '@aws-sdk/credential-provider-http': 3.521.0 - '@aws-sdk/credential-provider-ini': 3.521.0(@aws-sdk/credential-provider-node@3.521.0) - '@aws-sdk/credential-provider-process': 3.521.0 - '@aws-sdk/credential-provider-sso': 3.521.0(@aws-sdk/credential-provider-node@3.521.0) - '@aws-sdk/credential-provider-web-identity': 3.521.0(@aws-sdk/credential-provider-node@3.521.0) - '@aws-sdk/types': 3.521.0 - '@smithy/credential-provider-imds': 2.2.2 - '@smithy/property-provider': 2.1.2 - '@smithy/shared-ini-file-loader': 2.3.2 - '@smithy/types': 2.10.0 - tslib: 2.6.2 + '@aws-sdk/credential-provider-node@3.678.0(@aws-sdk/client-sso-oidc@3.678.0(@aws-sdk/client-sts@3.678.0))(@aws-sdk/client-sts@3.678.0)': + dependencies: + '@aws-sdk/credential-provider-env': 3.678.0 + '@aws-sdk/credential-provider-http': 3.678.0 + '@aws-sdk/credential-provider-ini': 3.678.0(@aws-sdk/client-sso-oidc@3.678.0(@aws-sdk/client-sts@3.678.0))(@aws-sdk/client-sts@3.678.0) + '@aws-sdk/credential-provider-process': 3.678.0 + '@aws-sdk/credential-provider-sso': 3.678.0(@aws-sdk/client-sso-oidc@3.678.0(@aws-sdk/client-sts@3.678.0)) + '@aws-sdk/credential-provider-web-identity': 3.678.0(@aws-sdk/client-sts@3.678.0) + '@aws-sdk/types': 3.667.0 + '@smithy/credential-provider-imds': 3.2.5 + '@smithy/property-provider': 3.1.8 + '@smithy/shared-ini-file-loader': 3.1.9 + '@smithy/types': 3.6.0 + tslib: 2.8.0 transitivePeerDependencies: + - '@aws-sdk/client-sso-oidc' + - '@aws-sdk/client-sts' - aws-crt - '@aws-sdk/credential-provider-process@3.521.0': - dependencies: - '@aws-sdk/types': 3.521.0 - '@smithy/property-provider': 2.1.2 - '@smithy/shared-ini-file-loader': 2.3.2 - '@smithy/types': 2.10.0 - tslib: 2.6.2 - - '@aws-sdk/credential-provider-sso@3.521.0(@aws-sdk/credential-provider-node@3.521.0)': - dependencies: - '@aws-sdk/client-sso': 3.521.0 - '@aws-sdk/token-providers': 3.521.0(@aws-sdk/credential-provider-node@3.521.0) - '@aws-sdk/types': 3.521.0 - '@smithy/property-provider': 2.1.2 - '@smithy/shared-ini-file-loader': 2.3.2 - '@smithy/types': 2.10.0 - tslib: 2.6.2 + '@aws-sdk/credential-provider-process@3.678.0': + dependencies: + '@aws-sdk/core': 3.678.0 + '@aws-sdk/types': 3.667.0 + '@smithy/property-provider': 3.1.8 + '@smithy/shared-ini-file-loader': 3.1.9 + '@smithy/types': 3.6.0 + tslib: 2.8.0 + + '@aws-sdk/credential-provider-sso@3.678.0(@aws-sdk/client-sso-oidc@3.678.0(@aws-sdk/client-sts@3.678.0))': + dependencies: + '@aws-sdk/client-sso': 3.678.0 + '@aws-sdk/core': 3.678.0 + '@aws-sdk/token-providers': 3.667.0(@aws-sdk/client-sso-oidc@3.678.0(@aws-sdk/client-sts@3.678.0)) + '@aws-sdk/types': 3.667.0 + '@smithy/property-provider': 3.1.8 + '@smithy/shared-ini-file-loader': 3.1.9 + '@smithy/types': 3.6.0 + tslib: 2.8.0 transitivePeerDependencies: - - '@aws-sdk/credential-provider-node' + - '@aws-sdk/client-sso-oidc' - aws-crt - '@aws-sdk/credential-provider-web-identity@3.521.0(@aws-sdk/credential-provider-node@3.521.0)': + '@aws-sdk/credential-provider-web-identity@3.678.0(@aws-sdk/client-sts@3.678.0)': dependencies: - '@aws-sdk/client-sts': 3.521.0(@aws-sdk/credential-provider-node@3.521.0) - '@aws-sdk/types': 3.521.0 - '@smithy/property-provider': 2.1.2 - '@smithy/types': 2.10.0 - tslib: 2.6.2 - transitivePeerDependencies: - - '@aws-sdk/credential-provider-node' - - aws-crt + '@aws-sdk/client-sts': 3.678.0 + '@aws-sdk/core': 3.678.0 + '@aws-sdk/types': 3.667.0 + '@smithy/property-provider': 3.1.8 + '@smithy/types': 3.6.0 + tslib: 2.8.0 - '@aws-sdk/middleware-host-header@3.521.0': + '@aws-sdk/middleware-host-header@3.667.0': dependencies: - '@aws-sdk/types': 3.521.0 - '@smithy/protocol-http': 3.2.0 - '@smithy/types': 2.10.0 - tslib: 2.6.2 + '@aws-sdk/types': 3.667.0 + '@smithy/protocol-http': 4.1.5 + '@smithy/types': 3.6.0 + tslib: 2.8.0 - '@aws-sdk/middleware-logger@3.521.0': + '@aws-sdk/middleware-logger@3.667.0': dependencies: - '@aws-sdk/types': 3.521.0 - '@smithy/types': 2.10.0 - tslib: 2.6.2 + '@aws-sdk/types': 3.667.0 + '@smithy/types': 3.6.0 + tslib: 2.8.0 - '@aws-sdk/middleware-recursion-detection@3.521.0': + '@aws-sdk/middleware-recursion-detection@3.667.0': dependencies: - '@aws-sdk/types': 3.521.0 - '@smithy/protocol-http': 3.2.0 - '@smithy/types': 2.10.0 - tslib: 2.6.2 + '@aws-sdk/types': 3.667.0 + '@smithy/protocol-http': 4.1.5 + '@smithy/types': 3.6.0 + tslib: 2.8.0 - '@aws-sdk/middleware-user-agent@3.521.0': + '@aws-sdk/middleware-user-agent@3.678.0': dependencies: - '@aws-sdk/types': 3.521.0 - '@aws-sdk/util-endpoints': 3.521.0 - '@smithy/protocol-http': 3.2.0 - '@smithy/types': 2.10.0 - tslib: 2.6.2 + '@aws-sdk/core': 3.678.0 + '@aws-sdk/types': 3.667.0 + '@aws-sdk/util-endpoints': 3.667.0 + '@smithy/core': 2.5.1 + '@smithy/protocol-http': 4.1.5 + '@smithy/types': 3.6.0 + tslib: 2.8.0 - '@aws-sdk/region-config-resolver@3.521.0': + '@aws-sdk/region-config-resolver@3.667.0': dependencies: - '@aws-sdk/types': 3.521.0 - '@smithy/node-config-provider': 2.2.2 - '@smithy/types': 2.10.0 - '@smithy/util-config-provider': 2.2.1 - '@smithy/util-middleware': 2.1.2 - tslib: 2.6.2 + '@aws-sdk/types': 3.667.0 + '@smithy/node-config-provider': 3.1.9 + '@smithy/types': 3.6.0 + '@smithy/util-config-provider': 3.0.0 + '@smithy/util-middleware': 3.0.8 + tslib: 2.8.0 - '@aws-sdk/token-providers@3.521.0(@aws-sdk/credential-provider-node@3.521.0)': + '@aws-sdk/token-providers@3.667.0(@aws-sdk/client-sso-oidc@3.678.0(@aws-sdk/client-sts@3.678.0))': dependencies: - '@aws-sdk/client-sso-oidc': 3.521.0(@aws-sdk/credential-provider-node@3.521.0) - '@aws-sdk/types': 3.521.0 - '@smithy/property-provider': 2.1.2 - '@smithy/shared-ini-file-loader': 2.3.2 - '@smithy/types': 2.10.0 - tslib: 2.6.2 - transitivePeerDependencies: - - '@aws-sdk/credential-provider-node' - - aws-crt + '@aws-sdk/client-sso-oidc': 3.678.0(@aws-sdk/client-sts@3.678.0) + '@aws-sdk/types': 3.667.0 + '@smithy/property-provider': 3.1.8 + '@smithy/shared-ini-file-loader': 3.1.9 + '@smithy/types': 3.6.0 + tslib: 2.8.0 - '@aws-sdk/types@3.521.0': + '@aws-sdk/types@3.667.0': dependencies: - '@smithy/types': 2.10.0 - tslib: 2.6.2 + '@smithy/types': 3.6.0 + tslib: 2.8.0 - '@aws-sdk/util-endpoints@3.521.0': + '@aws-sdk/util-endpoints@3.667.0': dependencies: - '@aws-sdk/types': 3.521.0 - '@smithy/types': 2.10.0 - '@smithy/util-endpoints': 1.1.2 - tslib: 2.6.2 + '@aws-sdk/types': 3.667.0 + '@smithy/types': 3.6.0 + '@smithy/util-endpoints': 2.1.4 + tslib: 2.8.0 - '@aws-sdk/util-locate-window@3.495.0': + '@aws-sdk/util-locate-window@3.568.0': dependencies: - tslib: 2.6.2 + tslib: 2.8.0 - '@aws-sdk/util-user-agent-browser@3.521.0': + '@aws-sdk/util-user-agent-browser@3.675.0': dependencies: - '@aws-sdk/types': 3.521.0 - '@smithy/types': 2.10.0 + '@aws-sdk/types': 3.667.0 + '@smithy/types': 3.6.0 bowser: 2.11.0 - tslib: 2.6.2 + tslib: 2.8.0 - '@aws-sdk/util-user-agent-node@3.521.0': + '@aws-sdk/util-user-agent-node@3.678.0': dependencies: - '@aws-sdk/types': 3.521.0 - '@smithy/node-config-provider': 2.2.2 - '@smithy/types': 2.10.0 - tslib: 2.6.2 + '@aws-sdk/middleware-user-agent': 3.678.0 + '@aws-sdk/types': 3.667.0 + '@smithy/node-config-provider': 3.1.9 + '@smithy/types': 3.6.0 + tslib: 2.8.0 - '@aws-sdk/util-utf8-browser@3.259.0': + '@babel/code-frame@7.25.9': dependencies: - tslib: 2.6.2 + '@babel/highlight': 7.25.9 + picocolors: 1.1.1 - '@babel/code-frame@7.23.5': - dependencies: - '@babel/highlight': 7.23.4 - chalk: 2.4.2 + '@babel/compat-data@7.25.9': {} - '@babel/compat-data@7.23.5': {} - - '@babel/core@7.23.9': + '@babel/core@7.25.9': dependencies: - '@ampproject/remapping': 2.2.1 - '@babel/code-frame': 7.23.5 - '@babel/generator': 7.23.6 - '@babel/helper-compilation-targets': 7.23.6 - '@babel/helper-module-transforms': 7.23.3(@babel/core@7.23.9) - '@babel/helpers': 7.23.9 - '@babel/parser': 7.23.9 - '@babel/template': 7.23.9 - '@babel/traverse': 7.23.9 - '@babel/types': 7.23.9 + '@ampproject/remapping': 2.3.0 + '@babel/code-frame': 7.25.9 + '@babel/generator': 7.25.9 + '@babel/helper-compilation-targets': 7.25.9 + '@babel/helper-module-transforms': 7.25.9(@babel/core@7.25.9) + '@babel/helpers': 7.25.9 + '@babel/parser': 7.25.9 + '@babel/template': 7.25.9 + '@babel/traverse': 7.25.9 + '@babel/types': 7.25.9 convert-source-map: 2.0.0 - debug: 4.3.4(supports-color@6.1.0) + debug: 4.3.7(supports-color@6.1.0) gensync: 1.0.0-beta.2 json5: 2.2.3 semver: 6.3.1 transitivePeerDependencies: - supports-color - '@babel/generator@7.23.6': + '@babel/generator@7.25.9': dependencies: - '@babel/types': 7.23.9 - '@jridgewell/gen-mapping': 0.3.4 - '@jridgewell/trace-mapping': 0.3.23 - jsesc: 2.5.2 + '@babel/types': 7.25.9 + '@jridgewell/gen-mapping': 0.3.5 + '@jridgewell/trace-mapping': 0.3.25 + jsesc: 3.0.2 - '@babel/helper-annotate-as-pure@7.22.5': + '@babel/helper-annotate-as-pure@7.25.9': dependencies: - '@babel/types': 7.23.9 + '@babel/types': 7.25.9 - '@babel/helper-builder-binary-assignment-operator-visitor@7.22.15': + '@babel/helper-builder-binary-assignment-operator-visitor@7.25.9': dependencies: - '@babel/types': 7.23.9 + '@babel/traverse': 7.25.9 + '@babel/types': 7.25.9 + transitivePeerDependencies: + - supports-color - '@babel/helper-compilation-targets@7.23.6': + '@babel/helper-compilation-targets@7.25.9': dependencies: - '@babel/compat-data': 7.23.5 - '@babel/helper-validator-option': 7.23.5 - browserslist: 4.23.0 + '@babel/compat-data': 7.25.9 + '@babel/helper-validator-option': 7.25.9 + browserslist: 4.24.2 lru-cache: 5.1.1 semver: 6.3.1 - '@babel/helper-create-class-features-plugin@7.23.10(@babel/core@7.23.9)': - dependencies: - '@babel/core': 7.23.9 - '@babel/helper-annotate-as-pure': 7.22.5 - '@babel/helper-environment-visitor': 7.22.20 - '@babel/helper-function-name': 7.23.0 - '@babel/helper-member-expression-to-functions': 7.23.0 - '@babel/helper-optimise-call-expression': 7.22.5 - '@babel/helper-replace-supers': 7.22.20(@babel/core@7.23.9) - '@babel/helper-skip-transparent-expression-wrappers': 7.22.5 - '@babel/helper-split-export-declaration': 7.22.6 + '@babel/helper-create-class-features-plugin@7.25.9(@babel/core@7.25.9)': + dependencies: + '@babel/core': 7.25.9 + '@babel/helper-annotate-as-pure': 7.25.9 + '@babel/helper-member-expression-to-functions': 7.25.9 + '@babel/helper-optimise-call-expression': 7.25.9 + '@babel/helper-replace-supers': 7.25.9(@babel/core@7.25.9) + '@babel/helper-skip-transparent-expression-wrappers': 7.25.9 + '@babel/traverse': 7.25.9 semver: 6.3.1 + transitivePeerDependencies: + - supports-color - '@babel/helper-create-regexp-features-plugin@7.22.15(@babel/core@7.23.9)': + '@babel/helper-create-regexp-features-plugin@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-annotate-as-pure': 7.22.5 - regexpu-core: 5.3.2 + '@babel/core': 7.25.9 + '@babel/helper-annotate-as-pure': 7.25.9 + regexpu-core: 6.1.1 semver: 6.3.1 - '@babel/helper-define-polyfill-provider@0.5.0(@babel/core@7.23.9)': + '@babel/helper-define-polyfill-provider@0.6.2(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-compilation-targets': 7.23.6 - '@babel/helper-plugin-utils': 7.22.5 - debug: 4.3.4(supports-color@6.1.0) + '@babel/core': 7.25.9 + '@babel/helper-compilation-targets': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 + debug: 4.3.7(supports-color@6.1.0) lodash.debounce: 4.0.8 resolve: 1.22.8 transitivePeerDependencies: - supports-color - '@babel/helper-environment-visitor@7.22.20': {} - - '@babel/helper-function-name@7.23.0': - dependencies: - '@babel/template': 7.23.9 - '@babel/types': 7.23.9 - - '@babel/helper-hoist-variables@7.22.5': - dependencies: - '@babel/types': 7.23.9 - - '@babel/helper-member-expression-to-functions@7.23.0': - dependencies: - '@babel/types': 7.23.9 - - '@babel/helper-module-imports@7.22.15': - dependencies: - '@babel/types': 7.23.9 - - '@babel/helper-module-transforms@7.23.3(@babel/core@7.23.9)': - dependencies: - '@babel/core': 7.23.9 - '@babel/helper-environment-visitor': 7.22.20 - '@babel/helper-module-imports': 7.22.15 - '@babel/helper-simple-access': 7.22.5 - '@babel/helper-split-export-declaration': 7.22.6 - '@babel/helper-validator-identifier': 7.22.20 - - '@babel/helper-optimise-call-expression@7.22.5': + '@babel/helper-member-expression-to-functions@7.25.9': dependencies: - '@babel/types': 7.23.9 - - '@babel/helper-plugin-utils@7.22.5': {} + '@babel/traverse': 7.25.9 + '@babel/types': 7.25.9 + transitivePeerDependencies: + - supports-color - '@babel/helper-remap-async-to-generator@7.22.20(@babel/core@7.23.9)': + '@babel/helper-module-imports@7.25.9': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-annotate-as-pure': 7.22.5 - '@babel/helper-environment-visitor': 7.22.20 - '@babel/helper-wrap-function': 7.22.20 + '@babel/traverse': 7.25.9 + '@babel/types': 7.25.9 + transitivePeerDependencies: + - supports-color - '@babel/helper-replace-supers@7.22.20(@babel/core@7.23.9)': + '@babel/helper-module-transforms@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-environment-visitor': 7.22.20 - '@babel/helper-member-expression-to-functions': 7.23.0 - '@babel/helper-optimise-call-expression': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-module-imports': 7.25.9 + '@babel/helper-simple-access': 7.25.9 + '@babel/helper-validator-identifier': 7.25.9 + '@babel/traverse': 7.25.9 + transitivePeerDependencies: + - supports-color - '@babel/helper-simple-access@7.22.5': + '@babel/helper-optimise-call-expression@7.25.9': dependencies: - '@babel/types': 7.23.9 + '@babel/types': 7.25.9 - '@babel/helper-skip-transparent-expression-wrappers@7.22.5': - dependencies: - '@babel/types': 7.23.9 + '@babel/helper-plugin-utils@7.25.9': {} - '@babel/helper-split-export-declaration@7.22.6': + '@babel/helper-remap-async-to-generator@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/types': 7.23.9 - - '@babel/helper-string-parser@7.23.4': {} - - '@babel/helper-validator-identifier@7.22.20': {} - - '@babel/helper-validator-option@7.23.5': {} + '@babel/core': 7.25.9 + '@babel/helper-annotate-as-pure': 7.25.9 + '@babel/helper-wrap-function': 7.25.9 + '@babel/traverse': 7.25.9 + transitivePeerDependencies: + - supports-color - '@babel/helper-wrap-function@7.22.20': + '@babel/helper-replace-supers@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/helper-function-name': 7.23.0 - '@babel/template': 7.23.9 - '@babel/types': 7.23.9 + '@babel/core': 7.25.9 + '@babel/helper-member-expression-to-functions': 7.25.9 + '@babel/helper-optimise-call-expression': 7.25.9 + '@babel/traverse': 7.25.9 + transitivePeerDependencies: + - supports-color - '@babel/helpers@7.23.9': + '@babel/helper-simple-access@7.25.9': dependencies: - '@babel/template': 7.23.9 - '@babel/traverse': 7.23.9 - '@babel/types': 7.23.9 + '@babel/traverse': 7.25.9 + '@babel/types': 7.25.9 transitivePeerDependencies: - supports-color - '@babel/highlight@7.23.4': + '@babel/helper-skip-transparent-expression-wrappers@7.25.9': dependencies: - '@babel/helper-validator-identifier': 7.22.20 - chalk: 2.4.2 - js-tokens: 4.0.0 + '@babel/traverse': 7.25.9 + '@babel/types': 7.25.9 + transitivePeerDependencies: + - supports-color - '@babel/parser@7.23.9': - dependencies: - '@babel/types': 7.23.9 + '@babel/helper-string-parser@7.25.9': {} - '@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression@7.23.3(@babel/core@7.23.9)': - dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/helper-validator-identifier@7.25.9': {} - '@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining@7.23.3(@babel/core@7.23.9)': - dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/helper-skip-transparent-expression-wrappers': 7.22.5 - '@babel/plugin-transform-optional-chaining': 7.23.4(@babel/core@7.23.9) + '@babel/helper-validator-option@7.25.9': {} - '@babel/plugin-bugfix-v8-static-class-fields-redefine-readonly@7.23.7(@babel/core@7.23.9)': + '@babel/helper-wrap-function@7.25.9': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-environment-visitor': 7.22.20 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/template': 7.25.9 + '@babel/traverse': 7.25.9 + '@babel/types': 7.25.9 + transitivePeerDependencies: + - supports-color - '@babel/plugin-proposal-private-property-in-object@7.21.0-placeholder-for-preset-env.2(@babel/core@7.23.9)': + '@babel/helpers@7.25.9': dependencies: - '@babel/core': 7.23.9 + '@babel/template': 7.25.9 + '@babel/types': 7.25.9 - '@babel/plugin-syntax-async-generators@7.8.4(@babel/core@7.23.9)': + '@babel/highlight@7.25.9': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/helper-validator-identifier': 7.25.9 + chalk: 2.4.2 + js-tokens: 4.0.0 + picocolors: 1.1.1 - '@babel/plugin-syntax-class-properties@7.12.13(@babel/core@7.23.9)': + '@babel/parser@7.25.9': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/types': 7.25.9 - '@babel/plugin-syntax-class-static-block@7.14.5(@babel/core@7.23.9)': + '@babel/plugin-bugfix-firefox-class-in-computed-class-key@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 + '@babel/traverse': 7.25.9 + transitivePeerDependencies: + - supports-color - '@babel/plugin-syntax-dynamic-import@7.8.3(@babel/core@7.23.9)': + '@babel/plugin-bugfix-safari-class-field-initializer-scope@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 - '@babel/plugin-syntax-export-namespace-from@7.8.3(@babel/core@7.23.9)': + '@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 - '@babel/plugin-syntax-import-assertions@7.23.3(@babel/core@7.23.9)': + '@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 + '@babel/helper-skip-transparent-expression-wrappers': 7.25.9 + '@babel/plugin-transform-optional-chaining': 7.25.9(@babel/core@7.25.9) + transitivePeerDependencies: + - supports-color - '@babel/plugin-syntax-import-attributes@7.23.3(@babel/core@7.23.9)': + '@babel/plugin-bugfix-v8-static-class-fields-redefine-readonly@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 + '@babel/traverse': 7.25.9 + transitivePeerDependencies: + - supports-color - '@babel/plugin-syntax-import-meta@7.10.4(@babel/core@7.23.9)': + '@babel/plugin-proposal-private-property-in-object@7.21.0-placeholder-for-preset-env.2(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.25.9 - '@babel/plugin-syntax-json-strings@7.8.3(@babel/core@7.23.9)': + '@babel/plugin-syntax-import-assertions@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 - '@babel/plugin-syntax-jsx@7.23.3(@babel/core@7.23.9)': + '@babel/plugin-syntax-import-attributes@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 - '@babel/plugin-syntax-logical-assignment-operators@7.10.4(@babel/core@7.23.9)': + '@babel/plugin-syntax-jsx@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 - '@babel/plugin-syntax-nullish-coalescing-operator@7.8.3(@babel/core@7.23.9)': + '@babel/plugin-syntax-typescript@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 - '@babel/plugin-syntax-numeric-separator@7.10.4(@babel/core@7.23.9)': + '@babel/plugin-syntax-unicode-sets-regex@7.18.6(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-create-regexp-features-plugin': 7.25.9(@babel/core@7.25.9) + '@babel/helper-plugin-utils': 7.25.9 - '@babel/plugin-syntax-object-rest-spread@7.8.3(@babel/core@7.23.9)': + '@babel/plugin-transform-arrow-functions@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 - '@babel/plugin-syntax-optional-catch-binding@7.8.3(@babel/core@7.23.9)': + '@babel/plugin-transform-async-generator-functions@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 + '@babel/helper-remap-async-to-generator': 7.25.9(@babel/core@7.25.9) + '@babel/traverse': 7.25.9 + transitivePeerDependencies: + - supports-color - '@babel/plugin-syntax-optional-chaining@7.8.3(@babel/core@7.23.9)': + '@babel/plugin-transform-async-to-generator@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-module-imports': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 + '@babel/helper-remap-async-to-generator': 7.25.9(@babel/core@7.25.9) + transitivePeerDependencies: + - supports-color - '@babel/plugin-syntax-private-property-in-object@7.14.5(@babel/core@7.23.9)': + '@babel/plugin-transform-block-scoped-functions@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 - '@babel/plugin-syntax-top-level-await@7.14.5(@babel/core@7.23.9)': + '@babel/plugin-transform-block-scoping@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 - '@babel/plugin-syntax-typescript@7.23.3(@babel/core@7.23.9)': + '@babel/plugin-transform-class-properties@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-create-class-features-plugin': 7.25.9(@babel/core@7.25.9) + '@babel/helper-plugin-utils': 7.25.9 + transitivePeerDependencies: + - supports-color - '@babel/plugin-syntax-unicode-sets-regex@7.18.6(@babel/core@7.23.9)': + '@babel/plugin-transform-class-static-block@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-create-regexp-features-plugin': 7.22.15(@babel/core@7.23.9) - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-create-class-features-plugin': 7.25.9(@babel/core@7.25.9) + '@babel/helper-plugin-utils': 7.25.9 + transitivePeerDependencies: + - supports-color - '@babel/plugin-transform-arrow-functions@7.23.3(@babel/core@7.23.9)': + '@babel/plugin-transform-classes@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-annotate-as-pure': 7.25.9 + '@babel/helper-compilation-targets': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 + '@babel/helper-replace-supers': 7.25.9(@babel/core@7.25.9) + '@babel/traverse': 7.25.9 + globals: 11.12.0 + transitivePeerDependencies: + - supports-color - '@babel/plugin-transform-async-generator-functions@7.23.9(@babel/core@7.23.9)': + '@babel/plugin-transform-computed-properties@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-environment-visitor': 7.22.20 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/helper-remap-async-to-generator': 7.22.20(@babel/core@7.23.9) - '@babel/plugin-syntax-async-generators': 7.8.4(@babel/core@7.23.9) + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 + '@babel/template': 7.25.9 - '@babel/plugin-transform-async-to-generator@7.23.3(@babel/core@7.23.9)': + '@babel/plugin-transform-destructuring@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-module-imports': 7.22.15 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/helper-remap-async-to-generator': 7.22.20(@babel/core@7.23.9) + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 - '@babel/plugin-transform-block-scoped-functions@7.23.3(@babel/core@7.23.9)': + '@babel/plugin-transform-dotall-regex@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-create-regexp-features-plugin': 7.25.9(@babel/core@7.25.9) + '@babel/helper-plugin-utils': 7.25.9 - '@babel/plugin-transform-block-scoping@7.23.4(@babel/core@7.23.9)': + '@babel/plugin-transform-duplicate-keys@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 - '@babel/plugin-transform-class-properties@7.23.3(@babel/core@7.23.9)': + '@babel/plugin-transform-duplicate-named-capturing-groups-regex@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-create-class-features-plugin': 7.23.10(@babel/core@7.23.9) - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-create-regexp-features-plugin': 7.25.9(@babel/core@7.25.9) + '@babel/helper-plugin-utils': 7.25.9 - '@babel/plugin-transform-class-static-block@7.23.4(@babel/core@7.23.9)': + '@babel/plugin-transform-dynamic-import@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-create-class-features-plugin': 7.23.10(@babel/core@7.23.9) - '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-class-static-block': 7.14.5(@babel/core@7.23.9) + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 - '@babel/plugin-transform-classes@7.23.8(@babel/core@7.23.9)': + '@babel/plugin-transform-exponentiation-operator@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-annotate-as-pure': 7.22.5 - '@babel/helper-compilation-targets': 7.23.6 - '@babel/helper-environment-visitor': 7.22.20 - '@babel/helper-function-name': 7.23.0 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/helper-replace-supers': 7.22.20(@babel/core@7.23.9) - '@babel/helper-split-export-declaration': 7.22.6 - globals: 11.12.0 + '@babel/core': 7.25.9 + '@babel/helper-builder-binary-assignment-operator-visitor': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 + transitivePeerDependencies: + - supports-color - '@babel/plugin-transform-computed-properties@7.23.3(@babel/core@7.23.9)': + '@babel/plugin-transform-export-namespace-from@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/template': 7.23.9 + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 - '@babel/plugin-transform-destructuring@7.23.3(@babel/core@7.23.9)': + '@babel/plugin-transform-for-of@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 + '@babel/helper-skip-transparent-expression-wrappers': 7.25.9 + transitivePeerDependencies: + - supports-color - '@babel/plugin-transform-dotall-regex@7.23.3(@babel/core@7.23.9)': + '@babel/plugin-transform-function-name@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-create-regexp-features-plugin': 7.22.15(@babel/core@7.23.9) - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-compilation-targets': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 + '@babel/traverse': 7.25.9 + transitivePeerDependencies: + - supports-color - '@babel/plugin-transform-duplicate-keys@7.23.3(@babel/core@7.23.9)': + '@babel/plugin-transform-json-strings@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 - '@babel/plugin-transform-dynamic-import@7.23.4(@babel/core@7.23.9)': + '@babel/plugin-transform-literals@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-dynamic-import': 7.8.3(@babel/core@7.23.9) + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 - '@babel/plugin-transform-exponentiation-operator@7.23.3(@babel/core@7.23.9)': + '@babel/plugin-transform-logical-assignment-operators@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-builder-binary-assignment-operator-visitor': 7.22.15 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 - '@babel/plugin-transform-export-namespace-from@7.23.4(@babel/core@7.23.9)': + '@babel/plugin-transform-member-expression-literals@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-export-namespace-from': 7.8.3(@babel/core@7.23.9) + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 - '@babel/plugin-transform-for-of@7.23.6(@babel/core@7.23.9)': + '@babel/plugin-transform-modules-amd@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/helper-skip-transparent-expression-wrappers': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-module-transforms': 7.25.9(@babel/core@7.25.9) + '@babel/helper-plugin-utils': 7.25.9 + transitivePeerDependencies: + - supports-color - '@babel/plugin-transform-function-name@7.23.3(@babel/core@7.23.9)': + '@babel/plugin-transform-modules-commonjs@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-compilation-targets': 7.23.6 - '@babel/helper-function-name': 7.23.0 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-module-transforms': 7.25.9(@babel/core@7.25.9) + '@babel/helper-plugin-utils': 7.25.9 + '@babel/helper-simple-access': 7.25.9 + transitivePeerDependencies: + - supports-color - '@babel/plugin-transform-json-strings@7.23.4(@babel/core@7.23.9)': + '@babel/plugin-transform-modules-systemjs@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-json-strings': 7.8.3(@babel/core@7.23.9) + '@babel/core': 7.25.9 + '@babel/helper-module-transforms': 7.25.9(@babel/core@7.25.9) + '@babel/helper-plugin-utils': 7.25.9 + '@babel/helper-validator-identifier': 7.25.9 + '@babel/traverse': 7.25.9 + transitivePeerDependencies: + - supports-color - '@babel/plugin-transform-literals@7.23.3(@babel/core@7.23.9)': + '@babel/plugin-transform-modules-umd@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-module-transforms': 7.25.9(@babel/core@7.25.9) + '@babel/helper-plugin-utils': 7.25.9 + transitivePeerDependencies: + - supports-color - '@babel/plugin-transform-logical-assignment-operators@7.23.4(@babel/core@7.23.9)': + '@babel/plugin-transform-named-capturing-groups-regex@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-logical-assignment-operators': 7.10.4(@babel/core@7.23.9) + '@babel/core': 7.25.9 + '@babel/helper-create-regexp-features-plugin': 7.25.9(@babel/core@7.25.9) + '@babel/helper-plugin-utils': 7.25.9 - '@babel/plugin-transform-member-expression-literals@7.23.3(@babel/core@7.23.9)': + '@babel/plugin-transform-new-target@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 - '@babel/plugin-transform-modules-amd@7.23.3(@babel/core@7.23.9)': + '@babel/plugin-transform-nullish-coalescing-operator@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-module-transforms': 7.23.3(@babel/core@7.23.9) - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 - '@babel/plugin-transform-modules-commonjs@7.23.3(@babel/core@7.23.9)': + '@babel/plugin-transform-numeric-separator@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-module-transforms': 7.23.3(@babel/core@7.23.9) - '@babel/helper-plugin-utils': 7.22.5 - '@babel/helper-simple-access': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 - '@babel/plugin-transform-modules-systemjs@7.23.9(@babel/core@7.23.9)': + '@babel/plugin-transform-object-rest-spread@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-hoist-variables': 7.22.5 - '@babel/helper-module-transforms': 7.23.3(@babel/core@7.23.9) - '@babel/helper-plugin-utils': 7.22.5 - '@babel/helper-validator-identifier': 7.22.20 + '@babel/core': 7.25.9 + '@babel/helper-compilation-targets': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 + '@babel/plugin-transform-parameters': 7.25.9(@babel/core@7.25.9) - '@babel/plugin-transform-modules-umd@7.23.3(@babel/core@7.23.9)': + '@babel/plugin-transform-object-super@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-module-transforms': 7.23.3(@babel/core@7.23.9) - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 + '@babel/helper-replace-supers': 7.25.9(@babel/core@7.25.9) + transitivePeerDependencies: + - supports-color - '@babel/plugin-transform-named-capturing-groups-regex@7.22.5(@babel/core@7.23.9)': + '@babel/plugin-transform-optional-catch-binding@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-create-regexp-features-plugin': 7.22.15(@babel/core@7.23.9) - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 - '@babel/plugin-transform-new-target@7.23.3(@babel/core@7.23.9)': + '@babel/plugin-transform-optional-chaining@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 + '@babel/helper-skip-transparent-expression-wrappers': 7.25.9 + transitivePeerDependencies: + - supports-color - '@babel/plugin-transform-nullish-coalescing-operator@7.23.4(@babel/core@7.23.9)': + '@babel/plugin-transform-parameters@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-nullish-coalescing-operator': 7.8.3(@babel/core@7.23.9) + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 - '@babel/plugin-transform-numeric-separator@7.23.4(@babel/core@7.23.9)': + '@babel/plugin-transform-private-methods@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-numeric-separator': 7.10.4(@babel/core@7.23.9) + '@babel/core': 7.25.9 + '@babel/helper-create-class-features-plugin': 7.25.9(@babel/core@7.25.9) + '@babel/helper-plugin-utils': 7.25.9 + transitivePeerDependencies: + - supports-color - '@babel/plugin-transform-object-rest-spread@7.23.4(@babel/core@7.23.9)': + '@babel/plugin-transform-private-property-in-object@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/compat-data': 7.23.5 - '@babel/core': 7.23.9 - '@babel/helper-compilation-targets': 7.23.6 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-object-rest-spread': 7.8.3(@babel/core@7.23.9) - '@babel/plugin-transform-parameters': 7.23.3(@babel/core@7.23.9) + '@babel/core': 7.25.9 + '@babel/helper-annotate-as-pure': 7.25.9 + '@babel/helper-create-class-features-plugin': 7.25.9(@babel/core@7.25.9) + '@babel/helper-plugin-utils': 7.25.9 + transitivePeerDependencies: + - supports-color - '@babel/plugin-transform-object-super@7.23.3(@babel/core@7.23.9)': + '@babel/plugin-transform-property-literals@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/helper-replace-supers': 7.22.20(@babel/core@7.23.9) + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 - '@babel/plugin-transform-optional-catch-binding@7.23.4(@babel/core@7.23.9)': + '@babel/plugin-transform-regenerator@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-optional-catch-binding': 7.8.3(@babel/core@7.23.9) + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 + regenerator-transform: 0.15.2 - '@babel/plugin-transform-optional-chaining@7.23.4(@babel/core@7.23.9)': + '@babel/plugin-transform-reserved-words@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/helper-skip-transparent-expression-wrappers': 7.22.5 - '@babel/plugin-syntax-optional-chaining': 7.8.3(@babel/core@7.23.9) + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 - '@babel/plugin-transform-parameters@7.23.3(@babel/core@7.23.9)': + '@babel/plugin-transform-runtime@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-module-imports': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 + babel-plugin-polyfill-corejs2: 0.4.11(@babel/core@7.25.9) + babel-plugin-polyfill-corejs3: 0.10.6(@babel/core@7.25.9) + babel-plugin-polyfill-regenerator: 0.6.2(@babel/core@7.25.9) + semver: 6.3.1 + transitivePeerDependencies: + - supports-color - '@babel/plugin-transform-private-methods@7.23.3(@babel/core@7.23.9)': + '@babel/plugin-transform-shorthand-properties@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-create-class-features-plugin': 7.23.10(@babel/core@7.23.9) - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 - '@babel/plugin-transform-private-property-in-object@7.23.4(@babel/core@7.23.9)': + '@babel/plugin-transform-spread@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-annotate-as-pure': 7.22.5 - '@babel/helper-create-class-features-plugin': 7.23.10(@babel/core@7.23.9) - '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-private-property-in-object': 7.14.5(@babel/core@7.23.9) + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 + '@babel/helper-skip-transparent-expression-wrappers': 7.25.9 + transitivePeerDependencies: + - supports-color - '@babel/plugin-transform-property-literals@7.23.3(@babel/core@7.23.9)': + '@babel/plugin-transform-sticky-regex@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 - '@babel/plugin-transform-regenerator@7.23.3(@babel/core@7.23.9)': + '@babel/plugin-transform-template-literals@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 - regenerator-transform: 0.15.2 + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 - '@babel/plugin-transform-reserved-words@7.23.3(@babel/core@7.23.9)': + '@babel/plugin-transform-typeof-symbol@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 - '@babel/plugin-transform-runtime@7.23.9(@babel/core@7.23.9)': + '@babel/plugin-transform-typescript@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-module-imports': 7.22.15 - '@babel/helper-plugin-utils': 7.22.5 - babel-plugin-polyfill-corejs2: 0.4.8(@babel/core@7.23.9) - babel-plugin-polyfill-corejs3: 0.9.0(@babel/core@7.23.9) - babel-plugin-polyfill-regenerator: 0.5.5(@babel/core@7.23.9) - semver: 6.3.1 + '@babel/core': 7.25.9 + '@babel/helper-annotate-as-pure': 7.25.9 + '@babel/helper-create-class-features-plugin': 7.25.9(@babel/core@7.25.9) + '@babel/helper-plugin-utils': 7.25.9 + '@babel/helper-skip-transparent-expression-wrappers': 7.25.9 + '@babel/plugin-syntax-typescript': 7.25.9(@babel/core@7.25.9) transitivePeerDependencies: - supports-color - '@babel/plugin-transform-shorthand-properties@7.23.3(@babel/core@7.23.9)': - dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 - - '@babel/plugin-transform-spread@7.23.3(@babel/core@7.23.9)': - dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/helper-skip-transparent-expression-wrappers': 7.22.5 - - '@babel/plugin-transform-sticky-regex@7.23.3(@babel/core@7.23.9)': - dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 - - '@babel/plugin-transform-template-literals@7.23.3(@babel/core@7.23.9)': - dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 - - '@babel/plugin-transform-typeof-symbol@7.23.3(@babel/core@7.23.9)': - dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 - - '@babel/plugin-transform-typescript@7.23.6(@babel/core@7.23.9)': - dependencies: - '@babel/core': 7.23.9 - '@babel/helper-annotate-as-pure': 7.22.5 - '@babel/helper-create-class-features-plugin': 7.23.10(@babel/core@7.23.9) - '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-typescript': 7.23.3(@babel/core@7.23.9) - - '@babel/plugin-transform-unicode-escapes@7.23.3(@babel/core@7.23.9)': - dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 - - '@babel/plugin-transform-unicode-property-regex@7.23.3(@babel/core@7.23.9)': - dependencies: - '@babel/core': 7.23.9 - '@babel/helper-create-regexp-features-plugin': 7.22.15(@babel/core@7.23.9) - '@babel/helper-plugin-utils': 7.22.5 - - '@babel/plugin-transform-unicode-regex@7.23.3(@babel/core@7.23.9)': - dependencies: - '@babel/core': 7.23.9 - '@babel/helper-create-regexp-features-plugin': 7.22.15(@babel/core@7.23.9) - '@babel/helper-plugin-utils': 7.22.5 - - '@babel/plugin-transform-unicode-sets-regex@7.23.3(@babel/core@7.23.9)': - dependencies: - '@babel/core': 7.23.9 - '@babel/helper-create-regexp-features-plugin': 7.22.15(@babel/core@7.23.9) - '@babel/helper-plugin-utils': 7.22.5 - - '@babel/preset-env@7.23.9(@babel/core@7.23.9)': - dependencies: - '@babel/compat-data': 7.23.5 - '@babel/core': 7.23.9 - '@babel/helper-compilation-targets': 7.23.6 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/helper-validator-option': 7.23.5 - '@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-bugfix-v8-static-class-fields-redefine-readonly': 7.23.7(@babel/core@7.23.9) - '@babel/plugin-proposal-private-property-in-object': 7.21.0-placeholder-for-preset-env.2(@babel/core@7.23.9) - '@babel/plugin-syntax-async-generators': 7.8.4(@babel/core@7.23.9) - '@babel/plugin-syntax-class-properties': 7.12.13(@babel/core@7.23.9) - '@babel/plugin-syntax-class-static-block': 7.14.5(@babel/core@7.23.9) - '@babel/plugin-syntax-dynamic-import': 7.8.3(@babel/core@7.23.9) - '@babel/plugin-syntax-export-namespace-from': 7.8.3(@babel/core@7.23.9) - '@babel/plugin-syntax-import-assertions': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-syntax-import-attributes': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-syntax-import-meta': 7.10.4(@babel/core@7.23.9) - '@babel/plugin-syntax-json-strings': 7.8.3(@babel/core@7.23.9) - '@babel/plugin-syntax-logical-assignment-operators': 7.10.4(@babel/core@7.23.9) - '@babel/plugin-syntax-nullish-coalescing-operator': 7.8.3(@babel/core@7.23.9) - '@babel/plugin-syntax-numeric-separator': 7.10.4(@babel/core@7.23.9) - '@babel/plugin-syntax-object-rest-spread': 7.8.3(@babel/core@7.23.9) - '@babel/plugin-syntax-optional-catch-binding': 7.8.3(@babel/core@7.23.9) - '@babel/plugin-syntax-optional-chaining': 7.8.3(@babel/core@7.23.9) - '@babel/plugin-syntax-private-property-in-object': 7.14.5(@babel/core@7.23.9) - '@babel/plugin-syntax-top-level-await': 7.14.5(@babel/core@7.23.9) - '@babel/plugin-syntax-unicode-sets-regex': 7.18.6(@babel/core@7.23.9) - '@babel/plugin-transform-arrow-functions': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-async-generator-functions': 7.23.9(@babel/core@7.23.9) - '@babel/plugin-transform-async-to-generator': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-block-scoped-functions': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-block-scoping': 7.23.4(@babel/core@7.23.9) - '@babel/plugin-transform-class-properties': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-class-static-block': 7.23.4(@babel/core@7.23.9) - '@babel/plugin-transform-classes': 7.23.8(@babel/core@7.23.9) - '@babel/plugin-transform-computed-properties': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-destructuring': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-dotall-regex': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-duplicate-keys': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-dynamic-import': 7.23.4(@babel/core@7.23.9) - '@babel/plugin-transform-exponentiation-operator': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-export-namespace-from': 7.23.4(@babel/core@7.23.9) - '@babel/plugin-transform-for-of': 7.23.6(@babel/core@7.23.9) - '@babel/plugin-transform-function-name': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-json-strings': 7.23.4(@babel/core@7.23.9) - '@babel/plugin-transform-literals': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-logical-assignment-operators': 7.23.4(@babel/core@7.23.9) - '@babel/plugin-transform-member-expression-literals': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-modules-amd': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-modules-commonjs': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-modules-systemjs': 7.23.9(@babel/core@7.23.9) - '@babel/plugin-transform-modules-umd': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-named-capturing-groups-regex': 7.22.5(@babel/core@7.23.9) - '@babel/plugin-transform-new-target': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-nullish-coalescing-operator': 7.23.4(@babel/core@7.23.9) - '@babel/plugin-transform-numeric-separator': 7.23.4(@babel/core@7.23.9) - '@babel/plugin-transform-object-rest-spread': 7.23.4(@babel/core@7.23.9) - '@babel/plugin-transform-object-super': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-optional-catch-binding': 7.23.4(@babel/core@7.23.9) - '@babel/plugin-transform-optional-chaining': 7.23.4(@babel/core@7.23.9) - '@babel/plugin-transform-parameters': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-private-methods': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-private-property-in-object': 7.23.4(@babel/core@7.23.9) - '@babel/plugin-transform-property-literals': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-regenerator': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-reserved-words': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-shorthand-properties': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-spread': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-sticky-regex': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-template-literals': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-typeof-symbol': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-unicode-escapes': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-unicode-property-regex': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-unicode-regex': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-unicode-sets-regex': 7.23.3(@babel/core@7.23.9) - '@babel/preset-modules': 0.1.6-no-external-plugins(@babel/core@7.23.9) - babel-plugin-polyfill-corejs2: 0.4.8(@babel/core@7.23.9) - babel-plugin-polyfill-corejs3: 0.9.0(@babel/core@7.23.9) - babel-plugin-polyfill-regenerator: 0.5.5(@babel/core@7.23.9) - core-js-compat: 3.36.0 + '@babel/plugin-transform-unicode-escapes@7.25.9(@babel/core@7.25.9)': + dependencies: + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 + + '@babel/plugin-transform-unicode-property-regex@7.25.9(@babel/core@7.25.9)': + dependencies: + '@babel/core': 7.25.9 + '@babel/helper-create-regexp-features-plugin': 7.25.9(@babel/core@7.25.9) + '@babel/helper-plugin-utils': 7.25.9 + + '@babel/plugin-transform-unicode-regex@7.25.9(@babel/core@7.25.9)': + dependencies: + '@babel/core': 7.25.9 + '@babel/helper-create-regexp-features-plugin': 7.25.9(@babel/core@7.25.9) + '@babel/helper-plugin-utils': 7.25.9 + + '@babel/plugin-transform-unicode-sets-regex@7.25.9(@babel/core@7.25.9)': + dependencies: + '@babel/core': 7.25.9 + '@babel/helper-create-regexp-features-plugin': 7.25.9(@babel/core@7.25.9) + '@babel/helper-plugin-utils': 7.25.9 + + '@babel/preset-env@7.25.9(@babel/core@7.25.9)': + dependencies: + '@babel/compat-data': 7.25.9 + '@babel/core': 7.25.9 + '@babel/helper-compilation-targets': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 + '@babel/helper-validator-option': 7.25.9 + '@babel/plugin-bugfix-firefox-class-in-computed-class-key': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-bugfix-safari-class-field-initializer-scope': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-bugfix-v8-static-class-fields-redefine-readonly': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-proposal-private-property-in-object': 7.21.0-placeholder-for-preset-env.2(@babel/core@7.25.9) + '@babel/plugin-syntax-import-assertions': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-syntax-import-attributes': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-syntax-unicode-sets-regex': 7.18.6(@babel/core@7.25.9) + '@babel/plugin-transform-arrow-functions': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-async-generator-functions': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-async-to-generator': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-block-scoped-functions': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-block-scoping': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-class-properties': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-class-static-block': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-classes': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-computed-properties': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-destructuring': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-dotall-regex': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-duplicate-keys': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-duplicate-named-capturing-groups-regex': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-dynamic-import': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-exponentiation-operator': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-export-namespace-from': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-for-of': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-function-name': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-json-strings': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-literals': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-logical-assignment-operators': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-member-expression-literals': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-modules-amd': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-modules-commonjs': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-modules-systemjs': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-modules-umd': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-named-capturing-groups-regex': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-new-target': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-nullish-coalescing-operator': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-numeric-separator': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-object-rest-spread': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-object-super': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-optional-catch-binding': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-optional-chaining': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-parameters': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-private-methods': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-private-property-in-object': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-property-literals': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-regenerator': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-reserved-words': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-shorthand-properties': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-spread': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-sticky-regex': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-template-literals': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-typeof-symbol': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-unicode-escapes': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-unicode-property-regex': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-unicode-regex': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-unicode-sets-regex': 7.25.9(@babel/core@7.25.9) + '@babel/preset-modules': 0.1.6-no-external-plugins(@babel/core@7.25.9) + babel-plugin-polyfill-corejs2: 0.4.11(@babel/core@7.25.9) + babel-plugin-polyfill-corejs3: 0.10.6(@babel/core@7.25.9) + babel-plugin-polyfill-regenerator: 0.6.2(@babel/core@7.25.9) + core-js-compat: 3.38.1 semver: 6.3.1 transitivePeerDependencies: - supports-color - '@babel/preset-modules@0.1.6-no-external-plugins(@babel/core@7.23.9)': + '@babel/preset-modules@0.1.6-no-external-plugins(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/types': 7.23.9 + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 + '@babel/types': 7.25.9 esutils: 2.0.3 - '@babel/preset-typescript@7.23.3(@babel/core@7.23.9)': + '@babel/preset-typescript@7.25.9(@babel/core@7.25.9)': dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/helper-validator-option': 7.23.5 - '@babel/plugin-syntax-jsx': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-modules-commonjs': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-typescript': 7.23.6(@babel/core@7.23.9) - - '@babel/regjsgen@0.8.0': {} + '@babel/core': 7.25.9 + '@babel/helper-plugin-utils': 7.25.9 + '@babel/helper-validator-option': 7.25.9 + '@babel/plugin-syntax-jsx': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-modules-commonjs': 7.25.9(@babel/core@7.25.9) + '@babel/plugin-transform-typescript': 7.25.9(@babel/core@7.25.9) + transitivePeerDependencies: + - supports-color - '@babel/runtime@7.23.9': + '@babel/runtime@7.25.9': dependencies: regenerator-runtime: 0.14.1 - '@babel/template@7.23.9': + '@babel/template@7.25.9': dependencies: - '@babel/code-frame': 7.23.5 - '@babel/parser': 7.23.9 - '@babel/types': 7.23.9 + '@babel/code-frame': 7.25.9 + '@babel/parser': 7.25.9 + '@babel/types': 7.25.9 - '@babel/traverse@7.23.9': + '@babel/traverse@7.25.9': dependencies: - '@babel/code-frame': 7.23.5 - '@babel/generator': 7.23.6 - '@babel/helper-environment-visitor': 7.22.20 - '@babel/helper-function-name': 7.23.0 - '@babel/helper-hoist-variables': 7.22.5 - '@babel/helper-split-export-declaration': 7.22.6 - '@babel/parser': 7.23.9 - '@babel/types': 7.23.9 - debug: 4.3.4(supports-color@6.1.0) + '@babel/code-frame': 7.25.9 + '@babel/generator': 7.25.9 + '@babel/parser': 7.25.9 + '@babel/template': 7.25.9 + '@babel/types': 7.25.9 + debug: 4.3.7(supports-color@6.1.0) globals: 11.12.0 transitivePeerDependencies: - supports-color - '@babel/types@7.23.9': + '@babel/types@7.25.9': dependencies: - '@babel/helper-string-parser': 7.23.4 - '@babel/helper-validator-identifier': 7.22.20 - to-fast-properties: 2.0.0 + '@babel/helper-string-parser': 7.25.9 + '@babel/helper-validator-identifier': 7.25.9 - '@changesets/apply-release-plan@7.0.0': + '@changesets/apply-release-plan@7.0.5': dependencies: - '@babel/runtime': 7.23.9 - '@changesets/config': 3.0.0 + '@changesets/config': 3.0.3 '@changesets/get-version-range-type': 0.4.0 - '@changesets/git': 3.0.0 + '@changesets/git': 3.0.1 + '@changesets/should-skip-package': 0.1.1 '@changesets/types': 6.0.0 '@manypkg/get-packages': 1.1.3 detect-indent: 6.1.0 @@ -9337,16 +9050,16 @@ snapshots: outdent: 0.5.0 prettier: 2.8.8 resolve-from: 5.0.0 - semver: 7.6.0 + semver: 7.6.3 - '@changesets/assemble-release-plan@6.0.0': + '@changesets/assemble-release-plan@6.0.4': dependencies: - '@babel/runtime': 7.23.9 '@changesets/errors': 0.2.0 - '@changesets/get-dependents-graph': 2.0.0 + '@changesets/get-dependents-graph': 2.1.2 + '@changesets/should-skip-package': 0.1.1 '@changesets/types': 6.0.0 '@manypkg/get-packages': 1.1.3 - semver: 7.6.0 + semver: 7.6.3 '@changesets/changelog-git@0.2.0': dependencies: @@ -9360,62 +9073,57 @@ snapshots: transitivePeerDependencies: - encoding - '@changesets/cli@2.27.1': + '@changesets/cli@2.27.9': dependencies: - '@babel/runtime': 7.23.9 - '@changesets/apply-release-plan': 7.0.0 - '@changesets/assemble-release-plan': 6.0.0 + '@changesets/apply-release-plan': 7.0.5 + '@changesets/assemble-release-plan': 6.0.4 '@changesets/changelog-git': 0.2.0 - '@changesets/config': 3.0.0 + '@changesets/config': 3.0.3 '@changesets/errors': 0.2.0 - '@changesets/get-dependents-graph': 2.0.0 - '@changesets/get-release-plan': 4.0.0 - '@changesets/git': 3.0.0 - '@changesets/logger': 0.1.0 - '@changesets/pre': 2.0.0 - '@changesets/read': 0.6.0 + '@changesets/get-dependents-graph': 2.1.2 + '@changesets/get-release-plan': 4.0.4 + '@changesets/git': 3.0.1 + '@changesets/logger': 0.1.1 + '@changesets/pre': 2.0.1 + '@changesets/read': 0.6.1 + '@changesets/should-skip-package': 0.1.1 '@changesets/types': 6.0.0 - '@changesets/write': 0.3.0 + '@changesets/write': 0.3.2 '@manypkg/get-packages': 1.1.3 - '@types/semver': 7.5.8 ansi-colors: 4.1.3 - chalk: 2.4.2 ci-info: 3.9.0 enquirer: 2.4.1 external-editor: 3.1.0 fs-extra: 7.0.1 - human-id: 1.0.2 - meow: 6.1.1 - outdent: 0.5.0 + mri: 1.2.0 p-limit: 2.3.0 - preferred-pm: 3.1.3 + package-manager-detector: 0.2.2 + picocolors: 1.1.1 resolve-from: 5.0.0 - semver: 7.6.0 + semver: 7.6.3 spawndamnit: 2.0.0 term-size: 2.2.1 - tty-table: 4.2.3 - '@changesets/config@3.0.0': + '@changesets/config@3.0.3': dependencies: '@changesets/errors': 0.2.0 - '@changesets/get-dependents-graph': 2.0.0 - '@changesets/logger': 0.1.0 + '@changesets/get-dependents-graph': 2.1.2 + '@changesets/logger': 0.1.1 '@changesets/types': 6.0.0 '@manypkg/get-packages': 1.1.3 fs-extra: 7.0.1 - micromatch: 4.0.5 + micromatch: 4.0.8 '@changesets/errors@0.2.0': dependencies: extendable-error: 0.1.7 - '@changesets/get-dependents-graph@2.0.0': + '@changesets/get-dependents-graph@2.1.2': dependencies: '@changesets/types': 6.0.0 '@manypkg/get-packages': 1.1.3 - chalk: 2.4.2 - fs-extra: 7.0.1 - semver: 7.6.0 + picocolors: 1.1.1 + semver: 7.6.3 '@changesets/get-github-info@0.6.0': dependencies: @@ -9424,63 +9132,62 @@ snapshots: transitivePeerDependencies: - encoding - '@changesets/get-release-plan@4.0.0': + '@changesets/get-release-plan@4.0.4': dependencies: - '@babel/runtime': 7.23.9 - '@changesets/assemble-release-plan': 6.0.0 - '@changesets/config': 3.0.0 - '@changesets/pre': 2.0.0 - '@changesets/read': 0.6.0 + '@changesets/assemble-release-plan': 6.0.4 + '@changesets/config': 3.0.3 + '@changesets/pre': 2.0.1 + '@changesets/read': 0.6.1 '@changesets/types': 6.0.0 '@manypkg/get-packages': 1.1.3 '@changesets/get-version-range-type@0.4.0': {} - '@changesets/git@3.0.0': + '@changesets/git@3.0.1': dependencies: - '@babel/runtime': 7.23.9 '@changesets/errors': 0.2.0 - '@changesets/types': 6.0.0 '@manypkg/get-packages': 1.1.3 is-subdir: 1.2.0 - micromatch: 4.0.5 + micromatch: 4.0.8 spawndamnit: 2.0.0 - '@changesets/logger@0.1.0': + '@changesets/logger@0.1.1': dependencies: - chalk: 2.4.2 + picocolors: 1.1.1 '@changesets/parse@0.4.0': dependencies: '@changesets/types': 6.0.0 js-yaml: 3.14.1 - '@changesets/pre@2.0.0': + '@changesets/pre@2.0.1': dependencies: - '@babel/runtime': 7.23.9 '@changesets/errors': 0.2.0 '@changesets/types': 6.0.0 '@manypkg/get-packages': 1.1.3 fs-extra: 7.0.1 - '@changesets/read@0.6.0': + '@changesets/read@0.6.1': dependencies: - '@babel/runtime': 7.23.9 - '@changesets/git': 3.0.0 - '@changesets/logger': 0.1.0 + '@changesets/git': 3.0.1 + '@changesets/logger': 0.1.1 '@changesets/parse': 0.4.0 '@changesets/types': 6.0.0 - chalk: 2.4.2 fs-extra: 7.0.1 p-filter: 2.1.0 + picocolors: 1.1.1 + + '@changesets/should-skip-package@0.1.1': + dependencies: + '@changesets/types': 6.0.0 + '@manypkg/get-packages': 1.1.3 '@changesets/types@4.1.0': {} '@changesets/types@6.0.0': {} - '@changesets/write@0.3.0': + '@changesets/write@0.3.2': dependencies: - '@babel/runtime': 7.23.9 '@changesets/types': 6.0.0 fs-extra: 7.0.1 human-id: 1.0.2 @@ -9490,116 +9197,98 @@ snapshots: dependencies: '@jridgewell/trace-mapping': 0.3.9 - '@cypress/request@3.0.1': - dependencies: - aws-sign2: 0.7.0 - aws4: 1.12.0 - caseless: 0.12.0 - combined-stream: 1.0.8 - extend: 3.0.2 - forever-agent: 0.6.1 - form-data: 2.3.3 - http-signature: 1.3.6 - is-typedarray: 1.0.0 - isstream: 0.1.2 - json-stringify-safe: 5.0.1 - mime-types: 2.1.35 - performance-now: 2.1.0 - qs: 6.10.4 - safe-buffer: 5.2.1 - tough-cookie: 4.1.3 - tunnel-agent: 0.6.0 - uuid: 8.3.2 - - '@databeat/tracker@0.9.1': + '@databeat/tracker@0.9.3': dependencies: - '@noble/hashes': 1.3.3 + '@noble/hashes': 1.5.0 '@discoveryjs/json-ext@0.5.7': {} - '@esbuild/aix-ppc64@0.19.12': + '@esbuild/aix-ppc64@0.23.1': optional: true - '@esbuild/android-arm64@0.19.12': + '@esbuild/android-arm64@0.23.1': optional: true - '@esbuild/android-arm@0.19.12': + '@esbuild/android-arm@0.23.1': optional: true - '@esbuild/android-x64@0.19.12': + '@esbuild/android-x64@0.23.1': optional: true - '@esbuild/darwin-arm64@0.19.12': + '@esbuild/darwin-arm64@0.23.1': optional: true - '@esbuild/darwin-x64@0.19.12': + '@esbuild/darwin-x64@0.23.1': optional: true - '@esbuild/freebsd-arm64@0.19.12': + '@esbuild/freebsd-arm64@0.23.1': optional: true - '@esbuild/freebsd-x64@0.19.12': + '@esbuild/freebsd-x64@0.23.1': optional: true - '@esbuild/linux-arm64@0.19.12': + '@esbuild/linux-arm64@0.23.1': optional: true - '@esbuild/linux-arm@0.19.12': + '@esbuild/linux-arm@0.23.1': optional: true - '@esbuild/linux-ia32@0.19.12': + '@esbuild/linux-ia32@0.23.1': optional: true - '@esbuild/linux-loong64@0.19.12': + '@esbuild/linux-loong64@0.23.1': optional: true - '@esbuild/linux-mips64el@0.19.12': + '@esbuild/linux-mips64el@0.23.1': optional: true - '@esbuild/linux-ppc64@0.19.12': + '@esbuild/linux-ppc64@0.23.1': optional: true - '@esbuild/linux-riscv64@0.19.12': + '@esbuild/linux-riscv64@0.23.1': optional: true - '@esbuild/linux-s390x@0.19.12': + '@esbuild/linux-s390x@0.23.1': optional: true - '@esbuild/linux-x64@0.19.12': + '@esbuild/linux-x64@0.23.1': optional: true - '@esbuild/netbsd-x64@0.19.12': + '@esbuild/netbsd-x64@0.23.1': optional: true - '@esbuild/openbsd-x64@0.19.12': + '@esbuild/openbsd-arm64@0.23.1': optional: true - '@esbuild/sunos-x64@0.19.12': + '@esbuild/openbsd-x64@0.23.1': optional: true - '@esbuild/win32-arm64@0.19.12': + '@esbuild/sunos-x64@0.23.1': optional: true - '@esbuild/win32-ia32@0.19.12': + '@esbuild/win32-arm64@0.23.1': optional: true - '@esbuild/win32-x64@0.19.12': + '@esbuild/win32-ia32@0.23.1': optional: true - '@eslint-community/eslint-utils@4.4.0(eslint@8.57.0)': + '@esbuild/win32-x64@0.23.1': + optional: true + + '@eslint-community/eslint-utils@4.4.0(eslint@8.57.1)': dependencies: - eslint: 8.57.0 + eslint: 8.57.1 eslint-visitor-keys: 3.4.3 - '@eslint-community/regexpp@4.10.0': {} + '@eslint-community/regexpp@4.11.1': {} '@eslint/eslintrc@2.1.4': dependencies: ajv: 6.12.6 - debug: 4.3.4(supports-color@6.1.0) + debug: 4.3.7(supports-color@6.1.0) espree: 9.6.1 globals: 13.24.0 - ignore: 5.3.1 + ignore: 5.3.2 import-fresh: 3.3.0 js-yaml: 4.1.0 minimatch: 3.1.2 @@ -9607,7 +9296,7 @@ snapshots: transitivePeerDependencies: - supports-color - '@eslint/js@8.57.0': {} + '@eslint/js@8.57.1': {} '@ethereumjs/common@2.6.5': dependencies: @@ -9624,7 +9313,7 @@ snapshots: '@ethereumjs/util@8.1.0': dependencies: '@ethereumjs/rlp': 4.0.1 - ethereum-cryptography: 2.1.3 + ethereum-cryptography: 2.2.1 micro-ftch: 0.3.1 '@ethersproject/abi@5.7.0': @@ -9657,6 +9346,14 @@ snapshots: '@ethersproject/logger': 5.7.0 '@ethersproject/properties': 5.7.0 + '@ethersproject/address@5.6.1': + dependencies: + '@ethersproject/bignumber': 5.7.0 + '@ethersproject/bytes': 5.7.0 + '@ethersproject/keccak256': 5.7.0 + '@ethersproject/logger': 5.7.0 + '@ethersproject/rlp': 5.7.0 + '@ethersproject/address@5.7.0': dependencies: '@ethersproject/bignumber': 5.7.0 @@ -9764,7 +9461,7 @@ snapshots: dependencies: '@ethersproject/logger': 5.7.0 - '@ethersproject/providers@5.7.2': + '@ethersproject/providers@5.7.2(bufferutil@4.0.8)(utf-8-validate@5.0.10)': dependencies: '@ethersproject/abstract-provider': 5.7.0 '@ethersproject/abstract-signer': 5.7.0 @@ -9785,7 +9482,7 @@ snapshots: '@ethersproject/transactions': 5.7.0 '@ethersproject/web': 5.7.1 bech32: 1.1.4 - ws: 7.4.6 + ws: 7.4.6(bufferutil@4.0.8)(utf-8-validate@5.0.10) transitivePeerDependencies: - bufferutil - utf-8-validate @@ -9882,31 +9579,31 @@ snapshots: '@ethersproject/properties': 5.7.0 '@ethersproject/strings': 5.7.0 - '@fastify/busboy@2.1.0': {} + '@fastify/busboy@2.1.1': {} - '@graphql-tools/merge@8.3.1(graphql@15.8.0)': + '@graphql-tools/merge@8.3.1(graphql@15.9.0)': dependencies: - '@graphql-tools/utils': 8.9.0(graphql@15.8.0) - graphql: 15.8.0 - tslib: 2.6.2 + '@graphql-tools/utils': 8.9.0(graphql@15.9.0) + graphql: 15.9.0 + tslib: 2.8.0 - '@graphql-tools/schema@8.5.1(graphql@15.8.0)': + '@graphql-tools/schema@8.5.1(graphql@15.9.0)': dependencies: - '@graphql-tools/merge': 8.3.1(graphql@15.8.0) - '@graphql-tools/utils': 8.9.0(graphql@15.8.0) - graphql: 15.8.0 - tslib: 2.6.2 + '@graphql-tools/merge': 8.3.1(graphql@15.9.0) + '@graphql-tools/utils': 8.9.0(graphql@15.9.0) + graphql: 15.9.0 + tslib: 2.8.0 value-or-promise: 1.0.11 - '@graphql-tools/utils@8.13.1(graphql@15.8.0)': + '@graphql-tools/utils@8.13.1(graphql@15.9.0)': dependencies: - graphql: 15.8.0 - tslib: 2.6.2 + graphql: 15.9.0 + tslib: 2.8.0 - '@graphql-tools/utils@8.9.0(graphql@15.8.0)': + '@graphql-tools/utils@8.9.0(graphql@15.9.0)': dependencies: - graphql: 15.8.0 - tslib: 2.6.2 + graphql: 15.9.0 + tslib: 2.8.0 '@hapi/hoek@9.3.0': {} @@ -9914,47 +9611,47 @@ snapshots: dependencies: '@hapi/hoek': 9.3.0 - '@httptoolkit/httpolyglot@2.2.1': + '@httptoolkit/httpolyglot@2.2.2': dependencies: - '@types/node': 20.11.20 + '@types/node': 22.7.9 - '@httptoolkit/subscriptions-transport-ws@0.11.2(graphql@15.8.0)': + '@httptoolkit/subscriptions-transport-ws@0.11.2(bufferutil@4.0.8)(graphql@15.9.0)(utf-8-validate@5.0.10)': dependencies: backo2: 1.0.2 eventemitter3: 3.1.2 - graphql: 15.8.0 + graphql: 15.9.0 iterall: 1.3.0 symbol-observable: 1.2.0 - ws: 8.16.0 + ws: 8.18.0(bufferutil@4.0.8)(utf-8-validate@5.0.10) transitivePeerDependencies: - bufferutil - utf-8-validate - '@httptoolkit/websocket-stream@6.0.1': + '@httptoolkit/websocket-stream@6.0.1(bufferutil@4.0.8)(utf-8-validate@5.0.10)': dependencies: - '@types/ws': 8.5.10 + '@types/ws': 8.5.12 duplexify: 3.7.1 inherits: 2.0.4 - isomorphic-ws: 4.0.1(ws@8.16.0) + isomorphic-ws: 4.0.1(ws@8.18.0(bufferutil@4.0.8)(utf-8-validate@5.0.10)) readable-stream: 2.3.8 safe-buffer: 5.2.1 - ws: 8.16.0 + ws: 8.18.0(bufferutil@4.0.8)(utf-8-validate@5.0.10) xtend: 4.0.2 transitivePeerDependencies: - bufferutil - utf-8-validate - '@humanwhocodes/config-array@0.11.14': + '@humanwhocodes/config-array@0.13.0': dependencies: - '@humanwhocodes/object-schema': 2.0.2 - debug: 4.3.4(supports-color@6.1.0) + '@humanwhocodes/object-schema': 2.0.3 + debug: 4.3.7(supports-color@6.1.0) minimatch: 3.1.2 transitivePeerDependencies: - supports-color '@humanwhocodes/module-importer@1.0.1': {} - '@humanwhocodes/object-schema@2.0.2': {} + '@humanwhocodes/object-schema@2.0.3': {} '@isaacs/cliui@8.0.2': dependencies: @@ -9978,45 +9675,50 @@ snapshots: '@istanbuljs/schema': 0.1.3 nyc: 15.1.0 + '@istanbuljs/nyc-config-typescript@1.0.2(nyc@17.1.0)': + dependencies: + '@istanbuljs/schema': 0.1.3 + nyc: 17.1.0 + '@istanbuljs/schema@0.1.3': {} - '@jridgewell/gen-mapping@0.3.4': + '@jridgewell/gen-mapping@0.3.5': dependencies: - '@jridgewell/set-array': 1.1.2 - '@jridgewell/sourcemap-codec': 1.4.15 - '@jridgewell/trace-mapping': 0.3.23 + '@jridgewell/set-array': 1.2.1 + '@jridgewell/sourcemap-codec': 1.5.0 + '@jridgewell/trace-mapping': 0.3.25 '@jridgewell/resolve-uri@3.1.2': {} - '@jridgewell/set-array@1.1.2': {} + '@jridgewell/set-array@1.2.1': {} - '@jridgewell/source-map@0.3.5': + '@jridgewell/source-map@0.3.6': dependencies: - '@jridgewell/gen-mapping': 0.3.4 - '@jridgewell/trace-mapping': 0.3.23 + '@jridgewell/gen-mapping': 0.3.5 + '@jridgewell/trace-mapping': 0.3.25 - '@jridgewell/sourcemap-codec@1.4.15': {} + '@jridgewell/sourcemap-codec@1.5.0': {} - '@jridgewell/trace-mapping@0.3.23': + '@jridgewell/trace-mapping@0.3.25': dependencies: '@jridgewell/resolve-uri': 3.1.2 - '@jridgewell/sourcemap-codec': 1.4.15 + '@jridgewell/sourcemap-codec': 1.5.0 '@jridgewell/trace-mapping@0.3.9': dependencies: '@jridgewell/resolve-uri': 3.1.2 - '@jridgewell/sourcemap-codec': 1.4.15 + '@jridgewell/sourcemap-codec': 1.5.0 '@manypkg/find-root@1.1.0': dependencies: - '@babel/runtime': 7.23.9 + '@babel/runtime': 7.25.9 '@types/node': 12.20.55 find-up: 4.1.0 fs-extra: 8.1.0 '@manypkg/get-packages@1.1.3': dependencies: - '@babel/runtime': 7.23.9 + '@babel/runtime': 7.25.9 '@changesets/types': 4.1.0 '@manypkg/find-root': 1.1.0 fs-extra: 8.1.0 @@ -10025,15 +9727,15 @@ snapshots: '@mapbox/node-pre-gyp@1.0.11': dependencies: - detect-libc: 2.0.2 + detect-libc: 2.0.3 https-proxy-agent: 5.0.1 make-dir: 3.1.0 node-fetch: 2.7.0 nopt: 5.0.0 npmlog: 5.0.1 rimraf: 3.0.2 - semver: 7.6.0 - tar: 6.2.0 + semver: 7.6.3 + tar: 6.2.1 transitivePeerDependencies: - encoding - supports-color @@ -10046,33 +9748,21 @@ snapshots: tweetnacl: 1.0.3 tweetnacl-util: 0.15.1 - '@metamask/eth-sig-util@5.1.0': - dependencies: - '@ethereumjs/util': 8.1.0 - bn.js: 4.12.0 - ethereum-cryptography: 2.1.3 - ethjs-util: 0.1.6 - tweetnacl: 1.0.3 - tweetnacl-util: 0.15.1 - - '@metamask/safe-event-emitter@2.0.0': {} - - '@metamask/utils@3.6.0': + '@noble/curves@1.2.0': dependencies: - '@types/debug': 4.1.12 - debug: 4.3.4(supports-color@6.1.0) - semver: 7.6.0 - superstruct: 1.0.3 - transitivePeerDependencies: - - supports-color + '@noble/hashes': 1.3.2 - '@noble/curves@1.3.0': + '@noble/curves@1.4.2': dependencies: - '@noble/hashes': 1.3.3 + '@noble/hashes': 1.4.0 '@noble/hashes@1.2.0': {} - '@noble/hashes@1.3.3': {} + '@noble/hashes@1.3.2': {} + + '@noble/hashes@1.4.0': {} + + '@noble/hashes@1.5.0': {} '@noble/secp256k1@1.7.1': {} @@ -10088,92 +9778,38 @@ snapshots: '@nodelib/fs.scandir': 2.1.5 fastq: 1.17.1 - '@nomicfoundation/ethereumjs-block@5.0.4': - dependencies: - '@nomicfoundation/ethereumjs-common': 4.0.4 - '@nomicfoundation/ethereumjs-rlp': 5.0.4 - '@nomicfoundation/ethereumjs-trie': 6.0.4 - '@nomicfoundation/ethereumjs-tx': 5.0.4 - '@nomicfoundation/ethereumjs-util': 9.0.4 - ethereum-cryptography: 0.1.3 - transitivePeerDependencies: - - c-kzg + '@nomicfoundation/edr-darwin-arm64@0.6.4': {} - '@nomicfoundation/ethereumjs-blockchain@7.0.4': - dependencies: - '@nomicfoundation/ethereumjs-block': 5.0.4 - '@nomicfoundation/ethereumjs-common': 4.0.4 - '@nomicfoundation/ethereumjs-ethash': 3.0.4 - '@nomicfoundation/ethereumjs-rlp': 5.0.4 - '@nomicfoundation/ethereumjs-trie': 6.0.4 - '@nomicfoundation/ethereumjs-tx': 5.0.4 - '@nomicfoundation/ethereumjs-util': 9.0.4 - debug: 4.3.4(supports-color@6.1.0) - ethereum-cryptography: 0.1.3 - lru-cache: 10.2.0 - transitivePeerDependencies: - - c-kzg - - supports-color + '@nomicfoundation/edr-darwin-x64@0.6.4': {} - '@nomicfoundation/ethereumjs-common@4.0.4': - dependencies: - '@nomicfoundation/ethereumjs-util': 9.0.4 - transitivePeerDependencies: - - c-kzg + '@nomicfoundation/edr-linux-arm64-gnu@0.6.4': {} - '@nomicfoundation/ethereumjs-ethash@3.0.4': - dependencies: - '@nomicfoundation/ethereumjs-block': 5.0.4 - '@nomicfoundation/ethereumjs-rlp': 5.0.4 - '@nomicfoundation/ethereumjs-util': 9.0.4 - bigint-crypto-utils: 3.3.0 - ethereum-cryptography: 0.1.3 - transitivePeerDependencies: - - c-kzg + '@nomicfoundation/edr-linux-arm64-musl@0.6.4': {} - '@nomicfoundation/ethereumjs-evm@2.0.4(@nomicfoundation/ethereumjs-verkle@0.0.2)': - dependencies: - '@nomicfoundation/ethereumjs-common': 4.0.4 - '@nomicfoundation/ethereumjs-statemanager': 2.0.4(@nomicfoundation/ethereumjs-verkle@0.0.2) - '@nomicfoundation/ethereumjs-tx': 5.0.4 - '@nomicfoundation/ethereumjs-util': 9.0.4 - '@types/debug': 4.1.12 - debug: 4.3.4(supports-color@6.1.0) - ethereum-cryptography: 0.1.3 - rustbn-wasm: 0.2.0 - transitivePeerDependencies: - - '@nomicfoundation/ethereumjs-verkle' - - c-kzg - - supports-color + '@nomicfoundation/edr-linux-x64-gnu@0.6.4': {} - '@nomicfoundation/ethereumjs-rlp@5.0.4': {} + '@nomicfoundation/edr-linux-x64-musl@0.6.4': {} + + '@nomicfoundation/edr-win32-x64-msvc@0.6.4': {} - '@nomicfoundation/ethereumjs-statemanager@2.0.4(@nomicfoundation/ethereumjs-verkle@0.0.2)': + '@nomicfoundation/edr@0.6.4': dependencies: - '@nomicfoundation/ethereumjs-common': 4.0.4 - '@nomicfoundation/ethereumjs-rlp': 5.0.4 - '@nomicfoundation/ethereumjs-trie': 6.0.4 - '@nomicfoundation/ethereumjs-util': 9.0.4 - '@nomicfoundation/ethereumjs-verkle': 0.0.2 - debug: 4.3.4(supports-color@6.1.0) - ethereum-cryptography: 0.1.3 - js-sdsl: 4.4.2 - lru-cache: 10.2.0 - transitivePeerDependencies: - - c-kzg - - supports-color + '@nomicfoundation/edr-darwin-arm64': 0.6.4 + '@nomicfoundation/edr-darwin-x64': 0.6.4 + '@nomicfoundation/edr-linux-arm64-gnu': 0.6.4 + '@nomicfoundation/edr-linux-arm64-musl': 0.6.4 + '@nomicfoundation/edr-linux-x64-gnu': 0.6.4 + '@nomicfoundation/edr-linux-x64-musl': 0.6.4 + '@nomicfoundation/edr-win32-x64-msvc': 0.6.4 - '@nomicfoundation/ethereumjs-trie@6.0.4': + '@nomicfoundation/ethereumjs-common@4.0.4': dependencies: - '@nomicfoundation/ethereumjs-rlp': 5.0.4 '@nomicfoundation/ethereumjs-util': 9.0.4 - '@types/readable-stream': 2.3.15 - ethereum-cryptography: 0.1.3 - lru-cache: 10.2.0 - readable-stream: 3.6.2 transitivePeerDependencies: - c-kzg + '@nomicfoundation/ethereumjs-rlp@5.0.4': {} + '@nomicfoundation/ethereumjs-tx@5.0.4': dependencies: '@nomicfoundation/ethereumjs-common': 4.0.4 @@ -10186,104 +9822,154 @@ snapshots: '@nomicfoundation/ethereumjs-rlp': 5.0.4 ethereum-cryptography: 0.1.3 - '@nomicfoundation/ethereumjs-verkle@0.0.2': + '@nomicfoundation/hardhat-chai-matchers@2.0.8(@nomicfoundation/hardhat-ethers@3.0.8(ethers@6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10))(hardhat@2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10)))(chai@4.5.0)(ethers@6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10))(hardhat@2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10))': dependencies: - '@nomicfoundation/ethereumjs-rlp': 5.0.4 - '@nomicfoundation/ethereumjs-util': 9.0.4 - lru-cache: 10.2.0 - rust-verkle-wasm: 0.0.1 + '@nomicfoundation/hardhat-ethers': 3.0.8(ethers@6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10))(hardhat@2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10)) + '@types/chai-as-promised': 7.1.8 + chai: 4.5.0 + chai-as-promised: 7.1.2(chai@4.5.0) + deep-eql: 4.1.4 + ethers: 6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10) + hardhat: 2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10) + ordinal: 1.0.3 + + '@nomicfoundation/hardhat-ethers@3.0.8(ethers@6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10))(hardhat@2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10))': + dependencies: + debug: 4.3.7(supports-color@6.1.0) + ethers: 6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10) + hardhat: 2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10) + lodash.isequal: 4.5.0 transitivePeerDependencies: - - c-kzg + - supports-color - '@nomicfoundation/ethereumjs-vm@7.0.4(@nomicfoundation/ethereumjs-verkle@0.0.2)': + '@nomicfoundation/hardhat-ignition-ethers@0.15.6(@nomicfoundation/hardhat-ethers@3.0.8(ethers@6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10))(hardhat@2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10)))(@nomicfoundation/hardhat-ignition@0.15.6(@nomicfoundation/hardhat-verify@2.0.11(hardhat@2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10)))(bufferutil@4.0.8)(hardhat@2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10))(utf-8-validate@5.0.10))(@nomicfoundation/ignition-core@0.15.6(bufferutil@4.0.8)(utf-8-validate@5.0.10))(ethers@6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10))(hardhat@2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10))': dependencies: - '@nomicfoundation/ethereumjs-block': 5.0.4 - '@nomicfoundation/ethereumjs-blockchain': 7.0.4 - '@nomicfoundation/ethereumjs-common': 4.0.4 - '@nomicfoundation/ethereumjs-evm': 2.0.4(@nomicfoundation/ethereumjs-verkle@0.0.2) - '@nomicfoundation/ethereumjs-rlp': 5.0.4 - '@nomicfoundation/ethereumjs-statemanager': 2.0.4(@nomicfoundation/ethereumjs-verkle@0.0.2) - '@nomicfoundation/ethereumjs-trie': 6.0.4 - '@nomicfoundation/ethereumjs-tx': 5.0.4 - '@nomicfoundation/ethereumjs-util': 9.0.4 - debug: 4.3.4(supports-color@6.1.0) - ethereum-cryptography: 0.1.3 + '@nomicfoundation/hardhat-ethers': 3.0.8(ethers@6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10))(hardhat@2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10)) + '@nomicfoundation/hardhat-ignition': 0.15.6(@nomicfoundation/hardhat-verify@2.0.11(hardhat@2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10)))(bufferutil@4.0.8)(hardhat@2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10))(utf-8-validate@5.0.10) + '@nomicfoundation/ignition-core': 0.15.6(bufferutil@4.0.8)(utf-8-validate@5.0.10) + ethers: 6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10) + hardhat: 2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10) + + '@nomicfoundation/hardhat-ignition@0.15.6(@nomicfoundation/hardhat-verify@2.0.11(hardhat@2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10)))(bufferutil@4.0.8)(hardhat@2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10))(utf-8-validate@5.0.10)': + dependencies: + '@nomicfoundation/hardhat-verify': 2.0.11(hardhat@2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10)) + '@nomicfoundation/ignition-core': 0.15.6(bufferutil@4.0.8)(utf-8-validate@5.0.10) + '@nomicfoundation/ignition-ui': 0.15.6 + chalk: 4.1.2 + debug: 4.3.7(supports-color@6.1.0) + fs-extra: 10.1.0 + hardhat: 2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10) + json5: 2.2.3 + prompts: 2.4.2 transitivePeerDependencies: - - '@nomicfoundation/ethereumjs-verkle' - - c-kzg + - bufferutil - supports-color + - utf-8-validate - '@nomicfoundation/solidity-analyzer-darwin-arm64@0.1.1': - optional: true + '@nomicfoundation/hardhat-network-helpers@1.0.12(hardhat@2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10))': + dependencies: + ethereumjs-util: 7.1.5 + hardhat: 2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10) + + '@nomicfoundation/hardhat-toolbox@5.0.0(akrrydpj7boegc4sfckiephn7m)': + dependencies: + '@nomicfoundation/hardhat-chai-matchers': 2.0.8(@nomicfoundation/hardhat-ethers@3.0.8(ethers@6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10))(hardhat@2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10)))(chai@4.5.0)(ethers@6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10))(hardhat@2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10)) + '@nomicfoundation/hardhat-ethers': 3.0.8(ethers@6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10))(hardhat@2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10)) + '@nomicfoundation/hardhat-ignition-ethers': 0.15.6(@nomicfoundation/hardhat-ethers@3.0.8(ethers@6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10))(hardhat@2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10)))(@nomicfoundation/hardhat-ignition@0.15.6(@nomicfoundation/hardhat-verify@2.0.11(hardhat@2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10)))(bufferutil@4.0.8)(hardhat@2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10))(utf-8-validate@5.0.10))(@nomicfoundation/ignition-core@0.15.6(bufferutil@4.0.8)(utf-8-validate@5.0.10))(ethers@6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10))(hardhat@2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10)) + '@nomicfoundation/hardhat-network-helpers': 1.0.12(hardhat@2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10)) + '@nomicfoundation/hardhat-verify': 2.0.11(hardhat@2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10)) + '@typechain/ethers-v6': 0.5.1(ethers@6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10))(typechain@8.3.2(typescript@5.6.3))(typescript@5.6.3) + '@typechain/hardhat': 9.1.0(@typechain/ethers-v6@0.5.1(ethers@6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10))(typechain@8.3.2(typescript@5.6.3))(typescript@5.6.3))(ethers@6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10))(hardhat@2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10))(typechain@8.3.2(typescript@5.6.3)) + '@types/chai': 4.3.20 + '@types/mocha': 10.0.9 + '@types/node': 22.7.9 + chai: 4.5.0 + ethers: 6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10) + hardhat: 2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10) + hardhat-gas-reporter: 1.0.10(bufferutil@4.0.8)(hardhat@2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10))(utf-8-validate@5.0.10) + solidity-coverage: 0.8.13(hardhat@2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10)) + ts-node: 10.9.2(@types/node@22.7.9)(typescript@5.6.3) + typechain: 8.3.2(typescript@5.6.3) + typescript: 5.6.3 + + '@nomicfoundation/hardhat-verify@2.0.11(hardhat@2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10))': + dependencies: + '@ethersproject/abi': 5.7.0 + '@ethersproject/address': 5.7.0 + cbor: 8.1.0 + chalk: 2.4.2 + debug: 4.3.7(supports-color@6.1.0) + hardhat: 2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10) + lodash.clonedeep: 4.5.0 + semver: 6.3.1 + table: 6.8.2 + undici: 5.28.4 + transitivePeerDependencies: + - supports-color - '@nomicfoundation/solidity-analyzer-darwin-x64@0.1.1': - optional: true + '@nomicfoundation/ignition-core@0.15.6(bufferutil@4.0.8)(utf-8-validate@5.0.10)': + dependencies: + '@ethersproject/address': 5.6.1 + '@nomicfoundation/solidity-analyzer': 0.1.2 + cbor: 9.0.2 + debug: 4.3.7(supports-color@6.1.0) + ethers: 6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10) + fs-extra: 10.1.0 + immer: 10.0.2 + lodash: 4.17.21 + ndjson: 2.0.0 + transitivePeerDependencies: + - bufferutil + - supports-color + - utf-8-validate - '@nomicfoundation/solidity-analyzer-freebsd-x64@0.1.1': - optional: true + '@nomicfoundation/ignition-ui@0.15.6': {} - '@nomicfoundation/solidity-analyzer-linux-arm64-gnu@0.1.1': + '@nomicfoundation/solidity-analyzer-darwin-arm64@0.1.2': optional: true - '@nomicfoundation/solidity-analyzer-linux-arm64-musl@0.1.1': + '@nomicfoundation/solidity-analyzer-darwin-x64@0.1.2': optional: true - '@nomicfoundation/solidity-analyzer-linux-x64-gnu@0.1.1': + '@nomicfoundation/solidity-analyzer-linux-arm64-gnu@0.1.2': optional: true - '@nomicfoundation/solidity-analyzer-linux-x64-musl@0.1.1': + '@nomicfoundation/solidity-analyzer-linux-arm64-musl@0.1.2': optional: true - '@nomicfoundation/solidity-analyzer-win32-arm64-msvc@0.1.1': + '@nomicfoundation/solidity-analyzer-linux-x64-gnu@0.1.2': optional: true - '@nomicfoundation/solidity-analyzer-win32-ia32-msvc@0.1.1': + '@nomicfoundation/solidity-analyzer-linux-x64-musl@0.1.2': optional: true - '@nomicfoundation/solidity-analyzer-win32-x64-msvc@0.1.1': + '@nomicfoundation/solidity-analyzer-win32-x64-msvc@0.1.2': optional: true - '@nomicfoundation/solidity-analyzer@0.1.1': + '@nomicfoundation/solidity-analyzer@0.1.2': optionalDependencies: - '@nomicfoundation/solidity-analyzer-darwin-arm64': 0.1.1 - '@nomicfoundation/solidity-analyzer-darwin-x64': 0.1.1 - '@nomicfoundation/solidity-analyzer-freebsd-x64': 0.1.1 - '@nomicfoundation/solidity-analyzer-linux-arm64-gnu': 0.1.1 - '@nomicfoundation/solidity-analyzer-linux-arm64-musl': 0.1.1 - '@nomicfoundation/solidity-analyzer-linux-x64-gnu': 0.1.1 - '@nomicfoundation/solidity-analyzer-linux-x64-musl': 0.1.1 - '@nomicfoundation/solidity-analyzer-win32-arm64-msvc': 0.1.1 - '@nomicfoundation/solidity-analyzer-win32-ia32-msvc': 0.1.1 - '@nomicfoundation/solidity-analyzer-win32-x64-msvc': 0.1.1 - - '@nomiclabs/hardhat-ethers@2.2.3(ethers@5.7.2)(hardhat@2.20.1)': - dependencies: - ethers: 5.7.2 - hardhat: 2.20.1(ts-node@10.9.2)(typescript@5.3.3) - - '@nomiclabs/hardhat-web3@2.0.0(hardhat@2.20.1)(web3@1.10.4)': - dependencies: - '@types/bignumber.js': 5.0.0 - hardhat: 2.20.1(ts-node@10.9.2)(typescript@5.3.3) - web3: 1.10.4 - - '@pkgjs/parseargs@0.11.0': - optional: true + '@nomicfoundation/solidity-analyzer-darwin-arm64': 0.1.2 + '@nomicfoundation/solidity-analyzer-darwin-x64': 0.1.2 + '@nomicfoundation/solidity-analyzer-linux-arm64-gnu': 0.1.2 + '@nomicfoundation/solidity-analyzer-linux-arm64-musl': 0.1.2 + '@nomicfoundation/solidity-analyzer-linux-x64-gnu': 0.1.2 + '@nomicfoundation/solidity-analyzer-linux-x64-musl': 0.1.2 + '@nomicfoundation/solidity-analyzer-win32-x64-msvc': 0.1.2 '@pkgr/core@0.1.1': {} - '@preconstruct/cli@2.8.3': + '@preconstruct/cli@2.8.9': dependencies: - '@babel/code-frame': 7.23.5 - '@babel/core': 7.23.9 - '@babel/helper-module-imports': 7.22.15 - '@babel/runtime': 7.23.9 + '@babel/code-frame': 7.25.9 + '@babel/core': 7.25.9 + '@babel/helper-module-imports': 7.25.9 + '@babel/runtime': 7.25.9 '@preconstruct/hook': 0.4.0 - '@rollup/plugin-alias': 3.1.9(rollup@2.79.1) - '@rollup/plugin-commonjs': 15.1.0(rollup@2.79.1) - '@rollup/plugin-json': 4.1.0(rollup@2.79.1) - '@rollup/plugin-node-resolve': 11.2.1(rollup@2.79.1) - '@rollup/plugin-replace': 2.4.2(rollup@2.79.1) + '@rollup/plugin-alias': 3.1.9(rollup@2.79.2) + '@rollup/plugin-commonjs': 15.1.0(rollup@2.79.2) + '@rollup/plugin-json': 4.1.0(rollup@2.79.2) + '@rollup/plugin-node-resolve': 11.2.1(rollup@2.79.2) + '@rollup/plugin-replace': 2.4.2(rollup@2.79.2) builtin-modules: 3.3.0 chalk: 4.1.2 ci-info: 3.9.0 @@ -10296,8 +9982,7 @@ snapshots: fs-extra: 9.1.0 is-reference: 1.2.1 jest-worker: 26.6.2 - magic-string: 0.30.7 - meow: 7.1.1 + magic-string: 0.30.12 ms: 2.1.3 normalize-path: 3.0.0 npm-packlist: 2.2.2 @@ -10305,109 +9990,111 @@ snapshots: parse-glob: 3.0.4 parse-json: 5.2.0 quick-lru: 5.1.1 - resolve: 1.22.8 resolve-from: 5.0.0 - rollup: 2.79.1 - semver: 7.6.0 - terser: 5.28.1 + rollup: 2.79.2 + semver: 7.6.3 + terser: 5.36.0 v8-compile-cache: 2.4.0 - zod: 3.22.4 + zod: 3.23.8 transitivePeerDependencies: - supports-color '@preconstruct/hook@0.4.0': dependencies: - '@babel/core': 7.23.9 - '@babel/plugin-transform-modules-commonjs': 7.23.3(@babel/core@7.23.9) + '@babel/core': 7.25.9 + '@babel/plugin-transform-modules-commonjs': 7.25.9(@babel/core@7.25.9) pirates: 4.0.6 source-map-support: 0.5.21 transitivePeerDependencies: - supports-color - '@puppeteer/browsers@1.9.1': + '@puppeteer/browsers@2.6.1': dependencies: - debug: 4.3.4(supports-color@6.1.0) + debug: 4.4.0 extract-zip: 2.0.1 progress: 2.0.3 - proxy-agent: 6.3.1 - tar-fs: 3.0.4 + proxy-agent: 6.5.0 + semver: 7.6.3 + tar-fs: 3.0.6 unbzip2-stream: 1.4.3 yargs: 17.7.2 transitivePeerDependencies: - supports-color - '@rollup/plugin-alias@3.1.9(rollup@2.79.1)': + '@rollup/plugin-alias@3.1.9(rollup@2.79.2)': dependencies: - rollup: 2.79.1 + rollup: 2.79.2 slash: 3.0.0 - '@rollup/plugin-commonjs@15.1.0(rollup@2.79.1)': + '@rollup/plugin-commonjs@15.1.0(rollup@2.79.2)': dependencies: - '@rollup/pluginutils': 3.1.0(rollup@2.79.1) + '@rollup/pluginutils': 3.1.0(rollup@2.79.2) commondir: 1.0.1 estree-walker: 2.0.2 glob: 7.2.3 is-reference: 1.2.1 magic-string: 0.25.9 resolve: 1.22.8 - rollup: 2.79.1 + rollup: 2.79.2 - '@rollup/plugin-json@4.1.0(rollup@2.79.1)': + '@rollup/plugin-json@4.1.0(rollup@2.79.2)': dependencies: - '@rollup/pluginutils': 3.1.0(rollup@2.79.1) - rollup: 2.79.1 + '@rollup/pluginutils': 3.1.0(rollup@2.79.2) + rollup: 2.79.2 - '@rollup/plugin-node-resolve@11.2.1(rollup@2.79.1)': + '@rollup/plugin-node-resolve@11.2.1(rollup@2.79.2)': dependencies: - '@rollup/pluginutils': 3.1.0(rollup@2.79.1) + '@rollup/pluginutils': 3.1.0(rollup@2.79.2) '@types/resolve': 1.17.1 builtin-modules: 3.3.0 deepmerge: 4.3.1 is-module: 1.0.0 resolve: 1.22.8 - rollup: 2.79.1 + rollup: 2.79.2 - '@rollup/plugin-replace@2.4.2(rollup@2.79.1)': + '@rollup/plugin-replace@2.4.2(rollup@2.79.2)': dependencies: - '@rollup/pluginutils': 3.1.0(rollup@2.79.1) + '@rollup/pluginutils': 3.1.0(rollup@2.79.2) magic-string: 0.25.9 - rollup: 2.79.1 + rollup: 2.79.2 - '@rollup/pluginutils@3.1.0(rollup@2.79.1)': + '@rollup/pluginutils@3.1.0(rollup@2.79.2)': dependencies: '@types/estree': 0.0.39 estree-walker: 1.0.1 picomatch: 2.3.1 - rollup: 2.79.1 + rollup: 2.79.2 '@rollup/pluginutils@4.2.1': dependencies: estree-walker: 2.0.2 picomatch: 2.3.1 - '@scure/base@1.1.5': {} + '@rtsao/scc@1.1.0': {} + + '@scure/base@1.1.9': {} '@scure/bip32@1.1.5': dependencies: '@noble/hashes': 1.2.0 '@noble/secp256k1': 1.7.1 - '@scure/base': 1.1.5 + '@scure/base': 1.1.9 - '@scure/bip32@1.3.3': + '@scure/bip32@1.4.0': dependencies: - '@noble/curves': 1.3.0 - '@noble/hashes': 1.3.3 - '@scure/base': 1.1.5 + '@noble/curves': 1.4.2 + '@noble/hashes': 1.4.0 + '@scure/base': 1.1.9 '@scure/bip39@1.1.1': dependencies: '@noble/hashes': 1.2.0 - '@scure/base': 1.1.5 + '@scure/base': 1.1.9 - '@scure/bip39@1.2.2': + '@scure/bip39@1.3.0': dependencies: - '@noble/hashes': 1.3.3 - '@scure/base': 1.1.5 + '@noble/hashes': 1.4.0 + '@scure/base': 1.1.9 '@sentry/core@5.30.0': dependencies: @@ -10470,262 +10157,286 @@ snapshots: '@sindresorhus/merge-streams@2.3.0': {} - '@smithy/abort-controller@2.1.2': + '@smithy/abort-controller@3.1.6': dependencies: - '@smithy/types': 2.10.0 - tslib: 2.6.2 + '@smithy/types': 3.6.0 + tslib: 2.8.0 - '@smithy/config-resolver@2.1.2': + '@smithy/config-resolver@3.0.10': dependencies: - '@smithy/node-config-provider': 2.2.2 - '@smithy/types': 2.10.0 - '@smithy/util-config-provider': 2.2.1 - '@smithy/util-middleware': 2.1.2 - tslib: 2.6.2 + '@smithy/node-config-provider': 3.1.9 + '@smithy/types': 3.6.0 + '@smithy/util-config-provider': 3.0.0 + '@smithy/util-middleware': 3.0.8 + tslib: 2.8.0 - '@smithy/core@1.3.3': + '@smithy/core@2.5.1': dependencies: - '@smithy/middleware-endpoint': 2.4.2 - '@smithy/middleware-retry': 2.1.2 - '@smithy/middleware-serde': 2.1.2 - '@smithy/protocol-http': 3.2.0 - '@smithy/smithy-client': 2.4.0 - '@smithy/types': 2.10.0 - '@smithy/util-middleware': 2.1.2 - tslib: 2.6.2 + '@smithy/middleware-serde': 3.0.8 + '@smithy/protocol-http': 4.1.5 + '@smithy/types': 3.6.0 + '@smithy/util-body-length-browser': 3.0.0 + '@smithy/util-middleware': 3.0.8 + '@smithy/util-stream': 3.2.1 + '@smithy/util-utf8': 3.0.0 + tslib: 2.8.0 - '@smithy/credential-provider-imds@2.2.2': + '@smithy/credential-provider-imds@3.2.5': dependencies: - '@smithy/node-config-provider': 2.2.2 - '@smithy/property-provider': 2.1.2 - '@smithy/types': 2.10.0 - '@smithy/url-parser': 2.1.2 - tslib: 2.6.2 + '@smithy/node-config-provider': 3.1.9 + '@smithy/property-provider': 3.1.8 + '@smithy/types': 3.6.0 + '@smithy/url-parser': 3.0.8 + tslib: 2.8.0 - '@smithy/eventstream-codec@2.1.2': + '@smithy/fetch-http-handler@3.2.9': dependencies: - '@aws-crypto/crc32': 3.0.0 - '@smithy/types': 2.10.0 - '@smithy/util-hex-encoding': 2.1.1 - tslib: 2.6.2 + '@smithy/protocol-http': 4.1.5 + '@smithy/querystring-builder': 3.0.8 + '@smithy/types': 3.6.0 + '@smithy/util-base64': 3.0.0 + tslib: 2.8.0 - '@smithy/fetch-http-handler@2.4.2': + '@smithy/fetch-http-handler@4.0.0': dependencies: - '@smithy/protocol-http': 3.2.0 - '@smithy/querystring-builder': 2.1.2 - '@smithy/types': 2.10.0 - '@smithy/util-base64': 2.1.1 - tslib: 2.6.2 + '@smithy/protocol-http': 4.1.5 + '@smithy/querystring-builder': 3.0.8 + '@smithy/types': 3.6.0 + '@smithy/util-base64': 3.0.0 + tslib: 2.8.0 - '@smithy/hash-node@2.1.2': + '@smithy/hash-node@3.0.8': dependencies: - '@smithy/types': 2.10.0 - '@smithy/util-buffer-from': 2.1.1 - '@smithy/util-utf8': 2.1.1 - tslib: 2.6.2 + '@smithy/types': 3.6.0 + '@smithy/util-buffer-from': 3.0.0 + '@smithy/util-utf8': 3.0.0 + tslib: 2.8.0 - '@smithy/invalid-dependency@2.1.2': + '@smithy/invalid-dependency@3.0.8': dependencies: - '@smithy/types': 2.10.0 - tslib: 2.6.2 + '@smithy/types': 3.6.0 + tslib: 2.8.0 - '@smithy/is-array-buffer@2.1.1': + '@smithy/is-array-buffer@2.2.0': dependencies: - tslib: 2.6.2 + tslib: 2.8.0 - '@smithy/middleware-content-length@2.1.2': + '@smithy/is-array-buffer@3.0.0': dependencies: - '@smithy/protocol-http': 3.2.0 - '@smithy/types': 2.10.0 - tslib: 2.6.2 + tslib: 2.8.0 - '@smithy/middleware-endpoint@2.4.2': + '@smithy/middleware-content-length@3.0.10': dependencies: - '@smithy/middleware-serde': 2.1.2 - '@smithy/node-config-provider': 2.2.2 - '@smithy/shared-ini-file-loader': 2.3.2 - '@smithy/types': 2.10.0 - '@smithy/url-parser': 2.1.2 - '@smithy/util-middleware': 2.1.2 - tslib: 2.6.2 + '@smithy/protocol-http': 4.1.5 + '@smithy/types': 3.6.0 + tslib: 2.8.0 - '@smithy/middleware-retry@2.1.2': + '@smithy/middleware-endpoint@3.2.1': dependencies: - '@smithy/node-config-provider': 2.2.2 - '@smithy/protocol-http': 3.2.0 - '@smithy/service-error-classification': 2.1.2 - '@smithy/smithy-client': 2.4.0 - '@smithy/types': 2.10.0 - '@smithy/util-middleware': 2.1.2 - '@smithy/util-retry': 2.1.2 - tslib: 2.6.2 - uuid: 8.3.2 + '@smithy/core': 2.5.1 + '@smithy/middleware-serde': 3.0.8 + '@smithy/node-config-provider': 3.1.9 + '@smithy/shared-ini-file-loader': 3.1.9 + '@smithy/types': 3.6.0 + '@smithy/url-parser': 3.0.8 + '@smithy/util-middleware': 3.0.8 + tslib: 2.8.0 + + '@smithy/middleware-retry@3.0.25': + dependencies: + '@smithy/node-config-provider': 3.1.9 + '@smithy/protocol-http': 4.1.5 + '@smithy/service-error-classification': 3.0.8 + '@smithy/smithy-client': 3.4.2 + '@smithy/types': 3.6.0 + '@smithy/util-middleware': 3.0.8 + '@smithy/util-retry': 3.0.8 + tslib: 2.8.0 + uuid: 9.0.1 + + '@smithy/middleware-serde@3.0.8': + dependencies: + '@smithy/types': 3.6.0 + tslib: 2.8.0 - '@smithy/middleware-serde@2.1.2': + '@smithy/middleware-stack@3.0.8': dependencies: - '@smithy/types': 2.10.0 - tslib: 2.6.2 + '@smithy/types': 3.6.0 + tslib: 2.8.0 - '@smithy/middleware-stack@2.1.2': + '@smithy/node-config-provider@3.1.9': dependencies: - '@smithy/types': 2.10.0 - tslib: 2.6.2 + '@smithy/property-provider': 3.1.8 + '@smithy/shared-ini-file-loader': 3.1.9 + '@smithy/types': 3.6.0 + tslib: 2.8.0 - '@smithy/node-config-provider@2.2.2': + '@smithy/node-http-handler@3.2.5': dependencies: - '@smithy/property-provider': 2.1.2 - '@smithy/shared-ini-file-loader': 2.3.2 - '@smithy/types': 2.10.0 - tslib: 2.6.2 + '@smithy/abort-controller': 3.1.6 + '@smithy/protocol-http': 4.1.5 + '@smithy/querystring-builder': 3.0.8 + '@smithy/types': 3.6.0 + tslib: 2.8.0 - '@smithy/node-http-handler@2.4.0': + '@smithy/property-provider@3.1.8': dependencies: - '@smithy/abort-controller': 2.1.2 - '@smithy/protocol-http': 3.2.0 - '@smithy/querystring-builder': 2.1.2 - '@smithy/types': 2.10.0 - tslib: 2.6.2 + '@smithy/types': 3.6.0 + tslib: 2.8.0 - '@smithy/property-provider@2.1.2': + '@smithy/protocol-http@4.1.5': dependencies: - '@smithy/types': 2.10.0 - tslib: 2.6.2 + '@smithy/types': 3.6.0 + tslib: 2.8.0 - '@smithy/protocol-http@3.2.0': + '@smithy/querystring-builder@3.0.8': dependencies: - '@smithy/types': 2.10.0 - tslib: 2.6.2 + '@smithy/types': 3.6.0 + '@smithy/util-uri-escape': 3.0.0 + tslib: 2.8.0 - '@smithy/querystring-builder@2.1.2': + '@smithy/querystring-parser@3.0.8': dependencies: - '@smithy/types': 2.10.0 - '@smithy/util-uri-escape': 2.1.1 - tslib: 2.6.2 + '@smithy/types': 3.6.0 + tslib: 2.8.0 - '@smithy/querystring-parser@2.1.2': + '@smithy/service-error-classification@3.0.8': dependencies: - '@smithy/types': 2.10.0 - tslib: 2.6.2 + '@smithy/types': 3.6.0 - '@smithy/service-error-classification@2.1.2': + '@smithy/shared-ini-file-loader@3.1.9': dependencies: - '@smithy/types': 2.10.0 + '@smithy/types': 3.6.0 + tslib: 2.8.0 - '@smithy/shared-ini-file-loader@2.3.2': + '@smithy/signature-v4@4.2.1': dependencies: - '@smithy/types': 2.10.0 - tslib: 2.6.2 + '@smithy/is-array-buffer': 3.0.0 + '@smithy/protocol-http': 4.1.5 + '@smithy/types': 3.6.0 + '@smithy/util-hex-encoding': 3.0.0 + '@smithy/util-middleware': 3.0.8 + '@smithy/util-uri-escape': 3.0.0 + '@smithy/util-utf8': 3.0.0 + tslib: 2.8.0 - '@smithy/signature-v4@2.1.2': + '@smithy/smithy-client@3.4.2': dependencies: - '@smithy/eventstream-codec': 2.1.2 - '@smithy/is-array-buffer': 2.1.1 - '@smithy/types': 2.10.0 - '@smithy/util-hex-encoding': 2.1.1 - '@smithy/util-middleware': 2.1.2 - '@smithy/util-uri-escape': 2.1.1 - '@smithy/util-utf8': 2.1.1 - tslib: 2.6.2 + '@smithy/core': 2.5.1 + '@smithy/middleware-endpoint': 3.2.1 + '@smithy/middleware-stack': 3.0.8 + '@smithy/protocol-http': 4.1.5 + '@smithy/types': 3.6.0 + '@smithy/util-stream': 3.2.1 + tslib: 2.8.0 - '@smithy/smithy-client@2.4.0': + '@smithy/types@3.6.0': dependencies: - '@smithy/middleware-endpoint': 2.4.2 - '@smithy/middleware-stack': 2.1.2 - '@smithy/protocol-http': 3.2.0 - '@smithy/types': 2.10.0 - '@smithy/util-stream': 2.1.2 - tslib: 2.6.2 + tslib: 2.8.0 - '@smithy/types@2.10.0': + '@smithy/url-parser@3.0.8': dependencies: - tslib: 2.6.2 + '@smithy/querystring-parser': 3.0.8 + '@smithy/types': 3.6.0 + tslib: 2.8.0 - '@smithy/url-parser@2.1.2': + '@smithy/util-base64@3.0.0': dependencies: - '@smithy/querystring-parser': 2.1.2 - '@smithy/types': 2.10.0 - tslib: 2.6.2 + '@smithy/util-buffer-from': 3.0.0 + '@smithy/util-utf8': 3.0.0 + tslib: 2.8.0 - '@smithy/util-base64@2.1.1': + '@smithy/util-body-length-browser@3.0.0': dependencies: - '@smithy/util-buffer-from': 2.1.1 - tslib: 2.6.2 + tslib: 2.8.0 - '@smithy/util-body-length-browser@2.1.1': + '@smithy/util-body-length-node@3.0.0': dependencies: - tslib: 2.6.2 + tslib: 2.8.0 - '@smithy/util-body-length-node@2.2.1': + '@smithy/util-buffer-from@2.2.0': dependencies: - tslib: 2.6.2 + '@smithy/is-array-buffer': 2.2.0 + tslib: 2.8.0 - '@smithy/util-buffer-from@2.1.1': + '@smithy/util-buffer-from@3.0.0': dependencies: - '@smithy/is-array-buffer': 2.1.1 - tslib: 2.6.2 + '@smithy/is-array-buffer': 3.0.0 + tslib: 2.8.0 - '@smithy/util-config-provider@2.2.1': + '@smithy/util-config-provider@3.0.0': dependencies: - tslib: 2.6.2 + tslib: 2.8.0 - '@smithy/util-defaults-mode-browser@2.1.2': + '@smithy/util-defaults-mode-browser@3.0.25': dependencies: - '@smithy/property-provider': 2.1.2 - '@smithy/smithy-client': 2.4.0 - '@smithy/types': 2.10.0 + '@smithy/property-provider': 3.1.8 + '@smithy/smithy-client': 3.4.2 + '@smithy/types': 3.6.0 bowser: 2.11.0 - tslib: 2.6.2 + tslib: 2.8.0 - '@smithy/util-defaults-mode-node@2.2.1': + '@smithy/util-defaults-mode-node@3.0.25': dependencies: - '@smithy/config-resolver': 2.1.2 - '@smithy/credential-provider-imds': 2.2.2 - '@smithy/node-config-provider': 2.2.2 - '@smithy/property-provider': 2.1.2 - '@smithy/smithy-client': 2.4.0 - '@smithy/types': 2.10.0 - tslib: 2.6.2 + '@smithy/config-resolver': 3.0.10 + '@smithy/credential-provider-imds': 3.2.5 + '@smithy/node-config-provider': 3.1.9 + '@smithy/property-provider': 3.1.8 + '@smithy/smithy-client': 3.4.2 + '@smithy/types': 3.6.0 + tslib: 2.8.0 - '@smithy/util-endpoints@1.1.2': + '@smithy/util-endpoints@2.1.4': dependencies: - '@smithy/node-config-provider': 2.2.2 - '@smithy/types': 2.10.0 - tslib: 2.6.2 + '@smithy/node-config-provider': 3.1.9 + '@smithy/types': 3.6.0 + tslib: 2.8.0 - '@smithy/util-hex-encoding@2.1.1': + '@smithy/util-hex-encoding@3.0.0': dependencies: - tslib: 2.6.2 + tslib: 2.8.0 - '@smithy/util-middleware@2.1.2': + '@smithy/util-middleware@3.0.8': dependencies: - '@smithy/types': 2.10.0 - tslib: 2.6.2 + '@smithy/types': 3.6.0 + tslib: 2.8.0 - '@smithy/util-retry@2.1.2': + '@smithy/util-retry@3.0.8': dependencies: - '@smithy/service-error-classification': 2.1.2 - '@smithy/types': 2.10.0 - tslib: 2.6.2 + '@smithy/service-error-classification': 3.0.8 + '@smithy/types': 3.6.0 + tslib: 2.8.0 - '@smithy/util-stream@2.1.2': + '@smithy/util-stream@3.2.1': dependencies: - '@smithy/fetch-http-handler': 2.4.2 - '@smithy/node-http-handler': 2.4.0 - '@smithy/types': 2.10.0 - '@smithy/util-base64': 2.1.1 - '@smithy/util-buffer-from': 2.1.1 - '@smithy/util-hex-encoding': 2.1.1 - '@smithy/util-utf8': 2.1.1 - tslib: 2.6.2 + '@smithy/fetch-http-handler': 4.0.0 + '@smithy/node-http-handler': 3.2.5 + '@smithy/types': 3.6.0 + '@smithy/util-base64': 3.0.0 + '@smithy/util-buffer-from': 3.0.0 + '@smithy/util-hex-encoding': 3.0.0 + '@smithy/util-utf8': 3.0.0 + tslib: 2.8.0 - '@smithy/util-uri-escape@2.1.1': + '@smithy/util-uri-escape@3.0.0': dependencies: - tslib: 2.6.2 + tslib: 2.8.0 - '@smithy/util-utf8@2.1.1': + '@smithy/util-utf8@2.3.0': dependencies: - '@smithy/util-buffer-from': 2.1.1 - tslib: 2.6.2 + '@smithy/util-buffer-from': 2.2.0 + tslib: 2.8.0 + + '@smithy/util-utf8@3.0.0': + dependencies: + '@smithy/util-buffer-from': 3.0.0 + tslib: 2.8.0 + + '@solidity-parser/parser@0.14.5': + dependencies: + antlr4ts: 0.5.0-alpha.4 + + '@solidity-parser/parser@0.18.0': {} '@szmarczak/http-timer@4.0.6': dependencies: @@ -10737,18 +10448,14 @@ snapshots: '@tootallnate/quickjs-emscripten@0.23.0': {} - '@trufflesuite/bigint-buffer@1.1.10': - dependencies: - node-gyp-build: 4.4.0 - '@trufflesuite/uws-js-unofficial@20.30.0-unofficial.0': dependencies: - ws: 8.13.0(bufferutil@4.0.7)(utf-8-validate@6.0.3) + ws: 8.13.0(bufferutil@4.0.8)(utf-8-validate@6.0.3) optionalDependencies: - bufferutil: 4.0.7 + bufferutil: 4.0.8 utf-8-validate: 6.0.3 - '@tsconfig/node10@1.0.9': {} + '@tsconfig/node10@1.0.11': {} '@tsconfig/node12@1.0.11': {} @@ -10756,82 +10463,71 @@ snapshots: '@tsconfig/node16@1.0.4': {} - '@typechain/ethers-v5@10.2.1(@ethersproject/abi@5.7.0)(@ethersproject/providers@5.7.2)(ethers@5.7.2)(typechain@8.3.2)(typescript@5.3.3)': + '@typechain/ethers-v6@0.5.1(ethers@6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10))(typechain@8.3.2(typescript@5.6.3))(typescript@5.6.3)': dependencies: - '@ethersproject/abi': 5.7.0 - '@ethersproject/providers': 5.7.2 - ethers: 5.7.2 + ethers: 6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10) lodash: 4.17.21 - ts-essentials: 7.0.3(typescript@5.3.3) - typechain: 8.3.2(typescript@5.3.3) - typescript: 5.3.3 + ts-essentials: 7.0.3(typescript@5.6.3) + typechain: 8.3.2(typescript@5.6.3) + typescript: 5.6.3 - '@typechain/ethers-v5@7.2.0(@ethersproject/abi@5.7.0)(@ethersproject/bytes@5.7.0)(@ethersproject/providers@5.7.2)(ethers@5.7.2)(typechain@5.2.0)(typescript@5.3.3)': + '@typechain/ethers-v6@0.5.1(ethers@6.13.4(bufferutil@4.0.8)(utf-8-validate@6.0.3))(typechain@8.3.2(typescript@5.6.3))(typescript@5.6.3)': dependencies: - '@ethersproject/abi': 5.7.0 - '@ethersproject/bytes': 5.7.0 - '@ethersproject/providers': 5.7.2 - ethers: 5.7.2 + ethers: 6.13.4(bufferutil@4.0.8)(utf-8-validate@6.0.3) lodash: 4.17.21 - ts-essentials: 7.0.3(typescript@5.3.3) - typechain: 5.2.0(typescript@5.3.3) - typescript: 5.3.3 + ts-essentials: 7.0.3(typescript@5.6.3) + typechain: 8.3.2(typescript@5.6.3) + typescript: 5.6.3 - '@types/bignumber.js@5.0.0': + '@typechain/hardhat@9.1.0(@typechain/ethers-v6@0.5.1(ethers@6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10))(typechain@8.3.2(typescript@5.6.3))(typescript@5.6.3))(ethers@6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10))(hardhat@2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10))(typechain@8.3.2(typescript@5.6.3))': dependencies: - bignumber.js: 9.1.2 + '@typechain/ethers-v6': 0.5.1(ethers@6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10))(typechain@8.3.2(typescript@5.6.3))(typescript@5.6.3) + ethers: 6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10) + fs-extra: 9.1.0 + hardhat: 2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10) + typechain: 8.3.2(typescript@5.6.3) '@types/bn.js@4.11.6': dependencies: - '@types/node': 20.11.20 + '@types/node': 22.7.9 - '@types/bn.js@5.1.5': + '@types/bn.js@5.1.6': dependencies: - '@types/node': 20.11.20 + '@types/node': 22.7.9 '@types/cacheable-request@6.0.3': dependencies: '@types/http-cache-semantics': 4.0.4 '@types/keyv': 3.1.4 - '@types/node': 20.11.20 + '@types/node': 22.7.9 '@types/responselike': 1.0.3 '@types/chai-as-promised@7.1.8': dependencies: - '@types/chai': 4.3.12 - - '@types/chai@4.3.12': {} - - '@types/cors@2.8.17': - dependencies: - '@types/node': 20.11.20 + '@types/chai': 4.3.20 - '@types/debug@4.1.12': - dependencies: - '@types/ms': 0.7.34 + '@types/chai@4.3.20': {} - '@types/eslint-scope@3.7.7': + '@types/concat-stream@1.6.1': dependencies: - '@types/eslint': 8.56.3 - '@types/estree': 1.0.5 + '@types/node': 22.7.9 - '@types/eslint@8.56.3': + '@types/cors@2.8.17': dependencies: - '@types/estree': 1.0.5 - '@types/json-schema': 7.0.15 + '@types/node': 22.7.9 '@types/estree@0.0.39': {} - '@types/estree@1.0.5': {} + '@types/estree@1.0.6': {} - '@types/ethereum-protocol@1.0.5': + '@types/form-data@0.0.33': dependencies: - bignumber.js: 7.2.1 + '@types/node': 22.7.9 '@types/glob@7.2.0': dependencies: '@types/minimatch': 5.1.2 - '@types/node': 20.11.20 + '@types/node': 22.7.9 '@types/html-minifier-terser@6.1.0': {} @@ -10847,171 +10543,163 @@ snapshots: '@types/keyv@3.1.4': dependencies: - '@types/node': 20.11.20 + '@types/node': 22.7.9 '@types/lru-cache@5.1.1': {} '@types/minimatch@5.1.2': {} - '@types/minimist@1.2.5': {} + '@types/mocha@10.0.9': {} - '@types/mocha@10.0.6': {} - - '@types/ms@0.7.34': {} + '@types/node@10.17.60': {} '@types/node@12.20.55': {} - '@types/node@20.11.20': + '@types/node@22.7.5': + dependencies: + undici-types: 6.19.8 + + '@types/node@22.7.9': dependencies: - undici-types: 5.26.5 + undici-types: 6.19.8 - '@types/normalize-package-data@2.4.4': {} + '@types/node@8.10.66': {} '@types/pbkdf2@3.1.2': dependencies: - '@types/node': 20.11.20 + '@types/node': 22.7.9 '@types/prettier@2.7.3': {} - '@types/readable-stream@2.3.15': - dependencies: - '@types/node': 20.11.20 - safe-buffer: 5.1.2 + '@types/qs@6.9.16': {} '@types/resolve@1.17.1': dependencies: - '@types/node': 20.11.20 + '@types/node': 22.7.9 '@types/responselike@1.0.3': dependencies: - '@types/node': 20.11.20 + '@types/node': 22.7.9 '@types/secp256k1@4.0.6': dependencies: - '@types/node': 20.11.20 + '@types/node': 22.7.9 '@types/seedrandom@3.0.1': {} - '@types/semver@7.5.8': {} - - '@types/web3-provider-engine@14.0.4': - dependencies: - '@types/ethereum-protocol': 1.0.5 - '@types/webextension-polyfill@0.10.7': {} - '@types/ws@8.5.10': + '@types/ws@8.5.12': dependencies: - '@types/node': 20.11.20 + '@types/node': 22.7.9 '@types/yauzl@2.10.3': dependencies: - '@types/node': 20.11.20 + '@types/node': 22.7.9 optional: true - '@typescript-eslint/eslint-plugin@6.21.0(@typescript-eslint/parser@6.21.0)(eslint@8.57.0)(typescript@5.3.3)': + '@typescript-eslint/eslint-plugin@8.11.0(@typescript-eslint/parser@8.11.0(eslint@8.57.1)(typescript@5.6.3))(eslint@8.57.1)(typescript@5.6.3)': dependencies: - '@eslint-community/regexpp': 4.10.0 - '@typescript-eslint/parser': 6.21.0(eslint@8.57.0)(typescript@5.3.3) - '@typescript-eslint/scope-manager': 6.21.0 - '@typescript-eslint/type-utils': 6.21.0(eslint@8.57.0)(typescript@5.3.3) - '@typescript-eslint/utils': 6.21.0(eslint@8.57.0)(typescript@5.3.3) - '@typescript-eslint/visitor-keys': 6.21.0 - debug: 4.3.4(supports-color@6.1.0) - eslint: 8.57.0 + '@eslint-community/regexpp': 4.11.1 + '@typescript-eslint/parser': 8.11.0(eslint@8.57.1)(typescript@5.6.3) + '@typescript-eslint/scope-manager': 8.11.0 + '@typescript-eslint/type-utils': 8.11.0(eslint@8.57.1)(typescript@5.6.3) + '@typescript-eslint/utils': 8.11.0(eslint@8.57.1)(typescript@5.6.3) + '@typescript-eslint/visitor-keys': 8.11.0 + eslint: 8.57.1 graphemer: 1.4.0 - ignore: 5.3.1 + ignore: 5.3.2 natural-compare: 1.4.0 - semver: 7.6.0 - ts-api-utils: 1.2.1(typescript@5.3.3) - typescript: 5.3.3 + ts-api-utils: 1.3.0(typescript@5.6.3) + optionalDependencies: + typescript: 5.6.3 transitivePeerDependencies: - supports-color - '@typescript-eslint/parser@6.21.0(eslint@8.57.0)(typescript@5.3.3)': + '@typescript-eslint/parser@8.11.0(eslint@8.57.1)(typescript@5.6.3)': dependencies: - '@typescript-eslint/scope-manager': 6.21.0 - '@typescript-eslint/types': 6.21.0 - '@typescript-eslint/typescript-estree': 6.21.0(typescript@5.3.3) - '@typescript-eslint/visitor-keys': 6.21.0 - debug: 4.3.4(supports-color@6.1.0) - eslint: 8.57.0 - typescript: 5.3.3 + '@typescript-eslint/scope-manager': 8.11.0 + '@typescript-eslint/types': 8.11.0 + '@typescript-eslint/typescript-estree': 8.11.0(typescript@5.6.3) + '@typescript-eslint/visitor-keys': 8.11.0 + debug: 4.3.7(supports-color@6.1.0) + eslint: 8.57.1 + optionalDependencies: + typescript: 5.6.3 transitivePeerDependencies: - supports-color - '@typescript-eslint/scope-manager@6.21.0': + '@typescript-eslint/scope-manager@8.11.0': dependencies: - '@typescript-eslint/types': 6.21.0 - '@typescript-eslint/visitor-keys': 6.21.0 + '@typescript-eslint/types': 8.11.0 + '@typescript-eslint/visitor-keys': 8.11.0 - '@typescript-eslint/type-utils@6.21.0(eslint@8.57.0)(typescript@5.3.3)': + '@typescript-eslint/type-utils@8.11.0(eslint@8.57.1)(typescript@5.6.3)': dependencies: - '@typescript-eslint/typescript-estree': 6.21.0(typescript@5.3.3) - '@typescript-eslint/utils': 6.21.0(eslint@8.57.0)(typescript@5.3.3) - debug: 4.3.4(supports-color@6.1.0) - eslint: 8.57.0 - ts-api-utils: 1.2.1(typescript@5.3.3) - typescript: 5.3.3 + '@typescript-eslint/typescript-estree': 8.11.0(typescript@5.6.3) + '@typescript-eslint/utils': 8.11.0(eslint@8.57.1)(typescript@5.6.3) + debug: 4.3.7(supports-color@6.1.0) + ts-api-utils: 1.3.0(typescript@5.6.3) + optionalDependencies: + typescript: 5.6.3 transitivePeerDependencies: + - eslint - supports-color - '@typescript-eslint/types@6.21.0': {} + '@typescript-eslint/types@8.11.0': {} - '@typescript-eslint/typescript-estree@6.21.0(typescript@5.3.3)': + '@typescript-eslint/typescript-estree@8.11.0(typescript@5.6.3)': dependencies: - '@typescript-eslint/types': 6.21.0 - '@typescript-eslint/visitor-keys': 6.21.0 - debug: 4.3.4(supports-color@6.1.0) - globby: 11.1.0 + '@typescript-eslint/types': 8.11.0 + '@typescript-eslint/visitor-keys': 8.11.0 + debug: 4.3.7(supports-color@6.1.0) + fast-glob: 3.3.2 is-glob: 4.0.3 - minimatch: 9.0.3 - semver: 7.6.0 - ts-api-utils: 1.2.1(typescript@5.3.3) - typescript: 5.3.3 + minimatch: 9.0.5 + semver: 7.6.3 + ts-api-utils: 1.3.0(typescript@5.6.3) + optionalDependencies: + typescript: 5.6.3 transitivePeerDependencies: - supports-color - '@typescript-eslint/utils@6.21.0(eslint@8.57.0)(typescript@5.3.3)': + '@typescript-eslint/utils@8.11.0(eslint@8.57.1)(typescript@5.6.3)': dependencies: - '@eslint-community/eslint-utils': 4.4.0(eslint@8.57.0) - '@types/json-schema': 7.0.15 - '@types/semver': 7.5.8 - '@typescript-eslint/scope-manager': 6.21.0 - '@typescript-eslint/types': 6.21.0 - '@typescript-eslint/typescript-estree': 6.21.0(typescript@5.3.3) - eslint: 8.57.0 - semver: 7.6.0 + '@eslint-community/eslint-utils': 4.4.0(eslint@8.57.1) + '@typescript-eslint/scope-manager': 8.11.0 + '@typescript-eslint/types': 8.11.0 + '@typescript-eslint/typescript-estree': 8.11.0(typescript@5.6.3) + eslint: 8.57.1 transitivePeerDependencies: - supports-color - typescript - '@typescript-eslint/visitor-keys@6.21.0': + '@typescript-eslint/visitor-keys@8.11.0': dependencies: - '@typescript-eslint/types': 6.21.0 + '@typescript-eslint/types': 8.11.0 eslint-visitor-keys: 3.4.3 '@ungap/structured-clone@1.2.0': {} - '@vercel/nft@0.26.4': + '@vercel/nft@0.26.5': dependencies: '@mapbox/node-pre-gyp': 1.0.11 '@rollup/pluginutils': 4.2.1 - acorn: 8.11.3 - acorn-import-attributes: 1.9.2(acorn@8.11.3) + acorn: 8.13.0 + acorn-import-attributes: 1.9.5(acorn@8.13.0) async-sema: 3.1.1 bindings: 1.5.0 estree-walker: 2.0.2 glob: 7.2.3 graceful-fs: 4.2.11 - micromatch: 4.0.5 - node-gyp-build: 4.8.0 + micromatch: 4.0.8 + node-gyp-build: 4.8.2 resolve-from: 5.0.0 transitivePeerDependencies: - encoding - supports-color - '@webassemblyjs/ast@1.11.6': + '@webassemblyjs/ast@1.12.1': dependencies: '@webassemblyjs/helper-numbers': 1.11.6 '@webassemblyjs/helper-wasm-bytecode': 1.11.6 @@ -11020,7 +10708,7 @@ snapshots: '@webassemblyjs/helper-api-error@1.11.6': {} - '@webassemblyjs/helper-buffer@1.11.6': {} + '@webassemblyjs/helper-buffer@1.12.1': {} '@webassemblyjs/helper-numbers@1.11.6': dependencies: @@ -11030,12 +10718,12 @@ snapshots: '@webassemblyjs/helper-wasm-bytecode@1.11.6': {} - '@webassemblyjs/helper-wasm-section@1.11.6': + '@webassemblyjs/helper-wasm-section@1.12.1': dependencies: - '@webassemblyjs/ast': 1.11.6 - '@webassemblyjs/helper-buffer': 1.11.6 + '@webassemblyjs/ast': 1.12.1 + '@webassemblyjs/helper-buffer': 1.12.1 '@webassemblyjs/helper-wasm-bytecode': 1.11.6 - '@webassemblyjs/wasm-gen': 1.11.6 + '@webassemblyjs/wasm-gen': 1.12.1 '@webassemblyjs/ieee754@1.11.6': dependencies: @@ -11047,65 +10735,68 @@ snapshots: '@webassemblyjs/utf8@1.11.6': {} - '@webassemblyjs/wasm-edit@1.11.6': + '@webassemblyjs/wasm-edit@1.12.1': dependencies: - '@webassemblyjs/ast': 1.11.6 - '@webassemblyjs/helper-buffer': 1.11.6 + '@webassemblyjs/ast': 1.12.1 + '@webassemblyjs/helper-buffer': 1.12.1 '@webassemblyjs/helper-wasm-bytecode': 1.11.6 - '@webassemblyjs/helper-wasm-section': 1.11.6 - '@webassemblyjs/wasm-gen': 1.11.6 - '@webassemblyjs/wasm-opt': 1.11.6 - '@webassemblyjs/wasm-parser': 1.11.6 - '@webassemblyjs/wast-printer': 1.11.6 + '@webassemblyjs/helper-wasm-section': 1.12.1 + '@webassemblyjs/wasm-gen': 1.12.1 + '@webassemblyjs/wasm-opt': 1.12.1 + '@webassemblyjs/wasm-parser': 1.12.1 + '@webassemblyjs/wast-printer': 1.12.1 - '@webassemblyjs/wasm-gen@1.11.6': + '@webassemblyjs/wasm-gen@1.12.1': dependencies: - '@webassemblyjs/ast': 1.11.6 + '@webassemblyjs/ast': 1.12.1 '@webassemblyjs/helper-wasm-bytecode': 1.11.6 '@webassemblyjs/ieee754': 1.11.6 '@webassemblyjs/leb128': 1.11.6 '@webassemblyjs/utf8': 1.11.6 - '@webassemblyjs/wasm-opt@1.11.6': + '@webassemblyjs/wasm-opt@1.12.1': dependencies: - '@webassemblyjs/ast': 1.11.6 - '@webassemblyjs/helper-buffer': 1.11.6 - '@webassemblyjs/wasm-gen': 1.11.6 - '@webassemblyjs/wasm-parser': 1.11.6 + '@webassemblyjs/ast': 1.12.1 + '@webassemblyjs/helper-buffer': 1.12.1 + '@webassemblyjs/wasm-gen': 1.12.1 + '@webassemblyjs/wasm-parser': 1.12.1 - '@webassemblyjs/wasm-parser@1.11.6': + '@webassemblyjs/wasm-parser@1.12.1': dependencies: - '@webassemblyjs/ast': 1.11.6 + '@webassemblyjs/ast': 1.12.1 '@webassemblyjs/helper-api-error': 1.11.6 '@webassemblyjs/helper-wasm-bytecode': 1.11.6 '@webassemblyjs/ieee754': 1.11.6 '@webassemblyjs/leb128': 1.11.6 '@webassemblyjs/utf8': 1.11.6 - '@webassemblyjs/wast-printer@1.11.6': + '@webassemblyjs/wast-printer@1.12.1': dependencies: - '@webassemblyjs/ast': 1.11.6 + '@webassemblyjs/ast': 1.12.1 '@xtuc/long': 4.2.2 - '@webpack-cli/configtest@1.2.0(webpack-cli@4.10.0)(webpack@5.90.3)': + '@webpack-cli/configtest@1.2.0(webpack-cli@4.10.0)(webpack@5.95.0)': dependencies: - webpack: 5.90.3(webpack-cli@4.10.0) - webpack-cli: 4.10.0(webpack-dev-server@3.11.3)(webpack@5.90.3) + webpack: 5.95.0(webpack-cli@4.10.0) + webpack-cli: 4.10.0(webpack-dev-server@3.11.3)(webpack@5.95.0) '@webpack-cli/info@1.5.0(webpack-cli@4.10.0)': dependencies: - envinfo: 7.11.1 - webpack-cli: 4.10.0(webpack-dev-server@3.11.3)(webpack@5.90.3) + envinfo: 7.14.0 + webpack-cli: 4.10.0(webpack-dev-server@3.11.3)(webpack@5.95.0) '@webpack-cli/serve@1.7.0(webpack-cli@4.10.0)(webpack-dev-server@3.11.3)': dependencies: - webpack-cli: 4.10.0(webpack-dev-server@3.11.3)(webpack@5.90.3) - webpack-dev-server: 3.11.3(webpack-cli@4.10.0)(webpack@5.90.3) + webpack-cli: 4.10.0(webpack-dev-server@3.11.3)(webpack@5.95.0) + optionalDependencies: + webpack-dev-server: 3.11.3(bufferutil@4.0.8)(utf-8-validate@6.0.3)(webpack-cli@4.10.0)(webpack@5.95.0) '@xtuc/ieee754@1.2.0': {} '@xtuc/long@4.2.2': {} + abbrev@1.0.9: {} + abbrev@1.1.1: {} abortcontroller-polyfill@1.7.5: {} @@ -11120,14 +10811,6 @@ snapshots: module-error: 1.0.2 queue-microtask: 1.2.3 - abstract-leveldown@2.6.3: - dependencies: - xtend: 4.0.2 - - abstract-leveldown@2.7.2: - dependencies: - xtend: 4.0.2 - abstract-leveldown@7.2.0: dependencies: buffer: 6.0.3 @@ -11142,38 +10825,40 @@ snapshots: mime-types: 2.1.35 negotiator: 0.6.3 - acorn-import-assertions@1.9.0(acorn@8.11.3): + acorn-import-attributes@1.9.5(acorn@8.13.0): dependencies: - acorn: 8.11.3 + acorn: 8.13.0 - acorn-import-attributes@1.9.2(acorn@8.11.3): + acorn-jsx@5.3.2(acorn@8.13.0): dependencies: - acorn: 8.11.3 + acorn: 8.13.0 - acorn-jsx@5.3.2(acorn@8.11.3): + acorn-walk@8.3.4: dependencies: - acorn: 8.11.3 - - acorn-walk@8.3.2: {} + acorn: 8.13.0 - acorn@8.11.3: {} + acorn@8.13.0: {} adm-zip@0.4.16: {} aes-js@3.0.0: {} + aes-js@4.0.0-beta.5: {} + agent-base@6.0.2: dependencies: - debug: 4.3.4(supports-color@6.1.0) + debug: 4.3.7(supports-color@6.1.0) transitivePeerDependencies: - supports-color - agent-base@7.1.0: + agent-base@7.1.1: dependencies: - debug: 4.3.4(supports-color@6.1.0) + debug: 4.3.7(supports-color@6.1.0) transitivePeerDependencies: - supports-color + agent-base@7.1.3: {} + aggregate-error@3.1.0: dependencies: clean-stack: 2.2.0 @@ -11183,17 +10868,17 @@ snapshots: dependencies: ajv: 6.12.6 - ajv-formats@2.1.1(ajv@8.12.0): - dependencies: - ajv: 8.12.0 + ajv-formats@2.1.1(ajv@8.17.1): + optionalDependencies: + ajv: 8.17.1 ajv-keywords@3.5.2(ajv@6.12.6): dependencies: ajv: 6.12.6 - ajv-keywords@5.1.0(ajv@8.12.0): + ajv-keywords@5.1.0(ajv@8.17.1): dependencies: - ajv: 8.12.0 + ajv: 8.17.1 fast-deep-equal: 3.1.3 ajv@6.12.6: @@ -11203,12 +10888,15 @@ snapshots: json-schema-traverse: 0.4.1 uri-js: 4.4.1 - ajv@8.12.0: + ajv@8.17.1: dependencies: fast-deep-equal: 3.1.3 + fast-uri: 3.0.3 json-schema-traverse: 1.0.0 require-from-string: 2.0.2 - uri-js: 4.4.1 + + amdefine@1.0.1: + optional: true ansi-align@3.0.1: dependencies: @@ -11216,8 +10904,6 @@ snapshots: ansi-colors@3.2.4: {} - ansi-colors@4.1.1: {} - ansi-colors@4.1.3: {} ansi-escapes@4.3.2: @@ -11228,11 +10914,13 @@ snapshots: ansi-regex@2.1.1: {} + ansi-regex@3.0.1: {} + ansi-regex@4.1.1: {} ansi-regex@5.0.1: {} - ansi-regex@6.0.1: {} + ansi-regex@6.1.0: {} ansi-styles@3.2.1: dependencies: @@ -11244,6 +10932,8 @@ snapshots: ansi-styles@6.2.1: {} + antlr4ts@0.5.0-alpha.4: {} + anymatch@2.0.0(supports-color@6.1.0): dependencies: micromatch: 3.1.10(supports-color@6.1.0) @@ -11283,14 +10973,6 @@ snapshots: arr-union@3.1.0: {} - array-back@1.0.4: - dependencies: - typical: 2.6.1 - - array-back@2.0.0: - dependencies: - typical: 2.6.1 - array-back@3.1.0: {} array-back@4.0.2: {} @@ -11306,11 +10988,12 @@ snapshots: array-flatten@2.1.2: {} - array-includes@3.1.7: + array-includes@3.1.8: dependencies: call-bind: 1.0.7 define-properties: 1.2.1 - es-abstract: 1.22.4 + es-abstract: 1.23.3 + es-object-atoms: 1.0.0 get-intrinsic: 1.2.4 is-string: 1.0.7 @@ -11324,34 +11007,27 @@ snapshots: array-unique@0.3.2: {} - array.prototype.filter@1.0.3: - dependencies: - call-bind: 1.0.7 - define-properties: 1.2.1 - es-abstract: 1.22.4 - es-array-method-boxes-properly: 1.0.0 - is-string: 1.0.7 - - array.prototype.findlastindex@1.2.4: + array.prototype.findlastindex@1.2.5: dependencies: call-bind: 1.0.7 define-properties: 1.2.1 - es-abstract: 1.22.4 + es-abstract: 1.23.3 es-errors: 1.3.0 + es-object-atoms: 1.0.0 es-shim-unscopables: 1.0.2 array.prototype.flat@1.3.2: dependencies: call-bind: 1.0.7 define-properties: 1.2.1 - es-abstract: 1.22.4 + es-abstract: 1.23.3 es-shim-unscopables: 1.0.2 array.prototype.flatmap@1.3.2: dependencies: call-bind: 1.0.7 define-properties: 1.2.1 - es-abstract: 1.22.4 + es-abstract: 1.23.3 es-shim-unscopables: 1.0.2 arraybuffer.prototype.slice@1.0.3: @@ -11359,7 +11035,7 @@ snapshots: array-buffer-byte-length: 1.0.1 call-bind: 1.0.7 define-properties: 1.2.1 - es-abstract: 1.22.4 + es-abstract: 1.23.3 es-errors: 1.3.0 get-intrinsic: 1.2.4 is-array-buffer: 3.0.4 @@ -11367,10 +11043,10 @@ snapshots: arrgv@1.0.2: {} - arrify@1.0.1: {} - arrify@3.0.0: {} + asap@2.0.6: {} + asn1@0.2.6: dependencies: safer-buffer: 2.1.2 @@ -11383,7 +11059,9 @@ snapshots: ast-types@0.13.4: dependencies: - tslib: 2.6.2 + tslib: 2.8.0 + + astral-regex@2.0.0: {} async-each@1.0.6: {} @@ -11393,9 +11071,9 @@ snapshots: async-limiter@1.0.1: {} - async-mutex@0.2.6: + async-mutex@0.5.0: dependencies: - tslib: 2.6.2 + tslib: 2.8.0 async-sema@3.1.1: {} @@ -11411,15 +11089,15 @@ snapshots: atob@2.1.2: {} - ava@6.1.1: + ava@6.1.3: dependencies: - '@vercel/nft': 0.26.4 - acorn: 8.11.3 - acorn-walk: 8.3.2 + '@vercel/nft': 0.26.5 + acorn: 8.13.0 + acorn-walk: 8.3.4 ansi-styles: 6.2.1 arrgv: 1.0.2 arrify: 3.0.0 - callsites: 4.1.0 + callsites: 4.2.0 cbor: 9.0.2 chalk: 5.3.0 chunkd: 2.0.1 @@ -11430,10 +11108,10 @@ snapshots: common-path-prefix: 3.0.0 concordance: 5.0.4 currently-unhandled: 0.4.1 - debug: 4.3.4(supports-color@6.1.0) + debug: 4.3.7(supports-color@6.1.0) emittery: 1.0.3 - figures: 6.0.1 - globby: 14.0.1 + figures: 6.1.0 + globby: 14.0.2 ignore-by-default: 2.1.0 indent-string: 5.0.0 is-plain-object: 5.0.0 @@ -11441,11 +11119,11 @@ snapshots: matcher: 5.0.0 memoize: 10.0.0 ms: 2.1.3 - p-map: 7.0.1 + p-map: 7.0.2 package-config: 5.0.0 picomatch: 3.0.1 plur: 5.1.0 - pretty-ms: 9.0.0 + pretty-ms: 9.1.0 resolve-cwd: 3.0.0 stack-utils: 2.0.6 strip-ansi: 7.1.0 @@ -11463,61 +11141,77 @@ snapshots: aws-sign2@0.7.0: {} - aws4@1.12.0: {} + aws4@1.13.2: {} - axios@1.6.7: + axios@1.7.7: dependencies: - follow-redirects: 1.15.5(debug@4.3.4) - form-data: 4.0.0 + follow-redirects: 1.15.9(debug@4.3.7(supports-color@6.1.0)) + form-data: 4.0.1 proxy-from-env: 1.1.0 transitivePeerDependencies: - debug - b4a@1.6.6: {} + b4a@1.6.7: {} - babel-loader@9.1.3(@babel/core@7.23.9)(webpack@5.90.3): + babel-loader@9.2.1(@babel/core@7.25.9)(webpack@5.95.0): dependencies: - '@babel/core': 7.23.9 + '@babel/core': 7.25.9 find-cache-dir: 4.0.0 schema-utils: 4.2.0 - webpack: 5.90.3(webpack-cli@4.10.0) + webpack: 5.95.0(webpack-cli@4.10.0) - babel-plugin-polyfill-corejs2@0.4.8(@babel/core@7.23.9): + babel-plugin-polyfill-corejs2@0.4.11(@babel/core@7.25.9): dependencies: - '@babel/compat-data': 7.23.5 - '@babel/core': 7.23.9 - '@babel/helper-define-polyfill-provider': 0.5.0(@babel/core@7.23.9) + '@babel/compat-data': 7.25.9 + '@babel/core': 7.25.9 + '@babel/helper-define-polyfill-provider': 0.6.2(@babel/core@7.25.9) semver: 6.3.1 transitivePeerDependencies: - supports-color - babel-plugin-polyfill-corejs3@0.9.0(@babel/core@7.23.9): + babel-plugin-polyfill-corejs3@0.10.6(@babel/core@7.25.9): dependencies: - '@babel/core': 7.23.9 - '@babel/helper-define-polyfill-provider': 0.5.0(@babel/core@7.23.9) - core-js-compat: 3.36.0 + '@babel/core': 7.25.9 + '@babel/helper-define-polyfill-provider': 0.6.2(@babel/core@7.25.9) + core-js-compat: 3.38.1 transitivePeerDependencies: - supports-color - babel-plugin-polyfill-regenerator@0.5.5(@babel/core@7.23.9): + babel-plugin-polyfill-regenerator@0.6.2(@babel/core@7.25.9): dependencies: - '@babel/core': 7.23.9 - '@babel/helper-define-polyfill-provider': 0.5.0(@babel/core@7.23.9) + '@babel/core': 7.25.9 + '@babel/helper-define-polyfill-provider': 0.6.2(@babel/core@7.25.9) transitivePeerDependencies: - supports-color backo2@1.0.2: {} - backoff@2.5.0: + balanced-match@1.0.2: {} + + bare-events@2.5.0: + optional: true + + bare-fs@2.3.5: dependencies: - precond: 0.2.3 + bare-events: 2.5.0 + bare-path: 2.1.3 + bare-stream: 2.3.2 + optional: true - balanced-match@1.0.2: {} + bare-os@2.4.4: + optional: true + + bare-path@2.1.3: + dependencies: + bare-os: 2.4.4 + optional: true - bare-events@2.2.0: + bare-stream@2.3.2: + dependencies: + streamx: 2.20.1 optional: true - base-x@3.0.9: + base-x@3.0.10: dependencies: safe-buffer: 5.2.1 @@ -11537,7 +11231,7 @@ snapshots: mixin-deep: 1.3.2 pascalcase: 0.1.1 - basic-ftp@5.0.4: {} + basic-ftp@5.0.5: {} batch@0.6.1: {} @@ -11551,15 +11245,11 @@ snapshots: dependencies: is-windows: 1.0.2 - bigint-crypto-utils@3.3.0: {} - - bignumber.js@7.2.1: {} - bignumber.js@9.1.2: {} binary-extensions@1.13.1: {} - binary-extensions@2.2.0: {} + binary-extensions@2.3.0: {} bindings@1.5.0: dependencies: @@ -11577,24 +11267,7 @@ snapshots: bn.js@5.2.1: {} - body-parser@1.20.1(supports-color@6.1.0): - dependencies: - bytes: 3.1.2 - content-type: 1.0.5 - debug: 2.6.9(supports-color@6.1.0) - depd: 2.0.0 - destroy: 1.2.0 - http-errors: 2.0.0 - iconv-lite: 0.4.24 - on-finished: 2.4.1 - qs: 6.11.0 - raw-body: 2.5.1 - type-is: 1.6.18 - unpipe: 1.0.0 - transitivePeerDependencies: - - supports-color - - body-parser@1.20.2: + body-parser@1.20.3(supports-color@6.1.0): dependencies: bytes: 3.1.2 content-type: 1.0.5 @@ -11604,7 +11277,7 @@ snapshots: http-errors: 2.0.0 iconv-lite: 0.4.24 on-finished: 2.4.1 - qs: 6.11.0 + qs: 6.13.0 raw-body: 2.5.2 type-is: 1.6.18 unpipe: 1.0.0 @@ -11659,17 +11332,13 @@ snapshots: transitivePeerDependencies: - supports-color - braces@3.0.2: - dependencies: - fill-range: 7.0.1 - - breakword@1.0.6: + braces@3.0.3: dependencies: - wcwidth: 1.0.1 + fill-range: 7.1.1 brorand@1.1.0: {} - brotli-wasm@1.3.1: {} + brotli-wasm@3.0.1: {} browser-stdout@1.3.1: {} @@ -11682,16 +11351,16 @@ snapshots: inherits: 2.0.4 safe-buffer: 5.2.1 - browserslist@4.23.0: + browserslist@4.24.2: dependencies: - caniuse-lite: 1.0.30001591 - electron-to-chromium: 1.4.682 - node-releases: 2.0.14 - update-browserslist-db: 1.0.13(browserslist@4.23.0) + caniuse-lite: 1.0.30001669 + electron-to-chromium: 1.5.45 + node-releases: 2.0.18 + update-browserslist-db: 1.1.1(browserslist@4.24.2) bs58@4.0.1: dependencies: - base-x: 3.0.9 + base-x: 3.0.10 bs58check@2.1.2: dependencies: @@ -11699,8 +11368,6 @@ snapshots: create-hash: 1.2.0 safe-buffer: 5.2.1 - btoa@1.2.1: {} - buffer-crc32@0.2.13: {} buffer-from@1.1.2: {} @@ -11721,18 +11388,9 @@ snapshots: base64-js: 1.5.1 ieee754: 1.2.1 - bufferutil@4.0.5: - dependencies: - node-gyp-build: 4.8.0 - optional: true - - bufferutil@4.0.7: - dependencies: - node-gyp-build: 4.8.0 - bufferutil@4.0.8: dependencies: - node-gyp-build: 4.8.0 + node-gyp-build: 4.8.2 builtin-modules@3.3.0: {} @@ -11779,51 +11437,49 @@ snapshots: es-errors: 1.3.0 function-bind: 1.1.2 get-intrinsic: 1.2.4 - set-function-length: 1.2.1 + set-function-length: 1.2.2 callsites@3.1.0: {} - callsites@4.1.0: {} + callsites@4.2.0: {} camel-case@4.1.2: dependencies: pascal-case: 3.1.2 - tslib: 2.6.2 - - camelcase-keys@6.2.2: - dependencies: - camelcase: 5.3.1 - map-obj: 4.3.0 - quick-lru: 4.0.1 + tslib: 2.8.0 camelcase@5.3.1: {} camelcase@6.3.0: {} - caniuse-lite@1.0.30001591: {} + caniuse-lite@1.0.30001669: {} caseless@0.12.0: {} catering@2.1.1: {} + cbor@8.1.0: + dependencies: + nofilter: 3.1.0 + cbor@9.0.2: dependencies: nofilter: 3.1.0 - chai-as-promised@7.1.1(chai@4.4.1): + chai-as-promised@7.1.2(chai@4.5.0): dependencies: - chai: 4.4.1 + chai: 4.5.0 check-error: 1.0.3 - chai@4.4.1: + chai@4.5.0: dependencies: assertion-error: 1.1.0 check-error: 1.0.3 - deep-eql: 4.1.3 + deep-eql: 4.1.4 get-func-name: 2.0.2 loupe: 2.3.7 pathval: 1.1.1 - type-detect: 4.0.8 + type-detect: 4.1.0 chalk@2.4.2: dependencies: @@ -11840,14 +11496,12 @@ snapshots: chardet@0.7.0: {} + charenc@0.0.2: {} + check-error@1.0.3: dependencies: get-func-name: 2.0.2 - checkpoint-store@1.1.0: - dependencies: - functional-red-black-tree: 1.0.1 - chokidar@2.1.8(supports-color@6.1.0): dependencies: anymatch: 2.0.0(supports-color@6.1.0) @@ -11866,10 +11520,10 @@ snapshots: transitivePeerDependencies: - supports-color - chokidar@3.5.3: + chokidar@3.6.0: dependencies: anymatch: 3.1.3 - braces: 3.0.2 + braces: 3.0.3 glob-parent: 5.1.2 is-binary-path: 2.1.0 is-glob: 4.0.3 @@ -11878,29 +11532,22 @@ snapshots: optionalDependencies: fsevents: 2.3.3 - chokidar@3.6.0: + chokidar@4.0.1: dependencies: - anymatch: 3.1.3 - braces: 3.0.2 - glob-parent: 5.1.2 - is-binary-path: 2.1.0 - is-glob: 4.0.3 - normalize-path: 3.0.0 - readdirp: 3.6.0 - optionalDependencies: - fsevents: 2.3.3 + readdirp: 4.0.2 chownr@1.1.4: {} chownr@2.0.0: {} - chrome-trace-event@1.0.3: {} + chrome-trace-event@1.0.4: {} - chromium-bidi@0.5.8(devtools-protocol@0.0.1232444): + chromium-bidi@0.8.0(devtools-protocol@0.0.1367902): dependencies: - devtools-protocol: 0.0.1232444 + devtools-protocol: 0.0.1367902 mitt: 3.0.1 urlpattern-polyfill: 10.0.0 + zod: 3.23.8 chunkd@2.0.1: {} @@ -11942,10 +11589,17 @@ snapshots: cli-boxes@2.2.1: {} + cli-table3@0.5.1: + dependencies: + object-assign: 4.1.1 + string-width: 2.1.1 + optionalDependencies: + colors: 1.4.0 + cli-truncate@4.0.0: dependencies: slice-ansi: 5.0.0 - string-width: 7.1.0 + string-width: 7.2.0 cliui@5.0.0: dependencies: @@ -11981,10 +11635,6 @@ snapshots: dependencies: mimic-response: 1.0.1 - clone@1.0.4: {} - - clone@2.1.2: {} - code-excerpt@4.0.0: dependencies: convert-to-spaces: 2.0.1 @@ -12010,18 +11660,14 @@ snapshots: colorette@2.0.20: {} + colors@1.4.0: {} + combined-stream@1.0.8: dependencies: delayed-stream: 1.0.0 command-exists@1.2.9: {} - command-line-args@4.0.7: - dependencies: - array-back: 2.0.0 - find-replace: 1.0.3 - typical: 2.6.1 - command-line-args@5.2.1: dependencies: array-back: 3.1.0 @@ -12038,8 +11684,6 @@ snapshots: commander@2.20.3: {} - commander@3.0.2: {} - commander@7.2.0: {} commander@8.3.0: {} @@ -12054,7 +11698,7 @@ snapshots: compressible@2.0.18: dependencies: - mime-db: 1.52.0 + mime-db: 1.53.0 compression@1.7.4(supports-color@6.1.0): dependencies: @@ -12070,6 +11714,13 @@ snapshots: concat-map@0.0.1: {} + concat-stream@1.6.2: + dependencies: + buffer-from: 1.1.2 + inherits: 2.0.4 + readable-stream: 2.3.8 + typedarray: 0.0.6 + concordance@5.0.4: dependencies: date-time: 3.1.0 @@ -12078,29 +11729,15 @@ snapshots: js-string-escape: 1.0.1 lodash: 4.17.21 md5-hex: 3.0.1 - semver: 7.6.0 + semver: 7.6.3 well-known-symbols: 2.0.0 - concurrently@7.6.0: - dependencies: - chalk: 4.1.2 - date-fns: 2.30.0 - lodash: 4.17.21 - rxjs: 7.8.1 - shell-quote: 1.8.1 - spawn-command: 0.0.2-1 - supports-color: 8.1.1 - tree-kill: 1.2.2 - yargs: 17.7.2 - - concurrently@8.2.2: + concurrently@9.0.1: dependencies: chalk: 4.1.2 - date-fns: 2.30.0 lodash: 4.17.21 rxjs: 7.8.1 shell-quote: 1.8.1 - spawn-command: 0.0.2 supports-color: 8.1.1 tree-kill: 1.2.2 yargs: 17.7.2 @@ -12140,13 +11777,13 @@ snapshots: cookie@0.4.2: {} - cookie@0.5.0: {} + cookie@0.7.1: {} copy-descriptor@0.1.1: {} - core-js-compat@3.36.0: + core-js-compat@3.38.1: dependencies: - browserslist: 4.23.0 + browserslist: 4.24.2 core-util-is@1.0.2: {} @@ -12159,13 +11796,14 @@ snapshots: object-assign: 4.1.1 vary: 1.1.2 - cosmiconfig@9.0.0(typescript@5.3.3): + cosmiconfig@9.0.0(typescript@5.6.3): dependencies: env-paths: 2.2.1 import-fresh: 3.3.0 js-yaml: 4.1.0 parse-json: 5.2.0 - typescript: 5.3.3 + optionalDependencies: + typescript: 5.6.3 crc-32@1.2.2: {} @@ -12220,6 +11858,8 @@ snapshots: shebang-command: 2.0.0 which: 2.0.2 + crypt@0.0.2: {} + css-select@4.3.0: dependencies: boolbase: 1.0.0 @@ -12230,27 +11870,14 @@ snapshots: css-what@6.1.0: {} - csv-generate@3.4.3: {} - - csv-parse@4.16.3: {} - - csv-stringify@5.6.5: {} - - csv@5.5.3: - dependencies: - csv-generate: 3.4.3 - csv-parse: 4.16.3 - csv-stringify: 5.6.5 - stream-transform: 2.1.3 - currently-unhandled@0.4.1: dependencies: array-find-index: 1.0.2 - d@1.0.1: + d@1.0.2: dependencies: - es5-ext: 0.10.63 - type: 1.2.0 + es5-ext: 0.10.64 + type: 2.7.3 dashdash@1.14.1: dependencies: @@ -12258,42 +11885,61 @@ snapshots: data-uri-to-buffer@6.0.2: {} - dataloader@1.4.0: {} + data-view-buffer@1.0.1: + dependencies: + call-bind: 1.0.7 + es-errors: 1.3.0 + is-data-view: 1.0.1 - dataloader@2.2.2: {} + data-view-byte-length@1.0.1: + dependencies: + call-bind: 1.0.7 + es-errors: 1.3.0 + is-data-view: 1.0.1 - date-fns@2.30.0: + data-view-byte-offset@1.0.0: dependencies: - '@babel/runtime': 7.23.9 + call-bind: 1.0.7 + es-errors: 1.3.0 + is-data-view: 1.0.1 + + dataloader@1.4.0: {} + + dataloader@2.2.2: {} date-time@3.1.0: dependencies: time-zone: 1.0.0 + death@1.1.0: {} + debug@2.6.9(supports-color@6.1.0): dependencies: ms: 2.0.0 + optionalDependencies: supports-color: 6.1.0 debug@3.2.7(supports-color@6.1.0): dependencies: ms: 2.1.3 + optionalDependencies: supports-color: 6.1.0 - debug@4.3.4(supports-color@6.1.0): + debug@4.3.7(supports-color@6.1.0): dependencies: - ms: 2.1.2 + ms: 2.1.3 + optionalDependencies: supports-color: 6.1.0 - debug@4.3.4(supports-color@8.1.1): + debug@4.3.7(supports-color@8.1.1): dependencies: - ms: 2.1.2 + ms: 2.1.3 + optionalDependencies: supports-color: 8.1.1 - decamelize-keys@1.1.1: + debug@4.4.0: dependencies: - decamelize: 1.2.0 - map-obj: 1.0.1 + ms: 2.1.3 decamelize@1.2.0: {} @@ -12309,18 +11955,18 @@ snapshots: dependencies: mimic-response: 3.1.0 - deep-eql@4.1.3: + deep-eql@4.1.4: dependencies: - type-detect: 4.0.8 + type-detect: 4.1.0 deep-equal@1.1.2: dependencies: is-arguments: 1.1.1 is-date-object: 1.0.5 is-regex: 1.1.4 - object-is: 1.1.5 + object-is: 1.1.6 object-keys: 1.1.1 - regexp.prototype.flags: 1.5.2 + regexp.prototype.flags: 1.5.3 deep-extend@0.6.0: {} @@ -12337,16 +11983,8 @@ snapshots: dependencies: strip-bom: 4.0.0 - defaults@1.0.4: - dependencies: - clone: 1.0.4 - defer-to-connect@2.0.1: {} - deferred-leveldown@1.2.2: - dependencies: - abstract-leveldown: 2.6.3 - define-data-property@1.1.4: dependencies: es-define-property: 1.0.0 @@ -12398,21 +12036,25 @@ snapshots: destroy@1.2.0: {} - destroyable-server@1.0.1: + destroyable-server@1.0.2: dependencies: - '@types/node': 20.11.20 + '@types/node': 22.7.9 detect-indent@6.1.0: {} - detect-libc@2.0.2: {} + detect-libc@2.0.3: {} detect-node@2.1.0: {} - devtools-protocol@0.0.1232444: {} + devtools-protocol@0.0.1367902: {} diff@4.0.2: {} - diff@5.0.0: {} + diff@5.2.0: {} + + difflib@0.2.4: + dependencies: + heap: 0.2.7 dir-glob@3.0.1: dependencies: @@ -12468,7 +12110,7 @@ snapshots: dot-case@3.0.4: dependencies: no-case: 3.0.4 - tslib: 2.6.2 + tslib: 2.8.0 dotenv@16.4.5: {} @@ -12490,7 +12132,7 @@ snapshots: ee-first@1.1.1: {} - electron-to-chromium@1.4.682: {} + electron-to-chromium@1.5.45: {} elliptic@6.5.4: dependencies: @@ -12502,11 +12144,21 @@ snapshots: minimalistic-assert: 1.0.1 minimalistic-crypto-utils: 1.0.1 + elliptic@6.5.7: + dependencies: + bn.js: 4.12.0 + brorand: 1.1.0 + hash.js: 1.1.7 + hmac-drbg: 1.0.1 + inherits: 2.0.4 + minimalistic-assert: 1.0.1 + minimalistic-crypto-utils: 1.0.1 + emittery@0.10.0: {} emittery@1.0.3: {} - emoji-regex@10.3.0: {} + emoji-regex@10.4.0: {} emoji-regex@7.0.3: {} @@ -12516,11 +12168,13 @@ snapshots: encodeurl@1.0.2: {} + encodeurl@2.0.0: {} + end-of-stream@1.4.4: dependencies: once: 1.4.0 - enhanced-resolve@5.15.0: + enhanced-resolve@5.17.1: dependencies: graceful-fs: 4.2.11 tapable: 2.2.1 @@ -12534,7 +12188,7 @@ snapshots: env-paths@2.2.1: {} - envinfo@7.11.1: {} + envinfo@7.14.0: {} errno@0.1.8: dependencies: @@ -12544,51 +12198,54 @@ snapshots: dependencies: is-arrayish: 0.2.1 - es-abstract@1.22.4: + es-abstract@1.23.3: dependencies: array-buffer-byte-length: 1.0.1 arraybuffer.prototype.slice: 1.0.3 available-typed-arrays: 1.0.7 call-bind: 1.0.7 + data-view-buffer: 1.0.1 + data-view-byte-length: 1.0.1 + data-view-byte-offset: 1.0.0 es-define-property: 1.0.0 es-errors: 1.3.0 + es-object-atoms: 1.0.0 es-set-tostringtag: 2.0.3 es-to-primitive: 1.2.1 function.prototype.name: 1.1.6 get-intrinsic: 1.2.4 get-symbol-description: 1.0.2 - globalthis: 1.0.3 + globalthis: 1.0.4 gopd: 1.0.1 has-property-descriptors: 1.0.2 has-proto: 1.0.3 has-symbols: 1.0.3 - hasown: 2.0.1 + hasown: 2.0.2 internal-slot: 1.0.7 is-array-buffer: 3.0.4 is-callable: 1.2.7 + is-data-view: 1.0.1 is-negative-zero: 2.0.3 is-regex: 1.1.4 is-shared-array-buffer: 1.0.3 is-string: 1.0.7 is-typed-array: 1.1.13 is-weakref: 1.0.2 - object-inspect: 1.13.1 + object-inspect: 1.13.2 object-keys: 1.1.1 object.assign: 4.1.5 - regexp.prototype.flags: 1.5.2 - safe-array-concat: 1.1.0 + regexp.prototype.flags: 1.5.3 + safe-array-concat: 1.1.2 safe-regex-test: 1.0.3 - string.prototype.trim: 1.2.8 - string.prototype.trimend: 1.0.7 - string.prototype.trimstart: 1.0.7 + string.prototype.trim: 1.2.9 + string.prototype.trimend: 1.0.8 + string.prototype.trimstart: 1.0.8 typed-array-buffer: 1.0.2 typed-array-byte-length: 1.0.1 typed-array-byte-offset: 1.0.2 - typed-array-length: 1.0.5 + typed-array-length: 1.0.6 unbox-primitive: 1.0.2 - which-typed-array: 1.1.14 - - es-array-method-boxes-properly@1.0.0: {} + which-typed-array: 1.1.15 es-define-property@1.0.0: dependencies: @@ -12596,17 +12253,21 @@ snapshots: es-errors@1.3.0: {} - es-module-lexer@1.4.1: {} + es-module-lexer@1.5.4: {} + + es-object-atoms@1.0.0: + dependencies: + es-errors: 1.3.0 es-set-tostringtag@2.0.3: dependencies: get-intrinsic: 1.2.4 has-tostringtag: 1.0.2 - hasown: 2.0.1 + hasown: 2.0.2 es-shim-unscopables@1.0.2: dependencies: - hasown: 2.0.1 + hasown: 2.0.2 es-to-primitive@1.2.1: dependencies: @@ -12614,10 +12275,10 @@ snapshots: is-date-object: 1.0.5 is-symbol: 1.0.4 - es5-ext@0.10.63: + es5-ext@0.10.64: dependencies: es6-iterator: 2.0.3 - es6-symbol: 3.1.3 + es6-symbol: 3.1.4 esniff: 2.0.1 next-tick: 1.1.0 @@ -12625,44 +12286,45 @@ snapshots: es6-iterator@2.0.3: dependencies: - d: 1.0.1 - es5-ext: 0.10.63 - es6-symbol: 3.1.3 + d: 1.0.2 + es5-ext: 0.10.64 + es6-symbol: 3.1.4 es6-promise@4.2.8: {} - es6-symbol@3.1.3: + es6-symbol@3.1.4: dependencies: - d: 1.0.1 + d: 1.0.2 ext: 1.7.0 - esbuild@0.19.12: + esbuild@0.23.1: optionalDependencies: - '@esbuild/aix-ppc64': 0.19.12 - '@esbuild/android-arm': 0.19.12 - '@esbuild/android-arm64': 0.19.12 - '@esbuild/android-x64': 0.19.12 - '@esbuild/darwin-arm64': 0.19.12 - '@esbuild/darwin-x64': 0.19.12 - '@esbuild/freebsd-arm64': 0.19.12 - '@esbuild/freebsd-x64': 0.19.12 - '@esbuild/linux-arm': 0.19.12 - '@esbuild/linux-arm64': 0.19.12 - '@esbuild/linux-ia32': 0.19.12 - '@esbuild/linux-loong64': 0.19.12 - '@esbuild/linux-mips64el': 0.19.12 - '@esbuild/linux-ppc64': 0.19.12 - '@esbuild/linux-riscv64': 0.19.12 - '@esbuild/linux-s390x': 0.19.12 - '@esbuild/linux-x64': 0.19.12 - '@esbuild/netbsd-x64': 0.19.12 - '@esbuild/openbsd-x64': 0.19.12 - '@esbuild/sunos-x64': 0.19.12 - '@esbuild/win32-arm64': 0.19.12 - '@esbuild/win32-ia32': 0.19.12 - '@esbuild/win32-x64': 0.19.12 - - escalade@3.1.2: {} + '@esbuild/aix-ppc64': 0.23.1 + '@esbuild/android-arm': 0.23.1 + '@esbuild/android-arm64': 0.23.1 + '@esbuild/android-x64': 0.23.1 + '@esbuild/darwin-arm64': 0.23.1 + '@esbuild/darwin-x64': 0.23.1 + '@esbuild/freebsd-arm64': 0.23.1 + '@esbuild/freebsd-x64': 0.23.1 + '@esbuild/linux-arm': 0.23.1 + '@esbuild/linux-arm64': 0.23.1 + '@esbuild/linux-ia32': 0.23.1 + '@esbuild/linux-loong64': 0.23.1 + '@esbuild/linux-mips64el': 0.23.1 + '@esbuild/linux-ppc64': 0.23.1 + '@esbuild/linux-riscv64': 0.23.1 + '@esbuild/linux-s390x': 0.23.1 + '@esbuild/linux-x64': 0.23.1 + '@esbuild/netbsd-x64': 0.23.1 + '@esbuild/openbsd-arm64': 0.23.1 + '@esbuild/openbsd-x64': 0.23.1 + '@esbuild/sunos-x64': 0.23.1 + '@esbuild/win32-arm64': 0.23.1 + '@esbuild/win32-ia32': 0.23.1 + '@esbuild/win32-x64': 0.23.1 + + escalade@3.2.0: {} escape-html@1.0.3: {} @@ -12674,6 +12336,15 @@ snapshots: escape-string-regexp@5.0.0: {} + escodegen@1.8.1: + dependencies: + esprima: 2.7.3 + estraverse: 1.9.3 + esutils: 2.0.3 + optionator: 0.8.3 + optionalDependencies: + source-map: 0.2.0 + escodegen@2.1.0: dependencies: esprima: 4.0.1 @@ -12682,60 +12353,65 @@ snapshots: optionalDependencies: source-map: 0.6.1 - eslint-config-prettier@9.1.0(eslint@8.57.0): + eslint-config-prettier@9.1.0(eslint@8.57.1): dependencies: - eslint: 8.57.0 + eslint: 8.57.1 eslint-import-resolver-node@0.3.9: dependencies: debug: 3.2.7(supports-color@6.1.0) - is-core-module: 2.13.1 + is-core-module: 2.15.1 resolve: 1.22.8 transitivePeerDependencies: - supports-color - eslint-module-utils@2.8.1(@typescript-eslint/parser@6.21.0)(eslint-import-resolver-node@0.3.9)(eslint@8.57.0): + eslint-module-utils@2.12.0(@typescript-eslint/parser@8.11.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-node@0.3.9)(eslint@8.57.1): dependencies: - '@typescript-eslint/parser': 6.21.0(eslint@8.57.0)(typescript@5.3.3) debug: 3.2.7(supports-color@6.1.0) - eslint: 8.57.0 + optionalDependencies: + '@typescript-eslint/parser': 8.11.0(eslint@8.57.1)(typescript@5.6.3) + eslint: 8.57.1 eslint-import-resolver-node: 0.3.9 transitivePeerDependencies: - supports-color - eslint-plugin-import@2.29.1(@typescript-eslint/parser@6.21.0)(eslint@8.57.0): + eslint-plugin-import@2.31.0(@typescript-eslint/parser@8.11.0(eslint@8.57.1)(typescript@5.6.3))(eslint@8.57.1): dependencies: - '@typescript-eslint/parser': 6.21.0(eslint@8.57.0)(typescript@5.3.3) - array-includes: 3.1.7 - array.prototype.findlastindex: 1.2.4 + '@rtsao/scc': 1.1.0 + array-includes: 3.1.8 + array.prototype.findlastindex: 1.2.5 array.prototype.flat: 1.3.2 array.prototype.flatmap: 1.3.2 debug: 3.2.7(supports-color@6.1.0) doctrine: 2.1.0 - eslint: 8.57.0 + eslint: 8.57.1 eslint-import-resolver-node: 0.3.9 - eslint-module-utils: 2.8.1(@typescript-eslint/parser@6.21.0)(eslint-import-resolver-node@0.3.9)(eslint@8.57.0) - hasown: 2.0.1 - is-core-module: 2.13.1 + eslint-module-utils: 2.12.0(@typescript-eslint/parser@8.11.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-node@0.3.9)(eslint@8.57.1) + hasown: 2.0.2 + is-core-module: 2.15.1 is-glob: 4.0.3 minimatch: 3.1.2 - object.fromentries: 2.0.7 - object.groupby: 1.0.2 - object.values: 1.1.7 + object.fromentries: 2.0.8 + object.groupby: 1.0.3 + object.values: 1.2.0 semver: 6.3.1 + string.prototype.trimend: 1.0.8 tsconfig-paths: 3.15.0 + optionalDependencies: + '@typescript-eslint/parser': 8.11.0(eslint@8.57.1)(typescript@5.6.3) transitivePeerDependencies: - eslint-import-resolver-typescript - eslint-import-resolver-webpack - supports-color - eslint-plugin-prettier@5.1.3(eslint-config-prettier@9.1.0)(eslint@8.57.0)(prettier@3.2.5): + eslint-plugin-prettier@5.2.1(eslint-config-prettier@9.1.0(eslint@8.57.1))(eslint@8.57.1)(prettier@3.3.3): dependencies: - eslint: 8.57.0 - eslint-config-prettier: 9.1.0(eslint@8.57.0) - prettier: 3.2.5 + eslint: 8.57.1 + prettier: 3.3.3 prettier-linter-helpers: 1.0.0 - synckit: 0.8.8 + synckit: 0.9.2 + optionalDependencies: + eslint-config-prettier: 9.1.0(eslint@8.57.1) eslint-scope@5.1.1: dependencies: @@ -12749,26 +12425,26 @@ snapshots: eslint-visitor-keys@3.4.3: {} - eslint@8.57.0: + eslint@8.57.1: dependencies: - '@eslint-community/eslint-utils': 4.4.0(eslint@8.57.0) - '@eslint-community/regexpp': 4.10.0 + '@eslint-community/eslint-utils': 4.4.0(eslint@8.57.1) + '@eslint-community/regexpp': 4.11.1 '@eslint/eslintrc': 2.1.4 - '@eslint/js': 8.57.0 - '@humanwhocodes/config-array': 0.11.14 + '@eslint/js': 8.57.1 + '@humanwhocodes/config-array': 0.13.0 '@humanwhocodes/module-importer': 1.0.1 '@nodelib/fs.walk': 1.2.8 '@ungap/structured-clone': 1.2.0 ajv: 6.12.6 chalk: 4.1.2 cross-spawn: 7.0.3 - debug: 4.3.4(supports-color@6.1.0) + debug: 4.3.7(supports-color@6.1.0) doctrine: 3.0.0 escape-string-regexp: 4.0.0 eslint-scope: 7.2.2 eslint-visitor-keys: 3.4.3 espree: 9.6.1 - esquery: 1.5.0 + esquery: 1.6.0 esutils: 2.0.3 fast-deep-equal: 3.1.3 file-entry-cache: 6.0.1 @@ -12776,7 +12452,7 @@ snapshots: glob-parent: 6.0.2 globals: 13.24.0 graphemer: 1.4.0 - ignore: 5.3.1 + ignore: 5.3.2 imurmurhash: 0.1.4 is-glob: 4.0.3 is-path-inside: 3.0.3 @@ -12786,7 +12462,7 @@ snapshots: lodash.merge: 4.6.2 minimatch: 3.1.2 natural-compare: 1.4.0 - optionator: 0.9.3 + optionator: 0.9.4 strip-ansi: 6.0.1 text-table: 0.2.0 transitivePeerDependencies: @@ -12794,20 +12470,22 @@ snapshots: esniff@2.0.1: dependencies: - d: 1.0.1 - es5-ext: 0.10.63 + d: 1.0.2 + es5-ext: 0.10.64 event-emitter: 0.3.5 - type: 2.7.2 + type: 2.7.3 espree@9.6.1: dependencies: - acorn: 8.11.3 - acorn-jsx: 5.3.2(acorn@8.11.3) + acorn: 8.13.0 + acorn-jsx: 5.3.2(acorn@8.13.0) eslint-visitor-keys: 3.4.3 + esprima@2.7.3: {} + esprima@4.0.1: {} - esquery@1.5.0: + esquery@1.6.0: dependencies: estraverse: 5.3.0 @@ -12815,6 +12493,8 @@ snapshots: dependencies: estraverse: 5.3.0 + estraverse@1.9.3: {} + estraverse@4.3.0: {} estraverse@5.3.0: {} @@ -12827,77 +12507,38 @@ snapshots: etag@1.8.1: {} - eth-block-tracker@5.0.1: - dependencies: - '@metamask/safe-event-emitter': 2.0.0 - json-rpc-random-id: 1.0.1 - pify: 3.0.0 - eth-ens-namehash@2.0.8: dependencies: idna-uts46-hx: 2.3.1 js-sha3: 0.5.7 - eth-json-rpc-filters@4.2.2: - dependencies: - '@metamask/safe-event-emitter': 2.0.0 - async-mutex: 0.2.6 - eth-json-rpc-middleware: 6.0.0 - eth-query: 2.1.2 - json-rpc-engine: 6.1.0 - pify: 5.0.0 - transitivePeerDependencies: - - encoding - - eth-json-rpc-infura@5.1.0: - dependencies: - eth-json-rpc-middleware: 6.0.0 - eth-rpc-errors: 3.0.0 - json-rpc-engine: 5.4.0 - node-fetch: 2.7.0 - transitivePeerDependencies: - - encoding - - eth-json-rpc-middleware@6.0.0: + eth-gas-reporter@0.2.27(bufferutil@4.0.8)(utf-8-validate@5.0.10): dependencies: - btoa: 1.2.1 - clone: 2.1.2 - eth-query: 2.1.2 - eth-rpc-errors: 3.0.0 - eth-sig-util: 1.4.2 - ethereumjs-util: 5.2.1 - json-rpc-engine: 5.4.0 - json-stable-stringify: 1.1.1 - node-fetch: 2.7.0 - pify: 3.0.0 - safe-event-emitter: 1.0.1 - transitivePeerDependencies: - - encoding - - eth-json-rpc-middleware@9.0.1: - dependencies: - '@metamask/eth-sig-util': 5.1.0 - '@metamask/safe-event-emitter': 2.0.0 - '@metamask/utils': 3.6.0 - btoa: 1.2.1 - clone: 2.1.2 - eth-block-tracker: 5.0.1 - eth-rpc-errors: 4.0.3 - json-rpc-engine: 6.1.0 - json-stable-stringify: 1.1.1 - node-fetch: 2.7.0 - pify: 3.0.0 + '@solidity-parser/parser': 0.14.5 + axios: 1.7.7 + cli-table3: 0.5.1 + colors: 1.4.0 + ethereum-cryptography: 1.2.0 + ethers: 5.7.2(bufferutil@4.0.8)(utf-8-validate@5.0.10) + fs-readdir-recursive: 1.1.0 + lodash: 4.17.21 + markdown-table: 1.1.3 + mocha: 10.7.3 + req-cwd: 2.0.0 + sha1: 1.1.1 + sync-request: 6.1.0 transitivePeerDependencies: - - encoding - - supports-color + - bufferutil + - debug + - utf-8-validate - eth-lib@0.1.29: + eth-lib@0.1.29(bufferutil@4.0.8)(utf-8-validate@5.0.10): dependencies: bn.js: 4.12.0 - elliptic: 6.5.4 + elliptic: 6.5.7 nano-json-stream-parser: 0.1.2 servify: 0.1.12 - ws: 3.3.3 + ws: 3.3.3(bufferutil@4.0.8)(utf-8-validate@5.0.10) xhr-request-promise: 0.1.3 transitivePeerDependencies: - bufferutil @@ -12907,34 +12548,12 @@ snapshots: eth-lib@0.2.8: dependencies: bn.js: 4.12.0 - elliptic: 6.5.4 + elliptic: 6.5.7 xhr-request-promise: 0.1.3 - eth-query@2.1.2: - dependencies: - json-rpc-random-id: 1.0.1 - xtend: 4.0.2 - - eth-rpc-errors@3.0.0: - dependencies: - fast-safe-stringify: 2.1.1 - - eth-rpc-errors@4.0.3: - dependencies: - fast-safe-stringify: 2.1.1 - - eth-sig-util@1.4.2: - dependencies: - ethereumjs-abi: https://codeload.github.com/ethereumjs/ethereumjs-abi/tar.gz/ee3994657fa7a427238e6ba92a84d0b529bbcde0 - ethereumjs-util: 5.2.1 - - ethereum-bloom-filters@1.0.10: + ethereum-bloom-filters@1.2.0: dependencies: - js-sha3: 0.8.0 - - ethereum-common@0.0.18: {} - - ethereum-common@0.2.0: {} + '@noble/hashes': 1.5.0 ethereum-cryptography@0.1.3: dependencies: @@ -12951,7 +12570,7 @@ snapshots: randombytes: 2.1.0 safe-buffer: 5.2.1 scrypt-js: 3.0.1 - secp256k1: 4.0.3 + secp256k1: 4.0.4 setimmediate: 1.0.5 ethereum-cryptography@1.2.0: @@ -12961,100 +12580,37 @@ snapshots: '@scure/bip32': 1.1.5 '@scure/bip39': 1.1.1 - ethereum-cryptography@2.1.3: + ethereum-cryptography@2.2.1: dependencies: - '@noble/curves': 1.3.0 - '@noble/hashes': 1.3.3 - '@scure/bip32': 1.3.3 - '@scure/bip39': 1.2.2 + '@noble/curves': 1.4.2 + '@noble/hashes': 1.4.0 + '@scure/bip32': 1.4.0 + '@scure/bip39': 1.3.0 ethereumjs-abi@0.6.8: dependencies: bn.js: 4.12.0 ethereumjs-util: 6.2.1 - ethereumjs-abi@https://codeload.github.com/ethereumjs/ethereumjs-abi/tar.gz/ee3994657fa7a427238e6ba92a84d0b529bbcde0: - dependencies: - bn.js: 4.12.0 - ethereumjs-util: 6.2.1 - - ethereumjs-account@2.0.5: - dependencies: - ethereumjs-util: 5.2.1 - rlp: 2.2.7 - safe-buffer: 5.2.1 - - ethereumjs-block@1.7.1: - dependencies: - async: 2.6.4 - ethereum-common: 0.2.0 - ethereumjs-tx: 1.3.7 - ethereumjs-util: 5.2.1 - merkle-patricia-tree: 2.3.2 - - ethereumjs-block@2.2.2: - dependencies: - async: 2.6.4 - ethereumjs-common: 1.5.2 - ethereumjs-tx: 2.1.2 - ethereumjs-util: 5.2.1 - merkle-patricia-tree: 2.3.2 - - ethereumjs-common@1.5.2: {} - - ethereumjs-tx@1.3.7: - dependencies: - ethereum-common: 0.0.18 - ethereumjs-util: 5.2.1 - - ethereumjs-tx@2.1.2: - dependencies: - ethereumjs-common: 1.5.2 - ethereumjs-util: 6.2.1 - - ethereumjs-util@5.2.1: - dependencies: - bn.js: 4.12.0 - create-hash: 1.2.0 - elliptic: 6.5.4 - ethereum-cryptography: 0.1.3 - ethjs-util: 0.1.6 - rlp: 2.2.7 - safe-buffer: 5.2.1 - ethereumjs-util@6.2.1: dependencies: '@types/bn.js': 4.11.6 bn.js: 4.12.0 create-hash: 1.2.0 - elliptic: 6.5.4 + elliptic: 6.5.7 ethereum-cryptography: 0.1.3 ethjs-util: 0.1.6 rlp: 2.2.7 ethereumjs-util@7.1.5: dependencies: - '@types/bn.js': 5.1.5 + '@types/bn.js': 5.1.6 bn.js: 5.2.1 create-hash: 1.2.0 ethereum-cryptography: 0.1.3 rlp: 2.2.7 - ethereumjs-vm@2.6.0: - dependencies: - async: 2.6.4 - async-eventemitter: 0.2.4 - ethereumjs-account: 2.0.5 - ethereumjs-block: 2.2.2 - ethereumjs-common: 1.5.2 - ethereumjs-util: 6.2.1 - fake-merkle-patricia-tree: 1.0.1 - functional-red-black-tree: 1.0.1 - merkle-patricia-tree: 2.3.2 - rustbn.js: 0.2.0 - safe-buffer: 5.2.1 - - ethers@5.7.2: + ethers@5.7.2(bufferutil@4.0.8)(utf-8-validate@5.0.10): dependencies: '@ethersproject/abi': 5.7.0 '@ethersproject/abstract-provider': 5.7.0 @@ -13074,7 +12630,7 @@ snapshots: '@ethersproject/networks': 5.7.1 '@ethersproject/pbkdf2': 5.7.0 '@ethersproject/properties': 5.7.0 - '@ethersproject/providers': 5.7.2 + '@ethersproject/providers': 5.7.2(bufferutil@4.0.8)(utf-8-validate@5.0.10) '@ethersproject/random': 5.7.0 '@ethersproject/rlp': 5.7.0 '@ethersproject/sha2': 5.7.0 @@ -13090,6 +12646,32 @@ snapshots: - bufferutil - utf-8-validate + ethers@6.13.4(bufferutil@4.0.8)(utf-8-validate@5.0.10): + dependencies: + '@adraffy/ens-normalize': 1.10.1 + '@noble/curves': 1.2.0 + '@noble/hashes': 1.3.2 + '@types/node': 22.7.5 + aes-js: 4.0.0-beta.5 + tslib: 2.7.0 + ws: 8.17.1(bufferutil@4.0.8)(utf-8-validate@5.0.10) + transitivePeerDependencies: + - bufferutil + - utf-8-validate + + ethers@6.13.4(bufferutil@4.0.8)(utf-8-validate@6.0.3): + dependencies: + '@adraffy/ens-normalize': 1.10.1 + '@noble/curves': 1.2.0 + '@noble/hashes': 1.3.2 + '@types/node': 22.7.5 + aes-js: 4.0.0-beta.5 + tslib: 2.7.0 + ws: 8.17.1(bufferutil@4.0.8)(utf-8-validate@6.0.3) + transitivePeerDependencies: + - bufferutil + - utf-8-validate + ethjs-unit@0.1.6: dependencies: bn.js: 4.11.6 @@ -13102,8 +12684,8 @@ snapshots: event-emitter@0.3.5: dependencies: - d: 1.0.1 - es5-ext: 0.10.63 + d: 1.0.2 + es5-ext: 0.10.64 eventemitter2@6.4.9: {} @@ -13144,34 +12726,34 @@ snapshots: transitivePeerDependencies: - supports-color - express@4.18.2(supports-color@6.1.0): + express@4.21.1(supports-color@6.1.0): dependencies: accepts: 1.3.8 array-flatten: 1.1.1 - body-parser: 1.20.1(supports-color@6.1.0) + body-parser: 1.20.3(supports-color@6.1.0) content-disposition: 0.5.4 content-type: 1.0.5 - cookie: 0.5.0 + cookie: 0.7.1 cookie-signature: 1.0.6 debug: 2.6.9(supports-color@6.1.0) depd: 2.0.0 - encodeurl: 1.0.2 + encodeurl: 2.0.0 escape-html: 1.0.3 etag: 1.8.1 - finalhandler: 1.2.0(supports-color@6.1.0) + finalhandler: 1.3.1(supports-color@6.1.0) fresh: 0.5.2 http-errors: 2.0.0 - merge-descriptors: 1.0.1 + merge-descriptors: 1.0.3 methods: 1.1.2 on-finished: 2.4.1 parseurl: 1.3.3 - path-to-regexp: 0.1.7 + path-to-regexp: 0.1.10 proxy-addr: 2.0.7 - qs: 6.11.0 + qs: 6.13.0 range-parser: 1.2.1 safe-buffer: 5.2.1 - send: 0.18.0(supports-color@6.1.0) - serve-static: 1.15.0(supports-color@6.1.0) + send: 0.19.0(supports-color@6.1.0) + serve-static: 1.16.2(supports-color@6.1.0) setprototypeof: 1.2.0 statuses: 2.0.1 type-is: 1.6.18 @@ -13182,7 +12764,7 @@ snapshots: ext@1.7.0: dependencies: - type: 2.7.2 + type: 2.7.3 extend-shallow@2.0.1: dependencies: @@ -13218,7 +12800,7 @@ snapshots: extract-zip@2.0.1: dependencies: - debug: 4.3.4(supports-color@6.1.0) + debug: 4.4.0 get-stream: 5.2.0 yauzl: 2.10.0 optionalDependencies: @@ -13232,10 +12814,6 @@ snapshots: dependencies: realistic-structured-clone: 3.0.0 - fake-merkle-patricia-tree@1.0.1: - dependencies: - checkpoint-store: 1.1.0 - fast-deep-equal@2.0.1: {} fast-deep-equal@3.1.3: {} @@ -13250,15 +12828,17 @@ snapshots: '@nodelib/fs.walk': 1.2.8 glob-parent: 5.1.2 merge2: 1.4.1 - micromatch: 4.0.5 + micromatch: 4.0.8 + + fast-json-patch@3.1.1: {} fast-json-stable-stringify@2.1.0: {} fast-levenshtein@2.0.6: {} - fast-safe-stringify@2.1.1: {} + fast-uri@3.0.3: {} - fast-xml-parser@4.2.5: + fast-xml-parser@4.4.1: dependencies: strnum: 1.0.5 @@ -13276,9 +12856,9 @@ snapshots: dependencies: pend: 1.2.0 - figures@6.0.1: + figures@6.1.0: dependencies: - is-unicode-supported: 2.0.0 + is-unicode-supported: 2.1.0 file-entry-cache@6.0.1: dependencies: @@ -13293,7 +12873,7 @@ snapshots: repeat-string: 1.6.1 to-regex-range: 2.1.1 - fill-range@7.0.1: + fill-range@7.1.1: dependencies: to-regex-range: 5.0.1 @@ -13309,10 +12889,10 @@ snapshots: transitivePeerDependencies: - supports-color - finalhandler@1.2.0(supports-color@6.1.0): + finalhandler@1.3.1(supports-color@6.1.0): dependencies: debug: 2.6.9(supports-color@6.1.0) - encodeurl: 1.0.2 + encodeurl: 2.0.0 escape-html: 1.0.3 on-finished: 2.4.1 parseurl: 1.3.3 @@ -13332,11 +12912,6 @@ snapshots: common-path-prefix: 3.0.0 pkg-dir: 7.0.0 - find-replace@1.0.3: - dependencies: - array-back: 1.0.4 - test-value: 2.1.0 - find-replace@3.0.0: dependencies: array-back: 3.1.0 @@ -13366,11 +12941,6 @@ snapshots: locate-path: 7.2.0 path-exists: 5.0.0 - find-yarn-workspace-root2@1.2.16: - dependencies: - micromatch: 4.0.5 - pkg-dir: 4.2.0 - flat-cache@3.2.0: dependencies: flatted: 3.3.1 @@ -13381,9 +12951,13 @@ snapshots: flatted@3.3.1: {} - follow-redirects@1.15.5(debug@4.3.4): - dependencies: - debug: 4.3.4(supports-color@6.1.0) + follow-redirects@1.15.9(debug@4.3.7(supports-color@6.1.0)): + optionalDependencies: + debug: 4.3.7(supports-color@6.1.0) + + follow-redirects@1.15.9(debug@4.3.7): + optionalDependencies: + debug: 4.3.7(supports-color@6.1.0) for-each@0.3.3: dependencies: @@ -13396,7 +12970,7 @@ snapshots: cross-spawn: 7.0.3 signal-exit: 3.0.7 - foreground-child@3.1.1: + foreground-child@3.3.0: dependencies: cross-spawn: 7.0.3 signal-exit: 4.1.0 @@ -13411,7 +12985,14 @@ snapshots: combined-stream: 1.0.8 mime-types: 2.1.35 - form-data@4.0.0: + form-data@2.5.2: + dependencies: + asynckit: 0.4.0 + combined-stream: 1.0.8 + mime-types: 2.1.35 + safe-buffer: 5.2.1 + + form-data@4.0.1: dependencies: asynckit: 0.4.0 combined-stream: 1.0.8 @@ -13429,13 +13010,11 @@ snapshots: fromentries@1.3.2: {} - fs-extra@0.30.0: + fs-extra@10.1.0: dependencies: graceful-fs: 4.2.11 - jsonfile: 2.4.0 - klaw: 1.3.1 - path-is-absolute: 1.0.1 - rimraf: 2.7.1 + jsonfile: 6.1.0 + universalify: 2.0.1 fs-extra@11.2.0: dependencies: @@ -13476,12 +13055,14 @@ snapshots: dependencies: minipass: 3.3.6 + fs-readdir-recursive@1.1.0: {} + fs.realpath@1.0.0: {} fsevents@1.2.13: dependencies: bindings: 1.5.0 - nan: 2.18.0 + nan: 2.22.0 optional: true fsevents@2.3.3: @@ -13493,29 +13074,23 @@ snapshots: dependencies: call-bind: 1.0.7 define-properties: 1.2.1 - es-abstract: 1.22.4 + es-abstract: 1.23.3 functions-have-names: 1.2.3 - functional-red-black-tree@1.0.1: {} - functions-have-names@1.2.3: {} ganache@7.9.2: dependencies: - '@trufflesuite/bigint-buffer': 1.1.10 '@trufflesuite/uws-js-unofficial': 20.30.0-unofficial.0 - '@types/bn.js': 5.1.5 + '@types/bn.js': 5.1.6 '@types/lru-cache': 5.1.1 '@types/seedrandom': 3.0.1 abstract-level: 1.0.3 abstract-leveldown: 7.2.0 async-eventemitter: 0.2.4 emittery: 0.10.0 - keccak: 3.0.2 - leveldown: 6.1.0 - secp256k1: 4.0.3 optionalDependencies: - bufferutil: 4.0.5 + bufferutil: 4.0.8 utf-8-validate: 5.0.7 gauge@3.0.2: @@ -13534,7 +13109,7 @@ snapshots: get-caller-file@2.0.5: {} - get-east-asian-width@1.2.0: {} + get-east-asian-width@1.3.0: {} get-func-name@2.0.2: {} @@ -13544,17 +13119,19 @@ snapshots: function-bind: 1.1.2 has-proto: 1.0.3 has-symbols: 1.0.3 - hasown: 2.0.1 + hasown: 2.0.2 get-package-type@0.1.0: {} + get-port@3.2.0: {} + get-stream@4.1.0: dependencies: - pump: 3.0.0 + pump: 3.0.2 get-stream@5.2.0: dependencies: - pump: 3.0.0 + pump: 3.0.2 get-stream@6.0.1: {} @@ -13564,15 +13141,15 @@ snapshots: es-errors: 1.3.0 get-intrinsic: 1.2.4 - get-tsconfig@4.7.2: + get-tsconfig@4.8.1: dependencies: resolve-pkg-maps: 1.0.0 get-uri@6.0.3: dependencies: - basic-ftp: 5.0.4 + basic-ftp: 5.0.5 data-uri-to-buffer: 6.0.2 - debug: 4.3.4(supports-color@6.1.0) + debug: 4.3.7(supports-color@6.1.0) fs-extra: 11.2.0 transitivePeerDependencies: - supports-color @@ -13583,6 +13160,11 @@ snapshots: dependencies: assert-plus: 1.0.0 + ghost-testrpc@0.0.2: + dependencies: + chalk: 2.4.2 + node-emoji: 1.11.0 + glob-base@0.3.0: dependencies: glob-parent: 6.0.2 @@ -13598,13 +13180,22 @@ snapshots: glob-to-regexp@0.4.1: {} - glob@10.3.10: + glob@11.0.0: + dependencies: + foreground-child: 3.3.0 + jackspeak: 4.0.2 + minimatch: 10.0.1 + minipass: 7.1.2 + package-json-from-dist: 1.0.1 + path-scurry: 2.0.0 + + glob@5.0.15: dependencies: - foreground-child: 3.1.1 - jackspeak: 2.3.6 - minimatch: 9.0.3 - minipass: 7.0.4 - path-scurry: 1.10.1 + inflight: 1.0.6 + inherits: 2.0.4 + minimatch: 3.1.2 + once: 1.4.0 + path-is-absolute: 1.0.1 glob@7.1.7: dependencies: @@ -13638,9 +13229,19 @@ snapshots: fs.realpath: 1.0.0 inflight: 1.0.6 inherits: 2.0.4 - minimatch: 5.0.1 + minimatch: 5.1.6 once: 1.4.0 + global-modules@2.0.0: + dependencies: + global-prefix: 3.0.0 + + global-prefix@3.0.0: + dependencies: + ini: 1.3.8 + kind-of: 6.0.3 + which: 1.3.1 + global@4.4.0: dependencies: min-document: 2.19.0 @@ -13652,24 +13253,36 @@ snapshots: dependencies: type-fest: 0.20.2 - globalthis@1.0.3: + globalthis@1.0.4: dependencies: define-properties: 1.2.1 + gopd: 1.0.1 + + globby@10.0.2: + dependencies: + '@types/glob': 7.2.0 + array-union: 2.1.0 + dir-glob: 3.0.1 + fast-glob: 3.3.2 + glob: 7.2.3 + ignore: 5.3.2 + merge2: 1.4.1 + slash: 3.0.0 globby@11.1.0: dependencies: array-union: 2.1.0 dir-glob: 3.0.1 fast-glob: 3.3.2 - ignore: 5.3.1 + ignore: 5.3.2 merge2: 1.4.1 slash: 3.0.0 - globby@14.0.1: + globby@14.0.2: dependencies: '@sindresorhus/merge-streams': 2.3.0 fast-glob: 3.3.2 - ignore: 5.3.1 + ignore: 5.3.2 path-type: 5.0.0 slash: 5.1.0 unicorn-magic: 0.1.0 @@ -13718,28 +13331,35 @@ snapshots: graceful-fs@4.2.11: {} - grapheme-splitter@1.0.4: {} - graphemer@1.4.0: {} - graphql-http@1.22.0(graphql@15.8.0): + graphql-http@1.22.1(graphql@15.9.0): dependencies: - graphql: 15.8.0 + graphql: 15.9.0 - graphql-subscriptions@1.2.1(graphql@15.8.0): + graphql-subscriptions@1.2.1(graphql@15.9.0): dependencies: - graphql: 15.8.0 + graphql: 15.9.0 iterall: 1.3.0 - graphql-tag@2.12.6(graphql@15.8.0): + graphql-tag@2.12.6(graphql@15.9.0): dependencies: - graphql: 15.8.0 - tslib: 2.6.2 + graphql: 15.9.0 + tslib: 2.8.0 - graphql@15.8.0: {} + graphql@15.9.0: {} handle-thing@2.0.1: {} + handlebars@4.7.8: + dependencies: + minimist: 1.2.8 + neo-async: 2.6.2 + source-map: 0.6.1 + wordwrap: 1.0.0 + optionalDependencies: + uglify-js: 3.19.3 + har-schema@2.0.0: {} har-validator@5.1.5: @@ -13747,35 +13367,93 @@ snapshots: ajv: 6.12.6 har-schema: 2.0.0 - hard-rejection@2.1.0: {} + hardhat-gas-reporter@1.0.10(bufferutil@4.0.8)(hardhat@2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10))(utf-8-validate@5.0.10): + dependencies: + array-uniq: 1.0.3 + eth-gas-reporter: 0.2.27(bufferutil@4.0.8)(utf-8-validate@5.0.10) + hardhat: 2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10) + sha1: 1.1.1 + transitivePeerDependencies: + - '@codechecks/client' + - bufferutil + - debug + - utf-8-validate - hardhat@2.20.1(ts-node@10.9.2)(typescript@5.3.3): + hardhat@2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10): dependencies: '@ethersproject/abi': 5.7.0 '@metamask/eth-sig-util': 4.0.1 - '@nomicfoundation/ethereumjs-block': 5.0.4 - '@nomicfoundation/ethereumjs-blockchain': 7.0.4 + '@nomicfoundation/edr': 0.6.4 '@nomicfoundation/ethereumjs-common': 4.0.4 - '@nomicfoundation/ethereumjs-evm': 2.0.4(@nomicfoundation/ethereumjs-verkle@0.0.2) - '@nomicfoundation/ethereumjs-rlp': 5.0.4 - '@nomicfoundation/ethereumjs-statemanager': 2.0.4(@nomicfoundation/ethereumjs-verkle@0.0.2) - '@nomicfoundation/ethereumjs-trie': 6.0.4 '@nomicfoundation/ethereumjs-tx': 5.0.4 '@nomicfoundation/ethereumjs-util': 9.0.4 - '@nomicfoundation/ethereumjs-verkle': 0.0.2 - '@nomicfoundation/ethereumjs-vm': 7.0.4(@nomicfoundation/ethereumjs-verkle@0.0.2) - '@nomicfoundation/solidity-analyzer': 0.1.1 + '@nomicfoundation/solidity-analyzer': 0.1.2 '@sentry/node': 5.30.0 - '@types/bn.js': 5.1.5 + '@types/bn.js': 5.1.6 '@types/lru-cache': 5.1.1 adm-zip: 0.4.16 aggregate-error: 3.1.0 ansi-escapes: 4.3.2 boxen: 5.1.2 chalk: 2.4.2 - chokidar: 3.6.0 + chokidar: 4.0.1 + ci-info: 2.0.0 + debug: 4.3.7(supports-color@6.1.0) + enquirer: 2.4.1 + env-paths: 2.2.1 + ethereum-cryptography: 1.2.0 + ethereumjs-abi: 0.6.8 + find-up: 2.1.0 + fp-ts: 1.19.3 + fs-extra: 7.0.1 + glob: 7.2.0 + immutable: 4.3.7 + io-ts: 1.10.4 + json-stream-stringify: 3.1.6 + keccak: 3.0.4 + lodash: 4.17.21 + mnemonist: 0.38.5 + mocha: 10.7.3 + p-map: 4.0.0 + raw-body: 2.5.2 + resolve: 1.17.0 + semver: 6.3.1 + solc: 0.8.26(debug@4.3.7) + source-map-support: 0.5.21 + stacktrace-parser: 0.1.10 + tsort: 0.0.1 + undici: 5.28.4 + uuid: 8.3.2 + ws: 7.5.10(bufferutil@4.0.8)(utf-8-validate@5.0.10) + optionalDependencies: + ts-node: 10.9.2(@types/node@22.7.9)(typescript@5.6.3) + typescript: 5.6.3 + transitivePeerDependencies: + - bufferutil + - c-kzg + - supports-color + - utf-8-validate + + hardhat@2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@6.0.3): + dependencies: + '@ethersproject/abi': 5.7.0 + '@metamask/eth-sig-util': 4.0.1 + '@nomicfoundation/edr': 0.6.4 + '@nomicfoundation/ethereumjs-common': 4.0.4 + '@nomicfoundation/ethereumjs-tx': 5.0.4 + '@nomicfoundation/ethereumjs-util': 9.0.4 + '@nomicfoundation/solidity-analyzer': 0.1.2 + '@sentry/node': 5.30.0 + '@types/bn.js': 5.1.6 + '@types/lru-cache': 5.1.1 + adm-zip: 0.4.16 + aggregate-error: 3.1.0 + ansi-escapes: 4.3.2 + boxen: 5.1.2 + chalk: 2.4.2 + chokidar: 4.0.1 ci-info: 2.0.0 - debug: 4.3.4(supports-color@6.1.0) + debug: 4.3.7(supports-color@6.1.0) enquirer: 2.4.1 env-paths: 2.2.1 ethereum-cryptography: 1.2.0 @@ -13784,25 +13462,27 @@ snapshots: fp-ts: 1.19.3 fs-extra: 7.0.1 glob: 7.2.0 - immutable: 4.3.5 + immutable: 4.3.7 io-ts: 1.10.4 + json-stream-stringify: 3.1.6 keccak: 3.0.4 lodash: 4.17.21 mnemonist: 0.38.5 - mocha: 10.3.0 + mocha: 10.7.3 p-map: 4.0.0 raw-body: 2.5.2 resolve: 1.17.0 semver: 6.3.1 - solc: 0.7.3(debug@4.3.4) + solc: 0.8.26(debug@4.3.7) source-map-support: 0.5.21 stacktrace-parser: 0.1.10 - ts-node: 10.9.2(@types/node@20.11.20)(typescript@5.3.3) tsort: 0.0.1 - typescript: 5.3.3 - undici: 5.28.3 + undici: 5.28.4 uuid: 8.3.2 - ws: 7.5.9 + ws: 7.5.10(bufferutil@4.0.8)(utf-8-validate@6.0.3) + optionalDependencies: + ts-node: 10.9.2(@types/node@22.7.9)(typescript@5.6.3) + typescript: 5.6.3 transitivePeerDependencies: - bufferutil - c-kzg @@ -13811,6 +13491,8 @@ snapshots: has-bigints@1.0.2: {} + has-flag@1.0.0: {} + has-flag@3.0.0: {} has-flag@4.0.0: {} @@ -13864,20 +13546,20 @@ snapshots: is-stream: 2.0.1 type-fest: 0.8.1 - hasown@2.0.1: + hasown@2.0.2: dependencies: function-bind: 1.1.2 he@1.2.0: {} + heap@0.2.7: {} + hmac-drbg@1.0.1: dependencies: hash.js: 1.1.7 minimalistic-assert: 1.0.1 minimalistic-crypto-utils: 1.0.1 - hosted-git-info@2.8.9: {} - hpack.js@2.1.6: dependencies: inherits: 2.0.4 @@ -13897,16 +13579,17 @@ snapshots: he: 1.2.0 param-case: 3.0.4 relateurl: 0.2.7 - terser: 5.28.1 + terser: 5.36.0 - html-webpack-plugin@5.6.0(webpack@5.90.3): + html-webpack-plugin@5.6.3(webpack@5.95.0): dependencies: '@types/html-minifier-terser': 6.1.0 html-minifier-terser: 6.1.0 lodash: 4.17.21 pretty-error: 4.0.0 tapable: 2.2.1 - webpack: 5.90.3(webpack-cli@4.10.0) + optionalDependencies: + webpack: 5.95.0(webpack-cli@4.10.0) htmlparser2@6.1.0: dependencies: @@ -13915,15 +13598,22 @@ snapshots: domutils: 2.8.0 entities: 2.2.0 + http-basic@8.1.3: + dependencies: + caseless: 0.12.0 + concat-stream: 1.6.2 + http-response-object: 3.0.2 + parse-cache-control: 1.0.1 + http-cache-semantics@4.1.1: {} http-deceiver@1.2.7: {} - http-encoding@1.5.1: + http-encoding@2.0.1: dependencies: - brotli-wasm: 1.3.1 + brotli-wasm: 3.0.1 pify: 5.0.0 - zstd-codec: 0.1.4 + zstd-codec: 0.1.5 http-errors@1.6.3: dependencies: @@ -13946,14 +13636,14 @@ snapshots: http-proxy-agent@7.0.2: dependencies: - agent-base: 7.1.0 - debug: 4.3.4(supports-color@6.1.0) + agent-base: 7.1.3 + debug: 4.4.0 transitivePeerDependencies: - supports-color - http-proxy-middleware@0.19.1(debug@4.3.4)(supports-color@6.1.0): + http-proxy-middleware@0.19.1(debug@4.3.7(supports-color@6.1.0))(supports-color@6.1.0): dependencies: - http-proxy: 1.18.1(debug@4.3.4) + http-proxy: 1.18.1(debug@4.3.7(supports-color@6.1.0)) is-glob: 4.0.3 lodash: 4.17.21 micromatch: 3.1.10(supports-color@6.1.0) @@ -13961,24 +13651,22 @@ snapshots: - debug - supports-color - http-proxy@1.18.1(debug@4.3.4): + http-proxy@1.18.1(debug@4.3.7(supports-color@6.1.0)): dependencies: eventemitter3: 4.0.7 - follow-redirects: 1.15.5(debug@4.3.4) + follow-redirects: 1.15.9(debug@4.3.7(supports-color@6.1.0)) requires-port: 1.0.0 transitivePeerDependencies: - debug - http-signature@1.2.0: + http-response-object@3.0.2: dependencies: - assert-plus: 1.0.0 - jsprim: 1.4.2 - sshpk: 1.18.0 + '@types/node': 10.17.60 - http-signature@1.3.6: + http-signature@1.2.0: dependencies: assert-plus: 1.0.0 - jsprim: 2.0.2 + jsprim: 1.4.2 sshpk: 1.18.0 http2-wrapper@1.0.3: @@ -13994,14 +13682,21 @@ snapshots: https-proxy-agent@5.0.1: dependencies: agent-base: 6.0.2 - debug: 4.3.4(supports-color@6.1.0) + debug: 4.3.7(supports-color@6.1.0) + transitivePeerDependencies: + - supports-color + + https-proxy-agent@7.0.5: + dependencies: + agent-base: 7.1.1 + debug: 4.3.7(supports-color@6.1.0) transitivePeerDependencies: - supports-color - https-proxy-agent@7.0.4: + https-proxy-agent@7.0.6: dependencies: - agent-base: 7.1.0 - debug: 4.3.4(supports-color@6.1.0) + agent-base: 7.1.3 + debug: 4.4.0 transitivePeerDependencies: - supports-color @@ -14027,11 +13722,11 @@ snapshots: dependencies: minimatch: 3.1.2 - ignore@5.3.1: {} + ignore@5.3.2: {} - immediate@3.3.0: {} + immer@10.0.2: {} - immutable@4.3.5: {} + immutable@4.3.7: {} import-fresh@3.3.0: dependencies: @@ -14043,7 +13738,7 @@ snapshots: pkg-dir: 3.0.0 resolve-cwd: 2.0.0 - import-local@3.1.0: + import-local@3.2.0: dependencies: pkg-dir: 4.2.0 resolve-cwd: 3.0.0 @@ -14063,6 +13758,8 @@ snapshots: inherits@2.0.4: {} + ini@1.3.8: {} + internal-ip@4.3.0: dependencies: default-gateway: 4.2.0 @@ -14071,8 +13768,10 @@ snapshots: internal-slot@1.0.7: dependencies: es-errors: 1.3.0 - hasown: 2.0.1 - side-channel: 1.0.5 + hasown: 2.0.2 + side-channel: 1.0.6 + + interpret@1.4.0: {} interpret@2.2.0: {} @@ -14097,7 +13796,7 @@ snapshots: is-accessor-descriptor@1.0.1: dependencies: - hasown: 2.0.1 + hasown: 2.0.2 is-arguments@1.1.1: dependencies: @@ -14121,7 +13820,7 @@ snapshots: is-binary-path@2.1.0: dependencies: - binary-extensions: 2.2.0 + binary-extensions: 2.3.0 is-boolean-object@1.1.2: dependencies: @@ -14134,13 +13833,17 @@ snapshots: is-callable@1.2.7: {} - is-core-module@2.13.1: + is-core-module@2.15.1: dependencies: - hasown: 2.0.1 + hasown: 2.0.2 is-data-descriptor@1.0.1: dependencies: - hasown: 2.0.1 + hasown: 2.0.2 + + is-data-view@1.0.1: + dependencies: + is-typed-array: 1.1.13 is-date-object@1.0.5: dependencies: @@ -14168,8 +13871,6 @@ snapshots: is-extglob@2.1.1: {} - is-fn@1.0.0: {} - is-fullwidth-code-point@2.0.0: {} is-fullwidth-code-point@3.0.0: {} @@ -14218,8 +13919,6 @@ snapshots: is-path-inside@3.0.3: {} - is-plain-obj@1.1.0: {} - is-plain-obj@2.1.0: {} is-plain-object@2.0.4: @@ -14232,7 +13931,7 @@ snapshots: is-reference@1.2.1: dependencies: - '@types/estree': 1.0.5 + '@types/estree': 1.0.6 is-regex@1.1.4: dependencies: @@ -14261,13 +13960,13 @@ snapshots: is-typed-array@1.1.13: dependencies: - which-typed-array: 1.1.14 + which-typed-array: 1.1.15 is-typedarray@1.0.0: {} is-unicode-supported@0.1.0: {} - is-unicode-supported@2.0.0: {} + is-unicode-supported@2.1.0: {} is-weakref@1.0.2: dependencies: @@ -14277,8 +13976,6 @@ snapshots: is-wsl@1.1.0: {} - isarray@0.0.1: {} - isarray@1.0.0: {} isarray@2.0.5: {} @@ -14291,9 +13988,9 @@ snapshots: isobject@3.0.1: {} - isomorphic-ws@4.0.1(ws@8.16.0): + isomorphic-ws@4.0.1(ws@8.18.0(bufferutil@4.0.8)(utf-8-validate@5.0.10)): dependencies: - ws: 8.16.0 + ws: 8.18.0(bufferutil@4.0.8)(utf-8-validate@5.0.10) isstream@0.1.2: {} @@ -14305,13 +14002,23 @@ snapshots: istanbul-lib-instrument@4.0.3: dependencies: - '@babel/core': 7.23.9 + '@babel/core': 7.25.9 '@istanbuljs/schema': 0.1.3 istanbul-lib-coverage: 3.2.2 semver: 6.3.1 transitivePeerDependencies: - supports-color + istanbul-lib-instrument@6.0.3: + dependencies: + '@babel/core': 7.25.9 + '@babel/parser': 7.25.9 + '@istanbuljs/schema': 0.1.3 + istanbul-lib-coverage: 3.2.2 + semver: 7.6.3 + transitivePeerDependencies: + - supports-color + istanbul-lib-processinfo@2.0.3: dependencies: archy: 1.0.0 @@ -14329,7 +14036,7 @@ snapshots: istanbul-lib-source-maps@4.0.1: dependencies: - debug: 4.3.4(supports-color@6.1.0) + debug: 4.3.7(supports-color@6.1.0) istanbul-lib-coverage: 3.2.2 source-map: 0.6.1 transitivePeerDependencies: @@ -14342,25 +14049,23 @@ snapshots: iterall@1.3.0: {} - jackspeak@2.3.6: + jackspeak@4.0.2: dependencies: '@isaacs/cliui': 8.0.2 - optionalDependencies: - '@pkgjs/parseargs': 0.11.0 jest-worker@26.6.2: dependencies: - '@types/node': 20.11.20 + '@types/node': 22.7.9 merge-stream: 2.0.0 supports-color: 7.2.0 jest-worker@27.5.1: dependencies: - '@types/node': 20.11.20 + '@types/node': 22.7.9 merge-stream: 2.0.0 supports-color: 8.1.1 - joi@17.12.2: + joi@17.13.3: dependencies: '@hapi/hoek': 9.3.0 '@hapi/topo': 5.1.0 @@ -14370,8 +14075,6 @@ snapshots: js-base64@3.7.7: {} - js-sdsl@4.4.2: {} - js-sha3@0.5.7: {} js-sha3@0.8.0: {} @@ -14393,9 +14096,7 @@ snapshots: jsbn@1.1.0: {} - jsesc@0.5.0: {} - - jsesc@2.5.2: {} + jsesc@3.0.2: {} json-buffer@3.0.1: {} @@ -14403,18 +14104,6 @@ snapshots: json-parse-even-better-errors@2.3.1: {} - json-rpc-engine@5.4.0: - dependencies: - eth-rpc-errors: 3.0.0 - safe-event-emitter: 1.0.1 - - json-rpc-engine@6.1.0: - dependencies: - '@metamask/safe-event-emitter': 2.0.0 - eth-rpc-errors: 4.0.3 - - json-rpc-random-id@1.0.1: {} - json-schema-traverse@0.4.1: {} json-schema-traverse@1.0.0: {} @@ -14423,12 +14112,7 @@ snapshots: json-stable-stringify-without-jsonify@1.0.1: {} - json-stable-stringify@1.1.1: - dependencies: - call-bind: 1.0.7 - isarray: 2.0.5 - jsonify: 0.0.1 - object-keys: 1.1.1 + json-stream-stringify@3.1.6: {} json-stringify-safe@5.0.1: {} @@ -14438,10 +14122,6 @@ snapshots: json5@2.2.3: {} - jsonfile@2.4.0: - optionalDependencies: - graceful-fs: 4.2.11 - jsonfile@4.0.0: optionalDependencies: graceful-fs: 4.2.11 @@ -14452,7 +14132,7 @@ snapshots: optionalDependencies: graceful-fs: 4.2.11 - jsonify@0.0.1: {} + jsonschema@1.4.1: {} jsprim@1.4.2: dependencies: @@ -14461,13 +14141,6 @@ snapshots: json-schema: 0.4.0 verror: 1.10.0 - jsprim@2.0.2: - dependencies: - assert-plus: 1.0.0 - extsprintf: 1.3.0 - json-schema: 0.4.0 - verror: 1.10.0 - jwt-decode@4.0.0: {} keccak256@1.0.6: @@ -14476,16 +14149,10 @@ snapshots: buffer: 6.0.3 keccak: 3.0.4 - keccak@3.0.2: - dependencies: - node-addon-api: 2.0.2 - node-gyp-build: 4.8.0 - readable-stream: 3.6.2 - keccak@3.0.4: dependencies: node-addon-api: 2.0.2 - node-gyp-build: 4.8.0 + node-gyp-build: 4.8.2 readable-stream: 3.6.2 keyv@4.5.4: @@ -14504,29 +14171,12 @@ snapshots: kind-of@6.0.3: {} - klaw@1.3.1: - optionalDependencies: - graceful-fs: 4.2.11 - - kleur@4.1.5: {} - - level-codec@7.0.1: {} + kleur@3.0.3: {} level-concat-iterator@3.1.0: dependencies: catering: 2.1.1 - level-errors@1.0.5: - dependencies: - errno: 0.1.8 - - level-iterator-stream@1.3.1: - dependencies: - inherits: 2.0.4 - level-errors: 1.0.5 - readable-stream: 1.1.14 - xtend: 4.0.2 - level-supports@2.1.0: {} level-supports@4.0.1: {} @@ -14536,26 +14186,10 @@ snapshots: buffer: 6.0.3 module-error: 1.0.2 - level-ws@0.0.0: - dependencies: - readable-stream: 1.0.34 - xtend: 2.1.2 - - leveldown@6.1.0: - dependencies: - abstract-leveldown: 7.2.0 - napi-macros: 2.0.0 - node-gyp-build: 4.8.0 - - levelup@1.3.9: + levn@0.3.0: dependencies: - deferred-leveldown: 1.2.2 - level-codec: 7.0.1 - level-errors: 1.0.5 - level-iterator-stream: 1.3.1 - prr: 1.0.1 - semver: 5.4.1 - xtend: 4.0.2 + prelude-ls: 1.1.2 + type-check: 0.3.2 levn@0.4.1: dependencies: @@ -14566,13 +14200,6 @@ snapshots: load-json-file@7.0.1: {} - load-yaml-file@0.2.0: - dependencies: - graceful-fs: 4.2.11 - js-yaml: 3.14.1 - pify: 4.0.1 - strip-bom: 3.0.0 - loader-runner@4.3.0: {} locate-path@2.0.0: @@ -14599,14 +14226,20 @@ snapshots: lodash.camelcase@4.3.0: {} + lodash.clonedeep@4.5.0: {} + lodash.debounce@4.0.8: {} lodash.flattendeep@4.4.0: {} + lodash.isequal@4.5.0: {} + lodash.merge@4.6.2: {} lodash.startcase@4.4.0: {} + lodash.truncate@4.4.2: {} + lodash@4.17.21: {} log-symbols@4.1.0: @@ -14614,7 +14247,7 @@ snapshots: chalk: 4.1.2 is-unicode-supported: 0.1.0 - loglevel@1.9.1: {} + loglevel@1.9.2: {} loupe@2.3.7: dependencies: @@ -14622,13 +14255,13 @@ snapshots: lower-case@2.0.2: dependencies: - tslib: 2.6.2 + tslib: 2.8.0 lowercase-keys@2.0.0: {} lowercase-keys@3.0.0: {} - lru-cache@10.2.0: {} + lru-cache@11.0.1: {} lru-cache@4.1.5: dependencies: @@ -14639,23 +14272,17 @@ snapshots: dependencies: yallist: 3.1.1 - lru-cache@6.0.0: - dependencies: - yallist: 4.0.0 - lru-cache@7.18.3: {} lru_map@0.3.3: {} - ltgt@2.2.1: {} - magic-string@0.25.9: dependencies: sourcemap-codec: 1.4.8 - magic-string@0.30.7: + magic-string@0.30.12: dependencies: - '@jridgewell/sourcemap-codec': 1.4.15 + '@jridgewell/sourcemap-codec': 1.5.0 make-dir@3.1.0: dependencies: @@ -14663,20 +14290,18 @@ snapshots: make-dir@4.0.0: dependencies: - semver: 7.6.0 + semver: 7.6.3 make-error@1.3.6: {} map-cache@0.2.2: {} - map-obj@1.0.1: {} - - map-obj@4.3.0: {} - map-visit@1.0.0: dependencies: object-visit: 1.0.1 + markdown-table@1.1.3: {} + matcher@5.0.0: dependencies: escape-string-regexp: 5.0.0 @@ -14693,18 +14318,9 @@ snapshots: media-typer@0.3.0: {} - memdown@1.4.1: - dependencies: - abstract-leveldown: 2.7.2 - functional-red-black-tree: 1.0.1 - immediate: 3.3.0 - inherits: 2.0.4 - ltgt: 2.2.1 - safe-buffer: 5.1.2 - memoize@10.0.0: dependencies: - mimic-function: 5.0.0 + mimic-function: 5.0.1 memory-fs@0.4.1: dependencies: @@ -14713,51 +14329,12 @@ snapshots: memorystream@0.3.1: {} - meow@6.1.1: - dependencies: - '@types/minimist': 1.2.5 - camelcase-keys: 6.2.2 - decamelize-keys: 1.1.1 - hard-rejection: 2.1.0 - minimist-options: 4.1.0 - normalize-package-data: 2.5.0 - read-pkg-up: 7.0.1 - redent: 3.0.0 - trim-newlines: 3.0.1 - type-fest: 0.13.1 - yargs-parser: 18.1.3 - - meow@7.1.1: - dependencies: - '@types/minimist': 1.2.5 - camelcase-keys: 6.2.2 - decamelize-keys: 1.1.1 - hard-rejection: 2.1.0 - minimist-options: 4.1.0 - normalize-package-data: 2.5.0 - read-pkg-up: 7.0.1 - redent: 3.0.0 - trim-newlines: 3.0.1 - type-fest: 0.13.1 - yargs-parser: 18.1.3 - - merge-descriptors@1.0.1: {} + merge-descriptors@1.0.3: {} merge-stream@2.0.0: {} merge2@1.4.1: {} - merkle-patricia-tree@2.3.2: - dependencies: - async: 1.5.2 - ethereumjs-util: 5.2.1 - level-ws: 0.0.0 - levelup: 1.3.9 - memdown: 1.4.1 - readable-stream: 2.3.8 - rlp: 2.2.7 - semaphore: 1.1.0 - methods@1.1.2: {} micro-ftch@0.3.1: {} @@ -14780,13 +14357,15 @@ snapshots: transitivePeerDependencies: - supports-color - micromatch@4.0.5: + micromatch@4.0.8: dependencies: - braces: 3.0.2 + braces: 3.0.3 picomatch: 2.3.1 mime-db@1.52.0: {} + mime-db@1.53.0: {} + mime-types@2.1.35: dependencies: mime-db: 1.52.0 @@ -14795,7 +14374,7 @@ snapshots: mime@2.6.0: {} - mimic-function@5.0.0: {} + mimic-function@5.0.1: {} mimic-response@1.0.1: {} @@ -14805,30 +14384,26 @@ snapshots: dependencies: dom-walk: 0.1.2 - min-indent@1.0.1: {} - minimalistic-assert@1.0.1: {} minimalistic-crypto-utils@1.0.1: {} + minimatch@10.0.1: + dependencies: + brace-expansion: 2.0.1 + minimatch@3.1.2: dependencies: brace-expansion: 1.1.11 - minimatch@5.0.1: + minimatch@5.1.6: dependencies: brace-expansion: 2.0.1 - minimatch@9.0.3: + minimatch@9.0.5: dependencies: brace-expansion: 2.0.1 - minimist-options@4.1.0: - dependencies: - arrify: 1.0.1 - is-plain-obj: 1.1.0 - kind-of: 6.0.3 - minimist@1.2.8: {} minipass@2.9.0: @@ -14842,7 +14417,7 @@ snapshots: minipass@5.0.0: {} - minipass@7.0.4: {} + minipass@7.1.2: {} minizlib@1.3.3: dependencies: @@ -14860,10 +14435,6 @@ snapshots: for-in: 1.0.2 is-extendable: 1.0.1 - mixme@0.5.10: {} - - mkdirp-classic@0.5.3: {} - mkdirp-promise@5.0.1: dependencies: mkdirp: 3.0.1 @@ -14880,72 +14451,75 @@ snapshots: dependencies: obliterator: 2.0.4 - mocha@10.3.0: + mocha@10.7.3: dependencies: - ansi-colors: 4.1.1 + ansi-colors: 4.1.3 browser-stdout: 1.3.1 - chokidar: 3.5.3 - debug: 4.3.4(supports-color@8.1.1) - diff: 5.0.0 + chokidar: 3.6.0 + debug: 4.3.7(supports-color@8.1.1) + diff: 5.2.0 escape-string-regexp: 4.0.0 find-up: 5.0.0 glob: 8.1.0 he: 1.2.0 js-yaml: 4.1.0 log-symbols: 4.1.0 - minimatch: 5.0.1 + minimatch: 5.1.6 ms: 2.1.3 - serialize-javascript: 6.0.0 + serialize-javascript: 6.0.2 strip-json-comments: 3.1.1 supports-color: 8.1.1 - workerpool: 6.2.1 + workerpool: 6.5.1 yargs: 16.2.0 - yargs-parser: 20.2.4 + yargs-parser: 20.2.9 yargs-unparser: 2.0.0 mock-fs@4.14.0: {} - mockttp@3.10.1: + mockttp@3.15.3(bufferutil@4.0.8)(utf-8-validate@5.0.10): dependencies: - '@graphql-tools/schema': 8.5.1(graphql@15.8.0) - '@graphql-tools/utils': 8.13.1(graphql@15.8.0) - '@httptoolkit/httpolyglot': 2.2.1 - '@httptoolkit/subscriptions-transport-ws': 0.11.2(graphql@15.8.0) - '@httptoolkit/websocket-stream': 6.0.1 + '@graphql-tools/schema': 8.5.1(graphql@15.9.0) + '@graphql-tools/utils': 8.13.1(graphql@15.9.0) + '@httptoolkit/httpolyglot': 2.2.2 + '@httptoolkit/subscriptions-transport-ws': 0.11.2(bufferutil@4.0.8)(graphql@15.9.0)(utf-8-validate@5.0.10) + '@httptoolkit/websocket-stream': 6.0.1(bufferutil@4.0.8)(utf-8-validate@5.0.10) '@types/cors': 2.8.17 - '@types/node': 20.11.20 + '@types/node': 22.7.9 + async-mutex: 0.5.0 base64-arraybuffer: 0.1.5 - body-parser: 1.20.2 + body-parser: 1.20.3(supports-color@6.1.0) cacheable-lookup: 6.1.0 common-tags: 1.8.2 connect: 3.7.0 cors: 2.8.5 cors-gate: 1.1.3 cross-fetch: 3.1.8 - destroyable-server: 1.0.1 - express: 4.18.2(supports-color@6.1.0) - graphql: 15.8.0 - graphql-http: 1.22.0(graphql@15.8.0) - graphql-subscriptions: 1.2.1(graphql@15.8.0) - graphql-tag: 2.12.6(graphql@15.8.0) - http-encoding: 1.5.1 + destroyable-server: 1.0.2 + express: 4.21.1(supports-color@6.1.0) + fast-json-patch: 3.1.1 + graphql: 15.9.0 + graphql-http: 1.22.1(graphql@15.9.0) + graphql-subscriptions: 1.2.1(graphql@15.9.0) + graphql-tag: 2.12.6(graphql@15.9.0) + http-encoding: 2.0.1 http2-wrapper: 2.2.1 https-proxy-agent: 5.0.1 - isomorphic-ws: 4.0.1(ws@8.16.0) + isomorphic-ws: 4.0.1(ws@8.18.0(bufferutil@4.0.8)(utf-8-validate@5.0.10)) lodash: 4.17.21 lru-cache: 7.18.3 native-duplexpair: 1.0.0 node-forge: 1.3.1 - pac-proxy-agent: 7.0.1 + pac-proxy-agent: 7.0.2 parse-multipart-data: 1.5.0 performance-now: 2.1.0 - portfinder: 1.0.28 + portfinder: 1.0.32(supports-color@6.1.0) read-tls-client-hello: 1.0.1 - semver: 7.6.0 + semver: 7.6.3 socks-proxy-agent: 7.0.0 typed-error: 3.2.2 + urlpattern-polyfill: 8.0.2 uuid: 8.3.2 - ws: 8.16.0 + ws: 8.18.0(bufferutil@4.0.8)(utf-8-validate@5.0.10) transitivePeerDependencies: - bufferutil - encoding @@ -14954,20 +14528,20 @@ snapshots: module-error@1.0.2: {} - ms@2.0.0: {} + mri@1.2.0: {} - ms@2.1.2: {} + ms@2.0.0: {} ms@2.1.3: {} multibase@0.6.1: dependencies: - base-x: 3.0.9 + base-x: 3.0.10 buffer: 5.7.1 multibase@0.7.0: dependencies: - base-x: 3.0.9 + base-x: 3.0.10 buffer: 5.7.1 multicast-dns-service-types@1.1.0: {} @@ -14992,7 +14566,7 @@ snapshots: multibase: 0.7.0 varint: 5.0.2 - nan@2.18.0: + nan@2.22.0: optional: true nano-json-stream-parser@0.1.2: {} @@ -15013,12 +14587,18 @@ snapshots: transitivePeerDependencies: - supports-color - napi-macros@2.0.0: {} - native-duplexpair@1.0.0: {} natural-compare@1.4.0: {} + ndjson@2.0.0: + dependencies: + json-stringify-safe: 5.0.1 + minimist: 1.2.8 + readable-stream: 3.6.2 + split2: 3.2.2 + through2: 4.0.2 + negotiator@0.6.3: {} neo-async@2.6.2: {} @@ -15032,38 +14612,39 @@ snapshots: no-case@3.0.4: dependencies: lower-case: 2.0.2 - tslib: 2.6.2 + tslib: 2.8.0 node-addon-api@2.0.2: {} + node-addon-api@5.1.0: {} + + node-emoji@1.11.0: + dependencies: + lodash: 4.17.21 + node-fetch@2.7.0: dependencies: whatwg-url: 5.0.0 node-forge@1.3.1: {} - node-gyp-build@4.4.0: {} - - node-gyp-build@4.8.0: {} + node-gyp-build@4.8.2: {} node-preload@0.2.1: dependencies: process-on-spawn: 1.0.0 - node-releases@2.0.14: {} + node-releases@2.0.18: {} nofilter@3.1.0: {} - nopt@5.0.0: + nopt@3.0.6: dependencies: abbrev: 1.1.1 - normalize-package-data@2.5.0: + nopt@5.0.0: dependencies: - hosted-git-info: 2.8.9 - resolve: 1.22.8 - semver: 5.7.2 - validate-npm-package-license: 3.0.4 + abbrev: 1.1.1 normalize-path@2.1.1: dependencies: @@ -15138,6 +14719,38 @@ snapshots: transitivePeerDependencies: - supports-color + nyc@17.1.0: + dependencies: + '@istanbuljs/load-nyc-config': 1.1.0 + '@istanbuljs/schema': 0.1.3 + caching-transform: 4.0.0 + convert-source-map: 1.9.0 + decamelize: 1.2.0 + find-cache-dir: 3.3.2 + find-up: 4.1.0 + foreground-child: 3.3.0 + get-package-type: 0.1.0 + glob: 7.2.3 + istanbul-lib-coverage: 3.2.2 + istanbul-lib-hook: 3.0.0 + istanbul-lib-instrument: 6.0.3 + istanbul-lib-processinfo: 2.0.3 + istanbul-lib-report: 3.0.1 + istanbul-lib-source-maps: 4.0.1 + istanbul-reports: 3.1.7 + make-dir: 3.1.0 + node-preload: 0.2.1 + p-map: 3.0.0 + process-on-spawn: 1.0.0 + resolve-from: 5.0.0 + rimraf: 3.0.2 + signal-exit: 3.0.7 + spawn-wrap: 2.0.0 + test-exclude: 6.0.0 + yargs: 15.4.1 + transitivePeerDependencies: + - supports-color + oauth-sign@0.9.0: {} object-assign@4.1.1: {} @@ -15148,15 +14761,13 @@ snapshots: define-property: 0.2.5 kind-of: 3.2.2 - object-inspect@1.13.1: {} + object-inspect@1.13.2: {} - object-is@1.1.5: + object-is@1.1.6: dependencies: call-bind: 1.0.7 define-properties: 1.2.1 - object-keys@0.4.0: {} - object-keys@1.1.1: {} object-visit@1.0.1: @@ -15170,29 +14781,28 @@ snapshots: has-symbols: 1.0.3 object-keys: 1.1.1 - object.fromentries@2.0.7: + object.fromentries@2.0.8: dependencies: call-bind: 1.0.7 define-properties: 1.2.1 - es-abstract: 1.22.4 + es-abstract: 1.23.3 + es-object-atoms: 1.0.0 - object.groupby@1.0.2: + object.groupby@1.0.3: dependencies: - array.prototype.filter: 1.0.3 call-bind: 1.0.7 define-properties: 1.2.1 - es-abstract: 1.22.4 - es-errors: 1.3.0 + es-abstract: 1.23.3 object.pick@1.3.0: dependencies: isobject: 3.0.1 - object.values@1.1.7: + object.values@1.2.0: dependencies: call-bind: 1.0.7 define-properties: 1.2.1 - es-abstract: 1.22.4 + es-object-atoms: 1.0.0 obliterator@2.0.4: {} @@ -15220,14 +14830,25 @@ snapshots: dependencies: is-wsl: 1.1.0 - optionator@0.9.3: + optionator@0.8.3: + dependencies: + deep-is: 0.1.4 + fast-levenshtein: 2.0.6 + levn: 0.3.0 + prelude-ls: 1.1.2 + type-check: 0.3.2 + word-wrap: 1.2.5 + + optionator@0.9.4: dependencies: - '@aashutoshrathi/word-wrap': 1.2.6 deep-is: 0.1.4 fast-levenshtein: 2.0.6 levn: 0.4.1 prelude-ls: 1.2.1 type-check: 0.4.0 + word-wrap: 1.2.5 + + ordinal@1.0.3: {} os-tmpdir@1.0.2: {} @@ -15257,7 +14878,7 @@ snapshots: p-limit@4.0.0: dependencies: - yocto-queue: 1.0.0 + yocto-queue: 1.1.1 p-locate@2.0.0: dependencies: @@ -15289,7 +14910,7 @@ snapshots: dependencies: aggregate-error: 3.1.0 - p-map@7.0.1: {} + p-map@7.0.2: {} p-retry@3.0.1: dependencies: @@ -15299,16 +14920,29 @@ snapshots: p-try@2.2.0: {} - pac-proxy-agent@7.0.1: + pac-proxy-agent@7.0.2: + dependencies: + '@tootallnate/quickjs-emscripten': 0.23.0 + agent-base: 7.1.1 + debug: 4.3.7(supports-color@6.1.0) + get-uri: 6.0.3 + http-proxy-agent: 7.0.2 + https-proxy-agent: 7.0.5 + pac-resolver: 7.0.1 + socks-proxy-agent: 8.0.4 + transitivePeerDependencies: + - supports-color + + pac-proxy-agent@7.1.0: dependencies: '@tootallnate/quickjs-emscripten': 0.23.0 - agent-base: 7.1.0 - debug: 4.3.4(supports-color@6.1.0) + agent-base: 7.1.3 + debug: 4.4.0 get-uri: 6.0.3 http-proxy-agent: 7.0.2 - https-proxy-agent: 7.0.4 + https-proxy-agent: 7.0.6 pac-resolver: 7.0.1 - socks-proxy-agent: 8.0.2 + socks-proxy-agent: 8.0.5 transitivePeerDependencies: - supports-color @@ -15329,15 +14963,21 @@ snapshots: lodash.flattendeep: 4.4.0 release-zalgo: 1.0.0 + package-json-from-dist@1.0.1: {} + + package-manager-detector@0.2.2: {} + param-case@3.0.4: dependencies: dot-case: 3.0.4 - tslib: 2.6.2 + tslib: 2.8.0 parent-module@1.0.1: dependencies: callsites: 3.1.0 + parse-cache-control@1.0.1: {} + parse-glob@3.0.4: dependencies: glob-base: 0.3.0 @@ -15349,7 +14989,7 @@ snapshots: parse-json@5.2.0: dependencies: - '@babel/code-frame': 7.23.5 + '@babel/code-frame': 7.25.9 error-ex: 1.3.2 json-parse-even-better-errors: 2.3.1 lines-and-columns: 1.2.4 @@ -15363,7 +15003,7 @@ snapshots: pascal-case@3.1.2: dependencies: no-case: 3.0.4 - tslib: 2.6.2 + tslib: 2.8.0 pascalcase@0.1.1: {} @@ -15383,12 +15023,12 @@ snapshots: path-parse@1.0.7: {} - path-scurry@1.10.1: + path-scurry@2.0.0: dependencies: - lru-cache: 10.2.0 - minipass: 7.0.4 + lru-cache: 11.0.1 + minipass: 7.1.2 - path-to-regexp@0.1.7: {} + path-to-regexp@0.1.10: {} path-type@4.0.0: {} @@ -15408,7 +15048,7 @@ snapshots: performance-now@2.1.0: {} - picocolors@1.0.0: {} + picocolors@1.1.1: {} picomatch@2.3.1: {} @@ -15416,8 +15056,6 @@ snapshots: pify@2.3.0: {} - pify@3.0.0: {} - pify@4.0.1: {} pify@5.0.0: {} @@ -15446,14 +15084,6 @@ snapshots: dependencies: irregular-plurals: 3.5.0 - portfinder@1.0.28: - dependencies: - async: 2.6.4 - debug: 3.2.7(supports-color@6.1.0) - mkdirp: 0.5.6 - transitivePeerDependencies: - - supports-color - portfinder@1.0.32(supports-color@6.1.0): dependencies: async: 2.6.4 @@ -15466,14 +15096,7 @@ snapshots: possible-typed-array-names@1.0.0: {} - precond@0.2.3: {} - - preferred-pm@3.1.3: - dependencies: - find-up: 5.0.0 - find-yarn-workspace-root2: 1.2.16 - path-exists: 4.0.0 - which-pm: 2.0.0 + prelude-ls@1.1.2: {} prelude-ls@1.2.1: {} @@ -15483,14 +15106,14 @@ snapshots: prettier@2.8.8: {} - prettier@3.2.5: {} + prettier@3.3.3: {} pretty-error@4.0.0: dependencies: lodash: 4.17.21 renderkid: 3.0.0 - pretty-ms@9.0.0: + pretty-ms@9.1.0: dependencies: parse-ms: 4.0.0 @@ -15504,26 +15127,30 @@ snapshots: progress@2.0.3: {} - promise-to-callback@1.0.0: + promise@8.3.0: + dependencies: + asap: 2.0.6 + + prompts@2.4.2: dependencies: - is-fn: 1.0.0 - set-immediate-shim: 1.0.1 + kleur: 3.0.3 + sisteransi: 1.0.5 proxy-addr@2.0.7: dependencies: forwarded: 0.2.0 ipaddr.js: 1.9.1 - proxy-agent@6.3.1: + proxy-agent@6.5.0: dependencies: - agent-base: 7.1.0 - debug: 4.3.4(supports-color@6.1.0) + agent-base: 7.1.3 + debug: 4.4.0 http-proxy-agent: 7.0.2 - https-proxy-agent: 7.0.4 + https-proxy-agent: 7.0.6 lru-cache: 7.18.3 - pac-proxy-agent: 7.0.1 + pac-proxy-agent: 7.1.0 proxy-from-env: 1.1.0 - socks-proxy-agent: 8.0.2 + socks-proxy-agent: 8.0.5 transitivePeerDependencies: - supports-color @@ -15535,7 +15162,7 @@ snapshots: psl@1.9.0: {} - pump@3.0.0: + pump@3.0.2: dependencies: end-of-stream: 1.4.4 once: 1.4.0 @@ -15546,43 +15173,36 @@ snapshots: punycode@2.3.1: {} - puppeteer-core@21.11.0: + puppeteer-core@23.10.3(bufferutil@4.0.8)(utf-8-validate@5.0.10): dependencies: - '@puppeteer/browsers': 1.9.1 - chromium-bidi: 0.5.8(devtools-protocol@0.0.1232444) - cross-fetch: 4.0.0 - debug: 4.3.4(supports-color@6.1.0) - devtools-protocol: 0.0.1232444 - ws: 8.16.0 + '@puppeteer/browsers': 2.6.1 + chromium-bidi: 0.8.0(devtools-protocol@0.0.1367902) + debug: 4.4.0 + devtools-protocol: 0.0.1367902 + typed-query-selector: 2.12.0 + ws: 8.18.0(bufferutil@4.0.8)(utf-8-validate@5.0.10) transitivePeerDependencies: - bufferutil - - encoding - supports-color - utf-8-validate - puppeteer@21.11.0(typescript@5.3.3): + puppeteer@23.10.3(bufferutil@4.0.8)(typescript@5.6.3)(utf-8-validate@5.0.10): dependencies: - '@puppeteer/browsers': 1.9.1 - cosmiconfig: 9.0.0(typescript@5.3.3) - puppeteer-core: 21.11.0 + '@puppeteer/browsers': 2.6.1 + chromium-bidi: 0.8.0(devtools-protocol@0.0.1367902) + cosmiconfig: 9.0.0(typescript@5.6.3) + devtools-protocol: 0.0.1367902 + puppeteer-core: 23.10.3(bufferutil@4.0.8)(utf-8-validate@5.0.10) + typed-query-selector: 2.12.0 transitivePeerDependencies: - bufferutil - - encoding - supports-color - typescript - utf-8-validate - qs@6.10.4: - dependencies: - side-channel: 1.0.5 - - qs@6.11.0: + qs@6.13.0: dependencies: - side-channel: 1.0.5 - - qs@6.11.2: - dependencies: - side-channel: 1.0.5 + side-channel: 1.0.6 qs@6.5.3: {} @@ -15598,8 +15218,6 @@ snapshots: queue-tick@1.0.1: {} - quick-lru@4.0.1: {} - quick-lru@5.1.1: {} randombytes@2.1.0: @@ -15608,13 +15226,6 @@ snapshots: range-parser@1.2.1: {} - raw-body@2.5.1: - dependencies: - bytes: 3.1.2 - http-errors: 2.0.0 - iconv-lite: 0.4.24 - unpipe: 1.0.0 - raw-body@2.5.2: dependencies: bytes: 3.1.2 @@ -15624,22 +15235,9 @@ snapshots: react-native-keychain@8.2.0: {} - read-pkg-up@7.0.1: - dependencies: - find-up: 4.1.0 - read-pkg: 5.2.0 - type-fest: 0.8.1 - - read-pkg@5.2.0: - dependencies: - '@types/normalize-package-data': 2.4.4 - normalize-package-data: 2.5.0 - parse-json: 5.2.0 - type-fest: 0.6.0 - read-tls-client-hello@1.0.1: dependencies: - '@types/node': 20.11.20 + '@types/node': 22.7.9 read-yaml-file@1.1.0: dependencies: @@ -15648,20 +15246,6 @@ snapshots: pify: 4.0.1 strip-bom: 3.0.0 - readable-stream@1.0.34: - dependencies: - core-util-is: 1.0.3 - inherits: 2.0.4 - isarray: 0.0.1 - string_decoder: 0.10.31 - - readable-stream@1.1.14: - dependencies: - core-util-is: 1.0.3 - inherits: 2.0.4 - isarray: 0.0.1 - string_decoder: 0.10.31 - readable-stream@2.3.8: dependencies: core-util-is: 1.0.3 @@ -15690,24 +15274,29 @@ snapshots: dependencies: picomatch: 2.3.1 + readdirp@4.0.2: {} + realistic-structured-clone@3.0.0: dependencies: domexception: 1.0.1 typeson: 6.1.0 typeson-registry: 1.0.0-alpha.39 + rechoir@0.6.2: + dependencies: + resolve: 1.22.8 + rechoir@0.7.1: dependencies: resolve: 1.22.8 - redent@3.0.0: + recursive-readdir@2.2.3: dependencies: - indent-string: 4.0.0 - strip-indent: 3.0.0 + minimatch: 3.1.2 reduce-flatten@2.0.0: {} - regenerate-unicode-properties@10.1.1: + regenerate-unicode-properties@10.2.0: dependencies: regenerate: 1.4.2 @@ -15717,32 +15306,34 @@ snapshots: regenerator-transform@0.15.2: dependencies: - '@babel/runtime': 7.23.9 + '@babel/runtime': 7.25.9 regex-not@1.0.2: dependencies: extend-shallow: 3.0.2 safe-regex: 1.1.0 - regexp.prototype.flags@1.5.2: + regexp.prototype.flags@1.5.3: dependencies: call-bind: 1.0.7 define-properties: 1.2.1 es-errors: 1.3.0 set-function-name: 2.0.2 - regexpu-core@5.3.2: + regexpu-core@6.1.1: dependencies: - '@babel/regjsgen': 0.8.0 regenerate: 1.4.2 - regenerate-unicode-properties: 10.1.1 - regjsparser: 0.9.1 + regenerate-unicode-properties: 10.2.0 + regjsgen: 0.8.0 + regjsparser: 0.11.1 unicode-match-property-ecmascript: 2.0.0 - unicode-match-property-value-ecmascript: 2.1.0 + unicode-match-property-value-ecmascript: 2.2.0 - regjsparser@0.9.1: + regjsgen@0.8.0: {} + + regjsparser@0.11.1: dependencies: - jsesc: 0.5.0 + jsesc: 3.0.2 relateurl@0.2.7: {} @@ -15764,10 +15355,18 @@ snapshots: repeat-string@1.6.1: {} + req-cwd@2.0.0: + dependencies: + req-from: 2.0.0 + + req-from@2.0.0: + dependencies: + resolve-from: 3.0.0 + request@2.88.2: dependencies: aws-sign2: 0.7.0 - aws4: 1.12.0 + aws4: 1.13.2 caseless: 0.12.0 combined-stream: 1.0.8 extend: 3.0.2 @@ -15815,13 +15414,15 @@ snapshots: resolve-url@0.2.1: {} + resolve@1.1.7: {} + resolve@1.17.0: dependencies: path-parse: 1.0.7 resolve@1.22.8: dependencies: - is-core-module: 2.13.1 + is-core-module: 2.15.1 path-parse: 1.0.7 supports-preserve-symlinks-flag: 1.0.0 @@ -15843,9 +15444,10 @@ snapshots: dependencies: glob: 7.2.3 - rimraf@5.0.5: + rimraf@6.0.1: dependencies: - glob: 10.3.10 + glob: 11.0.0 + package-json-from-dist: 1.0.1 ripemd160@2.0.2: dependencies: @@ -15856,7 +15458,7 @@ snapshots: dependencies: bn.js: 5.2.1 - rollup@2.79.1: + rollup@2.79.2: optionalDependencies: fsevents: 2.3.3 @@ -15864,19 +15466,11 @@ snapshots: dependencies: queue-microtask: 1.2.3 - rust-verkle-wasm@0.0.1: {} - - rustbn-wasm@0.2.0: - dependencies: - '@scure/base': 1.1.5 - - rustbn.js@0.2.0: {} - rxjs@7.8.1: dependencies: - tslib: 2.6.2 + tslib: 2.8.0 - safe-array-concat@1.1.0: + safe-array-concat@1.1.2: dependencies: call-bind: 1.0.7 get-intrinsic: 1.2.4 @@ -15887,10 +15481,6 @@ snapshots: safe-buffer@5.2.1: {} - safe-event-emitter@1.0.1: - dependencies: - events: 3.3.0 - safe-regex-test@1.0.3: dependencies: call-bind: 1.0.7 @@ -15903,6 +15493,23 @@ snapshots: safer-buffer@2.1.2: {} + sc-istanbul@0.4.6: + dependencies: + abbrev: 1.0.9 + async: 1.5.2 + escodegen: 1.8.1 + esprima: 2.7.3 + glob: 5.0.15 + handlebars: 4.7.8 + js-yaml: 3.14.1 + mkdirp: 0.5.6 + nopt: 3.0.6 + once: 1.4.0 + resolve: 1.1.7 + supports-color: 3.2.3 + which: 1.3.1 + wordwrap: 1.0.0 + schema-utils@1.0.0: dependencies: ajv: 6.12.6 @@ -15918,17 +15525,17 @@ snapshots: schema-utils@4.2.0: dependencies: '@types/json-schema': 7.0.15 - ajv: 8.12.0 - ajv-formats: 2.1.1(ajv@8.12.0) - ajv-keywords: 5.1.0(ajv@8.12.0) + ajv: 8.17.1 + ajv-formats: 2.1.1(ajv@8.17.1) + ajv-keywords: 5.1.0(ajv@8.17.1) scrypt-js@3.0.1: {} - secp256k1@4.0.3: + secp256k1@4.0.4: dependencies: - elliptic: 6.5.4 - node-addon-api: 2.0.2 - node-gyp-build: 4.8.0 + elliptic: 6.5.7 + node-addon-api: 5.1.0 + node-gyp-build: 4.8.2 select-hose@2.0.0: {} @@ -15936,19 +15543,13 @@ snapshots: dependencies: node-forge: 1.3.1 - semaphore@1.1.0: {} - - semver@5.4.1: {} - semver@5.7.2: {} semver@6.3.1: {} - semver@7.6.0: - dependencies: - lru-cache: 6.0.0 + semver@7.6.3: {} - send@0.18.0(supports-color@6.1.0): + send@0.19.0(supports-color@6.1.0): dependencies: debug: 2.6.9(supports-color@6.1.0) depd: 2.0.0 @@ -15970,10 +15571,6 @@ snapshots: dependencies: type-fest: 0.13.1 - serialize-javascript@6.0.0: - dependencies: - randombytes: 2.1.0 - serialize-javascript@6.0.2: dependencies: randombytes: 2.1.0 @@ -15990,20 +15587,20 @@ snapshots: transitivePeerDependencies: - supports-color - serve-static@1.15.0(supports-color@6.1.0): + serve-static@1.16.2(supports-color@6.1.0): dependencies: - encodeurl: 1.0.2 + encodeurl: 2.0.0 escape-html: 1.0.3 parseurl: 1.3.3 - send: 0.18.0(supports-color@6.1.0) + send: 0.19.0(supports-color@6.1.0) transitivePeerDependencies: - supports-color servify@0.1.12: dependencies: - body-parser: 1.20.2 + body-parser: 1.20.3(supports-color@6.1.0) cors: 2.8.5 - express: 4.18.2(supports-color@6.1.0) + express: 4.21.1(supports-color@6.1.0) request: 2.88.2 xhr: 2.6.0 transitivePeerDependencies: @@ -16011,7 +15608,7 @@ snapshots: set-blocking@2.0.0: {} - set-function-length@1.2.1: + set-function-length@1.2.2: dependencies: define-data-property: 1.1.4 es-errors: 1.3.0 @@ -16027,8 +15624,6 @@ snapshots: functions-have-names: 1.2.3 has-property-descriptors: 1.0.2 - set-immediate-shim@1.0.1: {} - set-value@2.0.1: dependencies: extend-shallow: 2.0.1 @@ -16047,6 +15642,11 @@ snapshots: inherits: 2.0.4 safe-buffer: 5.2.1 + sha1@1.1.1: + dependencies: + charenc: 0.0.2 + crypt: 0.0.2 + shallow-clone@3.0.1: dependencies: kind-of: 6.0.3 @@ -16065,12 +15665,18 @@ snapshots: shell-quote@1.8.1: {} - side-channel@1.0.5: + shelljs@0.8.5: + dependencies: + glob: 7.2.3 + interpret: 1.4.0 + rechoir: 0.6.2 + + side-channel@1.0.6: dependencies: call-bind: 1.0.7 es-errors: 1.3.0 get-intrinsic: 1.2.4 - object-inspect: 1.13.1 + object-inspect: 1.13.2 signal-exit@3.0.7: {} @@ -16084,10 +15690,18 @@ snapshots: once: 1.4.0 simple-concat: 1.0.1 + sisteransi@1.0.5: {} + slash@3.0.0: {} slash@5.1.0: {} + slice-ansi@4.0.0: + dependencies: + ansi-styles: 4.3.0 + astral-regex: 2.0.0 + is-fullwidth-code-point: 3.0.0 + slice-ansi@5.0.0: dependencies: ansi-styles: 6.2.1 @@ -16095,15 +15709,6 @@ snapshots: smart-buffer@4.2.0: {} - smartwrap@2.0.2: - dependencies: - array.prototype.flat: 1.3.2 - breakword: 1.0.6 - grapheme-splitter: 1.0.4 - strip-ansi: 6.0.1 - wcwidth: 1.0.1 - yargs: 15.4.1 - snapdragon-node@2.1.1: dependencies: define-property: 1.0.0 @@ -16146,38 +15751,67 @@ snapshots: socks-proxy-agent@7.0.0: dependencies: agent-base: 6.0.2 - debug: 4.3.4(supports-color@6.1.0) - socks: 2.8.1 + debug: 4.3.7(supports-color@6.1.0) + socks: 2.8.3 transitivePeerDependencies: - supports-color - socks-proxy-agent@8.0.2: + socks-proxy-agent@8.0.4: dependencies: - agent-base: 7.1.0 - debug: 4.3.4(supports-color@6.1.0) - socks: 2.8.1 + agent-base: 7.1.1 + debug: 4.3.7(supports-color@6.1.0) + socks: 2.8.3 transitivePeerDependencies: - supports-color - socks@2.8.1: + socks-proxy-agent@8.0.5: + dependencies: + agent-base: 7.1.3 + debug: 4.4.0 + socks: 2.8.3 + transitivePeerDependencies: + - supports-color + + socks@2.8.3: dependencies: ip-address: 9.0.5 smart-buffer: 4.2.0 - solc@0.7.3(debug@4.3.4): + solc@0.8.26(debug@4.3.7): dependencies: command-exists: 1.2.9 - commander: 3.0.2 - follow-redirects: 1.15.5(debug@4.3.4) - fs-extra: 0.30.0 + commander: 8.3.0 + follow-redirects: 1.15.9(debug@4.3.7) js-sha3: 0.8.0 memorystream: 0.3.1 - require-from-string: 2.0.2 semver: 5.7.2 tmp: 0.0.33 transitivePeerDependencies: - debug + solidity-coverage@0.8.13(hardhat@2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10)): + dependencies: + '@ethersproject/abi': 5.7.0 + '@solidity-parser/parser': 0.18.0 + chalk: 2.4.2 + death: 1.1.0 + difflib: 0.2.4 + fs-extra: 8.1.0 + ghost-testrpc: 0.0.2 + global-modules: 2.0.0 + globby: 10.0.2 + hardhat: 2.22.14(bufferutil@4.0.8)(ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3))(typescript@5.6.3)(utf-8-validate@5.0.10) + jsonschema: 1.4.1 + lodash: 4.17.21 + mocha: 10.7.3 + node-emoji: 1.11.0 + pify: 4.0.1 + recursive-readdir: 2.2.3 + sc-istanbul: 0.4.6 + semver: 7.6.3 + shelljs: 0.8.5 + web3-utils: 1.10.4 + source-map-resolve@0.5.3: dependencies: atob: 2.1.2 @@ -16193,16 +15827,17 @@ snapshots: source-map-url@0.4.1: {} + source-map@0.2.0: + dependencies: + amdefine: 1.0.1 + optional: true + source-map@0.5.7: {} source-map@0.6.1: {} sourcemap-codec@1.4.8: {} - spawn-command@0.0.2: {} - - spawn-command@0.0.2-1: {} - spawn-wrap@2.0.0: dependencies: foreground-child: 2.0.0 @@ -16217,23 +15852,9 @@ snapshots: cross-spawn: 5.1.0 signal-exit: 3.0.7 - spdx-correct@3.2.0: - dependencies: - spdx-expression-parse: 3.0.1 - spdx-license-ids: 3.0.17 - - spdx-exceptions@2.5.0: {} - - spdx-expression-parse@3.0.1: - dependencies: - spdx-exceptions: 2.5.0 - spdx-license-ids: 3.0.17 - - spdx-license-ids@3.0.17: {} - spdy-transport@3.0.0(supports-color@6.1.0): dependencies: - debug: 4.3.4(supports-color@6.1.0) + debug: 4.3.7(supports-color@6.1.0) detect-node: 2.1.0 hpack.js: 2.1.6 obuf: 1.1.2 @@ -16244,7 +15865,7 @@ snapshots: spdy@4.0.2(supports-color@6.1.0): dependencies: - debug: 4.3.4(supports-color@6.1.0) + debug: 4.3.7(supports-color@6.1.0) handle-thing: 2.0.1 http-deceiver: 1.2.7 select-hose: 2.0.0 @@ -16256,6 +15877,10 @@ snapshots: dependencies: extend-shallow: 3.0.2 + split2@3.2.2: + dependencies: + readable-stream: 3.6.2 + sprintf-js@1.0.3: {} sprintf-js@1.1.3: {} @@ -16291,21 +15916,23 @@ snapshots: stream-shift@1.0.3: {} - stream-transform@2.1.3: - dependencies: - mixme: 0.5.10 - - streamx@2.16.1: + streamx@2.20.1: dependencies: fast-fifo: 1.3.2 queue-tick: 1.0.1 + text-decoder: 1.2.1 optionalDependencies: - bare-events: 2.2.0 + bare-events: 2.5.0 strict-uri-encode@1.1.0: {} string-format@2.0.0: {} + string-width@2.1.1: + dependencies: + is-fullwidth-code-point: 2.0.0 + strip-ansi: 4.0.0 + string-width@3.1.0: dependencies: emoji-regex: 7.0.3 @@ -16324,31 +15951,30 @@ snapshots: emoji-regex: 9.2.2 strip-ansi: 7.1.0 - string-width@7.1.0: + string-width@7.2.0: dependencies: - emoji-regex: 10.3.0 - get-east-asian-width: 1.2.0 + emoji-regex: 10.4.0 + get-east-asian-width: 1.3.0 strip-ansi: 7.1.0 - string.prototype.trim@1.2.8: + string.prototype.trim@1.2.9: dependencies: call-bind: 1.0.7 define-properties: 1.2.1 - es-abstract: 1.22.4 + es-abstract: 1.23.3 + es-object-atoms: 1.0.0 - string.prototype.trimend@1.0.7: + string.prototype.trimend@1.0.8: dependencies: call-bind: 1.0.7 define-properties: 1.2.1 - es-abstract: 1.22.4 + es-object-atoms: 1.0.0 - string.prototype.trimstart@1.0.7: + string.prototype.trimstart@1.0.8: dependencies: call-bind: 1.0.7 define-properties: 1.2.1 - es-abstract: 1.22.4 - - string_decoder@0.10.31: {} + es-object-atoms: 1.0.0 string_decoder@1.1.1: dependencies: @@ -16362,6 +15988,10 @@ snapshots: dependencies: ansi-regex: 2.1.1 + strip-ansi@4.0.0: + dependencies: + ansi-regex: 3.0.1 + strip-ansi@5.2.0: dependencies: ansi-regex: 4.1.1 @@ -16372,7 +16002,7 @@ snapshots: strip-ansi@7.1.0: dependencies: - ansi-regex: 6.0.1 + ansi-regex: 6.1.0 strip-bom@3.0.0: {} @@ -16384,16 +16014,10 @@ snapshots: dependencies: is-hex-prefixed: 1.0.0 - strip-indent@3.0.0: - dependencies: - min-indent: 1.0.1 - strip-json-comments@3.1.1: {} strnum@1.0.5: {} - superstruct@1.0.3: {} - supertap@3.0.1: dependencies: indent-string: 5.0.0 @@ -16401,6 +16025,10 @@ snapshots: serialize-error: 7.0.1 strip-ansi: 7.1.0 + supports-color@3.2.3: + dependencies: + has-flag: 1.0.0 + supports-color@5.5.0: dependencies: has-flag: 3.0.0 @@ -16419,11 +16047,11 @@ snapshots: supports-preserve-symlinks-flag@1.0.0: {} - swarm-js@0.1.42: + swarm-js@0.1.42(bufferutil@4.0.8)(utf-8-validate@5.0.10): dependencies: bluebird: 3.7.2 buffer: 5.7.1 - eth-lib: 0.1.29 + eth-lib: 0.1.29(bufferutil@4.0.8)(utf-8-validate@5.0.10) fs-extra: 4.0.3 got: 11.8.6 mime-types: 2.1.35 @@ -16439,10 +16067,20 @@ snapshots: symbol-observable@1.2.0: {} - synckit@0.8.8: + sync-request@6.1.0: + dependencies: + http-response-object: 3.0.2 + sync-rpc: 1.3.6 + then-request: 6.0.2 + + sync-rpc@1.3.6: + dependencies: + get-port: 3.2.0 + + synckit@0.9.2: dependencies: '@pkgr/core': 0.1.1 - tslib: 2.6.2 + tslib: 2.8.0 table-layout@1.0.2: dependencies: @@ -16451,19 +16089,29 @@ snapshots: typical: 5.2.0 wordwrapjs: 4.0.1 + table@6.8.2: + dependencies: + ajv: 8.17.1 + lodash.truncate: 4.4.2 + slice-ansi: 4.0.0 + string-width: 4.2.3 + strip-ansi: 6.0.1 + tapable@2.2.1: {} - tar-fs@3.0.4: + tar-fs@3.0.6: dependencies: - mkdirp-classic: 0.5.3 - pump: 3.0.0 + pump: 3.0.2 tar-stream: 3.1.7 + optionalDependencies: + bare-fs: 2.3.5 + bare-path: 2.1.3 tar-stream@3.1.7: dependencies: - b4a: 1.6.6 + b4a: 1.6.7 fast-fifo: 1.3.2 - streamx: 2.16.1 + streamx: 2.20.1 tar@4.4.19: dependencies: @@ -16475,7 +16123,7 @@ snapshots: safe-buffer: 5.2.1 yallist: 3.1.1 - tar@6.2.0: + tar@6.2.1: dependencies: chownr: 2.0.0 fs-minipass: 2.1.0 @@ -16488,19 +16136,19 @@ snapshots: term-size@2.2.1: {} - terser-webpack-plugin@5.3.10(webpack@5.90.3): + terser-webpack-plugin@5.3.10(webpack@5.95.0): dependencies: - '@jridgewell/trace-mapping': 0.3.23 + '@jridgewell/trace-mapping': 0.3.25 jest-worker: 27.5.1 schema-utils: 3.3.0 serialize-javascript: 6.0.2 - terser: 5.28.1 - webpack: 5.90.3(webpack-cli@4.10.0) + terser: 5.36.0 + webpack: 5.95.0(webpack-cli@4.10.0) - terser@5.28.1: + terser@5.36.0: dependencies: - '@jridgewell/source-map': 0.3.5 - acorn: 8.11.3 + '@jridgewell/source-map': 0.3.6 + acorn: 8.13.0 commander: 2.20.3 source-map-support: 0.5.21 @@ -16510,13 +16158,28 @@ snapshots: glob: 7.2.3 minimatch: 3.1.2 - test-value@2.1.0: - dependencies: - array-back: 1.0.4 - typical: 2.6.1 + text-decoder@1.2.1: {} text-table@0.2.0: {} + then-request@6.0.2: + dependencies: + '@types/concat-stream': 1.6.1 + '@types/form-data': 0.0.33 + '@types/node': 8.10.66 + '@types/qs': 6.9.16 + caseless: 0.12.0 + concat-stream: 1.6.2 + form-data: 2.5.2 + http-basic: 8.1.3 + http-response-object: 3.0.2 + promise: 8.3.0 + qs: 6.13.0 + + through2@4.0.2: + dependencies: + readable-stream: 3.6.2 + through@2.3.8: {} thunky@1.1.0: {} @@ -16529,8 +16192,6 @@ snapshots: dependencies: os-tmpdir: 1.0.2 - to-fast-properties@2.0.0: {} - to-object-path@0.3.0: dependencies: kind-of: 3.2.2 @@ -16558,13 +16219,6 @@ snapshots: psl: 1.9.0 punycode: 2.3.1 - tough-cookie@4.1.3: - dependencies: - psl: 1.9.0 - punycode: 2.3.1 - universalify: 0.2.0 - url-parse: 1.5.10 - tr46@0.0.3: {} tr46@2.1.0: @@ -16573,11 +16227,9 @@ snapshots: tree-kill@1.2.2: {} - trim-newlines@3.0.1: {} - - ts-api-utils@1.2.1(typescript@5.3.3): + ts-api-utils@1.3.0(typescript@5.6.3): dependencies: - typescript: 5.3.3 + typescript: 5.6.3 ts-command-line-args@2.5.1: dependencies: @@ -16586,25 +16238,25 @@ snapshots: command-line-usage: 6.1.3 string-format: 2.0.0 - ts-essentials@7.0.3(typescript@5.3.3): + ts-essentials@7.0.3(typescript@5.6.3): dependencies: - typescript: 5.3.3 + typescript: 5.6.3 - ts-node@10.9.2(@types/node@20.11.20)(typescript@5.3.3): + ts-node@10.9.2(@types/node@22.7.9)(typescript@5.6.3): dependencies: '@cspotcode/source-map-support': 0.8.1 - '@tsconfig/node10': 1.0.9 + '@tsconfig/node10': 1.0.11 '@tsconfig/node12': 1.0.11 '@tsconfig/node14': 1.0.3 '@tsconfig/node16': 1.0.4 - '@types/node': 20.11.20 - acorn: 8.11.3 - acorn-walk: 8.3.2 + '@types/node': 22.7.9 + acorn: 8.13.0 + acorn-walk: 8.3.4 arg: 4.1.3 create-require: 1.1.1 diff: 4.0.2 make-error: 1.3.6 - typescript: 5.3.3 + typescript: 5.6.3 v8-compile-cache-lib: 3.0.1 yn: 3.1.1 @@ -16617,27 +16269,19 @@ snapshots: tslib@1.14.1: {} - tslib@2.6.2: {} + tslib@2.7.0: {} + + tslib@2.8.0: {} tsort@0.0.1: {} - tsx@4.7.1: + tsx@4.19.1: dependencies: - esbuild: 0.19.12 - get-tsconfig: 4.7.2 + esbuild: 0.23.1 + get-tsconfig: 4.8.1 optionalDependencies: fsevents: 2.3.3 - tty-table@4.2.3: - dependencies: - chalk: 4.1.2 - csv: 5.5.3 - kleur: 4.1.5 - smartwrap: 2.0.2 - strip-ansi: 6.0.1 - wcwidth: 1.0.1 - yargs: 17.7.2 - tunnel-agent@0.6.0: dependencies: safe-buffer: 5.2.1 @@ -16648,11 +16292,15 @@ snapshots: tweetnacl@1.0.3: {} + type-check@0.3.2: + dependencies: + prelude-ls: 1.1.2 + type-check@0.4.0: dependencies: prelude-ls: 1.2.1 - type-detect@4.0.8: {} + type-detect@4.1.0: {} type-fest@0.13.1: {} @@ -16660,8 +16308,6 @@ snapshots: type-fest@0.21.3: {} - type-fest@0.6.0: {} - type-fest@0.7.1: {} type-fest@0.8.1: {} @@ -16671,30 +16317,12 @@ snapshots: media-typer: 0.3.0 mime-types: 2.1.35 - type@1.2.0: {} - - type@2.7.2: {} - - typechain@5.2.0(typescript@5.3.3): - dependencies: - '@types/prettier': 2.7.3 - command-line-args: 4.0.7 - debug: 4.3.4(supports-color@6.1.0) - fs-extra: 7.0.1 - glob: 7.2.3 - js-sha3: 0.8.0 - lodash: 4.17.21 - mkdirp: 1.0.4 - prettier: 2.8.8 - ts-essentials: 7.0.3(typescript@5.3.3) - typescript: 5.3.3 - transitivePeerDependencies: - - supports-color + type@2.7.3: {} - typechain@8.3.2(typescript@5.3.3): + typechain@8.3.2(typescript@5.6.3): dependencies: '@types/prettier': 2.7.3 - debug: 4.3.4(supports-color@6.1.0) + debug: 4.3.7(supports-color@6.1.0) fs-extra: 7.0.1 glob: 7.1.7 js-sha3: 0.8.0 @@ -16702,8 +16330,8 @@ snapshots: mkdirp: 1.0.4 prettier: 2.8.8 ts-command-line-args: 2.5.1 - ts-essentials: 7.0.3(typescript@5.3.3) - typescript: 5.3.3 + ts-essentials: 7.0.3(typescript@5.6.3) + typescript: 5.6.3 transitivePeerDependencies: - supports-color @@ -16730,7 +16358,7 @@ snapshots: has-proto: 1.0.3 is-typed-array: 1.1.13 - typed-array-length@1.0.5: + typed-array-length@1.0.6: dependencies: call-bind: 1.0.7 for-each: 0.3.3 @@ -16741,11 +16369,15 @@ snapshots: typed-error@3.2.2: {} + typed-query-selector@2.12.0: {} + typedarray-to-buffer@3.1.5: dependencies: is-typedarray: 1.0.0 - typescript@5.3.3: {} + typedarray@0.0.6: {} + + typescript@5.6.3: {} typeson-registry@1.0.0-alpha.39: dependencies: @@ -16755,12 +16387,13 @@ snapshots: typeson@6.1.0: {} - typical@2.6.1: {} - typical@4.0.0: {} typical@5.2.0: {} + uglify-js@3.19.3: + optional: true + ultron@1.1.1: {} unbox-primitive@1.0.2: @@ -16775,20 +16408,20 @@ snapshots: buffer: 5.7.1 through: 2.3.8 - undici-types@5.26.5: {} + undici-types@6.19.8: {} - undici@5.28.3: + undici@5.28.4: dependencies: - '@fastify/busboy': 2.1.0 + '@fastify/busboy': 2.1.1 - unicode-canonical-property-names-ecmascript@2.0.0: {} + unicode-canonical-property-names-ecmascript@2.0.1: {} unicode-match-property-ecmascript@2.0.0: dependencies: - unicode-canonical-property-names-ecmascript: 2.0.0 + unicode-canonical-property-names-ecmascript: 2.0.1 unicode-property-aliases-ecmascript: 2.1.0 - unicode-match-property-value-ecmascript@2.1.0: {} + unicode-match-property-value-ecmascript@2.2.0: {} unicode-property-aliases-ecmascript@2.1.0: {} @@ -16803,8 +16436,6 @@ snapshots: universalify@0.1.2: {} - universalify@0.2.0: {} - universalify@2.0.1: {} unpipe@1.0.0: {} @@ -16816,11 +16447,11 @@ snapshots: upath@1.2.0: {} - update-browserslist-db@1.0.13(browserslist@4.23.0): + update-browserslist-db@1.1.1(browserslist@4.24.2): dependencies: - browserslist: 4.23.0 - escalade: 3.1.2 - picocolors: 1.0.0 + browserslist: 4.24.2 + escalade: 3.2.0 + picocolors: 1.1.1 uri-js@4.4.1: dependencies: @@ -16835,27 +16466,30 @@ snapshots: url-set-query@1.0.0: {} - url@0.11.3: + url@0.11.4: dependencies: punycode: 1.4.1 - qs: 6.11.2 + qs: 6.13.0 urlpattern-polyfill@10.0.0: {} + urlpattern-polyfill@8.0.2: {} + use@3.1.1: {} utf-8-validate@5.0.10: dependencies: - node-gyp-build: 4.8.0 + node-gyp-build: 4.8.2 utf-8-validate@5.0.7: dependencies: - node-gyp-build: 4.8.0 + node-gyp-build: 4.8.2 optional: true utf-8-validate@6.0.3: dependencies: - node-gyp-build: 4.8.0 + node-gyp-build: 4.8.2 + optional: true utf8@3.0.0: {} @@ -16867,7 +16501,7 @@ snapshots: is-arguments: 1.1.1 is-generator-function: 1.0.10 is-typed-array: 1.1.13 - which-typed-array: 1.1.14 + which-typed-array: 1.1.15 utila@0.4.0: {} @@ -16883,11 +16517,6 @@ snapshots: v8-compile-cache@2.4.0: {} - validate-npm-package-license@3.0.4: - dependencies: - spdx-correct: 3.2.0 - spdx-expression-parse: 3.0.1 - value-or-promise@1.0.11: {} varint@5.0.2: {} @@ -16900,17 +16529,17 @@ snapshots: core-util-is: 1.0.2 extsprintf: 1.3.0 - wait-on@7.2.0: + wait-on@8.0.1: dependencies: - axios: 1.6.7 - joi: 17.12.2 + axios: 1.7.7 + joi: 17.13.3 lodash: 4.17.21 minimist: 1.2.8 rxjs: 7.8.1 transitivePeerDependencies: - debug - watchpack@2.4.0: + watchpack@2.4.2: dependencies: glob-to-regexp: 0.4.1 graceful-fs: 4.2.11 @@ -16919,15 +16548,11 @@ snapshots: dependencies: minimalistic-assert: 1.0.1 - wcwidth@1.0.1: - dependencies: - defaults: 1.0.4 - - web3-bzz@1.10.4: + web3-bzz@1.10.4(bufferutil@4.0.8)(utf-8-validate@5.0.10): dependencies: '@types/node': 12.20.55 got: 12.1.0 - swarm-js: 0.1.42 + swarm-js: 0.1.42(bufferutil@4.0.8)(utf-8-validate@5.0.10) transitivePeerDependencies: - bufferutil - supports-color @@ -16968,7 +16593,7 @@ snapshots: web3-core@1.10.4: dependencies: - '@types/bn.js': 5.1.5 + '@types/bn.js': 5.1.6 '@types/node': 12.20.55 bignumber.js: 9.1.2 web3-core-helpers: 1.10.4 @@ -17002,7 +16627,7 @@ snapshots: web3-eth-contract@1.10.4: dependencies: - '@types/bn.js': 5.1.5 + '@types/bn.js': 5.1.6 web3-core: 1.10.4 web3-core-helpers: 1.10.4 web3-core-method: 1.10.4 @@ -17072,34 +16697,6 @@ snapshots: - encoding - supports-color - web3-provider-engine@16.0.7: - dependencies: - '@cypress/request': 3.0.1 - '@ethereumjs/tx': 3.5.2 - async: 2.6.4 - backoff: 2.5.0 - clone: 2.1.2 - eth-block-tracker: 5.0.1 - eth-json-rpc-filters: 4.2.2 - eth-json-rpc-infura: 5.1.0 - eth-json-rpc-middleware: 6.0.0 - eth-rpc-errors: 3.0.0 - eth-sig-util: 1.4.2 - ethereumjs-block: 1.7.1 - ethereumjs-util: 5.2.1 - ethereumjs-vm: 2.6.0 - json-stable-stringify: 1.1.1 - promise-to-callback: 1.0.0 - readable-stream: 2.3.8 - semaphore: 1.1.0 - ws: 7.5.9 - xhr: 2.6.0 - xtend: 4.0.2 - transitivePeerDependencies: - - bufferutil - - encoding - - utf-8-validate - web3-providers-http@1.10.4: dependencies: abortcontroller-polyfill: 1.7.5 @@ -17118,7 +16715,7 @@ snapshots: dependencies: eventemitter3: 4.0.4 web3-core-helpers: 1.10.4 - websocket: 1.0.34 + websocket: 1.0.35 transitivePeerDependencies: - supports-color @@ -17136,16 +16733,16 @@ snapshots: dependencies: '@ethereumjs/util': 8.1.0 bn.js: 5.2.1 - ethereum-bloom-filters: 1.0.10 - ethereum-cryptography: 2.1.3 + ethereum-bloom-filters: 1.2.0 + ethereum-cryptography: 2.2.1 ethjs-unit: 0.1.6 number-to-bn: 1.7.0 randombytes: 2.1.0 utf8: 3.0.0 - web3@1.10.4: + web3@1.10.4(bufferutil@4.0.8)(utf-8-validate@5.0.10): dependencies: - web3-bzz: 1.10.4 + web3-bzz: 1.10.4(bufferutil@4.0.8)(utf-8-validate@5.0.10) web3-core: 1.10.4 web3-eth: 1.10.4 web3-eth-personal: 1.10.4 @@ -17166,50 +16763,51 @@ snapshots: webidl-conversions@6.1.0: {} - webpack-cli@4.10.0(webpack-dev-server@3.11.3)(webpack@5.90.3): + webpack-cli@4.10.0(webpack-dev-server@3.11.3)(webpack@5.95.0): dependencies: '@discoveryjs/json-ext': 0.5.7 - '@webpack-cli/configtest': 1.2.0(webpack-cli@4.10.0)(webpack@5.90.3) + '@webpack-cli/configtest': 1.2.0(webpack-cli@4.10.0)(webpack@5.95.0) '@webpack-cli/info': 1.5.0(webpack-cli@4.10.0) '@webpack-cli/serve': 1.7.0(webpack-cli@4.10.0)(webpack-dev-server@3.11.3) colorette: 2.0.20 commander: 7.2.0 cross-spawn: 7.0.3 fastest-levenshtein: 1.0.16 - import-local: 3.1.0 + import-local: 3.2.0 interpret: 2.2.0 rechoir: 0.7.1 - webpack: 5.90.3(webpack-cli@4.10.0) - webpack-dev-server: 3.11.3(webpack-cli@4.10.0)(webpack@5.90.3) + webpack: 5.95.0(webpack-cli@4.10.0) webpack-merge: 5.10.0 + optionalDependencies: + webpack-dev-server: 3.11.3(bufferutil@4.0.8)(utf-8-validate@6.0.3)(webpack-cli@4.10.0)(webpack@5.95.0) - webpack-dev-middleware@3.7.3(webpack@5.90.3): + webpack-dev-middleware@3.7.3(webpack@5.95.0): dependencies: memory-fs: 0.4.1 mime: 2.6.0 mkdirp: 0.5.6 range-parser: 1.2.1 - webpack: 5.90.3(webpack-cli@4.10.0) + webpack: 5.95.0(webpack-cli@4.10.0) webpack-log: 2.0.0 - webpack-dev-server@3.11.3(webpack-cli@4.10.0)(webpack@5.90.3): + webpack-dev-server@3.11.3(bufferutil@4.0.8)(utf-8-validate@6.0.3)(webpack-cli@4.10.0)(webpack@5.95.0): dependencies: ansi-html-community: 0.0.8 bonjour: 3.5.0 chokidar: 2.1.8(supports-color@6.1.0) compression: 1.7.4(supports-color@6.1.0) connect-history-api-fallback: 1.6.0 - debug: 4.3.4(supports-color@6.1.0) + debug: 4.3.7(supports-color@6.1.0) del: 4.1.1 - express: 4.18.2(supports-color@6.1.0) + express: 4.21.1(supports-color@6.1.0) html-entities: 1.4.0 - http-proxy-middleware: 0.19.1(debug@4.3.4)(supports-color@6.1.0) + http-proxy-middleware: 0.19.1(debug@4.3.7(supports-color@6.1.0))(supports-color@6.1.0) import-local: 2.0.0 internal-ip: 4.3.0 ip: 1.1.9 is-absolute-url: 3.0.3 killable: 1.0.1 - loglevel: 1.9.1 + loglevel: 1.9.2 opn: 5.5.0 p-retry: 3.0.1 portfinder: 1.0.32(supports-color@6.1.0) @@ -17222,13 +16820,14 @@ snapshots: spdy: 4.0.2(supports-color@6.1.0) strip-ansi: 3.0.1 supports-color: 6.1.0 - url: 0.11.3 - webpack: 5.90.3(webpack-cli@4.10.0) - webpack-cli: 4.10.0(webpack-dev-server@3.11.3)(webpack@5.90.3) - webpack-dev-middleware: 3.7.3(webpack@5.90.3) + url: 0.11.4 + webpack: 5.95.0(webpack-cli@4.10.0) + webpack-dev-middleware: 3.7.3(webpack@5.95.0) webpack-log: 2.0.0 - ws: 6.2.2 + ws: 6.2.3(bufferutil@4.0.8)(utf-8-validate@6.0.3) yargs: 13.3.2 + optionalDependencies: + webpack-cli: 4.10.0(webpack-dev-server@3.11.3)(webpack@5.95.0) transitivePeerDependencies: - bufferutil - utf-8-validate @@ -17246,19 +16845,18 @@ snapshots: webpack-sources@3.2.3: {} - webpack@5.90.3(webpack-cli@4.10.0): - dependencies: - '@types/eslint-scope': 3.7.7 - '@types/estree': 1.0.5 - '@webassemblyjs/ast': 1.11.6 - '@webassemblyjs/wasm-edit': 1.11.6 - '@webassemblyjs/wasm-parser': 1.11.6 - acorn: 8.11.3 - acorn-import-assertions: 1.9.0(acorn@8.11.3) - browserslist: 4.23.0 - chrome-trace-event: 1.0.3 - enhanced-resolve: 5.15.0 - es-module-lexer: 1.4.1 + webpack@5.95.0(webpack-cli@4.10.0): + dependencies: + '@types/estree': 1.0.6 + '@webassemblyjs/ast': 1.12.1 + '@webassemblyjs/wasm-edit': 1.12.1 + '@webassemblyjs/wasm-parser': 1.12.1 + acorn: 8.13.0 + acorn-import-attributes: 1.9.5(acorn@8.13.0) + browserslist: 4.24.2 + chrome-trace-event: 1.0.4 + enhanced-resolve: 5.17.1 + es-module-lexer: 1.5.4 eslint-scope: 5.1.1 events: 3.3.0 glob-to-regexp: 0.4.1 @@ -17269,10 +16867,11 @@ snapshots: neo-async: 2.6.2 schema-utils: 3.3.0 tapable: 2.2.1 - terser-webpack-plugin: 5.3.10(webpack@5.90.3) - watchpack: 2.4.0 - webpack-cli: 4.10.0(webpack-dev-server@3.11.3)(webpack@5.90.3) + terser-webpack-plugin: 5.3.10(webpack@5.95.0) + watchpack: 2.4.2 webpack-sources: 3.2.3 + optionalDependencies: + webpack-cli: 4.10.0(webpack-dev-server@3.11.3)(webpack@5.95.0) transitivePeerDependencies: - '@swc/core' - esbuild @@ -17286,11 +16885,11 @@ snapshots: websocket-extensions@0.1.4: {} - websocket@1.0.34: + websocket@1.0.35: dependencies: bufferutil: 4.0.8 debug: 2.6.9(supports-color@6.1.0) - es5-ext: 0.10.63 + es5-ext: 0.10.64 typedarray-to-buffer: 3.1.5 utf-8-validate: 5.0.10 yaeti: 0.0.6 @@ -17320,12 +16919,7 @@ snapshots: which-module@2.0.1: {} - which-pm@2.0.0: - dependencies: - load-yaml-file: 0.2.0 - path-exists: 4.0.0 - - which-typed-array@1.1.14: + which-typed-array@1.1.15: dependencies: available-typed-arrays: 1.0.7 call-bind: 1.0.7 @@ -17351,12 +16945,16 @@ snapshots: wildcard@2.0.1: {} + word-wrap@1.2.5: {} + + wordwrap@1.0.0: {} + wordwrapjs@4.0.1: dependencies: reduce-flatten: 2.0.0 typical: 5.2.0 - workerpool@6.2.1: {} + workerpool@6.5.1: {} wrap-ansi@5.1.0: dependencies: @@ -17396,26 +16994,56 @@ snapshots: imurmurhash: 0.1.4 signal-exit: 4.1.0 - ws@3.3.3: + ws@3.3.3(bufferutil@4.0.8)(utf-8-validate@5.0.10): dependencies: async-limiter: 1.0.1 safe-buffer: 5.1.2 ultron: 1.1.1 + optionalDependencies: + bufferutil: 4.0.8 + utf-8-validate: 5.0.10 - ws@6.2.2: + ws@6.2.3(bufferutil@4.0.8)(utf-8-validate@6.0.3): dependencies: async-limiter: 1.0.1 + optionalDependencies: + bufferutil: 4.0.8 + utf-8-validate: 6.0.3 - ws@7.4.6: {} + ws@7.4.6(bufferutil@4.0.8)(utf-8-validate@5.0.10): + optionalDependencies: + bufferutil: 4.0.8 + utf-8-validate: 5.0.10 - ws@7.5.9: {} + ws@7.5.10(bufferutil@4.0.8)(utf-8-validate@5.0.10): + optionalDependencies: + bufferutil: 4.0.8 + utf-8-validate: 5.0.10 - ws@8.13.0(bufferutil@4.0.7)(utf-8-validate@6.0.3): - dependencies: - bufferutil: 4.0.7 + ws@7.5.10(bufferutil@4.0.8)(utf-8-validate@6.0.3): + optionalDependencies: + bufferutil: 4.0.8 + utf-8-validate: 6.0.3 + + ws@8.13.0(bufferutil@4.0.8)(utf-8-validate@6.0.3): + optionalDependencies: + bufferutil: 4.0.8 + utf-8-validate: 6.0.3 + + ws@8.17.1(bufferutil@4.0.8)(utf-8-validate@5.0.10): + optionalDependencies: + bufferutil: 4.0.8 + utf-8-validate: 5.0.10 + + ws@8.17.1(bufferutil@4.0.8)(utf-8-validate@6.0.3): + optionalDependencies: + bufferutil: 4.0.8 utf-8-validate: 6.0.3 - ws@8.16.0: {} + ws@8.18.0(bufferutil@4.0.8)(utf-8-validate@5.0.10): + optionalDependencies: + bufferutil: 4.0.8 + utf-8-validate: 5.0.10 xhr-request-promise@0.1.3: dependencies: @@ -17438,10 +17066,6 @@ snapshots: parse-headers: 2.0.5 xtend: 4.0.2 - xtend@2.1.2: - dependencies: - object-keys: 0.4.0 - xtend@4.0.2: {} y18n@4.0.3: {} @@ -17466,7 +17090,7 @@ snapshots: camelcase: 5.3.1 decamelize: 1.2.0 - yargs-parser@20.2.4: {} + yargs-parser@20.2.9: {} yargs-parser@21.1.1: {} @@ -17507,17 +17131,17 @@ snapshots: yargs@16.2.0: dependencies: cliui: 7.0.4 - escalade: 3.1.2 + escalade: 3.2.0 get-caller-file: 2.0.5 require-directory: 2.1.1 string-width: 4.2.3 y18n: 5.0.8 - yargs-parser: 20.2.4 + yargs-parser: 20.2.9 yargs@17.7.2: dependencies: cliui: 8.0.1 - escalade: 3.1.2 + escalade: 3.2.0 get-caller-file: 2.0.5 require-directory: 2.1.1 string-width: 4.2.3 @@ -17533,8 +17157,8 @@ snapshots: yocto-queue@0.1.0: {} - yocto-queue@1.0.0: {} + yocto-queue@1.1.1: {} - zod@3.22.4: {} + zod@3.23.8: {} - zstd-codec@0.1.4: {} \ No newline at end of file + zstd-codec@0.1.5: {} diff --git a/tsconfig.json b/tsconfig.json index 9e44f9549..57c756154 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -12,12 +12,8 @@ "noImplicitAny": true, "noImplicitReturns": true, "isolatedModules": true, - "typeRoots": [ - "node_modules/@types" - ], - "types": [ - "node" - ] + "typeRoots": ["node_modules/@types"], + "types": ["node"] }, "include": ["./packages/**/src/**/*.ts"] } diff --git a/tsconfig.test.json b/tsconfig.test.json index 0c7b3c1e4..ff2758b41 100644 --- a/tsconfig.test.json +++ b/tsconfig.test.json @@ -7,11 +7,9 @@ "allowSyntheticDefaultImports": true, "strictNullChecks": false, "esModuleInterop": true, + "resolveJsonModule": true, "lib": ["dom.iterable", "dom", "es2020"], "types": ["node", "mocha", "puppeteer"] }, - "include": [ - "./src/**/*", - "./tests/**/*" - ] + "include": ["./src/**/*", "./tests/**/*"] }