Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 2 additions & 6 deletions .github/workflows/ci-cosmwasm-contract.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,16 +21,12 @@ jobs:
working-directory: target_chains/cosmwasm/contracts/pyth
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
toolchain: 1.82.0
components: rustfmt, clippy
override: true
- uses: actions-rust-lang/setup-rust-toolchain@v1
- name: Format check
run: cargo fmt --all -- --check
if: success() || failure()
- name: Clippy check
run: cargo clippy --tests -- --deny warnings
run: cargo clippy --all-targets -- --deny warnings
if: success() || failure()
- name: Build
run: cargo build --verbose
Expand Down
13 changes: 3 additions & 10 deletions .github/workflows/ci-fortuna.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,20 +16,13 @@ jobs:
working-directory: apps/fortuna
steps:
- uses: actions/checkout@v2
- uses: Swatinem/rust-cache@v2
with:
workspaces: "apps/fortuna -> target"
- uses: actions-rs/toolchain@v1
with:
toolchain: 1.82.0
override: true
components: rustfmt, clippy
- uses: actions-rust-lang/setup-rust-toolchain@v1
- name: Format check
run: cargo fmt --all -- --check
if: success() || failure()
- name: Clippy check
run: cargo clippy --tests -- --deny warnings
run: cargo clippy -p fortuna --all-targets -- --deny warnings
if: success() || failure()
- name: Run tests
run: cargo test
run: cargo test -p fortuna -- --test-threads=1
if: success() || failure()
3 changes: 1 addition & 2 deletions .github/workflows/ci-fuel-contract.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,8 @@ jobs:
working-directory: target_chains/fuel/contracts/
steps:
- uses: actions/checkout@v2
- uses: Swatinem/rust-cache@v2
with:
workspaces: "target_chains/fuel/contracts -> target"
cache-workspaces: "target_chains/fuel/contracts -> target"
- name: Install Fuel toolchain
run: |
curl https://install.fuel.network | sh
Expand Down
11 changes: 3 additions & 8 deletions .github/workflows/ci-hermes-server.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,9 @@ jobs:
working-directory: apps/hermes/server
steps:
- uses: actions/checkout@v2
- uses: Swatinem/rust-cache@v2
- uses: actions-rust-lang/setup-rust-toolchain@v1
with:
workspaces: "apps/hermes/server -> target"
- uses: actions-rs/toolchain@v1
with:
toolchain: 1.82.0
components: rustfmt, clippy
override: true
cache-workspaces: "apps/hermes/server -> target"
- name: Install protoc
uses: arduino/setup-protoc@v3
with:
Expand All @@ -31,7 +26,7 @@ jobs:
run: cargo fmt --all -- --check
if: success() || failure()
- name: Clippy check
run: cargo clippy --tests -- --deny warnings
run: cargo clippy --all-targets -- --deny warnings
if: success() || failure()
- name: Run executor tests
run: cargo test
Expand Down
13 changes: 2 additions & 11 deletions .github/workflows/ci-lazer-rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,6 @@ jobs:
with:
submodules: recursive
- uses: actions-rust-lang/setup-rust-toolchain@v1
with:
toolchain: 1.82.0
components: clippy,rustfmt
- uses: Swatinem/rust-cache@v2
with:
workspaces: "lazer -> target"
- name: Install Protoc
uses: arduino/setup-protoc@v3
with:
Expand All @@ -45,11 +39,8 @@ jobs:
run: cargo fmt --all -- --check
if: success() || failure()
- name: Clippy check
run: cargo clippy --all-targets -- --deny warnings
if: success() || failure()
- name: Build Solana programs
run: cargo build-sbf
run: cargo clippy -p pyth-lazer-protocol -p pyth-lazer-client -p pyth-lazer-publisher-sdk --all-targets -- --deny warnings
if: success() || failure()
- name: test
run: cargo test
run: cargo test -p pyth-lazer-protocol -p pyth-lazer-client -p pyth-lazer-publisher-sdk
if: success() || failure()
14 changes: 13 additions & 1 deletion .github/workflows/ci-lazer-solana-contract.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:
- uses: actions/checkout@v4
- uses: actions-rust-lang/setup-rust-toolchain@v1
with:
toolchain: 1.82.0
cache-workspaces: "lazer/contracts/solana -> target"
- name: install taplo
run: cargo install --locked [email protected]
- uses: actions/setup-node@v4
Expand All @@ -45,7 +45,19 @@ jobs:
- name: Install Anchor
run: |
rustup install 1.79.0
# anchor requires nightly for ABI generation and it's broken for more recent nightly versions
rustup install nightly-2025-04-15
# This anchor version doesn't build with newer Rust
RUSTFLAGS= cargo +1.79.0 install --git https://github.com/coral-xyz/anchor --tag v0.30.1 --locked anchor-cli
- name: Run anchor tests
run: pnpm run test:anchor
- name: check Cargo.toml formatting
run: find . -name Cargo.toml -exec taplo fmt --check --diff {} \;
- name: Format check
run: cargo fmt --all -- --check
- name: Clippy check
run: cargo clippy --all-targets -- --deny warnings
- name: Build contract
run: cargo build-sbf
- name: test
run: cargo test
23 changes: 13 additions & 10 deletions .github/workflows/ci-message-buffer.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,9 @@ jobs:
steps:
- name: Checkout sources
uses: actions/checkout@v3
- uses: Swatinem/rust-cache@v2
- uses: actions-rust-lang/setup-rust-toolchain@v1
with:
workspaces: "pythnet/message_buffer -> target"
- uses: actions-rs/toolchain@v1
with:
toolchain: 1.66.1
components: rustfmt, clippy
cache-workspaces: "pythnet/message_buffer -> target"
- name: Install Solana
run: |
wget http://nz2.archive.ubuntu.com/ubuntu/pool/main/o/openssl/libssl1.1_1.1.1f-1ubuntu2_amd64.deb
Expand All @@ -32,7 +28,10 @@ jobs:
echo "/home/runner/.local/share/solana/install/active_release/bin" >> $GITHUB_PATH
- name: Install Anchor
run: |
cargo install --git https://github.com/coral-xyz/anchor --tag v0.27.0 anchor-cli --locked
unset CARGO_UNSTABLE_SPARSE_REGISTRY
unset CARGO_REGISTRIES_CRATES_IO_PROTOCOL
# Anchor doesn't build with newer Rust
cargo +1.66.1 install --git https://github.com/coral-xyz/anchor --tag v0.27.0 anchor-cli --locked
- name: Install g++ 12
run: |
sudo apt-get install g++-12
Expand All @@ -50,7 +49,12 @@ jobs:
with:
run_install: true
- name: Build and generate IDLs
run: anchor build
run: |
unset CARGO_UNSTABLE_SPARSE_REGISTRY
unset CARGO_REGISTRIES_CRATES_IO_PROTOCOL
rustup override set 1.66.1
anchor build
rustup override unset
- name: Copy anchor target files
run: cp ./target/idl/message_buffer.json idl/ && cp ./target/types/message_buffer.ts idl/
- name: Fix formatting (to avoid pre-commit failures)
Expand All @@ -64,5 +68,4 @@ jobs:
run: cargo fmt --all -- --check
if: success() || failure()
- name: Cargo clippy
run: cargo clippy --tests -- --deny warnings
if: success() || failure()
run: cargo clippy --all-targets -- --deny warnings
10 changes: 5 additions & 5 deletions .github/workflows/ci-near-contract.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,9 @@ jobs:
working-directory: target_chains/near/receiver
steps:
- uses: actions/checkout@v2
- uses: Swatinem/rust-cache@v2
- uses: actions-rust-lang/setup-rust-toolchain@v1
with:
workspaces: "target_chains/near/receiver -> target"
cache-workspaces: "target_chains/near/receiver -> target"
- name: Test
run: ./workspace-test.sh
reproducible-build:
Expand All @@ -35,11 +35,11 @@ jobs:
working-directory: target_chains/near/receiver
steps:
- uses: actions/checkout@v2
- uses: Swatinem/rust-cache@v2
- uses: actions-rust-lang/setup-rust-toolchain@v1
with:
workspaces: "target_chains/near/receiver -> target"
cache-workspaces: "target_chains/near/receiver -> target"
- run: sudo apt-get update && sudo apt-get install -y libudev-dev
- run: cargo +stable install --locked [email protected]
- run: cargo install --locked [email protected]
- run: cargo near build reproducible-wasm
- name: Upload artifact
uses: actions/upload-artifact@v4
Expand Down
10 changes: 2 additions & 8 deletions .github/workflows/ci-pyth-lazer-agent.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,18 +20,12 @@ jobs:
with:
submodules: recursive
- uses: actions-rust-lang/setup-rust-toolchain@v1
with:
toolchain: 1.87.0
components: clippy,rustfmt
- uses: Swatinem/rust-cache@v2
with:
workspaces: "apps/pyth-lazer-agent -> target"
- name: Format check
run: cargo fmt --all -- --check
if: success() || failure()
- name: Clippy check
run: cargo clippy --all-targets -- --deny warnings
run: cargo clippy -p pyth-lazer-agent --all-targets -- --deny warnings
if: success() || failure()
- name: test
run: cargo test
run: cargo test -p pyth-lazer-agent
if: success() || failure()
13 changes: 3 additions & 10 deletions .github/workflows/ci-pythnet-sdk.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,20 +15,13 @@ jobs:
working-directory: pythnet/pythnet_sdk
steps:
- uses: actions/checkout@v2
- uses: Swatinem/rust-cache@v2
with:
workspaces: "pythnet/pythnet_sdk -> target"
- uses: actions-rs/toolchain@v1
with:
toolchain: 1.82.0
components: rustfmt, clippy
override: true
- uses: actions-rust-lang/setup-rust-toolchain@v1
- name: Format check
run: cargo fmt --all -- --check
if: success() || failure()
- name: Clippy check
run: cargo clippy --tests -- --deny warnings
run: cargo clippy -p pythnet-sdk --all-targets -- --deny warnings
if: success() || failure()
- name: Run executor tests
run: cargo test
run: cargo test -p pythnet-sdk
if: success() || failure()
13 changes: 3 additions & 10 deletions .github/workflows/ci-quorum.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,20 +15,13 @@ jobs:
working-directory: apps/quorum
steps:
- uses: actions/checkout@v2
- uses: Swatinem/rust-cache@v2
with:
workspaces: "apps/quorum -> target"
- uses: actions-rs/toolchain@v1
with:
toolchain: 1.87.0
components: rustfmt, clippy
override: true
- uses: actions-rust-lang/setup-rust-toolchain@v1
- name: Format check
run: cargo fmt --all -- --check
if: success() || failure()
- name: Clippy check
run: cargo clippy --tests -- --deny warnings
run: cargo clippy -p quorum --all-targets -- --deny warnings
if: success() || failure()
- name: Run executor tests
run: cargo test
run: cargo test -p quorum
if: success() || failure()
11 changes: 3 additions & 8 deletions .github/workflows/ci-remote-executor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,14 +16,9 @@ jobs:
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
- uses: actions-rs/toolchain@v1
- uses: actions-rust-lang/setup-rust-toolchain@v1
with:
toolchain: 1.73.0
components: rustfmt, clippy
override: true
- uses: Swatinem/rust-cache@v2
with:
workspaces: "governance/remote_executor -> target"
cache-workspaces: "governance/remote_executor -> target"
- name: Install Solana
run: |
sh -c "$(curl -sSfL https://release.anza.xyz/v1.18.23/install)"
Expand All @@ -32,7 +27,7 @@ jobs:
run: cargo fmt --all -- --check
if: success() || failure()
- name: Clippy check
run: cargo clippy --tests -- --deny warnings
run: cargo clippy --all-targets -- --deny warnings
if: success() || failure()
- name: Run executor tests
run: cargo test-sbf
Expand Down
11 changes: 3 additions & 8 deletions .github/workflows/ci-solana-contract.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,14 +21,9 @@ jobs:
working-directory: target_chains/solana
steps:
- uses: actions/checkout@v2
- uses: Swatinem/rust-cache@v2
with:
workspaces: "target_chains/solana -> target"
- uses: actions-rs/toolchain@v1
with:
toolchain: 1.73.0
components: rustfmt, clippy
override: true
cache-workspaces: "target_chains/solana -> target"
- uses: actions-rust-lang/setup-rust-toolchain@v1
- name: Install Solana
run: |
sh -c "$(curl -sSfL https://release.anza.xyz/v1.17.34/install)"
Expand All @@ -37,7 +32,7 @@ jobs:
run: cargo fmt --all -- --check
if: success() || failure()
- name: Clippy check
run: cargo clippy --tests -- --deny warnings
run: cargo clippy --all-targets -- --deny warnings
if: success() || failure()
- name: Build
run: cargo-build-sbf
Expand Down
7 changes: 2 additions & 5 deletions .github/workflows/ci-starknet-contract.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,9 @@ jobs:
tool-versions: target_chains/starknet/contracts/.tool-versions
- name: Install Starkli
run: curl https://get.starkli.sh | sh && . ~/.config/.starkli/env && starkliup -v $(awk '/starkli/{print $2}' .tool-versions)
- name: Install Rust
uses: actions-rs/toolchain@v1
with:
toolchain: 1.85.0
- uses: actions-rust-lang/setup-rust-toolchain@v1
- name: Install Devnet
run: cargo +1.85.0 install starknet-devnet --version $(awk '/starknet-devnet/{print $2}' .tool-versions)
run: cargo install starknet-devnet --version $(awk '/starknet-devnet/{print $2}' .tool-versions)
- name: Check formatting
run: scarb fmt --check
- name: Run tests
Expand Down
29 changes: 14 additions & 15 deletions .github/workflows/ci-starknet-tools.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,33 +9,32 @@ on:
jobs:
test:
runs-on: ubuntu-latest
defaults:
run:
working-directory: target_chains/starknet/tools/test_vaas
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
toolchain: 1.86.0
components: rustfmt, clippy
override: true
- uses: actions/checkout@v3
- uses: Swatinem/rust-cache@v2
with:
workspaces: "target_chains/starknet/tools/test_vaas -> target"
- uses: actions-rust-lang/setup-rust-toolchain@v1
- name: Install Scarb
uses: software-mansion/setup-scarb@v1
with:
tool-versions: target_chains/starknet/contracts/.tool-versions
- name: Install Starkli
run: curl https://get.starkli.sh | sh && . ~/.config/.starkli/env && starkliup -v $(awk '/starkli/{print $2}' target_chains/starknet/contracts/.tool-versions)
run: |
curl https://get.starkli.sh | sh
. ~/.config/.starkli/env
starkliup -v $(awk '/starkli/{print $2}' ../../contracts/.tool-versions)
echo "${HOME}/.starkli/bin" >> "${GITHUB_PATH}"
- name: Check formatting
run: cargo fmt --manifest-path ./target_chains/starknet/tools/test_vaas/Cargo.toml -- --check
run: cargo fmt -- --check
- name: Run clippy
run: cargo clippy --manifest-path ./target_chains/starknet/tools/test_vaas/Cargo.toml --all-targets -- --deny warnings
run: cargo clippy -p test_vaas --all-targets -- --deny warnings
- name: Run generate_keypair binary
run: cargo run --manifest-path ./target_chains/starknet/tools/test_vaas/Cargo.toml --bin generate_keypair
run: cargo run --bin generate_keypair
- name: Check test data
run: |
. ~/.config/.starkli/env && cargo run --manifest-path ./target_chains/starknet/tools/test_vaas/Cargo.toml --bin generate_test_data > ./target_chains/starknet/contracts/data.cairo
cd target_chains/starknet/contracts && scarb fmt data.cairo
. ~/.config/.starkli/env && cargo run --bin generate_test_data > ../../contracts/data.cairo
cd ../../contracts && scarb fmt data.cairo
if ! diff ./tests/data.cairo data.cairo; then
>&2 echo "Re-run generate_test_data to update data.cairo"
exit 1
Expand Down
Loading
Loading