Skip to content

Commit

Permalink
Merge branch '4.x' into fix-0-wei-issue-7339
Browse files Browse the repository at this point in the history
  • Loading branch information
whitemoshui authored Nov 18, 2024
2 parents c188c5a + 1b367e6 commit 7a882b9
Show file tree
Hide file tree
Showing 9 changed files with 433 additions and 259 deletions.
96 changes: 48 additions & 48 deletions .github/workflows/black_box_tests.yml
Original file line number Diff line number Diff line change
@@ -1,53 +1,53 @@
name: 'Black Box Tests'
on:
push:
branches:
- release/**
tags:
- v4.*
branches:
- release/**
tags:
- v4.*

jobs:
build:
strategy:
matrix:
node: [18]
name: Build Packages
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node }}
- run: yarn
- run: tar -czf /tmp/web3-${{ matrix.node }}.js.tar.gz --exclude="./.git" ./
- uses: actions/upload-artifact@v3
with:
name: web3-${{ matrix.node }}.js.tar.gz
path: /tmp/web3-${{ matrix.node }}.js.tar.gz
black-box:
name: Black Box
needs: build
runs-on: ubuntu-latest
env:
INFURA_MAINNET_HTTP: ${{ secrets.INFURA_MAINNET_HTTP }}
INFURA_MAINNET_WS: ${{ secrets.INFURA_MAINNET_WS }}
INFURA_SEPOLIA_WS: ${{ secrets.INFURA_SEPOLIA_WS }}
MODE: ${{ matrix.mode }}
strategy:
fail-fast: false
matrix:
node: [18]
mode: ['http', 'ws']
backend: ['geth', 'infura']
steps:
- uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node }}
- uses: actions/download-artifact@v3
with:
name: web3-${{ matrix.node }}.js.tar.gz
path: /tmp
- run: tar -xf /tmp/web3-${{ matrix.node }}.js.tar.gz -C ./
- run: |
yarn test:blackbox:${{ matrix.backend }}:${{ matrix.mode }}
shell: bash
build:
strategy:
matrix:
node: [18]
name: Build Packages
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node }}
- run: yarn
- run: tar -czf /tmp/web3-${{ matrix.node }}.js.tar.gz --exclude="./.git" ./
- uses: actions/upload-artifact@v4
with:
name: web3-${{ matrix.node }}.js.tar.gz
path: /tmp/web3-${{ matrix.node }}.js.tar.gz
black-box:
name: Black Box
needs: build
runs-on: ubuntu-latest
env:
INFURA_MAINNET_HTTP: ${{ secrets.INFURA_MAINNET_HTTP }}
INFURA_MAINNET_WS: ${{ secrets.INFURA_MAINNET_WS }}
INFURA_SEPOLIA_WS: ${{ secrets.INFURA_SEPOLIA_WS }}
MODE: ${{ matrix.mode }}
strategy:
fail-fast: false
matrix:
node: [18]
mode: ['http', 'ws']
backend: ['geth', 'infura']
steps:
- uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node }}
- uses: actions/download-artifact@v4
with:
name: web3-${{ matrix.node }}.js.tar.gz
path: /tmp
- run: tar -xf /tmp/web3-${{ matrix.node }}.js.tar.gz -C ./
- run: |
yarn test:blackbox:${{ matrix.backend }}:${{ matrix.mode }}
shell: bash
6 changes: 3 additions & 3 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ jobs:
- run: yarn test:unit
continue-on-error: ${{ matrix.node == '20.17.0' }}
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v3
uses: codecov/codecov-action@v4
with:
flags: UnitTests
token: ${{ secrets.CODECOV_TOKEN }}
Expand All @@ -162,7 +162,7 @@ jobs:
strategy:
fail-fast: false
steps:
- uses: actions/setup-node@v3
- uses: actions/setup-node@v4
with:
node-version: 18
- uses: actions/cache/restore@v4
Expand Down Expand Up @@ -204,7 +204,7 @@ jobs:
matrix:
browser: ['electron', 'chrome', 'firefox']
steps:
- uses: actions/setup-node@v3
- uses: actions/setup-node@v4
with:
node-version: 18
- uses: browser-actions/setup-firefox@latest
Expand Down
37 changes: 18 additions & 19 deletions .github/workflows/canary_release.yml
Original file line number Diff line number Diff line change
@@ -1,23 +1,22 @@
name: 'Release Canary'
on:
push:
branches:
- '4.x'
push:
branches:
- '4.x'

jobs:
release:
name: release
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 18
cache: yarn
registry-url: 'https://registry.npmjs.org'
- run: yarn install --frozen-lockfile
- run: yarn build:web
- run: yarn publish:canary
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

release:
name: release
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 18
cache: yarn
registry-url: 'https://registry.npmjs.org'
- run: yarn install --frozen-lockfile
- run: yarn build:web
- run: yarn publish:canary
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
8 changes: 4 additions & 4 deletions .github/workflows/deploy-docs.yaml
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
name: Docs CloudFlare Deploy
on:
push:
branches:
- "4.x"
tags-ignore:
- v4*
branches:
- '4.x'
tags-ignore:
- v4*

jobs:
deploy:
Expand Down
90 changes: 45 additions & 45 deletions .github/workflows/e2e_network_tests.yml
Original file line number Diff line number Diff line change
@@ -1,55 +1,55 @@
name: 'E2E Network Tests'
on:
push:
branches:
- release/**
tags:
- v4.*
branches:
- release/**
tags:
- v4.*

# For test purpose only:
# pull_request:
# branches:
# - '4.x'
# types: [ opened, reopened, synchronize ]
jobs:
build:
name: Build Packages
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 18
cache: yarn
- run: yarn
- uses: actions/cache/save@v4
with:
path: ./
key: web3-e2e-18-${{github.sha}}
e2e:
name: E2E Network Tests
needs: build
runs-on: ubuntu-latest
env:
INFURA_SEPOLIA_HTTP: ${{ secrets.CS_ETH_SEPOLIA }}
INFURA_MAINNET_HTTP: ${{ secrets.CS_ETH_MAINNET }}
MODE: ${{ matrix.mode }}
TEST_ACCOUNT_ADDRESS: ${{ fromJSON('{"sepolia":"0xa127C5E6a7E3600Ac34A9a9928E52521677e7211","mainnet":"0x98AF911164f9d4E0f5983ed114949c3Bfe3ADc9d"}')[matrix.network] }}
ALLOWED_SEND_TRANSACTION: ${{ secrets.E2E_TESTS_ALLOWED_SEND_TRANSACTION }}
TEST_ACCOUNT_PRIVATE_KEY: ${{ secrets.TEST_ACCOUNT_PRIVATE_KEY }}
strategy:
fail-fast: false
matrix:
mode: ['http']
network: ['sepolia', 'mainnet']
steps:
- uses: actions/setup-node@v3
with:
node-version: 18
- uses: actions/cache/restore@v4
with:
path: ./
key: web3-e2e-18-${{github.sha}}
- run: |
yarn test:e2e:${{ matrix.network }}:${{ matrix.mode }}
shell: bash
build:
name: Build Packages
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 18
cache: yarn
- run: yarn
- uses: actions/cache/save@v4
with:
path: ./
key: web3-e2e-18-${{github.sha}}
e2e:
name: E2E Network Tests
needs: build
runs-on: ubuntu-latest
env:
INFURA_SEPOLIA_HTTP: ${{ secrets.CS_ETH_SEPOLIA }}
INFURA_MAINNET_HTTP: ${{ secrets.CS_ETH_MAINNET }}
MODE: ${{ matrix.mode }}
TEST_ACCOUNT_ADDRESS: ${{ fromJSON('{"sepolia":"0xa127C5E6a7E3600Ac34A9a9928E52521677e7211","mainnet":"0x98AF911164f9d4E0f5983ed114949c3Bfe3ADc9d"}')[matrix.network] }}
ALLOWED_SEND_TRANSACTION: ${{ secrets.E2E_TESTS_ALLOWED_SEND_TRANSACTION }}
TEST_ACCOUNT_PRIVATE_KEY: ${{ secrets.TEST_ACCOUNT_PRIVATE_KEY }}
strategy:
fail-fast: false
matrix:
mode: ['http']
network: ['sepolia', 'mainnet']
steps:
- uses: actions/setup-node@v4
with:
node-version: 18
- uses: actions/cache/restore@v4
with:
path: ./
key: web3-e2e-18-${{github.sha}}
- run: |
yarn test:e2e:${{ matrix.network }}:${{ matrix.mode }}
shell: bash
32 changes: 16 additions & 16 deletions .github/workflows/stale.yml
Original file line number Diff line number Diff line change
@@ -1,19 +1,19 @@
name: "Close stale issues"
name: 'Close stale issues'
on:
schedule:
- cron: "0 0 * * *"
schedule:
- cron: '0 0 * * *'

jobs:
stale:
runs-on: ubuntu-latest
steps:
- uses: actions/stale@v3
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
stale-issue-message: 'This issue has been automatically marked as stale because it has not had recent activity. It will be closed in 7 days if no further activity occurs. Thank you for your contributions. If you believe this was a mistake, please comment.'
stale-pr-message: 'This PR has been automatically marked as stale because it has not had recent activity. It will be closed in 7 days if no further activity occurs. Thank you for your contributions. If you believe this was a mistake, please comment.'
days-before-stale: 60
days-before-close: 14
operations-per-run: 100
exempt-pr-labels: 'work-in-progress,4.x'
exempt-issue-labels: 'work-in-progress,4.x'
stale:
runs-on: ubuntu-latest
steps:
- uses: actions/stale@v3
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
stale-issue-message: 'This issue has been automatically marked as stale because it has not had recent activity. It will be closed in 7 days if no further activity occurs. Thank you for your contributions. If you believe this was a mistake, please comment.'
stale-pr-message: 'This PR has been automatically marked as stale because it has not had recent activity. It will be closed in 7 days if no further activity occurs. Thank you for your contributions. If you believe this was a mistake, please comment.'
days-before-stale: 60
days-before-close: 14
operations-per-run: 100
exempt-pr-labels: 'work-in-progress,4.x'
exempt-issue-labels: 'work-in-progress,4.x'
2 changes: 1 addition & 1 deletion docs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
"classnames": "^2.3.2",
"clsx": "^2.0.0",
"docusaurus-lunr-search": "^3.3.1",
"prism-react-renderer": "^2.3.0",
"prism-react-renderer": "^2.4.0",
"react": "^18.2.0",
"react-dom": "^18.2.0"
},
Expand Down
Loading

0 comments on commit 7a882b9

Please sign in to comment.