Skip to content

Commit

Permalink
feat: add support for BSC (#31)
Browse files Browse the repository at this point in the history
* feat: add support for BSC

* fix precompile contracts error

* optimize `specification` setting

* fix lint issues

* fix CI issues

* fix CI issues

* fix CI issues

* fix wrong precompile contracts set

* fix precompile revert error

* add check for bsc precompile

* add `PrecompileError::Reverted`

* fix evm spec for `KEPLER`

* fix CI issues

* add `haber` precompile set and fix errors

* add EIP4844 data fee to `collect_system_reward`

* update bsc feature dep

* fix review comments

* update `tendermint` version
  • Loading branch information
pythonberg1997 authored Jun 18, 2024
1 parent cd1ce9b commit bc30717
Show file tree
Hide file tree
Showing 24 changed files with 2,208 additions and 212 deletions.
45 changes: 30 additions & 15 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,8 @@ jobs:
fail-fast: false
matrix:
rust: ["stable", "beta", "nightly"]
flags: ["--no-default-features", "", "--all-features"]
# flags: ["--no-default-features", "", "--all-features"]
flags: ["--no-default-features", "", "--features bsc", "--features optimism,opbnb"]
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@master
Expand All @@ -31,16 +32,16 @@ jobs:
- uses: Swatinem/rust-cache@v2
- run: cargo test --workspace ${{ matrix.flags }}

# test-no-std:
# name: test no_std
# runs-on: ubuntu-latest
# timeout-minutes: 30
# steps:
# - uses: actions/checkout@v4
# - uses: dtolnay/rust-toolchain@stable
# with:
# targets: riscv32imac-unknown-none-elf
# - run: cargo check --target riscv32imac-unknown-none-elf --no-default-features
# test-no-std:
# name: test no_std
# runs-on: ubuntu-latest
# timeout-minutes: 30
# steps:
# - uses: actions/checkout@v4
# - uses: dtolnay/rust-toolchain@stable
# with:
# targets: riscv32imac-unknown-none-elf
# - run: cargo check --target riscv32imac-unknown-none-elf --no-default-features

check-no-default-features:
name: check no-default-features
Expand Down Expand Up @@ -73,26 +74,40 @@ jobs:
cargo check --no-default-features --features std
clippy:
name: clippy
name: clippy / ${{ matrix.network }}
runs-on: ubuntu-latest
timeout-minutes: 30
strategy:
matrix:
include:
- network: optimism
extra-features: "opbnb"
- network: bsc
extra-features: ""
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
- run: cargo clippy --workspace --all-targets --all-features
- run: cargo clippy --workspace --all-targets --features "${{ matrix.network }} ${{ matrix.extra-features }}"
env:
RUSTFLAGS: -Dwarnings

docs:
name: docs
name: docs / ${{ matrix.network }}
runs-on: ubuntu-latest
timeout-minutes: 30
strategy:
matrix:
include:
- network: optimism
extra-features: "opbnb"
- network: bsc
extra-features: ""
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
with:
components: rust-docs
- run: cargo doc --workspace --all-features --no-deps --document-private-items
- run: cargo doc --workspace --no-deps --document-private-items --features "${{ matrix.network }} ${{ matrix.extra-features }}"
env:
RUSTDOCFLAGS: "--cfg docsrs -D warnings"

Expand Down
Loading

0 comments on commit bc30717

Please sign in to comment.