Skip to content

fix(kad): target the requested bucket when refreshing (#2842) #12122

fix(kad): target the requested bucket when refreshing (#2842)

fix(kad): target the requested bucket when refreshing (#2842) #12122

Workflow file for this run

name: Interoperability Tests
on:
pull_request:
merge_group:
push:
branches:
- master
workflow_dispatch:
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
jobs:
run-transport-interop:
name: Run transport interoperability tests
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v6
- uses: docker/setup-buildx-action@v4
- name: Build image
run: docker build --load -t nim-libp2p-transport-head -f interop/transport/Dockerfile .
- name: Run tests
uses: libp2p/test-plans/.github/actions/run-transport-interop-test@master
with:
test-filter: nim-libp2p-transport-head
# without suffix action fails because "hole-punching-interop" artifacts have
# the same name as "transport-interop" artifacts
test-results-suffix: transport-interop
extra-versions: ${{ github.workspace }}/interop/transport/version.json
worker-count: 4
known-errors: "^(c-v0\\.0\\.1 x nim-libp2p-transport-head \\(quic-v1\\)|eth-p2p-z-v0\\.0\\.1 x nim-libp2p-transport-head \\(quic-v1\\))$"
run-hole-punching-interop:
name: Run hole punching interoperability tests
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v6
- uses: docker/setup-buildx-action@v4
- name: Build image
run: docker build --load -t nim-libp2p-hp-head -f interop/hole-punching/Dockerfile .
- name: Run tests
uses: libp2p/test-plans/.github/actions/run-interop-hole-punch-test@master
with:
test-filter: nim-libp2p-hp-head
extra-versions: ${{ github.workspace }}/interop/hole-punching/version.json
s3-cache-bucket: ${{ vars.S3_LIBP2P_BUILD_CACHE_BUCKET_NAME }}
s3-access-key-id: ${{ vars.S3_LIBP2P_BUILD_CACHE_AWS_ACCESS_KEY_ID }}
s3-secret-access-key: ${{ secrets.S3_LIBP2P_BUILD_CACHE_AWS_SECRET_ACCESS_KEY }}
aws-region: ${{ vars.S3_LIBP2P_BUILD_CACHE_AWS_REGION }}
run-autonatv2-interop:
name: Run AutoNATv2 interoperability tests
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v6
- name: Set up Go
uses: actions/setup-go@v6
with:
go-version: "1.25"
- name: Set up Nim
uses: jiro4989/setup-nim-action@v2
with:
nim-version: "stable"
- name: Run Go and Nim together
run: |
nimble install_pinned
nimble setup
cd interop/autonatv2/go-peer
go mod tidy
go run testautonatv2.go &
cd ../nim-peer
nim r src/nim_peer.nim $(cat ../go-peer/peer.id)
run-kad-interop:
name: Run Kademlia DHT interoperability tests
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v6
- name: Set up Rust
uses: dtolnay/rust-toolchain@stable
with:
toolchain: stable
- name: Set up Nim
uses: jiro4989/setup-nim-action@v2
with:
nim-version: "stable"
- name: Run Nim and Rust together
run: |
nimble install_pinned
nimble setup
cd interop/kad/rust-peer
cargo run &
cd ../nim-peer
nim r src/nim_peer.nim
run-partial-message-interop:
name: Run Partial Message interoperability tests
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v6
- name: Set up Go
uses: actions/setup-go@v6
with:
go-version: "1.25"
- name: Set up Nim
uses: jiro4989/setup-nim-action@v2
with:
nim-version: "stable"
# build go and nim clients first to prevent one from waiting on the other to finish building.
# the go peer runs in the background because the interop test logic is implemented in the nim peer.
- name: Run Interop
run: |
nimble install_pinned
nimble setup
cd interop/partial-message
nim c ./nim-peer/src/peer.nim
go build -C ./go-peer -o peer ./peer.go
./go-peer/peer & ./nim-peer/src/peer