Skip to content

Run a recent full block in the Hardhat Network #829

Run a recent full block in the Hardhat Network

Run a recent full block in the Hardhat Network #829

name: Run a recent full block in the Hardhat Network
on:
schedule:
- cron: "0 */8 * * *"
workflow_dispatch:
defaults:
run:
working-directory: packages/hardhat-core
jobs:
test-recent-mainnet-block:
name: Test recent mainnet block
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Install Rust (stable)
uses: actions-rs/toolchain@v1
with:
profile: minimal
override: true
- uses: Swatinem/rust-cache@v2
- name: Cache EDR RPC cache
uses: actions/cache@v2
with:
path: |
**/edr-cache
key: test-recent-mainnet-block-rpc-cache-v1
- name: Run test
uses: actions-rs/cargo@v1
env:
RUSTFLAGS: ${{ matrix.RUSTFLAGS }}
with:
command: replay-block
args: -u ${{ secrets.ALCHEMY_URL }} -c 1
- name: Notify failures
if: failure()
uses: slackapi/slack-github-action@v1.18.0
with:
payload: |
{
"workflow_name": "${{ github.workflow }}",
"run_url": "${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}"
}
env:
SLACK_WEBHOOK_URL: ${{ secrets.GH_ACTION_NOTIFICATIONS_SLACK_WEBHOOK_URL }}